demo code for R package
3
0
Entering edit mode
shirley zhang ★ 1.0k
@shirley-zhang-2038
Last seen 10.2 years ago
Dear List, Does anybody know a better way to run the demo code in users guide of each package? What I am doing now is copying each line into R to see the results. -- Xiaoling
• 1.0k views
ADD COMMENT
0
Entering edit mode
Patrick Aboyoun ★ 1.6k
@patrick-aboyoun-6734
Last seen 10.2 years ago
United States
Shirley, If the vignette was written in a Sweave format, which it should have been, the Stangle function from the tools package and the Stangle command from R CMD will create an R script that you can source or execute line by line. See library(tools) help(Stangle) from within R or R CMD Stangle --help from the OS command prompt for more information. Patrick shirley zhang wrote: > Dear List, > > Does anybody know a better way to run the demo code in users guide of > each package? What I am doing now is copying each line into R to see > the results. > >
ADD COMMENT
0
Entering edit mode
@steve-lianoglou-2771
Last seen 21 months ago
United States
Hi Shirley, On May 4, 2009, at 12:11 PM, shirley zhang wrote: > Dear List, > > Does anybody know a better way to run the demo code in users guide of > each package? What I am doing now is copying each line into R to see > the results. Use the `example` function. So, say I'd like to run the example code listed at the bottom of the `lapply` help page, I'd simply type: R> example(lapply) -steve -- Steve Lianoglou Graduate Student: Physiology, Biophysics and Systems Biology Weill Medical College of Cornell University http://cbio.mskcc.org/~lianos
ADD COMMENT
0
Entering edit mode
James F. Reid ▴ 610
@james-f-reid-3148
Last seen 10.2 years ago
Hi Shirley, try ?demo and ?example HTH. J. shirley zhang wrote: > Dear List, > > Does anybody know a better way to run the demo code in users guide of > each package? What I am doing now is copying each line into R to see > the results. >
ADD COMMENT

Login before adding your answer.

Traffic: 609 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6