Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- for (i in 1:length(X)) {
- X[[i]]$Y[which(is.na(X[[i]]$Y))] == "Unknown"
- }
- # Some data with `""`
- v <- 1:10
- v[c(3,5,8)] <- ""
- v
- [1] "1" "2" "" "4" "" "6" "7" "" "9" "10"
- v[v == ""] <- "Unknown"
- [1] "1" "2" "Unknown" "4" "Unknown" "6" "7" "Unknown" "9" "10"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement