Borrar filtros
Borrar filtros

Set limit for vertical or z dimension in surfl command

1 visualización (últimos 30 días)
ravi shukla
ravi shukla el 29 de Jun. de 2021
Comentada: DGM el 29 de Jun. de 2021
I am plotting my water depth in a physical domain over time with surfl(depth) where depth is a two d matrix. I want to fix vertical limits so that i can visualise the chnage of water level over time.

Respuestas (2)

DGM
DGM el 29 de Jun. de 2021
If you're refreshing the plot in a loop and want the extents of the z-axis fixed, just do
zlim([lowerlimit upperlimit])
  2 comentarios
ravi shukla
ravi shukla el 29 de Jun. de 2021
Editada: ravi shukla el 29 de Jun. de 2021
I have A and B with range 1:20 and C, a matrix that contains 400 (20*20) elements.. each for a combination of A and B.
I WANT TO PLOT THIS C AS VERTICAL AXIS AND A, B ON HORIZONTAL AXIS (as X-Y ) Please help
DGM
DGM el 29 de Jun. de 2021
If you're already plotting using surf() or surfl() or whatever, do that first, then use zlim() to set the axes limits.
The only other thing you would need to do is decide what limits to use. The obvious choice would be the min and max of the dataset.

Iniciar sesión para comentar.


Prakhar Rai
Prakhar Rai el 29 de Jun. de 2021
You could use zlim(limits) to set limit on z dimension.
Please refer : zlims
Also you could create time as a variable and it's variation will provide the results.

Categorías

Más información sobre Surface and Mesh Plots en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by