From: Whit Armstrong <whit_at_twinfieldscapital.com>

Date: Thu 21 Jul 2005 - 01:27:29 EST

Date: Thu 21 Jul 2005 - 01:27:29 EST

I have a package which I use to create excel files from R.

Have a look at the examples below. If it suits your needs, I will send it to you.

Cheers,

Whit

Here are the examples from the help page:

nc <- 4 nr <- 20 x <- matrix(rnorm(nc*nr),ncol=nc,nrow=nr) rownames(x) <- rep(letters,length=nr) colnames(x) <- rep(letters,length=nc) # write a matrix write.xls(x,"matrixFromR.xls","matrix") write.xls(x,"matrixFromR.no.colnms.xls","matrix",writeColNms=FALSE) write.xls(x,"matrix.no.rownms.xls","matrix",writeRowNms=FALSE)

write.xls(x,"matrix.no.nms.xls","matrix",writeColNms=FALSE,writeRowNms=F
**ALSE)
**
# add some formats

write.xls(x,"matrixFromR_formatted.xls","matrix",formats=rep("0.0",nc))

write.xls(x,"matrixFromR_formatted2.xls","matrix",formats=rep(c("0.0","0 "),nc/2))

write.xls(x,"matrixFromR_formatted3.xls","matrix",formats=rep("#,##0.0;[ Red]#-##0.0;\"\"",nc))

write.xls(x[,1],"vectorFromR.xls","vector")

write.xls(x[,1],"vectorFromR.no.colnms.xls","vector",writeColNms=FALSE)

write.xls(x[,1],"vectorFromR.no.rownms.xls","vector",writeRowNms=FALSE)

write.xls(x[,1],"vectorFromR.no.nms.xls","vector",writeColNms=FALSE,writ eRowNms=FALSE)

# char data test y <- matrix(rep(letters,each=26),ncol=26) rownames(y) <- rep(letters,length=26) colnames(y) <- rep(letters,length=26) write.xls(y,"char.data.xls","alphabet") # logical data test z <- matrix(as.logical(round(runif(nc*nr),0)),ncol=nc) rownames(z) <- rep(letters,length=nr) colnames(z) <- rep(letters,length=nc) write.xls(z,"logical.data.xls","myLogic") write.xls(z[,1],"logical.data.vector.xls","myLogicVector")

-----Original Message-----

From: r-help-bounces@stat.math.ethz.ch

[mailto:r-help-bounces@stat.math.ethz.ch] On Behalf Of Wensui Liu
Sent: Wednesday, July 20, 2005 10:56 AM

To: Greg Snow

Cc: r-help@stat.math.ethz.ch

Subject: Re: [R] Is it possible to create highly customized report in
*.xlsformat by using R/S+?

I appreciate your reply and understand your point completely. But at times we can't change the rule, the only choice is to follow the rule. Most deliverables in my work are in excel format.

On 7/20/05, Greg Snow <greg.snow@ihc.com> wrote:

*> See:
**>
*

> http://www.burns-stat.com/pages/Tutor/spreadsheet_addiction.html

*> and
**> http://www.stat.uiowa.edu/~jcryer/JSMTalk2001.pdf
**>
**> Greg Snow, Ph.D.
**> Statistical Data Center, LDS Hospital
**> Intermountain Health Care
**> greg.snow@ihc.com
**> (801) 408-8111
**>
**> >>> Wensui Liu <liuwensui@gmail.com> 07/19/05 03:22PM >>>
**> I remember in one slide of Prof. Ripley's presentation overhead, he
**> said the most popular data analysis software is excel.
**>
**> So is there any resource or tutorial on this topic?
**>
**> Thank you so much!
**>
**> ______________________________________________
**> R-help@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
**>
**>
*

-- WenSui Liu, MS MA Senior Decision Support Analyst Division of Health Policy and Clinical Effectiveness Cincinnati Children Hospital Medical Center ______________________________________________ R-help@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@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.htmlReceived on Thu Jul 21 01:40:30 2005

*
This archive was generated by hypermail 2.1.8
: Fri 03 Mar 2006 - 03:33:53 EST
*