How to move a lengend to the front with subplots

12 ビュー (過去 30 日間)
Al
Al 2015 年 8 月 16 日
コメント済み: Zong-Jhen Ye 2022 年 5 月 11 日
Hi have a figure with two subplots. The data for the legend comes from the top subplot. There is some empty space on the bottom subplot. When I drag the legend to the bottom subplot is disappears behind the plot.
I tried
I=legend({'$100 \hspace mm^{2}$'},'Location','southwest')
set(I, 'Interpreter', 'latex','Visible', 'on')
uistack(I,'up',200)
no joy
  3 件のコメント
Al
Al 2015 年 8 月 16 日
編集済み: Al 2015 年 8 月 16 日
Thanks. I tried
uistack(I,'top')
however the legend is still behind the lower sub plot. I am using 2015a.
Zong-Jhen Ye
Zong-Jhen Ye 2022 年 5 月 11 日
Hi, I have the same problem and I use the following method to solve it:
figure()
subplot(2,2,2)...
subplot(2,2,3)...
subplot(2,2,4)...
subplot(2,1,1)...
legend('Put what you want here')

サインインしてコメントする。

回答 (0 件)

カテゴリ

Help Center および File ExchangeLegend についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by