vec_seq_along() is equivalent to seq_along() but uses size, not length. vec_init_along() creates a vector of missing values with size matching an existing object.

## Usage

vec_seq_along(x)

vec_init_along(x, y = x)

x, y

Vectors

## Value

• vec_seq_along() an integer vector with the same size as x.

• vec_init_along() a vector with the same type as x and the same size as y.

## Examples

vec_seq_along(mtcars)
#>  [1]  1  2  3  4  5  6  7  8  9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
#> [24] 24 25 26 27 28 29 30 31 32