Info

Diese Frage ist geschlossen. Öffnen Sie sie erneut, um sie zu bearbeiten oder zu beantworten.

how can i stack different values on one axis?

1 Ansicht (letzte 30 Tage)
May Ovdat
May Ovdat am 11 Dez. 2019
Geschlossen: MATLAB Answer Bot am 20 Aug. 2021
hi guys
i have about 5 different ranges of the same value omega, from different expirements. i want to showcase them all along the same number line - meaning one axis, as shown here:
dfdfd.JPG
im really looking for one easy function that could help me
thanks!

Antworten (1)

Adam Danz
Adam Danz am 11 Dez. 2019
Bearbeitet: Adam Danz am 16 Dez. 2019
"I'm really looking for one easy function"
plot(X,Y) does that where each column of inputs produces a line. Here's a demo.
x = [69 72; 72.2 72.3; 72.3 72.4; 73.0 73.5; 73.6 74.2]; % x endpoints
y = [2 2; 2.2 2.2; 2.1 2.1; 1.9 1.9; 1.8 1.8 ]; % y values
h = plot(x.',y.');
Now you can edite each line color and other properties using
h(2).Color = 'r';

Community Treasure Hunt

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

Start Hunting!

Translated by