Intermingle data points in plot
1 Ansicht (letzte 30 Tage)
Ältere Kommentare anzeigen
Hello,
I have three data categories, which I have to plot in one figure and I want them to be intermingled, ie I don't want the category plotted last to hide the underlying data points of the other categories. In each category there are up to 40000 data points. An obvious way is to go through the data points one by one and plot point 1 of category 1, then point 1 of category 2, point 1 of category 3, point 2 of category 1, etc. - which takes hours to days.
Is there a fast way to plot data points of different categories in an intermingled fashion? Or to plot them and afterwards bring a random subset of the points to the front?
Thank you!
Kem
0 Kommentare
Akzeptierte Antwort
Matt Fig
am 21 Mai 2011
It shouldn't take days to plot even that many points. Please give a small but succinct example which shows what you are doing. Something like:
cat1 = rand(3); % Three categories.
cat2 = rand(3);
cat3 = rand(3);
hold on
for ii = 1:3
plot3(cat1(ii,1),cat1(ii,2),cat1(ii,3),'*r');
plot3(cat2(ii,1),cat2(ii,2),cat2(ii,3),'*b');
plot3(cat3(ii,1),cat3(ii,2),cat3(ii,3),'*y');
end
0 Kommentare
Weitere Antworten (1)
Siehe auch
Kategorien
Mehr zu Line Plots finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!