Stack lists into data.frames

Description

Takes two types of data: (1) a list of data.frames, (2) a list of vectors, which it interprets as rows of a data.frame

Usage

1
2
  ## S3 method for class 'list'
 stack(x, label = FALSE, ...)

Arguments

x

A list of rbindable objects (typically data.frames)

label

If false, drops labels

...

Ignored

Details

Method of stack for lists of data.frames (e.g. from replicate() ) Takes two types of data:

Value

Typically a data.frame

Examples

1
2
3
dat <- replicate(10, data.frame(x=runif(2),y=rnorm(2)), simplify=FALSE)
str(dat)
stack(dat)

Want to suggest features or report bugs for rdrr.io? Use the GitHub issue tracker.