Re: [R] how to pass a function to a function inside a function

2012-09-25 Thread Rui Barradas
Hello, Your function creates the vector 'x', then creates the function fs(), then returns the function just created. It _never_ reaches the line intgrt <- function(lower) { and therefore never creates this last function. Now supposed it did. In the very end you make the same mistake, you

[R] how to pass a function to a function inside a function

2012-09-25 Thread Al Ehan
Hi, I'm trying to compile two functions into one function. the first funtion is called 'fs' which is self-made function, another function is from the built-in 'integration' function that is copy-paste-edited. If built separatey, these functions work well. However that is not the case if combines t