Clear Filters
Clear Filters

plotting a 3d graph for a 3d table

5 views (last 30 days)
ammar ansari
ammar ansari on 30 Apr 2024
Commented: Voss on 30 Apr 2024
I have a table and I want to plot a 3d graph for that.

Accepted Answer

Voss
Voss on 30 Apr 2024
M = readmatrix('file.xlsx')
M = 22x10
NaN NaN 0.9200 1.3000 1.6100 2.2000 3.2000 4.1200 13.2000 26.0000 NaN 3.2000 0 0 0 0 0 -0.0200 0.0100 -0.0800 NaN 3.0000 0 0 0 0 0 -0.0200 0.0100 -0.0800 NaN 2.8900 0 0 0 0 0 -0.0200 0.0100 -0.0800 NaN 2.8000 0 0 0 0 0 -0.0200 0.0100 -0.0800 NaN 2.6000 0 0 0 0 0 -0.0200 0.0100 -0.0800 NaN 2.4200 0 0 0 0 0 -0.0200 0.0130 -0.0800 NaN 2.4000 0 0 0 0 0 -0.0200 0.0130 -0.0800 NaN 2.2000 0 0 0 0 0 -0.0500 0.0200 -0.1000 NaN 2.0000 0 0 0 0 0.0200 -0.0600 -0.0050 -0.1200
<mw-icon class=""></mw-icon>
<mw-icon class=""></mw-icon>
x = M(2:end,2);
y = M(1,3:end);
z = M(2:end,3:end);
figure
surf(x,y,z.')

More Answers (0)

Categories

Find more on 2-D and 3-D Plots in Help Center and File Exchange

Tags

Community Treasure Hunt

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

Start Hunting!