how to use more than one color for the plot with respect to the code given below

1 次查看(过去 30 天)
code:
load fisheriris.mat
plot(meas(:,1),meas(:,2),'s')
the plot gives all the points to be in same color.
Could anyone help me how to display the points in different color instead of single color.
  3 个评论
jaah navi
jaah navi 2019-2-10
As fisheriris contains 150 rows first 25 should be in one color,next 25 in another color,next 25 in another color and so on.could you please help me on this

请先登录,再进行评论。

采纳的回答

madhan ravi
madhan ravi 2019-2-10
Since I don't have the data :
R=rand(150,1); % example data
RR=reshape(R,25,[]); % reshape your data into 25 rows
plot(RR)% plots each 25 rows with n colors which is the column
% Remember MATLAB is column dominant

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Line Plots 的更多信息

标签

Community Treasure Hunt

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

Start Hunting!

Translated by