








Dear R-help community,


I often get this error "missing value where TRUE/FALSE needed" when I'm doing some loops, like with this one


for (i in 1:nrow(survey)) {

if (survey[i,7]==survey[i,3])

{survey[i,14]<-survey[i,6]}

else

if(survey[i,11]==0 && survey[i,12]==0)

{survey[i,14]<-survey[i,4]}

}


Can someone explain me what I do wrong because I don't see the difference with other loops that work
Thanks a lot

Sarah 		 	   		  
	[[alternative HTML version deleted]]

