Learn R Programming

dplyr (version 0.7.3)

add_rownames: Convert row names to an explicit variable.

Description

Deprecated, use tibble::rownames_to_column() instead.

Usage

add_rownames(df, var = "rowname")

Arguments

df

Input data frame with rownames.

var

Name of variable to use

Examples

Run this code
# NOT RUN {
mtcars %>% tbl_df()

mtcars %>% add_rownames()
# }

Run the code above in your browser using DataLab