od_MISOCP {OptimalDesign} | R Documentation |
Optimal exact design using mixed integer second-order cone programming
Description
Computes an optimal or nearly-optimal approximate or exact experimental design using mixed integer second-order cone programming.
Usage
od_MISOCP(Fx, b1=NULL, A1=NULL, b2=NULL, A2=NULL, b3=NULL, A3=NULL, w0=NULL,
bin=FALSE, type="exact", crit="D", h=NULL, gap=NULL,
t.max=120, echo=TRUE)
Arguments
Fx |
the |
b1 , A1 , b2 , A2 , b3 , A3 |
the real vectors and matrices that define the constraints on permissible designs |
w0 |
a non-negative vector of length |
bin |
Should each design point be used at most once? |
type |
the type of the design. Permissible values are |
crit |
the optimality criterion. Possible values are |
h |
a non-zero vector of length |
gap |
the gap for the MISOCP solver to stop the computation. If |
t.max |
the time limit for the computation. |
echo |
Print the call of the function? |
Details
At least one of b1
, b2
, b3
must be non-NULL
.
If bi
is non-NULL
and Ai
is NULL
for some i
then Ai
is set to be the vector of ones. If bi
is NULL
for some i
then Ai
is ignored.
Value
A list with the following components:
call |
the call of the function |
w.best |
the permissible design found, or |
supp |
the indices of the support of |
w.supp |
the weights of |
M.best |
the information matrix of |
Phi.best |
the value of the criterion of optimality of the design |
status |
the status variable of the gurobi optimization procedure; see the gurobi solver documentation for details |
t.act |
the actual time of the computation |
Author(s)
Radoslav Harman, Lenka Filova
References
Sagnol G, Harman R (2015): Computing exact D-optimal designs by mixed integer second order cone programming. The Annals of Statistics, Volume 43, Number 5, pp. 2198-2224.
See Also
Examples
## Not run:
# Compute an A-optimal block size two design
# for 6 treatments and 9 blocks
Fx <- Fx_blocks(6)
w <- od_MISOCP(Fx, b3 = 9, crit = "A", bin = TRUE)$w.best
des <- combn(6, 2)[, as.logical(w)]
print(des)
library(igraph)
grp <- graph_(t(des), from_edgelist(directed = FALSE))
plot(grp, layout=layout_with_graphopt)
# Compute a symmetrized D-optimal approximate design
# for the full quadratic model on a square grid
# with uniform marginal constraints
Fx <- Fx_cube(~x1 + x2 + I(x1^2) + I(x2^2) + I(x1*x2), n.levels = c(21, 21))
A3 <- matrix(0, nrow = 21, ncol = 21^2)
for(i in 1:21) A3[i, (i*21 - 20):(i*21)] <- 1
w <- od_MISOCP(Fx, b3 = rep(1, 21), A3 = A3, crit = "D", type = "approximate")$w.best
w.sym <- od_SYM(Fx, w, b3 = rep(1, 21), A3 = A3)$w.sym
od_plot(Fx, w.sym, Fx[, 2:3], dd.size = 2)
## End(Not run)