The R Project SVN R

Rev

Rev 61769 | Rev 65999 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 61769 Rev 63010
Line 1... Line 1...
1
% File src/library/utils/man/getParseData.Rd
1
% File src/library/utils/man/getParseData.Rd
2
% Part of the R package, http://www.R-project.org
2
% Part of the R package, http://www.R-project.org
3
% Copyright 2012 R Core Team
3
% Copyright 2012-3 R Core Team
4
% Distributed under GPL 2 or later
4
% Distributed under GPL 2 or later
5
 
5
 
6
\newcommand{\CRANpkg}{\href{http://CRAN.R-project.org/package=#1}{\pkg{#1}}}
6
\newcommand{\CRANpkg}{\href{http://CRAN.R-project.org/package=#1}{\pkg{#1}}}
7
 
7
 
8
\name{getParseData}
8
\name{getParseData}
Line 27... Line 27...
27
  }
27
  }
28
  \item{includeText}{
28
  \item{includeText}{
29
    logical; whether to include the text of parsed items in the result
29
    logical; whether to include the text of parsed items in the result
30
  }
30
  }
31
  \item{parseData}{
31
  \item{parseData}{
32
    a dataframe returned from \code{getParseData}
32
    a data frame returned from \code{getParseData}
33
  }
33
  }
34
  \item{id}{
34
  \item{id}{
35
    a vector of item identifiers whose text is to be retrieved
35
    a vector of item identifiers whose text is to be retrieved
36
  }
36
  }
37
}
37
}
Line 44... Line 44...
44
  parsed code, and retrieved by the \code{getParseData} function.
44
  parsed code, and retrieved by the \code{getParseData} function.
45
}
45
}
46
\value{
46
\value{
47
  For \code{getParseData}:\cr
47
  For \code{getParseData}:\cr
48
  If parse data is not present, \code{NULL}.  Otherwise
48
  If parse data is not present, \code{NULL}.  Otherwise
49
  a dataframe is returned, containing the following columns:
49
  a data frame is returned, containing the following columns:
50
  \item{line1}{integer. The line number where the item starts.  This is the
50
  \item{line1}{integer. The line number where the item starts.  This is the
51
    parsed line number called \code{"parse"} in \code{\link{getSrcLocation}},
51
    parsed line number called \code{"parse"} in \code{\link{getSrcLocation}},
52
    which ignores \verb{#line} directives.}
52
    which ignores \verb{#line} directives.}
53
  \item{col1}{integer. The column number where the item starts.  The first character
53
  \item{col1}{integer. The column number where the item starts.  The first character
54
    is column 1.  This corresponds to \code{"column"} in \code{\link{getSrcLocation}}.}
54
    is column 1.  This corresponds to \code{"column"} in \code{\link{getSrcLocation}}.}
Line 61... Line 61...
61
    a leaf in the parse tree.}
61
    a leaf in the parse tree.}
62
  \item{text}{character. If \code{includeText} is \code{TRUE}, the
62
  \item{text}{character. If \code{includeText} is \code{TRUE}, the
63
    text of all tokens; if it is \code{NA} (the default), the text of terminal
63
    text of all tokens; if it is \code{NA} (the default), the text of terminal
64
    tokens.  If \code{includeText == FALSE}, this column is not included.}
64
    tokens.  If \code{includeText == FALSE}, this column is not included.}
65
 
65
 
66
  The rownames of the dataframe will be equal to the \code{id} values,
66
  The rownames of the data frame will be equal to the \code{id} values,
67
  and the dataframe will have a \code{"srcfile"} attribute containing
67
  and the data frame will have a \code{"srcfile"} attribute containing
68
  the \code{\link{srcfile}} record which was used.  The rows will be
68
  the \code{\link{srcfile}} record which was used.  The rows will be
69
  ordered by starting position within the source file, with parent items
69
  ordered by starting position within the source file, with parent items
70
  occurring before their children.
70
  occurring before their children.
71
 
71
 
72
  For \code{getParseText}:\cr
72
  For \code{getParseText}:\cr