David Winsemius wrote:
> 
> On Aug 3, 2011, at 8:09 AM, zcatav wrote:
> ........................
> You need to apply the same logical test/selection on the rows of the  
> RHS as you are doing on the LHS.
> Possibly:
> 
> X[ X[,"c"]==1, "b"] <- X[ X[,"c"]==1, "d"]
> 
> 

This solution was suggested by R. Michael Weylandt and it works great.


--
View this message in context: 
http://r.789695.n4.nabble.com/conditional-data-replace-recode-change-or-whatsoever-tp3714715p3715544.html
Sent from the R help mailing list archive at Nabble.com.

______________________________________________
R-help@r-project.org 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