2014-09-03 74 views
0

我是matlab新手,我有三个单曲线曲线图。我需要将所有曲线合并为一个数字。我该怎么做?Matlab:合并单个图中的所有曲线图

代码:

figure; 
plot(RedInd,hRed); 
leg = legend('Red','Blue','Green') 
title('Histogram Red Channel'); 


figure; 
plot(BlueInd,hBlue); 
title('Histogram Blue Channel'); 

figure; 
plot(GreenInd,hGreen); 
title('Histogram Green Channel'); 
+1

也可以写成'图(RedInd,HRED, 'R',BlueInd,hBlue, 'B',GreenInd,hGreen, 'G');传说( '红', '蓝', '绿')' – bla 2014-09-03 22:51:28

回答

2

你想用 “坚持” 命令。

例如,

plot(x); 
hold on; 
plot(y); 
plot(z); 
hold off;