[R] Sum of a couple of variables of which a few have NA values

Filoche pmassicotte at hotmail.com
Tue Jan 10 17:41:10 CET 2012


x = runif(10)
x[4] = NA
sum(x, na.rm = T)

--
View this message in context: http://r.789695.n4.nabble.com/Sum-of-a-couple-of-variables-of-which-a-few-have-NA-values-tp4282448p4282483.html
Sent from the R help mailing list archive at Nabble.com.



More information about the R-help mailing list