% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/utils_data.R
\name{rownames_as_column}
\alias{rownames_as_column}
\alias{column_as_rownames}
\title{Tools for working with row names}
\usage{
rownames_as_column(x, var = "rowname")

column_as_rownames(x, var = "rowname")
}
\arguments{
\item{x}{A data frame.}

\item{var}{Name of column to use for rownames. For \code{column_as_rownames()},
this argument can be the variable name or the column number.}
}
\value{
\code{rownames_as_column()} and \code{column_as_rownames()} both return a data frame.
}
\description{
Tools for working with row names
}
\examples{
# Convert between row names and column --------------------------------
test <- rownames_as_column(mtcars, var = "car")
test
head(column_as_rownames(test, var = "car"))

}
