Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Plotting points while plotting vectors : Matlab

Tags:

plot

matlab

I need to make a plot with only points and tried something like

plot(x,y)

where x and y are vectors: collection of points.

I do not want matlab to connect these points itself. I want to plot as if plotted with

for loop
plot;hold on;
end

I tried

plot(x,y,'.');

But this gave me too thick points.

I do not want to use forloop because it is time expensive. It takes a lot of time.

like image 671
user2178841 Avatar asked Jun 22 '26 14:06

user2178841


2 Answers

You're almost there, just change the MarkerSize property:

plot(x,y,'.','MarkerSize',1)
like image 179
Dan Avatar answered Jun 24 '26 10:06

Dan


Try:

plot(x,y,'*');

or

plot(x,y,'+');

You can take a look to the documentation: http://www.mathworks.nl/help/matlab/creating_plots/using-high-level-plotting-functions.html

like image 45
AitorTheRed Avatar answered Jun 24 '26 11:06

AitorTheRed



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!