change color in loop with scatter3?
Show older comments
Hello i have a matrix of 40 lines and i need to scatter3 in loop need to change the color with p the first 10 lines p equal 1 then automatically will be 2 at the end . i need to give color blue when p=1 and color red p=2 .how to do ?
[nbclass p] = size(Nbrc)
if p ==1
color = 'blue';
elseif p ==2
color
the problem is the color change for all start with blue and end with red . need to have blue for the first 10 and red for the last 30 .
thank you .
Accepted Answer
More Answers (0)
Categories
Find more on Loops and Conditional Statements 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!