(relativenes[i] < cost) {dispersal[i]
<-((relativenes[i]- cost)/(relativenes[i]- cost*cost))} else
{dispersal[i] <- 0}}
}
}
> Subject: Re: [R] If function error: missing value where TRUE/FALSE needed
> From: petr.pi...@prech
which is treated by if as an inappropriate input so there is
missing value error.
But without data and its structure it is only a guess.
Regards
Petr
>
> [R] If function error: missing value where TRUE/FALSE needed
>
>
> Hello!
> I am trying to get a logic estatement in
Hello!
I am trying to get a logic estatement in R using the if function, but it is all
the time comming and error, I have tryied different methods but nothing is
working
the sentence is the following:
dispersal[1] <- if (any (relativenes[1] < cost)) ((relativenes[1]-
cost)/(relativenes[1]- co
3 matches
Mail list logo