if(data2$`part2$MAX_DPD` >= 60) data2$target <- 1 else data2$target <- 0
Error in if (data2$`part2$MAX_DPD` >= 60) data2$target <- 1 else data2$target <- 0 :
missing value where TRUE/FALSE needed
In addition: Warning message:
In if (data2$`part2$MAX_DPD` >= 60) data2$target <- 1 else data2$target <- 0 :
the condition has length > 1 and only the first element will be used