Insert NA in a vector
Inserting NA values in a vector at specific index locations
insertNA(y, ind)
y
: vectorind
: index locations where NA is insertedThe vector is parsed out and NA values are inserted where after the index values provided.
Jonathan M. Leesjonathan.lees@unc.edu
x = 1:10 insertNA(x, 6)
Useful links