Hi R-users,

How do I calculate a number of NA's in a row of every second column in my
data frame?

As a starting point:
dfr <- data.frame(sapply(x, function(x) sample(0:x, 6, replace = TRUE)))
dfr[dfr==0] <- NA

So, I would like to count the number of NA in row one, two, three etc. of
columns X1, X3, X5 etc.

Thanks in advance
Lauri

	[[alternative HTML version deleted]]

