You can try this:
 for (i in 1:length(ds)) {
dummy<-ds[[i]];
dummy[is.nan(dummy)]<-0
ds[[i]]<-dummy
}


if is.nan doesn't work, replace with is.na

-----
Yasir Kaheil

--
View this message in context: 
http://r.789695.n4.nabble.com/replacing-NaN-for-every-attribute-in-my-data-tp4636160p4636163.html
Sent from the R help mailing list archive at Nabble.com.

______________________________________________
[email protected] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to