mirror of
https://github.com/agdamsbo/FreesearchR.git
synced 2025-09-12 01:49:39 +02:00
28 lines
603 B
R
28 lines
603 B
R
% Generated by roxygen2: do not edit by hand
|
|
% Please edit documentation in R/helpers.R
|
|
\name{append_column}
|
|
\alias{append_column}
|
|
\title{Append a column to a data.frame}
|
|
\usage{
|
|
append_column(data, column, name, index = "right")
|
|
}
|
|
\arguments{
|
|
\item{data}{data}
|
|
|
|
\item{column}{new column (vector) or data.frame with 1 column}
|
|
|
|
\item{name}{new name (pre-fix)}
|
|
|
|
\item{index}{desired location. May be "left", "right" or numeric index.}
|
|
}
|
|
\value{
|
|
data.frame
|
|
}
|
|
\description{
|
|
Append a column to a data.frame
|
|
}
|
|
\examples{
|
|
mtcars |>
|
|
dplyr::mutate(mpg_cut = mpg) |>
|
|
append_column(mtcars$mpg, "mpg_cutter")
|
|
}
|