powered by
This function sets new row names for a data frame based on a tidy evaluation expression.
mutateToRownames(.data, expr, .remove = FALSE, .uniqueSep = ".")
A data frame with updated row names.
A data frame.
A tidy evaluation expression specifying the columns to use for the new row names.
A logical indicating whether to remove the selected columns. Default is FALSE.
A character string to separate duplicate row names when ensuring uniqueness with make.unique(). Default is ".".
make.unique()
library(dplyr) mtcars %>% head() %>% mutateToRownames(wt + 3*vs)
Run the code above in your browser using DataLab