To add to what David said, maybe you want ?sink or ?capture.output . If you're really looking to combine your own text and R output, than knitr is probably what you want. The RStudio ide integrates this stuff, so you may want to look at that, too.
Cheers, Bert Bert Gunter "The trouble with having an open mind is that people keep coming along and sticking things into it." -- Opus (aka Berkeley Breathed in his "Bloom County" comic strip ) On Fri, May 6, 2016 at 4:11 PM, Ashta <sewa...@gmail.com> wrote: > Hi all, > > I am trying to ge get the next month of the year. > > today <- Sys.Date() > xx<- format(today, format="%B%Y") > > I got "May2016", but I want Jun2016. How do I do that? > > My other question is that, I read a data and do some analysis and I > want to send all the results of the analysis to a pdf file > > Example > x5 <- runif(15, 5.0, 7.5) > x5 > > > I tried this one > > pdf(file=" test.pdf") > x5 > dev.off() > > I found the file is empty. I would appreciate if you help me out. > > Thanks in advance > > ______________________________________________ > R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see > 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. ______________________________________________ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see 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.