Skip to content

Commit

Permalink
Documentation fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
hadley committed Apr 15, 2009
1 parent 9a66056 commit 83db497
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 6 deletions.
2 changes: 2 additions & 0 deletions ANNOUNCE
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -12,4 +12,6 @@ It's already possible to do this with built-in functions (like split and the app
* progress bars to keep track of long running operations * progress bars to keep track of long running operations
* built-in error recovery, and informative error messages * built-in error recovery, and informative error messages


Some considerable effort has been put into making plyr fast and memory efficient, and in most cases it is faster than the built-in functions.

You can find out more at http://had.co.nz/plyr/, including a 20 page introductory guide, http://had.co.nz/plyr/plyr-intro.pdf. You can ask questions about plyr (and data-manipulation in general) on the plyr mailing list. Sign up at http://groups.google.com/group/manipulatr You can find out more at http://had.co.nz/plyr/, including a 20 page introductory guide, http://had.co.nz/plyr/plyr-intro.pdf. You can ask questions about plyr (and data-manipulation in general) on the plyr mailing list. Sign up at http://groups.google.com/group/manipulatr
1 change: 0 additions & 1 deletion R/ply-list.r
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -90,7 +90,6 @@ llply <- function(.data, .fun = NULL, ..., .progress = "none", .inform = FALSE)
# @arguments other arguments passed on to \code{.fun} # @arguments other arguments passed on to \code{.fun}
# @arguments name of the progress bar to use, see \code{\link{create_progress_bar}} # @arguments name of the progress bar to use, see \code{\link{create_progress_bar}}
# @value if results are atomic with same type and dimensionality, a vector, matrix or array; otherwise, a list-array (a list with dimensions) # @value if results are atomic with same type and dimensionality, a vector, matrix or array; otherwise, a list-array (a list with dimensions)
# @value list of results
#X linmod <- function(df) lm(rbi ~ year, data = transform(df, year = year - min(year))) #X linmod <- function(df) lm(rbi ~ year, data = transform(df, year = year - min(year)))
#X models <- dlply(baseball, .(id), linmod) #X models <- dlply(baseball, .(id), linmod)
#X models[[1]] #X models[[1]]
Expand Down
3 changes: 2 additions & 1 deletion man/data-baseball.rd
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ This data frame contains batting statistics for a subset of players collected fr


Variables: Variables:


\itemize{
\item id, unique player id \item id, unique player id
\item year, year of data \item year, year of data
\item stint \item stint
Expand All @@ -30,7 +31,7 @@ Variables:
\item sh, sacrifice hits \item sh, sacrifice hits
\item sf, sacrifice flies \item sf, sacrifice flies
\item gidp, ground into double play \item gidp, ground into double play

}
} }
\usage{data(baseball)} \usage{data(baseball)}
\format{A 21699 x 22 data frame} \format{A 21699 x 22 data frame}
Expand Down
5 changes: 1 addition & 4 deletions man/dlply-7t.rd
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -15,10 +15,7 @@ For each subset of a data frame, apply function then combine results into a lis
\item{.progress}{name of the progress bar to use, see \code{\link{create_progress_bar}}} \item{.progress}{name of the progress bar to use, see \code{\link{create_progress_bar}}}
\item{.drop}{} \item{.drop}{}
} }
\value{ \value{if results are atomic with same type and dimensionality, a vector, matrix or array; otherwise, a list-array (a list with dimensions)}
\item{if results are atomic with same type and dimensionality, a vector, matrix or array; otherwise, a list-array (a list with dimensions)}
\item{list of results}
}
\details{All plyr functions use the same split-apply-combine strategy: they split the \details{All plyr functions use the same split-apply-combine strategy: they split the
input into simpler pieces, apply \code{.fun} to each piece, and then combine input into simpler pieces, apply \code{.fun} to each piece, and then combine
the pieces into a single data structure. This function splits data frames the pieces into a single data structure. This function splits data frames
Expand Down
3 changes: 3 additions & 0 deletions man/each-4v.rd
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -14,5 +14,8 @@ Combine multiple functions to a single function returning a named vector of outp
\details{Each function should produce a single number as output} \details{Each function should produce a single number as output}


\examples{each(min, max)(1:10) \examples{each(min, max)(1:10)
each("min", "max")(1:10)
each(c("min", "max"))(1:10)
each(c(min, max))(1:10)
each(length, mean, var)(rnorm(100))} each(length, mean, var)(rnorm(100))}
\keyword{manip} \keyword{manip}

0 comments on commit 83db497

Please sign in to comment.