|
Thanks to both of you.
Specifically, thank you Matt for the command get(baro,'children').
It seems this still doesn't work the way I expect though.
Maybe it's just a problem with my verion (R2007b), but I want to confirm whether this is really a bug or if it's just a problem with my code.
Can someone check if the same thing happens on their version ??
-----------------------------------------------------
Appears to make bars transparent at RANDOM:
-----------------------------------------------------
figure(1)
for i=1:9
subplot(3,3,i)
x=rand(5,1);y=rand(5,1);bar(x);
hold on
bar(y)
baro = get(gca,'chi');baro1=get(baro,'children');baro2=cell2mat(baro1);set(baro2(1),'facea',0.5,'edgea',0.5)
hold off
end
-----------------------------------------------------
Even if I make a set of COMPLETELY transparent bars, THEN add new bars, the new ones are opaque RANDOMLY:
-----------------------------------------------------
figure(2)
for i=1:9
subplot(3,3,i)
x=rand(5,1);y=rand(5,1);bar(x);
baro = get(gca,'chi');baro1=get(baro,'children');
set(baro1,'facea',0.5,'edgea',0.5)
hold on
bar(y)
hold off
end
-----------------------------------------------------
I'm not sure if this is a bug or just a problem with my code so if someone can check if the same output occurs on their version I'd be very thankful.
Thanks in advance.
|