search for: internalfunct

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

Did you mean: internalfunc1
2020 Oct 15
0
calling stats::optim from Rcpp causes memory leak
...optim function Rcpp::Environment stats("package:stats"); Rcpp::Function optim = stats["optim"]; // Call the optim function from R in C++ Rcpp::List opt_results = optim(Rcpp::_["par"] = .5, Rcpp::_["fn"] = Rcpp::InternalFunction(&objective_function), Rcpp::_["method"] = "Brent", Rcpp::_["lower"] = a, Rcpp::_["upper"] = b); // Extract out the estimated parameter values doub...