Hi friends, I'm beginning in R and I have simple question.

I have this piece of my program and how you see, that's ok (whit > num<-
0.002)

num<-0.002 # ok, but not when I change whit num<-0... ?
factor1<-1;
while(1)
{
if (num*factor1<1)
factor1<-factor1*10
else
{
print("out ok!!");
break;
}
}

[1] "out ok!!"


but when I change (whit > num<-0) R show this:

Error in if (num * factor1 < 1) factor1 <- factor1 * 10 else { :
missing value where TRUE/FALSE needed


I can't understand that error, can somebody help me, please
thanks in advance
 Jac

        [[alternative HTML version deleted]]

______________________________________________
R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html

Reply via email to