How do I make the legend color rectangles smaller?

2 ビュー (過去 30 日間)
Jesús Gutiérrez
Jesús Gutiérrez 2021 年 5 月 20 日
コメント済み: Adriano 2022 年 4 月 7 日
In barplots legends I find too wide the boxes that show each color. I want they to be more like squares so I can have a narrower legend and save space. Is there any way to do it?

回答 (1 件)

Girijashankar Sahoo
Girijashankar Sahoo 2021 年 5 月 20 日
legend({'A','B'},'Position',[0.2 0.6 0.1 0.2])
%% four-element vector of the form [left bottom width height]
  2 件のコメント
Adriano 2022 年 4 月 7 日
Did you fix your problem? I have the same one...





Community Treasure Hunt

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

Start Hunting!

Translated by