plotting a 3d surface using 80 excel files

1 view (last 30 days)
Hi guys, I am really very new to use matlab. I have 80 excel files which each of them have about 54 columns and about 6000 rows. I have to use three of these columns in all the excel files to draw a 3d surface. I can understand how to do them separately, but for simultaneous plotting, the plotting is not possible. After that, I have to demonstrate the highest intensity of an internal factor on this surface with a color bar. I really dont know how to do the first part. glad to help me
  2 Comments
Walter Roberson
Walter Roberson on 3 Sep 2015
Do the columns represent scattered X, Y, Z coordinates? Or is there some structure implied by the rows being adjacent? Is there some structure implied by which excel file it is?
If all of the points are scattered then you have a point cloud. There is no clear way to decide what is "inside" or "outside" a point cloud unless you can impose some rules as to which points connect to the others. There are various ways of fitting surfaces around point clouds.
Shamsoddin Ghiami
Shamsoddin Ghiami on 3 Sep 2015
For each excel file, my x axis is power plant's net electrical output which increases linearly (500 then 501 and ....), my y axis is constant and represents the Amine Scrubber efficiency (For an excel file, it is always constant and other files have different values. for each file, it is always constant) and the z value is completely scattered and does not have any pattern as it is being experimentally obtained.I have to plot all these points in in 3d coordinates and fit a surface to these points for estimation and interpolation

Sign in to comment.

Answers (2)

Image Analyst
Image Analyst on 3 Sep 2015
Not sure what your "first part" is but if it's how to read in the Excel files, you don't want to use xlsread() to read 80 files unless you're prepared to wait an extraordinarily long time. You should use ActiveX (if you're on Windows) and I've attached a demo for that. Just open/launch Excel once, then oepn the 80 workbooks one at a time getting the data out of them, then shutdown Excel once.

Image Analyst
Image Analyst on 3 Sep 2015
If you need to fit a surface to your so-called 3D data to a surface in x-y space, so that you get an estimated Z for each x and y value you might plug in, then try John D.Errico's polyfitn(): http://www.mathworks.com/matlabcentral/fileexchange/34765-polyfitn

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!