help on some details of scatterplot
1 visualizzazione (ultimi 30 giorni)
Mostra commenti meno recenti
matteo bottoni
il 7 Lug 2020
Risposto: Image Analyst
il 7 Lug 2020
I would like that the last graph shows the 4 legends (that I put wrongly). Indeed I don't want any legend for line(Total_Matrix(:,1),Total_Matrix(:,2))
I would like also that the x coordinate on Total_Matrix(12,1) will appear not like a number (that is a number) but like the string 'adults'
Obviously Total_matrix is only a dobule matrix
subplot(3,2,1)
scatter(Total_Matrix(1:4,1),Total_Matrix(1:4,2),'r','filled')
legend '<= 1 y.o'
hold on
scatter(Total_Matrix(5:11,1),Total_Matrix(5:11,2),'g','filled')
legend '<= 2 y.o.'
scatter(Total_Matrix(12,1),Total_Matrix(12,2),'k','filled')
legend 'adults'
line(Total_Matrix(:,1),Total_Matrix(:,2))
hline = refline([0 0.68]);
legend 'ST ideal' %refers to refline
hline.Color = 'y';
ylabel ST
xlabel AGE
0 Commenti
Risposta accettata
Image Analyst
il 7 Lug 2020
legend(subset,___) only includes items in the legend for the data series listed in subset. Specify subset as a vector of graphics objects. You can specify subset before specifying the labels or with no other input arguments.
0 Commenti
Più risposte (0)
Vedere anche
Categorie
Scopri di più su Legend in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!