getDesign | R Documentation |
Find the design that maximizes the probability of dominating a target given by the user.
getDesign(model, target, lower, upper, optimcontrol = NULL)
model |
list of objects of class |
target |
vector corresponding to the desired output in the objective space, |
lower |
vector of lower bounds for the variables to be optimized over, |
upper |
vector of upper bounds for the variables to be optimized over, |
optimcontrol |
optional list of control parameters for optimization of the selected infill criterion.
" |
A list with components:
par
: best design found,
value
: probabilitity that the design dominates the target,
mean
: kriging mean of the objectives at the design,
sd
: prediction standard deviation at the design.
## Not run: #--------------------------------------------------------------------------- # Example of interactive optimization #--------------------------------------------------------------------------- set.seed(25468) library(DiceDesign) d <- 2 n.obj <- 2 fun <- "P1" n.grid <- 51 test.grid <- expand.grid(seq(0, 1, length.out = n.grid), seq(0, 1, length.out = n.grid)) nappr <- 20 design.grid <- round(maximinESE_LHS(lhsDesign(nappr, d, seed = 42)$design)$design, 1) response.grid <- t(apply(design.grid, 1, fun)) paretoFront <- t(nondominated_points(t(response.grid))) mf1 <- km(~., design = design.grid, response = response.grid[,1]) mf2 <- km(~., design = design.grid, response = response.grid[,2]) model <- list(mf1, mf2) lower <- rep(0, d); upper <- rep(1, d) sol <- GParetoptim(model, fun, crit = "SUR", nsteps = 5, lower = lower, upper = upper) plotGPareto(sol) target1 <- c(15, -25) points(x = target1[1], y = target1[2], col = "black", pch = 13) nDesign <- getDesign(sol$lastmodel, target = target1, lower = rep(0, d), upper = rep(1, d)) points(t(nDesign$mean), col = "green", pch = 20) target2 <- c(48, -27) points(x = target2[1], y = target2[2], col = "black", pch = 13) nDesign2 <- getDesign(sol$lastmodel, target = target2, lower = rep(0, d), upper = rep(1, d)) points(t(nDesign2$mean), col = "darkgreen", pch = 20) ## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.