W2IP | R Documentation |
2-Wasserstein distance selection by Integer Programming
W2IP(
X,
Y = NULL,
theta,
transport.method = transport_options(),
model.size = NULL,
nvars = NULL,
maxit = 100L,
infimum.maxit = 100L,
tol = 1e-07,
solver = c("cone", "lp", "mosek", "cplex", "gurobi"),
display.progress = FALSE,
parallel = NULL,
...
)
X |
Covariates |
Y |
Predictions from arbitrary model |
theta |
Parameters of original linear model. Required |
transport.method |
Method for Wasserstein distance calculation. Should be one of the outputs of |
model.size |
Maximum number of coefficients in interpretable model |
nvars |
The number of variables to explore. Should be an integer vector of model sizes. Default is NULL which will explore all models from 1 to |
maxit |
Maximum number of solver iterations |
infimum.maxit |
Maximum iterations to alternate binary program and Wasserstein distance calculation |
tol |
Tolerance for convergence of coefficients |
solver |
The solver to use. Must be one of "cone","lp", "cplex", "gurobi","mosek". |
display.progress |
Should progress be printed? |
parallel |
foreach back end. See |
... |
Extra args to Wasserstein distance methods |
For argument solution.method
, options "cone" and "lp" use the free solvers "ECOS" and "lpSolver", respectively. "cplex", "gurobi" and "mosek" require installing the corresponding commercial solvers.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.