
David,
 
For me, on a windows machine, help(package=) results in a summary window opening in R rather than the detailed help manual that is available through CRAN.  Others suggested help.start() which takes me to a CRAN library site but requires me to still click with the mouse to locate the manual for the specific package.  My function:
 
manual <- function(library){
    
LIB <- substitute(library)
LIB <- as.character(LIB)
browseURL(paste("http://cran.r-project.org/web/packages/",LIB,"/",LIB,".pdf", sep = ""))
}
 
...takes you right to the online package.  Does R have a similar function already that opens the detailed pdf as the vignette function does.  I don't know if the help manuals are downloaded automatically when I download a package but this would be even better as I would not require internet access to retieve the help manual.  If r doesn't have a function to do this but does download the help manuals automatically when I download a package I could use shell.exec()  with the library file path to do the same thing as the function above.  Again this is all provided that R does not already have a function to do this, however, I'm guessing there is because of the existance of the vignette() function
 
Cheers
Tyler

 

> CC: gunter.berton@gene.com; r-help@r-project.org
> From: dwinsemius@comcast.net
> To: tyler_rinker@hotmail.com
> Subject: Re: [R] Opening package manual from within R
> Date: Tue, 23 Aug 2011 18:22:38 -0400
> 
> 
> Try:
> 
> help(package=tm)
> 
> (You do not need library(). )
> -- 
> David.
> 
> On Aug 23, 2011, at 6:17 PM, Tyler Rinker wrote:
> 
> >
> > I don't think help.start is what I'm looking for but I may be doing 
> > it wrong. I tried:
> >
> > library(tm)
> > help.start("tm")
> >
> > This may be inappropriate as it returns:
> >
> >> library(tm)
> >> help.start("tm")
> > Error in if (update) make.packages.html(temp = TRUE) :
> > argument is not interpretable as logical
> >
> > Just typing help.start() takes me to a web page but I still have to 
> > search.
> >
> > I wrote a function to do what I want that I could place in 
> > my .First() or a premade package but why bother if there's a way to 
> > already do this?
> > #=============================================================
> > # FUNCTION
> > #=============================================================
> > manual <- function(library){
> >
> > LIB <- substitute(library)
> > LIB <- as.character(LIB)
> > browseURL(paste("http://cran.r-project.org/web/ 
> > packages/",LIB,"/",LIB,".pdf", sep = ""))
> > }
> >
> > #=============================================================
> > # EXAMPLES
> > #=============================================================
> > manual(plyr)
> > manual(tm)
> >
> >
> >
> >
> >
> >> Date: Tue, 23 Aug 2011 15:10:51 -0700
> >> Subject: Re: [R] Opening package manual from within R
> >> From: gunter.berton@gene.com
> >> To: tyler_rinker@hotmail.com
> >> CC: r-help@r-project.org
> >>
> >> After loading the package, does help.start() do what you want?
> >>
> >> -- Bert
> >>
> >> On Tue, Aug 23, 2011 at 2:32 PM, Tyler Rinker <tyler_rinker@hotmail.com 
> >> > wrote:
> >>>
> >>> Simple question but searching rseek did not yield the results I 
> >>> wanted.
> >>>
> >>> Question: Is there a way to open a help manual for a package from 
> >>> within R.
> >>>
> >>> For instance I would like to type a function in r for the tm 
> >>> package and R would open that PDF as seen here:
> >>> http://cran.r-project.org/web/packages/tm/tm.pdf
> >>>
> >>> -The vignette function exists for vignettes 
> >>> [vignette("package.name")] so I assume the same exists for manuals.
> >>>
> >>> -I do not want library(help="package.name") as this is not 
> >>> detailed enough.
> >>>
> >>> I am running R 2.14.0 beta on a windows 7 machine
> >>> Reproducible code does not seem appropriate in this case.
> >>> [[alternative HTML version deleted]]
> >>>
> >>> ______________________________________________
> >>> R-help@r-project.org mailing list
> >>> 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.
> >>>
> > 
> > [[alternative HTML version deleted]]
> >
> > ______________________________________________
> > R-help@r-project.org mailing list
> > 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.
> 
> David Winsemius, MD
> West Hartford, CT
> 
 		 	   		  
	[[alternative HTML version deleted]]

