% volume (cm^3)  area (cm^2) weight (g)
data = [885 382 800
1016 468 950
1125 387 1050
239 371 350
701 371 750
641 367 600
1228 396 1075
412 0 250
953 0 700
929 0 650
1492 0 975
419 0 350
1010 0 950
595 0 425
1034 0 725];

b=data(:,3);
A=[ones(15,1) data(:,1:2)];

beta=A\b;
x=data(:,1);
y=data(:,2);
figure(1),clf
plot3(x,y,b,'o'),hold

fit = beta(1)+beta(2)*x+beta(3)*y;

x0=[200, 200, 1300,1300];
y0=[0, 500, 500,0];
fit0 = beta(1)+beta(2)*x0+beta(3)*y0;
fill3(x0,y0,fit0,'r'),alpha(0.3)
grid on
[r2 rmse] = rsquare(b,fit) %  Root mean squared error (RMSE).