How does dplyr’s between work?

前端 未结 3 1859
说谎
说谎 2020-12-14 09:09

I’ve read the documentation and I’ve tried googling it; it should be a simple thing, but it would seem it’s not to me; so I boldly go forth and ask if someone here could exp

3条回答
  •  粉色の甜心
    2020-12-14 09:44

    I guess you want it like this:

    library(nycflights13)
    library(dplyr)
    
    flights %>% filter(between(month,7,9))
    

    I see in the meantime this solution also appeared in the comments.

提交回复
热议问题