A lens into the dimnames of an object. Lens equivalent of dimnames and dimnames<-.

dimnames_l

Format

An object of class lens of length 2.

Examples

x <- matrix(1:4, ncol = 2) colnames(x) <- c("first", "second") x
#> first second #> [1,] 1 3 #> [2,] 2 4
view(x, dimnames_l)
#> [[1]] #> NULL #> #> [[2]] #> [1] "first" "second" #>
set(x, dimnames_l, list(NULL, c("premiere", "deuxieme")))
#> premiere deuxieme #> [1,] 1 3 #> [2,] 2 4