我正在尝试通过使用美元以外的货币省略预算列中的任何原始数据来过滤 R 中的数据
I am trying to filter the data in R by omitting any raw in budget column with a currency other than us dollars
我试过了,但没用。
horror_movies %>% dplyr::filter(grepl("$", budget))
您需要添加 fixed=TRUE
作为 grepl 的参数。例如...
horror_movies[grepl('$', horror_movies$budget, fixed=TRUE),]
有关详细说明,请参阅 this answer。
我试过了,但没用。
horror_movies %>% dplyr::filter(grepl("$", budget))
您需要添加 fixed=TRUE
作为 grepl 的参数。例如...
horror_movies[grepl('$', horror_movies$budget, fixed=TRUE),]
有关详细说明,请参阅 this answer。