Skip to content
Prev 166040 / 398502 Next

prblem with NA

Hello -
kayj wrote:
An alternate, vectorized solution may be:

X <- ifelse(data <= 100, 1, 0)

And as 'data' is a function in the utils package include with R, you 
might consider not naming your variables 'data'.