On Mon, May 9, 2016 at 7:12 AM, peter dalgaard wrote:
>
> On 09 May 2016, at 02:46 , Bert Gunter wrote:
>
>> ... To be clear, Hadley or anyone else should also feel free to set me
>> straight, preferably publicly, but privately if you prefer.
>
> Not
On Sun, May 8, 2016 at 7:28 PM, Bert Gunter wrote:
> Jeff:
>
> That's easy to do already with substitute(), since you can pass around
> an unevaluated expression (a parse tree) however you like. As I read
> it, (admittedly quickly) what it's main feature is that it allows
On 09 May 2016, at 02:46 , Bert Gunter wrote:
> ... To be clear, Hadley or anyone else should also feel free to set me
> straight, preferably publicly, but privately if you prefer.
Not really to "set anyone straight", but there are some subtleties with mode
call
... To be clear, Hadley or anyone else should also feel free to set me
straight, preferably publicly, but privately if you prefer.
Cheers,
Bert
Bert Gunter
"The trouble with having an open mind is that people keep coming along
and sticking things into it."
-- Opus (aka Berkeley Breathed in his
Jeff:
That's easy to do already with substitute(), since you can pass around
an unevaluated expression (a parse tree) however you like. As I read
it, (admittedly quickly) what it's main feature is that it allows you
more control over the environment in which the expression is finally
evaluated --
The lazyeval package addresses the problem of how to delay evaluation even when
the function you want to do the evaluation in is buried two or more function
calls below where the original call was made. If you are not building nested
function calls with delayed evaluation then you probably
Hi, Hadley et al.:
Hadley's link requires his development version of "lazyeval",
which can be obtained as follows:
library(devtools)
install_github("hadley/lazyeval")
Hadley's link describes real problems with elegant solutions.
However, David's solution solved my
You may want to read http://rpubs.com/hadley/157957, which captures my
latest thinking (and tooling) around this problem. Feedback is much
appreciated.
Hadley
On Fri, May 6, 2016 at 2:14 PM, David Winsemius wrote:
>
>> On May 6, 2016, at 5:47 AM, Spencer Graves
>>
> On May 6, 2016, at 5:47 AM, Spencer Graves
> wrote:
>
>
>
> On 5/6/2016 6:46 AM, peter dalgaard wrote:
>> On 06 May 2016, at 02:43 , David Winsemius wrote:
>>
On May 5, 2016, at 5:12 PM, Spencer Graves
On 5/6/2016 6:46 AM, peter dalgaard wrote:
On 06 May 2016, at 02:43 , David Winsemius wrote:
On May 5, 2016, at 5:12 PM, Spencer Graves
wrote:
I want a function to evaluate one argument
in the environment of a data.frame
On 06 May 2016, at 02:43 , David Winsemius wrote:
>
>> On May 5, 2016, at 5:12 PM, Spencer Graves
>> wrote:
>>
>> I want a function to evaluate one argument
>> in the environment of a data.frame supplied
>> as another argument.
On 5/5/2016 11:17 PM, Bert Gunter wrote:
... and it's exactly with.default's code !
Thanks for pointing that out. Unfortunately, it didn't work inside
another function. However, if I had looked at it, I might have been
able to thought to try it. Spencer
Cheers,
Bert
Bert Gunter
... and it's exactly with.default's code !
Cheers,
Bert
Bert Gunter
"The trouble with having an open mind is that people keep coming along
and sticking things into it."
-- Opus (aka Berkeley Breathed in his "Bloom County" comic strip )
On Thu, May 5, 2016 at 7:38 PM, Spencer Graves
Hi, David: That works. Thanks very much. Spencer Graves
On 5/5/2016 7:43 PM, David Winsemius wrote:
On May 5, 2016, at 5:12 PM, Spencer Graves
wrote:
I want a function to evaluate one argument
in the environment of a data.frame supplied
as another
> On May 5, 2016, at 5:12 PM, Spencer Graves
> wrote:
>
> I want a function to evaluate one argument
> in the environment of a data.frame supplied
> as another argument. "attach" works for
> this, but "with" does not. Is there a way
> to make "with" work?
I want a function to evaluate one argument
in the environment of a data.frame supplied
as another argument. "attach" works for
this, but "with" does not. Is there a way
to make "with" work? I'd rather not attach
the data.frame.
With the following two functions "eval.w.attach"
works but
Duncan Murdoch wrote:
Just declaring it there is the only reasonable way, i.e.
test-function(foo) {
subtest - function() {
foo - foo+1
}
subtest()
return(foo)
}
The reason you can't somehow assign it within an existing test is that
subtest is a different closure every time. Its
Hello,
After hours of googling I could not resolve the following (although it
seems simple):
I would like to put subfunctions in a separate .R file that is then
called with source() from inside several main functions. A crude
example would be as follows:
file subtest.R **
18 matches
Mail list logo