plot single vector and plot matrix
2 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
piero
am 23 Nov. 2023
Bearbeitet: Dyuman Joshi
am 23 Nov. 2023
TEE =[3 8 9 12 3 2]
TEE1=[98 45 32 45 1 8]
TEE2(1,:)=TEE;
TEE2(2,:)=TEE1;
figure
hold on
plot(TEE)
plot(TEE1)
hold off
figure
plot(TEE2)
but the result is different!
how can build matrix using single vector and plot it?
0 Kommentare
Akzeptierte Antwort
Dyuman Joshi
am 23 Nov. 2023
Bearbeitet: Dyuman Joshi
am 23 Nov. 2023
To get the same result, transpose the array and then plot.
TEE =[3 8 9 12 3 2];
TEE1=[98 45 32 45 1 8];
TEE2(1,:)=TEE;
TEE2(2,:)=TEE1;
figure
hold on
plot(TEE)
plot(TEE1)
hold off
figure
%% Plot the transpose of the array
plot(TEE2.')
0 Kommentare
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Line Plots finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!