What's the difference between surf and surface?
34 次查看(过去 30 天)
显示 更早的评论
I think they are essentially the same function? But why do we have both of them? Are there any differences that I should keep in mind when making choices?
0 个评论
采纳的回答
Walter Roberson
2018-11-9
编辑:Walter Roberson
2019-1-2
The difference is that surf checks first to see if the axes Nextplot property says to replace plot, and if so then it does a cla. Then either way it calls surface()
In other words if "hold on" is not in effect (or the internal equivalent) then surf will erase the current plot. surface() will not do that.
The difference is sort of like the difference between line() and plot(). line() never erases the current plot. plot() might erase the current plot, and whether it does or not it will call line to do the drawing work.
4 个评论
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Surface and Mesh Plots 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!