From beierm at uni-duesseldorf.de  Wed Jun 13 14:14:06 2007
From: beierm at uni-duesseldorf.de (beierm at uni-duesseldorf.de)
Date: Wed, 13 Jun 2007 14:14:06 +0200 (CEST)
Subject: [Rd] subset() only returns first of equally named columns from a
	data.frame (PR#9733)
Message-ID: <20070613121406.BCFE54841A@slim.kubism.ku.dk>

Full_Name: Manfred Beier
Version: 2.5.0 (2007-04-23)
OS: linux-gnu
Submission from: (NULL) (134.99.204.101)


When multiple columns in a data.frame have the same name, only the first of them
is returned by the subset() function even when selected numerically.

> test <- data.frame(cbind(1,2,3))
> names(test) <- c("a","a","a")
> test
  a a a
1 1 2 3
> subset(test, TRUE, c(2,3))
  a a.1
1 1   1

For matrices subset() works correctly.



[Rd] subset() only returns first of equally named columns from a data.frame (PR#9733)
beierm at uni-duesseldorf.de