From tlumley@u.washington.edu  Thu Oct  4 16:51:35 2001
From: tlumley@u.washington.edu (Thomas Lumley)
Date: Thu, 4 Oct 2001 08:51:35 -0700 (PDT)
Subject: [Rd] Re: [R] Several R vs S-Plus issues
In-Reply-To: <15292.6722.281945.237767@mithrandir.hornik.net>
Message-ID: <Pine.A41.4.33.0110040846520.100374-100000@homer38.u.washington.edu>

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
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._


[Rd] Re: [R] Several R vs S-Plus issues
Thomas Lumley