Window title of figures in a for loop

조회 수: 1 (최근 30일)
Debbie Oomen
Debbie Oomen 2017년 11월 3일
댓글: Debbie Oomen 2017년 11월 3일
Please help!
I have two different loops. One that works with ii and one that works with i. Both of these loops need to plot figures but use different files. They are now plotted as follows: figure(i) and figure (ii+3) -- (3 because the i loop only needs to plot 3 figures). How can I change the titles for these figures? So that they correspond with the filename.
  댓글 수: 1
KL
KL 2017년 11월 3일
Do you really need two loops? How many files are you dealing with and what is the significance of having two loops? If you explain a bit more detail, maybe it could be simplified.

댓글을 달려면 로그인하십시오.

채택된 답변

Fangjun Jiang
Fangjun Jiang 2017년 11월 3일
try this, within your loop:
f=figure(i);
title('my title');
set(f,'Name','my window title');
  댓글 수: 1
Debbie Oomen
Debbie Oomen 2017년 11월 3일
This worked great!! Thank you very much

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Title에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by