Lukáš Altman
Lukáš Altman

Reputation: 527

How to connect two points from vector with lines with set y value?

I have a vector a with values

0.4000     0.4604

How to connect points with y value for instance 5 and x values of vector? I mean [0.4 0.46] using a vector and lets say y variable.

a
y = 5

one point is [0.4,5] and the second one [0.4604,5]

Upvotes: 0

Views: 119

Answers (1)

Adam
Adam

Reputation: 2777

X = [0.4, 0.46];
Y = [5, 5];
plot(X, Y);

Upvotes: 1

Related Questions