Learn R Programming

plyr (version 1.5.1)

strip_splits: Remove splitting variables from a data frame.

Description

Remove splitting variables from a data frame.

Usage

strip_splits(df)

Arguments

df
data frame produced by d*ply.

Details

This is useful when you want to perform some operation to every column in the data frame, except the variables that you have used to split it. These variables will be automatically added back on to the result when combining all results together.

Examples

Run this code
dlply(mtcars, c("vs", "am"))
dlply(mtcars, c("vs", "am"), strip_splits)

Run the code above in your browser using DataLab