How to edit surf graph in MATLAB?
Show older comments
Hi. I want plot Matrix to surf 3d graph on left picture, but I plot show on right picture. How to fix or code me for plot graph on left picture?
#Thank you.

6 Comments
Jan
on 20 Jul 2017
Please post the code directly on not a link to a strange download portal. I did not understand, what your code does so far. Does it draw tge picture in the middle? What is the pictuire of the right side?
Wittaya Sata
on 21 Jul 2017
Walter Roberson
on 21 Jul 2017
Part of this appears to be an aspect ratio (or zlim) matter.
However, notice that the one on the left has positive values on Z, whereas the one on the right has negative values on Z. This makes a difference in the colormap use.
Wittaya Sata
on 25 Jul 2017
dbmn
on 26 Jul 2017
If you want to get rid of the minus do:
zlim([-40 0]) % change limits, following walters remark
% now we take care about the minus
zticklabels(num2cell(-zticks)); % This creates new z-labels
Note if you update the zlims, you need to update the labels as well, because labels are just stickers that we put onto the z axis and they do not change when the axis changes.
Wittaya Sata
on 30 Jul 2017
Accepted Answer
More Answers (0)
Categories
Find more on Discrete Data Plots in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!