Now i've managed to do this:

funcs <- list()
funcs[]

# loop through to define functions
for(i in 1:ib-1){

    # Make function name
    funcName <- paste( 'func', i, sep = '' )

    # make function
    func = paste('function(x){sin(x + a[', i,'])))}',sep = '')

    funcs[[funcName]] = eval(parse(text=func))
  

    }
end

but still cant apply the integrate in a loop for all the different
functions..... :/
help me out guys.... pretty please :)



--
View this message in context: 
http://r.789695.n4.nabble.com/loop-function-and-integrate-tp4651436p4651455.html
Sent from the R help mailing list archive at Nabble.com.

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to