utils_rows_cols | R Documentation |
columns_to_rownames()
: Move a column of .data
to its row
names.
rownames_to_column()
: Move the row names of .data
to a new
column.
remove_rownames()
: Remove the row names of .data
.
round_cols()
Rounds the values of all numeric variables to the specified
number of decimal places (default 2).
column_to_rownames(.data, var = "rowname")
rownames_to_column(.data, var = "rowname")
remove_rownames(.data)
round_cols(.data, digits = 2)
.data |
A data frame |
var |
Name of column to use for rownames. |
digits |
The number of significant figures. Defaults to |
Tiago Olivoto tiagoolivoto@gmail.com
library(pliman)
iris2 <- iris |> rownames_to_column()
head(iris2)
iris2$rowname <- paste0("r", iris2$rowname)
iris2 |> column_to_rownames("rowname") |> head()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.