[R] Some more general questions
vograno at arbitrade.com
Wed Mar 19 21:11:29 CET 2003
The answer to your first question is yes, you can. Under the hood a call
"summary(data[])" invovles an implicit call to print() of the value
returned by summary(). This print produces the output you see. So you need
to suppress the default print and call one of your own, e.g.
> x <- summary(data[]) # no print since the returned value is assigned
A caviat, R will try to print the value returned by my.custom.print. To
suppress it the return value should be made invisible, e.g. put
invisible(NULL) in the end of my.custom.print
> -----Original Message-----
> From: laurent.duperval at microcell.ca
> [mailto:laurent.duperval at microcell.ca]
> Sent: Wednesday, March 19, 2003 11:28 AM
> To: R Help List
> Subject: [R] Some more general questions
> Some general questions. I want to build a web page with
> numerical analysis
> generated by R. I have a few questions:
> - Can I control the output of a function? For example, if I do:
> > summary(data[])
> Min. 1st Qu. Median Mean 3rd Qu. Max.
> 0.0 0.0 120.0 193.3 310.0 10290.0
> can I control the output to be something like
> in order to parse with an external program?
> - Yet another question on histograms: can I produce them with
> strings? I'm guessing I need to map each character value to
> a numerical
> one and use that instead.
> Laurent Duperval <laurent.duperval at microcell.ca>
> "My doctor told me to stop having intimate dinners for four.
> Unless there are
> three other people."
> - Orson Welles
> R-help at stat.math.ethz.ch mailing list
DISCLAIMER\ This e-mail, and any attachments thereto, is intende... [[dropped]]
More information about the R-help