[R] Problems with png()
Yves Magliulo
ym at climpact.com
Mon Sep 6 15:15:01 CEST 2004
hi,
here some alternative solution.
1-use postscript function then convert it in png in shell with convert
command (higher resolution)
2-use dev2bitmap(file, type = "png256") many other type available
?dev2bitmap for more info
--
------
Yves Magliulo <ym at climpact.com>
R&D Engineer, CLIMPACT
Tel. : +33 (0) 1 44 27 34 31
Fax. : +33 (0) 1 44 27 49 96
Universite Pierre et Marie Curie
Boite 101 - Tour 45 - 5eme etage - Couloir 45/46
4 place Jussieu, 75252 Paris CEDEX 05, France
Le lun 06/09/2004 à 14:58, Laura Quinn a écrit :
> A windows machine?? If you could suggest where I might get my hands on
> one...
>
> AFAIK I'm running the code interactively.
>
> Laura Quinn
> Institute of Atmospheric Science
> School of the Environment
> University of Leeds
> Leeds
> LS2 9JT
>
> tel: +44 113 343 1596
> fax: +44 113 343 6716
> mail: laura at env.leeds.ac.uk
>
> On Mon, 6 Sep 2004, Adaikalavan Ramasamy wrote:
>
> > Try running the codes on a windows machine just to rule out any
> > code-related errors.
> >
> > Also are you running the codes interactively or in the background ?
> >
> > Regards, Adai
> >
> >
> > On Mon, 2004-09-06 at 11:05, Laura Quinn wrote:
> > > On Mon, 6 Sep 2004, Barry Rowlingson wrote:
> > >
> > > > Laura Quinn wrote:
> > > > > I am trying to save a series of plots as .png files by using
> > > > >
> > > > > png(file="myfile.png",bg="transparent")
> > > > > dev.off()
> > > > >
> > > > > for each image plot I produce. Unfortunately when I have tried this I am
> > > > > unable to open the files, and am told they are corrupted.
> > > > >
> > > > > I have tried to use the jpeg() function but have the same problem. The only way I have managed to
> > > > > export a graphic successfully is as dev.copy2eps. Aside from producing
> > > > > unwieldy files, this is also unhelpful as I at m hoping to create a movie of
> > > > > the images via ImageMagick.
> > > > >
> > > >
> > > > This sounds a bit obvious, but are you doing your plot commands
> > > > _between_ the png() call and the dev.off() call?
> > > >
> > > > Try:
> > > >
> > > > png(file="foo.png")
> > > > plot(1:10)
> > > > dev.off()
> > > >
> > > > What version/platform are you using?
> > >
> > > Yes, I have been using the above call to no avail. I'd be suprised if my
> > > libpng wasn't up-to-date on SuSe 9.0, but I'm not sure how to check which
> > > version I have?
> > >
> > > Laura
> > >
> > >
> > > >
> > > > Barry
> > > >
> > > >
> > >
> > > ______________________________________________
> > > R-help at stat.math.ethz.ch mailing list
> > > https://stat.ethz.ch/mailman/listinfo/r-help
> > > PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
> > >
> >
> >
>
> ______________________________________________
> R-help at stat.math.ethz.ch mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html
More information about the R-help
mailing list