【发布时间】:2018-10-17 05:47:28
【问题描述】:
我们的目标:使用 R dplyr,如果 match_column 字段中的数据以 code_list
以下适用于静态字符串(即,它返回 dataset::match_column 中以静态字符串“123”开头的所有行。)
dataset1 <-filter(dataset, str_detect(match_column,"^123"))
经过多次尝试,我们无法弄清楚将“^123”替换为 code_list 的语法。
任何帮助将不胜感激。
【问题讨论】: