标签: r dataframe
indices <- c(2,5,9)
客户是data.frame。
我想要索引的索引位置中客户第2列的值列表。
names <- as.list(customer[,2] << indices)
答案 0 :(得分:3)
听起来你想从数据框中做一个简单的提取。尝试:
customer[indices, 2]