[R] how to save a heatmap.2 in png /jpeg /tiff
Jeff Newmiller
jdnewmil at dcn.davis.CA.us
Sun Sep 9 17:41:34 CEST 2012
"It just doesn't work" could mean anything... and for those of us for whom it does work, that leaves a lot of possible differences between your case and ours. This is your cue to read the Posting Guide.
Some issues I have encountered:
If you are using Windows, and you have opened a graphics file in an editor, and you try to write a new version out with R, the editor will prevent this change in most cases. You have to remember to close the graphics file first.
Also, you need to remember to close the file in R using dev.off() when you are done writing to it for similar reasons.
---------------------------------------------------------------------------
Jeff Newmiller The ..... ..... Go Live...
DCN:<jdnewmil at dcn.davis.ca.us> Basics: ##.#. ##.#. Live Go...
Live: OO#.. Dead: OO#.. Playing
Research Engineer (Solar/Batteries O.O#. #.O#. with
/Software/Embedded Controllers) .OO#. .OO#. rocks...1k
---------------------------------------------------------------------------
Sent from my phone. Please excuse my brevity.
STADLER Frederic <frederic.stadler at unifr.ch> wrote:
>Hey, I am still working on my heat map (for those who are read my
>previous post about row.names)�
>Now, I would like to save my heat map.2 in .png or .tiff in order being
>able to work on the picture in photoshop, but it doesn't work.
>I'am using (as I have found on some forum)
>> png("heatmap.2.png) # and it just doesn't work. when I try doing it
>with::
>>jpeg("heatmap.2.jpeg) # it works once every 10 times, but it's a 22kb
>file. completely use less !!!
>
>I really need to have high quality image, as I will have to work on
>photoshop and also I will have to cut and zoom in just some lines of my
>heatmap.
>
>#here is the code I use for my heatmap.2 :
>>heatmap.2(a_matrix, Rowv=NA, Colv =NA, col=greenred(60),
>scale="column", margins=c(7,10), trace="none", density.info=c("none"))
>
>Does someone know what I have to do in order to get my heatmap.2.png
>??? Do I need some other package (I only use gplots, to allow the
>heatpmap.2)
>
>THANKS for your help
>Fred
>
> [[alternative HTML version deleted]]
>
>
>
>------------------------------------------------------------------------
>
>______________________________________________
>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