Skip to content
Prev 208104 / 398502 Next

convert a data frame with NULL to a list of integer

I have a data frame with integers mixed with a lot of NULLs, how do I convert
that to multiple lists of integers with zero (to replace NULL)? I tried the
following, and they failed:
[1] 25352   173
[1] "data.frame"
[1] "data.frame"
30 31 32   33 34 35 36   37   38   39   40
NM_000014  1 14  1 NULL 27  8 21 NULL NULL NULL NULL
[1] NA NA NA NA NA NA NA NA NA NA NA
thanks a lot!

-Kenny