Set Variable Label

Share:

Description

This function sets a label to a variable, by storing a character string to its label attribute.

Usage

1
label(var) <- value

Arguments

var

a variable (see is.variable for details)

value

a character value that is to be set as variable label

See Also

label

Examples

1
2
3
4
5
6
## Not run: 
label(mtcars$mpg) <- "fuel consumption"
x <- rnorm(100)
(label(x) <- "pseudo-random normal variable")

## End(Not run)