Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

split_indices

Split indices.


Description

An optimised version of split for the special case of splitting row indices into groups, as used by splitter_d.

Usage

split_indices(group, n = 0L)

Arguments

n

largest integer (may not appear in index). This is hint: if the largest value of group is bigger than n, the output will silently expand.

index

integer indices

Examples

split_indices(sample(10, 100, rep = TRUE))
split_indices(sample(10, 100, rep = TRUE), 10)

plyr

Tools for Splitting, Applying and Combining Data

v1.8.6
MIT + file LICENSE
Authors
Hadley Wickham [aut, cre]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.