R/safe_rownames.R

Defines functions safe_rownames

safe_rownames <- function(x) {

  `if`(is.null(rownames(x)),
       sprintf("seq_%03d", seq_len(nrow(x))),
       rownames(x))
}

Try the agvgd package in your browser

Any scripts or data that you put into this service are public.

agvgd documentation built on Sept. 11, 2022, 1:07 a.m.