Message-ID: <873c91wjza.fsf@lumen.indyrad.iupui.edu>
Date: 2004-02-23T21:42:49Z
From: Michael A. Miller
Subject: R: Including R plots in a Microsoft Word document
>>>>> "Frank" == Frank E Harrell <feh3k at spamcop.net> writes:
> Also, has anyone tried creating a Word document using
> OpenOffice with figures imported from R?
I've tried that. It works fine with openoffice, but not with
word. For example, create a postscript file with R like this:
> postscript('tmp.eps', paper = "special", width=5,height=5, horizontal=F, onefile=F)
> plot(seq(20))
> dev.off()
Then add a preview with epstool -tg --device tiffg3 tmp.eps tmp-tiff.eps
If I insert this figure into an openoffice text document, I see
the bitmap preview and it prints nicely on a postscript printer.
If I save the openoffice document as "Microsoft Word 97/2000/XP",
the figure looks the same on the screen in word as openoffice,
but when I print with word, I just get the bitmap preview, not
the nice postscript. If I print the doc file with openoffice, it
works fine too.
Note that this is all for OpenOffice 1.0.3 and Word 2000 on
windows 2000 pro. I get similar results for openoffice 1.1 on
windows and various linuxes too.
Mike
--
Michael A. Miller mmiller3 at iupui.edu
Imaging Sciences, Department of Radiology, IU School of Medicine