获取
Error "incorrect number of dimensions"
我已加载内置数据框cars
library(datasets)
data("cars")
lapply(cars,'[',1) #This will get the first row works fine
lapply(cars,'[',,1) #This should give me the first column but it gives me error incorrect dimensions
我也尝试将数据帧转换为列表,它给了我正确的行,但没有给出相同错误的列。