【发布时间】:2019-10-27 04:03:40
【问题描述】:
我想将文件 2 中的值提取到与指定列中的值匹配的文件中。它是 Excel 中的一个简单查找函数。 但是给出的许多解决方案都是基于匹配的列名,我不想在我的数据集中进行更改。
2 files having a matching column and file2 column to be inserted in file1
【问题讨论】:
-
merge(file1, unique(file2)[, c("Symbol", "GeneID")], by="UniprotBlastGeneSymbol") 在
[.default(unique(file2$Symbol) 中输出错误, , c("Symbol", "GeneID")) : 维数不正确 -
file2%>% + select(Symbol, GeneID) %>% + distinct() %>% + left_join(file1, by = file1$UniprotBlastGeneSymbol) 错误:
by不能包含连接列DIR23、At5g34650、At1g53800、At2g30060、PER59、... LHS 中缺少该列调用rlang::last_error()以查看回溯
标签: r merge vlookup lookup plyr