how to plot a matrix with vector ??

 Respuesta aceptada

Star Strider
Star Strider el 6 de Mzo. de 2018
Depending on what you want, one of these will work:
A=[ 1 2 3 ; 4 5 6; 7 8 9];
B=1:3;
figure(1)
plot(B, A)
grid
figure(2)
surf(A)
set(gca, 'XTick',B)
grid on
If you want a 2D version of the surf plot, add:
view(0, 90)
after it.
Experiment to get the result you want.

Más respuestas (0)

Categorías

Más información sobre 2-D and 3-D Plots en Centro de ayuda y File Exchange.

Preguntada:

el 6 de Mzo. de 2018

Respondida:

el 6 de Mzo. de 2018

Community Treasure Hunt

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

Start Hunting!

Translated by