list_ones: List with vectors of ones

View source: R/list_ones.r

list_onesR Documentation

List with vectors of ones

Description

Create a list with vectors of ones from a numeric vector

Usage

  list_ones(x)

Arguments

x

a numeric vector

Value

A list of vectors with ones

Author(s)

Gaston Sanchez

See Also

listify

Examples

# let's say you have a numeric vector like this
num_vec = c(2, 3, 1, 4)

# get indices in vector format
list_ones(num_vec)

turner documentation built on May 29, 2024, 2:44 a.m.