[R] Applying a transformation to multiple data frame columns

Dimitri Shvorob dimitri.shvorob at gmail.com
Sat Jan 30 21:34:41 CET 2010


How can one simplify the folowing?

t$aum[is.na(t$aum)] = 0; t$aum.core[is.na(t$aum.core)] = 0
t$num[is.na(t$num)] = 0; t$num.core[is.na(t$num.core)] = 0

Thank you.
-- 
View this message in context: http://n4.nabble.com/Applying-a-transformation-to-multiple-data-frame-columns-tp1457641p1457641.html
Sent from the R help mailing list archive at Nabble.com.



More information about the R-help mailing list