8
Quiero hacerMATLAB - variable en el título parcela
for i = 1 : size(N, 2)
figure(i);
title('N = %d', i);
%other stuff
pero estableciendo el título no funciona. ¿Por qué?
Quiero hacerMATLAB - variable en el título parcela
for i = 1 : size(N, 2)
figure(i);
title('N = %d', i);
%other stuff
pero estableciendo el título no funciona. ¿Por qué?
porque se le olvidó añadir sprintf
for i = 1 : size(N, 2)
figure(i);
title(sprintf('N = %i', i)); %# %i for integer
%other stuff
end
num2str también deberían funciona.
title(['N = ',num2str(i)]);