index_groups: Determine Indices and Sizes of Subsets

View source: R/subsets.R

index_groupsR Documentation

Determine Indices and Sizes of Subsets

Description

Create starting and stopping indices for subsets defined by subset_sizes.

Usage

index_groups(n, k)

Arguments

n

The size of the set.

k

The number of subsets.

Value

A matrix with starting index, size, and stopping index for each subset.

See Also

Other subsetting functions: subset_sizes()

Examples

index_groups(n = 100, k = 6)
index_groups(n = 2, k = 6)

fritools2 documentation built on July 9, 2023, 7:07 p.m.