I have a dataset:I need to perform an analysis such that I can't have NA values in the gender variable. The other columns are too few and have no known predictive value so that imputing the values isn't really possible.
Let's say I have a vector x:How do I identify sets of the NAs within this vector, i.e.,My end goal is to use it with a pipe on a data frame using dplyr. So, if there's a function compatible with dplyr that's even better.
I already made a similar question but now I want just to restrict the new values of NA. I have some data like this:
Slightly difficult to phrase, as far as I saw none of the similar questions answered my problem.I have a data.frame such as:
I have a data frame with many columns of different types. I would like to replace each column with NA of the corresponding class.