Can I label all similar colored lines in one figure with subplots?

1 回表示 (過去 30 日間)
gsourop
gsourop 2019 年 11 月 4 日
Hi everyone,
I would ilke to label the lines that are getting the data from the same column with a common name, rather than naming the lines per subplot.
In the following example, I would like, for examle, to give a common name to all yellow lines as 'yellow', rather than naming the yellow line on each subplot.
rng(1)
for i = 1:5
A{i} = randn(10,2);
end
for i = 1:5
B1(:,i) = [A{i}(:,1)];
B2(:,i) = [A{i}(:,2)];
end
figure;
subplot(2,2,1)
filename = plot(B1)
hold on
subplot(2,2,2)
filename = plot(B2)
hold on

回答 (0 件)

カテゴリ

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

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by