Stacked bar plot, assign "names" to color
3 ビュー (過去 30 日間)
古いコメントを表示

How can I assign names to color? In the figure, say, in the right side list, I will assign "Jack's Contribution" to blue instead of "data 6".
0 件のコメント
回答 (1 件)
Scott MacKenzie
2021 年 6 月 10 日
編集済み: Scott MacKenzie
2021 年 6 月 10 日
Just add labels to your legend:
labels = { 'Jack', 'Fred', 'abc', 'def' }; % fill out, as desired
legend(labels);
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Annotations についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!