Opt_C_seq | R Documentation |
This corresponds to Procedure 3 in the paper (Ver20201104).
Opt_C_seq( C_l, C_u, C, Xt, Xc, mon_ind, sigma_t, sigma_c, alpha, n_grid = 10, gain_tol = 0.05, ratio = TRUE, p = Inf, n_sim = 10^5 )
C_l |
lower end of the adaptation range. |
C_u |
upper end of the adaptation range. |
C |
the Lipschitz coefficient for the function space we consider. |
Xt |
n_t by k design matrix for the treated units. |
Xc |
n_c by k design matrix for the control units. |
mon_ind |
index number for monotone variables. |
sigma_t |
standard deviation of the error term for the treated units (either length 1 or n_t). |
sigma_c |
standard deviation of the error term for the control units (either length 1 or n_c). |
alpha |
desired upper quantile value. |
n_grid |
number of grid points to evaluate the lengths. |
gain_tol |
stopping criterion when finding the optimal J. |
ratio |
the ratio measure is used if |
p |
the order of l_1-norm; the default is |
n_sim |
number of simulated observations to calculate the
expectation of the minimum of multivariate normal random variables;
the default is |
a list with components Cvec
, the optimal sequence of Lipschitz coefficients,
bmat
, the matrix of corresponding modulus values,
tau_res
, the corresponding calibrated values of τ and δ, and
dist_opt
, the optimal distance to the orale.
n <- 500 d <- 2 X <- matrix(rnorm(n * d), nrow = n, ncol = d) tind <- X[, 1] < 0 & X[, 2] < 0 Xt <- X[tind == 1, ,drop = FALSE] Xc <- X[tind == 0, ,drop = FALSE] mon_ind <- c(1, 2) sigma <- rnorm(n)^2 + 1 sigma_t <- sigma[tind == 1] sigma_c <- sigma[tind == 0] Opt_C_seq(0.1, 1, 2, Xt, Xc, mon_ind, sigma_t, sigma_c, 0.05, 10, 0.05)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.