How to extract specific data?
1 visualización (últimos 30 días)
Mostrar comentarios más antiguos
hj lee
el 6 de Oct. de 2020
Comentada: Star Strider
el 6 de Oct. de 2020
Hello,
a1 = [10 20 30 40 50 60];
b1 = [11 21 31 41 51 61];
c1 = [12 22 32 42 52 62];
- I want to extract specific data such as
A1 = [10 11 12]
B1 = [20 21 22]
C1 = [30 31 32]
....
F2 = [60 61 62]
and plus,
2. e = [0 3 6];
I want to figure A1,B1,C1,....F1 in one figure,
plot(e,A1,e,B1,.....)
but it has too much groups(A1,B1,C1,...) , so I can't use 'hold on' and plot each group or array each groups.
Could someone know how to plot all groups at one figure?
Thanks for helping me.
0 comentarios
Respuesta aceptada
Star Strider
el 6 de Oct. de 2020
Try this:
a1 = [10 20 30 40 50 60];
b1 = [11 21 31 41 51 61];
c1 = [12 22 32 42 52 62];
e = [0 3 6];
abc = cat(1, a1, b1, c1);
figure
plot(e, abc, '-x')
grid
producing:
2 comentarios
Más respuestas (0)
Ver también
Categorías
Más información sobre Annotations 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!