powered by
list_ones(x)
listify
# 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)
Run the code above in your browser using DataLab