The R Project SVN R

Rev

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

Rev 24798 Rev 24810
Line 1... Line 1...
1
\name{dataframeHelpers}
1
\name{dataframeHelpers}
2
\title{Data Frame Auxiliary Functions}
2
\title{Data Frame Auxiliary Functions}
3
\alias{row.names}
-
 
4
\alias{row.names.data.frame}
-
 
5
\alias{row.names.default}
-
 
6
\alias{row.names<-}
-
 
7
\alias{row.names<-.data.frame}
-
 
8
\alias{row.names<-.default}
-
 
9
\alias{xpdrows.data.frame}
3
\alias{xpdrows.data.frame}
10
\description{
4
\description{
11
  Auxiliary functions for use with data frames.
5
  Auxiliary functions for use with data frames.
12
}
6
}
13
\usage{
7
\usage{
14
row.names(x)
-
 
15
row.names(x) <- value
-
 
16
 
-
 
17
xpdrows.data.frame(x, old.rows, new.rows)
8
xpdrows.data.frame(x, old.rows, new.rows)
18
}
9
}
19
\arguments{
10
\arguments{
20
  \item{x}{object of class \code{data.frame}.}
11
  \item{x}{object of class \code{data.frame}.}
21
  \item{value}{a vector with the same length as the number of rows of
-
 
22
    \code{x}, to be coerced to character.  Duplicated or missing values
-
 
23
    are not allowed.}
-
 
24
  \item{old.rows, new.rows}{row names for old and new rows.}
12
  \item{old.rows, new.rows}{row names for old and new rows.}
25
}
13
}
26
\value{
14
\details{
27
  \code{row.names} can be used to set and retrieve the row names of a
-
 
28
  data frame, similarly to \code{\link{rownames}} for arrays (and
-
 
29
  it is a generic function that calls \code{rownames} for an
-
 
30
  array argument).}
-
 
31
 
-
 
32
  \code{xpdrows.data.frame} is an auxiliary function which expands the
15
  \code{xpdrows.data.frame} is an auxiliary function which expands the
33
  rows of a data frame.  It is used by the data frame methods of
16
  rows of a data frame.  It is used by the data frame methods of
34
  \code{[<-} and \code{[[<-} (which perform subscripted assignments on a
17
  \code{[<-} and \code{[[<-} (which perform subscripted assignments on a
35
  data frame), and not intended to be called directly.
18
  data frame), and not intended to be called directly.
36
}
19
}
37
\references{
-
 
38
  Chambers, J. M. (1992)
-
 
39
  \emph{Data for models.}
-
 
40
  Chapter 3 of \emph{Statistical Models in S}
-
 
41
  eds J. M. Chambers and T. J. Hastie, Wadsworth \& Brooks/Cole.
-
 
42
}
-
 
43
\seealso{
20
\seealso{
44
  \code{\link{data.frame}}
21
  \code{\link{[.data.frame}}
45
}
22
}
46
\keyword{classes}
-
 
47
\keyword{methods}
23
\keyword{internal}