grepl 与 grep
本练习是课程的一部分
R 中级
练习说明
交互式实操练习
通过完成这段示例代码来试试这个练习。
# The emails vector has already been defined for you
emails <- c("[email protected]", "[email protected]", "[email protected]",
"invalid.edu", "[email protected]", "[email protected]")
# Use grepl() to match for "edu"
# Use grep() to match for "edu", save result to hits
# Subset emails using hits