Rev 592 | Rev 3791 | Go to most recent revision | Blame | Compare with Previous | Last modification | View Log | Download | RSS feed
\name{system.file}\title{Find Names of R System Files}\usage{system.file(file = "", pkg = .packages(), lib = .lib.loc)}\alias{system.file}\arguments{\item{file}{a character string, specifying subdirectory and file(s).The default, \code{""} returns the root of the base package.}\item{pkg}{a character vector with package names.}\item{lib}{a character vector with path names of \R{} packagelibraries, see \code{\link{.lib.loc}} for the default.}}\description{\code{system.file} returns a character vector of positive length,containing the file names that matched \code{file}, or the emptystring, \code{""}, if none matched.A typical call is \code{fs <- system.file("help/lm")}, followed by\code{if (fs == "") \{ warning(".. not found") \} else \{ \dots \}}.}\examples{system.file("") # The root of the `base' packagesystem.file("INDEX")system.file("demo/*") # nothingsystem.file("help/AnIndex", pkg = c("stepfun", "mva"))system.file("data/w*")}\keyword{file}\keyword{utilities}