-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathunite.ir.Rd
72 lines (64 loc) · 2.09 KB
/
unite.ir.Rd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/tidyverse.R
\name{unite.ir}
\alias{unite.ir}
\title{Unite multiple columns in an \code{ir} object into one by pasting strings together}
\source{
\code{\link[tidyr:unite]{tidyr::unite()}}
}
\usage{
unite.ir(data, col, ..., sep = "_", remove = TRUE, na.rm = FALSE)
}
\arguments{
\item{data}{An object of class \code{ir}.}
\item{col}{The name of the new column, as a string or symbol.
This argument is passed by expression and supports
\link[rlang:nse-force]{quasiquotation} (you can unquote strings
and symbols). The name is captured from the expression with
\code{\link[rlang:nse-defuse]{rlang::ensym()}} (note that this kind of interface where
symbols do not represent actual objects is now discouraged in the
tidyverse; we support it here for backward compatibility).}
\item{...}{<\code{\link[tidyr:tidyr_tidy_select]{tidy-select}}> Columns to unite}
\item{sep}{Separator to use between values.}
\item{remove}{If \code{TRUE}, remove input columns from output data frame.}
\item{na.rm}{If \code{TRUE}, missing values will be remove prior to uniting
each value.}
}
\value{
\code{.data} with united columns. If the \code{spectra} column is
dropped or invalidated (see \code{\link[=ir_new_ir]{ir_new_ir()}}), the \code{ir} class is dropped, else
the object is of class \code{ir}.
}
\description{
Unite multiple columns in an \code{ir} object into one by pasting strings together
}
\examples{
## unite
ir_sample_data \%>\%
tidyr::separate(
"id_sample", c("a", "b", "c")
) \%>\%
tidyr::unite(id_sample, a, b, c)
}
\seealso{
Other tidyverse:
\code{\link{arrange.ir}()},
\code{\link{distinct.ir}()},
\code{\link{extract.ir}()},
\code{\link{filter-joins}},
\code{\link{filter.ir}()},
\code{\link{group_by}},
\code{\link{mutate-joins}},
\code{\link{mutate}},
\code{\link{nest}},
\code{\link{pivot_longer.ir}()},
\code{\link{pivot_wider.ir}()},
\code{\link{rename}},
\code{\link{rowwise.ir}()},
\code{\link{select.ir}()},
\code{\link{separate.ir}()},
\code{\link{separate_rows.ir}()},
\code{\link{slice}},
\code{\link{summarize}}
}
\concept{tidyverse}