R/misc.R
sum_nn.Rd
Sum with na.rm=TRUE
sum_nn(x, ...)
a vector of numbers
other arguments passed to sum
A numeric or complex scalar giving the sum of x, with missing values removed.
x
x <- c(NA, 10, 90) sum(x) #> [1] NA sum_nn(x) #> [1] 100