Suppose I have the following:
library(dplyr)
foo <- data.frame(Company = c("company1", "foo", "test", "food"), Metric = rnorm(4, 10))
> foo
Company Metric
1 company1 10.539970
2 foo 9.487823
3 test 9.663994
4 food 9.499327
Why foo %>% dplyr::filter(Company %like% "%foo%")returns 0 results? (instead of 2nd and 4th rows) I am trying to use the SQL equivalent wildcard filter for a specific input string for dplyr::filter.
What am I doing wrong?
source
share