Plot with dot and different colors
Show older comments
I am using plot function where i need dots.Also I want to change colors?How can I do it.
plot(x,y,'.');
Above function plot the dots but how I change the dots color red or green,etc The following doesn't work:
plot(x,y,'.','r:');
Suggest any answer or solution..
1 Comment
Alexander Reina Garzon
on 17 Oct 2022
plot(x,y,'r.')
plot(x,y,'o')
plot(x,y,'m')
Accepted Answer
More Answers (2)
Nadeem Tariq Beigh
on 8 Jun 2020
Edited: Nadeem Tariq Beigh
on 8 Jun 2020
1 vote
plot(x,y,'ro');//To plot a red circle
plot(x,y,'r.);//To plot ared dot
Goutham Saravanan
on 21 Sep 2021
0 votes
x = linspace(1*pi,100);
y =
;
plot(x,y,'ro');
xlabel('x')
ylabel('Likelihood ratio for the given conditions')
title('1.2/c')
Categories
Find more on Scatter Plots in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!