Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
indices <- c(2,5,9)
客户是一个data.frame。
我想要索引索引位置中客户第 2 列的值列表。
names <- as.list(customer[,2] << indices)
听起来您想从数据框中进行简单的提取。尝试:
customer[indices, 2]