Prevent ifelse() from being used to produce TRUE/FALSE or 1/0Source:
ifelse(x, TRUE, FALSE) and
ifelse(x, FALSE, TRUE) are
!x suffice in R code where logical vectors are a
core data structure.
ifelse(x, 1, 0) is also
as.numeric(x), but even
this should only be needed rarely.
TRUE, usage like
ifelse(x, 1, 0)is allowed, i.e., only usage like
ifelse(x, TRUE, FALSE)is linted.
linters for a complete list of linters available in lintr.