powered by
A convenience function for replacing missing values with a (non-missing) constant.
replaceMissing(x, replaceWith)
An atomic vector or array.
Value to replace missing entries in x. The default is FALSE for logical vectors, 0 for numeric vectors, and empty string "" for character vectors.
x
FALSE
x with missing data replaced.
# NOT RUN { logVec = c(TRUE, FALSE, NA, TRUE); replaceMissing(logVec) numVec = c(1,2,3,4,NA,2) replaceMissing(numVec) # }
Run the code above in your browser using DataLab