列表 list,可以包含不同类型的对象。
创建列表、命名、创建多维元素列表
#list
x <- list("a", 10, 2L, 1+2i, TRUE)
x1 <- list(a=1, b=2, c=3) //给列表里的元素命名
x2 <- list(c(1,2,3), c(4,5,6,7)) //创建多维元素列表
x3 <- matrix(1:6, nrow=2, ncol=3)
dimnames(x) <- list(c("a","b"), c("c","d","e")) //给矩阵命名