[R] Can not save plot to png file correctly

2010-05-31 Thread Felipe Carrillo
With ggsave the graph windows pops up but using: png("mypng.png") qplot(X, data=data, geom='histogram') + facet_wrap( ~ Y) dev.off() The graph is saved in the background Is there a way to hide the graph window when using ggsave? You can save as png like this too: library(ggplot2) data=data.frame(

Re: [R] Can not save plot to png file correctly

2010-05-31 Thread Felipe Carrillo
You can save as png like this too: library(ggplot2) data=data.frame(   X=sample(10,1000,replace=T)   , Y=letters[1:10]) png("mypng.png") qplot(X, data=data, geom='histogram') + facet_wrap( ~ Y) dev.off()   Felipe D. Carrillo Supervisory Fishery Biologist Department of the Interior US Fish & Wildli