Displaying 4 results from an estimated 4 matches for "realfun".
Did you mean:
realfunc
2015 Jan 21
2
reducing redundant work in methods package
...n")
funbody = deparse(body(fun))
newfun <- fun
newfun.body = c(
sprintf("fname = '%s'", fname),
"TEST_INFO = list()",
"TEST_INFO$input = mget(names(formals(fname)))",
c("realfun <- function()", funbody),
"TEST_INFO$output = realfun()",
"TEST_ENV[[fname]] = c(TEST_ENV[[fname]], list(TEST_INFO))",
"return(TEST_INFO$output)")
body(newfun) = as.call(c(as.name("{"),
as.list(parse(tex...
2015 Jan 21
2
reducing redundant work in methods package
...;> newfun.body = c(
>>
>> sprintf("fname = '%s'", fname),
>>
>> "TEST_INFO = list()",
>>
>> "TEST_INFO$input = mget(names(formals(fname)))",
>>
>> c("realfun <- function()", funbody),
>>
>> "TEST_INFO$output = realfun()",
>>
>> "TEST_ENV[[fname]] = c(TEST_ENV[[fname]], list(TEST_INFO))",
>>
>> "return(TEST_INFO$output)")
>>
>>...
2015 Jan 21
0
reducing redundant work in methods package
...t; newfun <- fun
>
> newfun.body = c(
>
> sprintf("fname = '%s'", fname),
>
> "TEST_INFO = list()",
>
> "TEST_INFO$input = mget(names(formals(fname)))",
>
> c("realfun <- function()", funbody),
>
> "TEST_INFO$output = realfun()",
>
> "TEST_ENV[[fname]] = c(TEST_ENV[[fname]], list(TEST_INFO))",
>
> "return(TEST_INFO$output)")
>
> body(newfun) = as.call(c(as.na...
2015 Jan 22
0
reducing redundant work in methods package
...gt;>>
>>> sprintf("fname = '%s'", fname),
>>>
>>> "TEST_INFO = list()",
>>>
>>> "TEST_INFO$input = mget(names(formals(fname)))",
>>>
>>> c("realfun <- function()", funbody),
>>>
>>> "TEST_INFO$output = realfun()",
>>>
>>> "TEST_ENV[[fname]] = c(TEST_ENV[[fname]], list(TEST_INFO))",
>>>
>>> "return(TEST_INFO$output)")...