unstack: Unstack a Vector or Matrix

Description Usage Arguments Value

View source: R/utility.R

Description

Takes a vector or matrix and an index vector and returns a list containing the pieces.

Usage

1
unstack(x, inds, n)

Arguments

x

vector or matrix.

inds

vector indicating how to split x. If not provided then it will automatically attempt to split into equal parts.

n

indicates the number of elements to split into. Only needed when inds is not provided.

Value

list containing the split elements.


wzhorton/ztools documentation built on Nov. 8, 2019, 1:28 p.m.