Skip to content

More along functions? #122

@hadley

Description

@hadley

I wonder if it would be useful to have:

list_along <- function(x) {
  vector("list", length(x)
}

rep_along <- function(x, y) {
   rep(x, length.out = length(y))
}

I find myself reaching for those functions (by analogy to seq_along()) fairly frequently

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions