From p.dalgaard at biostat.ku.dk  Sat Jun 28 22:39:16 2008
From: p.dalgaard at biostat.ku.dk (Peter Dalgaard)
Date: Sat, 28 Jun 2008 22:39:16 +0200
Subject: [Rd] get ...
In-Reply-To: <971536df0806281246o75249479gaab3a059952e0f85@mail.gmail.com>
References: <971536df0806281246o75249479gaab3a059952e0f85@mail.gmail.com>
Message-ID: <4866A174.4050706@biostat.ku.dk>

Gabor Grothendieck wrote:
> Suppose we do this:
>
>   
>> f <- function(...) environment()
>> e <- f(a = 1, b = 2)
>> ls(e, all = TRUE)
>>     
> [1] "..."
>   
>> e$...
>>     
> <...>
>   
>> class(e$...)
>>     
> [1] "..."
>
> Is there any way of getting a and b given e without
> modifying f?
>   
 > evalq(list(...),e)
$a
[1] 1

$b
[1] 2

-- 
   O__  ---- Peter Dalgaard             ?ster Farimagsgade 5, Entr.B
  c/ /'_ --- Dept. of Biostatistics     PO Box 2099, 1014 Cph. K
 (*) \(*) -- University of Copenhagen   Denmark      Ph:  (+45) 35327918
~~~~~~~~~~ - (p.dalgaard at biostat.ku.dk)              FAX: (+45) 35327907



[Rd] get ...
Peter Dalgaard