stamp-fw: Stamp

stampR Documentation

Stamp

Description

Stamp is like reshape but the "stamping" function is passed the entire data frame, instead of just a few variables.

Usage

stamp(data, formula = . ~ ., fun.aggregate, ..., margins=NULL,
  subset=TRUE, add.missing=FALSE)

Arguments

data

data.frame (no molten)

formula

formula that describes arrangement of result, columns ~ rows, see reshape for more information

fun.aggregate

aggregation function to use, should take a data frame as the first argument

...

arguments passed to the aggregation function

margins

margins to compute (character vector, or TRUE for all margins), can contain grand_row or grand_col to inclue grand row or column margins respectively.

subset

logical vector by which to subset the data frame, evaluated in the context of the data frame so you can

add.missing

fill in missing combinations?

Details

It is very similar to the by function except in the form of the output which is arranged using the formula as in reshape

Note that it's very easy to create objects that R can't print with this function. You will probably want to save the results to a variable and then use extract the results. See the examples.

Author(s)

Hadley Wickham <h.wickham@gmail.com>


reshape documentation built on April 12, 2022, 5:07 p.m.

Related to stamp-fw in reshape...