当我使用
>> load disney;
>> hcndl = candle(dis('3/31/98::4/30/98'))
hcndl =
176.0044
178.0032
177.0031
如何使用此句柄更改图表的背景颜色。
谢谢
当我使用
>> load disney;
>> hcndl = candle(dis('3/31/98::4/30/98'))
hcndl =
176.0044
178.0032
177.0031
如何使用此句柄更改图表的背景颜色。
谢谢
我认为您正在寻找 set 功能。Set 函数接受图形的句柄并允许您更改图形的属性。
handle = candle(dis('3/31/98::4/30/98'));
set(handle,'BackgroundColor','blue');
您想要修改轴的颜色。candle
为您提供线条的句柄,其父级是您要修改的轴。
load disney;
hcndl = candle(dis('3/31/98::4/30/98'));
%# find handle to axes using the first of the three handles
%# note that you could have used any of the three
axH = get(hcndl(1),'Parent');
%# modify axes
set(axH,'Color','k') %# black color