[R] help cannot put multiple chart Stacked Bar (from PerformanceAnalysis library) in a single plot

salmajj at softhome.net salmajj at softhome.net
Tue Nov 9 22:41:25 CET 2010


Hi,
try
> par(new=T)

patrick nguyen writes: 

> Hi 
> 
> I'm having problems displaying multiple chart.StackedBar from 
> PerformanceAnalysis library on a  single plot. I've tried using 
> par(mfrow=c(2,1)) but that doesn't work. 
> 
> If I do it with barplot(), it works fine and I see both plots on a single plot. 
> 
>> plot(mfrow=c(2,1))
>> barplot(blahblah)
>> barplot(blahblah)
> 
> However if I try to use chart.StackedBar, the second entry appears to just 
> overwrite the window. 
> 
>> plot(mfrow=c(2,1))
>> chart.StackedBar(blahblah,date.format="%H:%M:%S",las=2, 
>>colorset=rainbow12equal)
>> chart.StackedBar(blahblah,date.format="%H:%M:%S",las=2, 
>>colorset=rainbow12equal)
> 
> Any suggestions are greatly appreciated! 
> 
> -patrick 
> 
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.



More information about the R-help mailing list