Learn R Programming

ITRLearn (version 1.0-1)

maximin: Maixmin projection learning for optimal individualized treatment regime

Description

Derives a meaningful and reliable individualized treatment regime for future patients based on estimated groupwise contrast function.

Usage

maximin(B, c0)

Arguments

B

An \(p_1\)*\(G\) matrix containing parameters in the groupwise contast function. Here \(p_1\) is the dimension of x.tau and \(G\) is the number of subgroups. It does not contain the intercept term. It can be computed by MPL.

c0

The common marginal treatment effect shared by all subgroups. It can be computed by MPL. maximin to compute the maximin effects.

Value

A vector of maximin effects.

Details

Denoted by \(\beta_g\) the \(g\)-th column of B. This function computes $$\arg\max_{\|(\beta^T,c)^T\|=1} \min_{g\in\{1,\dots,G\}} (\beta_g^T \beta+c_0 c).$$ The above optimaization problem can be efficiently computed based on quadratic programming.

References

Shi, C., Song, R., Lu, W., and Fu, B. (2018). Maximin Projection Learning for Optimal Treatment Decision with Heterogeneous Individualized Treatment Effects. Journal of the Royal Statistical Society, Series B, 80: 681-702.

See Also

MPL

Examples

Run this code
# NOT RUN {
set.seed(12345)
X <- matrix(rnorm(1600), 800, 2)
A <- rbinom(800, 1, 0.5)
h <- 1+sin(0.5*pi*X[,1]+0.5*pi*X[,2])
tau <- rep(0, 800)
B <- matrix(0, 2, 4)
B[,1] <- c(2,0)
B[,2] <- 2*c(cos(15*pi/180), sin(15*pi/180))
B[,3] <- 2*c(cos(70*pi/180), sin(70*pi/180))
B[,4] <- c(0,2)
for (g in 1:4){
    tau[((g-1)*200+1):(g*200)] <- X[((g-1)*200+1):(g*200),]%*%B[,g]
}
## mean and scale of the subgroup covariates are allowed to be different
X[1:200,1] <- X[1:200,1]+1
X[201:400,2] <- 2*X[201:400,2]-1
X[601:800,] <- X[601:800,]/2
Y <- h+A*tau+0.5*rnorm(800)
G <- c(rep(1,200), rep(2,200), rep(3,200), rep(4,200))
result <- MPL(Y~X|A|G)
maximin(result$B, result$c0)
# }

Run the code above in your browser using DataLab