exactly | R Documentation |
exactly()
duplicates its input.
It lets you define singleton intervals like this: chop(x, c(1, exactly(2), 3))
.
This is the same as chop(x, c(1, 2, 2, 3))
but conveys your intent more
clearly.
exactly(x)
x |
A numeric vector. |
The same as rep(x, each = 2)
.
chop(1:10, c(2, exactly(5), 8))
# same:
chop(1:10, c(2, 5, 5, 8))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.