Replace NAs in a ffdf object
问题 I`m working with a ffdf object which has NAs in some of the columns. The NAs are the result of a left outer merge using merge.ffdf .I would like to replace the NAs with 0s but not managing to do it. Here is the code I am running: library(ffbase) deals <- merge(deals,rk,by.x=c("DEALID","STICHTAG"),by.y=c("ID","STICHTAG"),all.x=TRUE) attributes(deals) $names [1] "virtual" "physical" "row.names" $class [1] "ffdf" vmode(deals$CREDIT_R) [1] "double" idx <- ffwhich(deals,is.na(CREDIT_R)) # CREDIT_R