How can I change the view of a surface plot from a specified point to a specific direction?

18 views (last 30 days)
Hello everyone,
I want to change the view of my surface plot {} from to a specific direction { & }
At azimuth angle (ϕ)=?
= ; ,
elevation angle
Hence, i want to view the surface from to a direction ( & )
so, how can I perform it? please help...
I have used the surfl() function to plot my 3d surface {}
My Code is as follows:
[xx yy]=meshgrid(x,y);
zz=xx.^2 + yy.^2;
colormap(gray) % change color map
shading interp % interpolate colors across lines and faces
xlabel('x-axis ->')
ylabel('y-axis ->')
zlabel('f(x,y) ->')
title('f(x,y)= x^2 + y^2')
KSSV on 12 Oct 2020
You have two options.
  1. You can use view, campos by providing the viewing point input coordinates.
  2. You can do it manually, you have a rotation icon in the plot. You can click on it and adjuxt to your required view point.

Sign in to comment.

Answers (0)




Community Treasure Hunt

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

Start Hunting!