[Rd] Recall

2018-09-23 Thread Gabor Grothendieck
This works: my.compose <- function(f, ...) { if (missing(f)) identity else function(x) f(my.compose(...)(x)) } my.compose(sin, cos, tan)(pi/4) ## [1] 0.5143953 sin(cos(tan(pi/4))) ## [1] 0.5143953 But replacing my.compose with Recall in the else causes it to fail: my.comp

Re: [Rd] Recall

2018-09-23 Thread Gabor Grothendieck
Please ignore. Looking at this again I realize the problem is that Recall is not direclty within my.compose2 but rather is within the anonymous function in the else. On Sun, Sep 23, 2018 at 9:23 AM Gabor Grothendieck wrote: > > This works: > > my.compose <- function(f, ...) { > if (missing(f