[R] = vs. ==?
Alberto Monteiro
albmont at centroin.com.br
Wed Apr 16 13:13:40 CEST 2008
Ted Harding wrote:
>
> One is that "NA" is not a value. Its logical status is,
> in effect, "value not known". Therefore, when 'y' is "NA",
> "x==y" cannot have a definite resolution, since it is
> possible for the unkown value of 'y' to be equal to the
> value of 'x'; and equally possible that it may not be.
> Hence the value of "x==y" is itself "NA". Similarly
> the value of "x==y" is "NA" when both of 'x' and 'y'
> are "NA". The function to use for testing whether (say)
> 'x' is "NA" is is.na(x).
>
Just as an off-topic tangent, I found it quite interesting
that real-world language Aymara (see ...
http://en.wikipedia.org/wiki/Aymara_language
...) uses this three value logic system (I think the
computer jargon is "trollean logic").
Alberto Monteiro
More information about the R-help
mailing list