[Rd] Re: [R] Several R vs S-Plus issues
Thomas Lumley
tlumley@u.washington.edu
Thu, 4 Oct 2001 08:51:35 -0700 (PDT)
On Thu, 4 Oct 2001, Kurt Hornik wrote:
> >>>>> David Brahm writes:
> > - LETTERS[c(NA,2)] in S is c("","B"), but in R is c("NA","B")
>
> I think we do not want to change this.
>
> Splus has
>
> > (1:2)[c(NA,2)]
> [1] NA 2
> > is.na((1:2)[c(NA,2)])
> [1] T F
> > is.na(c(TRUE, FALSE)[c(NA,2)])
> [1] T F
>
I think we do want to change this (as we discussed quite recently) but by
adding a genuine character NA. The problem is not that LETTERS[c(NA,2)]
returns a missing value, it's that it isn't missing enough. We need a
"NaS" (Not a String) value that can't be confused with Nabisco, but also
can't be confused with an empty string.
-thomas
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !) To: r-devel-request@stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._