search for: myoptimc

Displaying 1 result from an estimated 1 matches for "myoptimc".

Did you mean: myoptim
2003 Oct 31
1
Optimization of objective function with generic number of arguments (R-Extension with C code)
...#################################################### ############## EXCERPT OF MY CODE ################ ###################################################### #My R minimization function MyOptim <-function(par, fn, ...) { ... fn1 <-function(par) fn(par,...) res <-.External(MyOptimC(par, fn1,new.env())) ... } #My C function __declspec (dllexport) SEXP MyOptimC(SEXP args) { args = CDR(args); SEXP par = CAR(args); args = CDR(args); SEXP fn = CAR(args); rho = CDR(args); SEXP rho = CAR(args); SEXP fminfn = lang2(fn, R_NilValue)); ... } I suceedeed on...