3D surface plot

조회 수: 3 (최근 30일)
Alan
Alan 2021년 1월 6일
편집: Alan 2021년 1월 12일
Hello,
I have plot a 3d figure. But the height on the z-axis looks like a flat 2d surface.
How can I plot the height and makes the height displays like a 3d surface.
Many thanks!
  댓글 수: 4
VBBV
VBBV 2021년 1월 6일
편집: VBBV 2021년 1월 6일
May be you're equations for Z axis produces flatter surfaces. Or try with varied xlim and ylim range values in meshgrid generation for surf plot
Alan
Alan 2021년 1월 6일
Thanks. The surf plot is what I want to realize.

댓글을 달려면 로그인하십시오.

채택된 답변

Star Strider
Star Strider 2021년 1월 6일
It depends what your data are.
If you are currently using scatter3 or plot3, and your data are reasonably ordered, instead use surf.
If your data are random, create a surface using griddata (or similar functions) to interpolate your point data to a surface that surf can use.
  댓글 수: 2
Alan
Alan 2021년 1월 6일
Thank you. The surf function works here.
Star Strider
Star Strider 2021년 1월 6일
My pleasure!
If my Answer helped you solve your problem, please Accept it!
Also, although I wrote ‘random’ I meant ‘scattered’ .

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Surface and Mesh Plots에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by