Copy and Change Variable Labels of a data.frame
col_relabel.Rd
Relabel a subset of the variables
Source
This function was taken 1-1 from formatters package, to reduce the complexity of the dependency tree.
Arguments
- x
a
data.frame
object- ...
name-value pairs, where name corresponds to a variable name in
x
and the value to the new variable label
See also
col_labels()
col_labels<-
Examples
x <- col_relabel(iris, Sepal.Length = "Sepal Length of iris flower")
col_labels(x)
#> Sepal.Length Sepal.Width
#> "Sepal Length of iris flower" NA
#> Petal.Length Petal.Width
#> NA NA
#> Species
#> NA