How to set axis of a plot to correspond to their values.
1 visualización (últimos 30 días)
Mostrar comentarios más antiguos
Joseph Lee
el 14 de Dic. de 2017
Comentada: Adam
el 14 de Dic. de 2017
x = 10:0.05:30;
z = 1:0.005:3;
[X,Z] = ndgrid(x,z);
mesh(X,Z,Y)
This is the plotting code, however the surface i got does not scale accordingly. It gives a scale of equal length for x and z instead of having z shorter and x longer. How do i adjust this such that the plot actually shows that the length of z axis is e.g 2 while length of x axis is a longer 20.
0 comentarios
Respuesta aceptada
Adam
el 14 de Dic. de 2017
Editada: Adam
el 14 de Dic. de 2017
doc pbaspect
doc daspect
can be used to control the aspect ratio of the plotting area and the data.
Also
axis equal
will set the true [1 1 1] aspect ratio.
2 comentarios
Adam
el 14 de Dic. de 2017
You need to use one of the two functions I mentioned first to give more specific control over the aspect ratios.
Más respuestas (0)
Ver también
Categorías
Más información sobre Surface and Mesh Plots en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!