[R] Re place only first NA in column
mlt35 at tamu.edu
Tue Nov 3 21:58:14 CET 2009
I am trying to fill in a blank vector ("a") with one value at a time, with
the value of the number of rows in a randomized dataset with rowSums=0.
Below is the code I've got so far, but what I want to be as the last line is
" a[1st NA,]=nz"
such that this will run until all of my NAs are replaced with an integer
value based on randomizations.
z<-matrix(rbinom(832, 1, prob = 0.048), nrow = 32)
Thank you for your help!
View this message in context: http://old.nabble.com/Replace-only-first-NA-in-column-tp26163589p26163589.html
Sent from the R help mailing list archive at Nabble.com.
More information about the R-help