Put title for each subplot
4 次查看(过去 30 天)
显示 更早的评论
Dear all,
I want to put a subtitle for each subplt. I tried to do, but it didn't work out.
The code is below, Could anyone help me to fix the code? Thanks!
Titileindex=["Group effect" "Condition effect" "Group by Condition"];
Titileindex=["Group effect" "Condition effect" "Group by Condition"];
figure;
for i= 1:3
subplot(3,1,i);
title ('Titleindex(i)');
end
0 个评论
采纳的回答
Star Strider
2019-9-18
Remove the single quotes:
title (Titleindex(i));
and spell the name correctly in both the variable and references to it!
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Title 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!