1:11 %>% length() > 10
However, when I pipe it within a ifelse()
, it evaluates it as if the condition must be applied per each element. Even the output is weird and illogical.
1:11 %>% ifelse(length(.) > 10,1)
At the same time,
ifelse(length(1:11) > 10,1)
works properly.