Legend showing same symbol for loop plot
Mostra commenti meno recenti
My legend is showing the same symbol for different data. My code is as follows
for i=1:size(obs,1)
x = V(:,1)'*obs(i,:)';
y = V(:,2)'*obs(i,:)';
z = V(:,3)'*obs(i,:)';
if(grp{i}=='Cancer')
plot3(x,y,z,'r+','LineWidth',2);
else
plot3(x,y,z,'ko','LineWidth',2);
end
end
xlabel ('V1 modes')
ylabel ('V2 modes')
zlabel ('V3 modes')
legend('Cancer Patients', 'Normal Patients')
In the output, the legend is showins the 'r+' for both cancer patients and normal patients
Risposta accettata
Più risposte (0)
Categorie
Scopri di più su Genomics and Next Generation Sequencing in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!