# Generated by roxytest: do not edit by hand!
# File R/subplex.R: @tests
## Function subplex() @ L61
expect_silent({
rosen <- function (x) {
x1 <- x[1]
x2 <- x[2]
100*(x2-x1*x1)^2+(1-x1)^2
}
fit <- subplex(par=c(11,-33),fn=rosen)
stopifnot(all.equal(fit$par,c(1,1),tol=1e-4))
})
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.