MATLAB: Surface fitting using custom equation

custom equationscriptsurface fit

I want to dynamically fit surface to a data sets using matlab SCRIPT NOT GUI SURFACE FIT TOOLBOX…i.e i have matrices for x, y, z. i want to use the a quadratic polynomial of the form z= c1 + c2*x + c3*x^2 + c4*y +c5*y^2 to fit . using the surface fit operation i would like to retrieve these coefficients c1 thru c5. How can i accomplish this using just a matlab script, not the GUI surface fit tool box. I intend to repeat this procedure for lot many number of data sets. I would highly appreciate your help. Thank you ….
Related Question