I would like to create a new dataset where the following four conditions are all found
rowSums (is .na (UNCA [, 11: 23])) & lt; 12 rowSums (is.na (UNCA [, 27: 39])) & lt; 12 rowSums (is Na (UNCA [, 40: 52])) & lt; 12 rowSums (is.na (UNCA [, 53: 65])) <12> Thanks!
then use and operator:
UNCA new & lt; - UNCA [rowSums (is.na (UNCA [, 11: 23])) & lt; 12 & amp; nbsp; Rows (is.na (UNCA [, 27: 39])) & lt; 12 & amp; nbsp; Rows (is.na (UNCA [, 40: 52])) & lt; 12 & amp; nbsp; Rows (is.na (UNCA [, 53: 65])) & lt; 12,] A single & amp; is a vectorized function, whereas a double & amp; Amp; is unary (usually a if statement, for example)
Comments
Post a Comment