Create a lens into the lower diagonal elements of a matrix

lower_tri_l(diag = FALSE)

Arguments

diag

whether or not to include the diagonal

Examples

(x <- matrix(1:9, ncol = 3))
#> [,1] [,2] [,3] #> [1,] 1 4 7 #> [2,] 2 5 8 #> [3,] 3 6 9
view(x, lower_tri_l())
#> [1] 2 3 6
view(x, lower_tri_l(diag = TRUE))
#> [1] 1 2 3 5 6 9
set(x, lower_tri_l(), c(100, 200, 300))
#> [,1] [,2] [,3] #> [1,] 1 4 7 #> [2,] 100 5 8 #> [3,] 200 300 9