View source: R/convert_zero_NA.r
convert_zero_NA | R Documentation |
Converts 0s in NA
convert_zero_NA(data, vars)
data |
the data frame in which we can find |
vars |
a character vector of covariates for which to transform 0s in |
The modified data frame
Hugo Varet
my.data=data.frame(x=rbinom(20,1,0.5),y=rbinom(20,1,0.5),z=rbinom(20,1,0.5))
my.data=convert_zero_NA(my.data,c("y","z"))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.