I\'m working with a large dataset x. I want to drop rows of x that are missing in one or more columns in a set of columns of x, that
x
This should be faster than using apply:
apply
x[rowSums(is.na(x[, ..varcols])) == 0, ] # var1 var2 textcol # 1: 0 0 e # 2: 0 1 f # 3: 1 0 h # 4: 1 1 i