Changing the Title of a plot in a nested loop

I have a Nested Loop that runs multiple iterations, and each iteration is going to spit out a plot.
I want to know whether there is a method to get the iteration number in the title itself, i.e "Plot from Run 1"
something like fprinf with strings, but with the title function

 採用された回答

Jos (10584)
Jos (10584) 2019 年 2 月 6 日

0 投票

k = 3 ;
str = sprintf('Run %d', k)
title(str)

その他の回答 (0 件)

カテゴリ

製品

リリース

R2017b

質問済み:

2019 年 2 月 5 日

回答済み:

2019 年 2 月 6 日

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by