id | R Documentation |
Generate a sequence of integers the
length
/ncol
of an object.
id(x, prefix = FALSE, pad = TRUE, ...)
x |
A dataframe, matrix, vector, or list object. |
prefix |
A character string to use as a prefix. |
pad |
logical. If |
... |
Other arguments passed to |
Returns a vector of sequential integers.
id(list(1, 4, 6))
id(matrix(1:10, ncol=1))
id(mtcars)
id(mtcars, TRUE)
id("w")
id(mtcars, prefix="id-")
## Not run:
library(qdap)
question_type(DATA.SPLIT$state, id(DATA.SPLIT, TRUE))
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.