How do add a variable in a plot title
6 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
I have a string called names:
names = {'X4' 'X5' 'X10' 'X13' 'X25' 'X311'};
And I would like my plot title to read
Sample number X5 in experiment
X5 being names(2). How do I insert this into:
title('Sample number __ in experiment')
the underscore being names(2)
0 Kommentare
Antworten (1)
Star Strider
am 19 Jun. 2014
names = {'X4' 'X5' 'X10' 'X13' 'X25' 'X311'};
k1 = 2;
title(sprintf('Sample number %s in experiment',names{k1}))
0 Kommentare
Siehe auch
Kategorien
Mehr zu Title 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!