Will additionally set all NaN elements to NA.
to_na(x, ...)
A vector with elements that should set to NA
The elements that should be set to NA
Vector with specified elements set to NA
to_na(c(1, NaN, 2, 3), 2, NaN)#> [1] 1 NA NA 3