I want to perform a 2 variable (linear) regression according to the following bilinear equation:
f(x,y) = a + b*x + c*y + d*x*y,
where the f(x,y) data is, for example, given by the following matrix:
x\y 6.0 7.0 8.0 9.0
00000 005804.69 007999.53 009833.15 011476.38
00150 005573.34 007821.44 009687.63 011353.49
00500 005161.67 007488.53 009408.31 011112.30
01000 004718.80 007097.39 009060.98 010801.41
01500 004374.67 006773.64 008760.04 010523.11
02000 004082.90 006493.12 008492.45 010269.24
02500 003819.52 006240.45 008248.46 010035.37
03000 003571.24 006005.50 008021.36 009815.34
I have found a couple of ways to interpolate (e.g. passing arguments to a function for fitting), but it seems the x and y values must have the same dimension.
Thanks!