尝试
一个)
df %>% group_by(id) %>% filter(all(value == "a"))
b)
df %>% group_by(id) %>% filter(all(c("a", "b") %in% value))