From berwin at maths.uwa.edu.au  Wed May 26 13:12:24 2010
From: berwin at maths.uwa.edu.au (Berwin A Turlach)
Date: Wed, 26 May 2010 19:12:24 +0800
Subject: [Rd] Indexing bug?
In-Reply-To: <4BFCF092.2010501@gmail.com>
References: <4BFCF092.2010501@gmail.com>
Message-ID: <20100526191224.787eccb0@bossiaea>

G'day Duncan,

On Wed, 26 May 2010 05:57:38 -0400
Duncan Murdoch <murdoch.duncan at gmail.com> wrote:

> Is this expected behaviour?

Yes, according to the answer that this poster

https://stat.ethz.ch/pipermail/r-devel/2008-March/048674.html

got.

Indeed, the help page of '[' states:

The index object i can be numeric, logical, character or empty.
Indexing by factors is allowed and is equivalent to indexing by the
numeric codes (see factor) and not by the character values which are
printed (for which use [as.character(i)]). 

Cheers,

	Berwin



[Rd] Indexing bug?
Berwin A Turlach