# IPTW for multiple treatments

I am dealing with a dataset where patients are subjected to multiple treatments A or B or C or D . Since there are four treatment options I am using multinomial regression to estimate the propensity score $$e_i$$ which are as follows

  Obs#  Treatment  e_A       e_B       e_C       e_D
1     A          0.0011    0.4743    0.3380    0.1864
2     A          0.0013    0.3989    0.3678    0.2318
3     B          0.0171    0.2382    0.5900    0.1545
4     B          0.0355    0.3024    0.5086    0.1533
5     C          0.0171    0.2382    0.5900    0.1545
6     C          0.0355    0.3024    0.5086    0.1533
7     D          0.0791    0.1953    0.2979    0.4275
8     D          0.0272    0.2750    0.5415    0.1560


Now for IPTW I am following this article Moving towards best practice when using inverse probability of treatment weighting (IPTW) using the propensity score to estimate causal treatment effects in observational studies by Peter Austin and Beth Stuart,

This this estimating casual effects among patients where all are in either of these treatment so I am using ATT not ATE.

page 3 states that , weights for estimation of Average Treatment effect among the treated( ATT) : $${w_{ATT}} = Z_i+ \frac{(1-Z_i)e_i}{1-\hat{e}_i}$$,

And furthure the author states, these weights are obtained by multiplying the conventional weights by e$$_i$$, so that treated subjects receive a weight of one

I am not sure I understand this. For example considering first observations

   Obs#  Treatment  e_A       e_B       e_C       e_D
1     A          0.0011    0.4743    0.3380    0.1864


What is $$w_i$$ supposed to be, because if $$Z_1=A$$ indicates that $$Z_1 = 1$$ , I am not sure how
0.0011 0.4743 0.3380 0.1864 translates to a single estimate of $$e_i$$ , I suppose I could ignore $$e_i$$ in this equation $${w_{ATT}} = Z_i+ \frac{(1-Z_i)e_i}{1-\hat{e}_i}$$ because $$1-Z_i = 0$$ and the this just leaves me with $${w_{ATT}} = Z_i$$ so does this mean $$w_i = 1$$ ??

I know I am missing something here, if somebody can tell me where I am going wrong or how to calculate $$w_i$$ in a multi-treatment scenario while estimating ATT that will be helpful. Thanks.

## 1 Answer

You'll want to check out McCaffrey et al. (2013) for advice on this, not Austin & Stuart (2015), which is for binary treatments only. It's not clear to me which causal estimand you want, so I'll explain how to get weights for both.

The ATE for any pair of treatments is the effect of moving everyone from one treatment to the another. In your example, one ATE would be the effect of moving the entire population from A to B, while another might be the effect of moving the entire population from B to D.

To estimate ATE weights, you take the inverse of the estimated probability of being the group actually assigned. So, for an individual in group A, their weight would be $$w_{ATE,i}=\frac{1}{e_{A,i}}$$. More generally, the weights are $$w_{ATE,i} = \sum_{j=1}^p{\frac{I(Z_i=j)}{e_{j,i}}}$$ where $$j$$ indexes treatment group, $$I(Z_i=j)=1$$ if $$Z_i=j$$ and $$0$$ otherwise, and $$e_{j,i}=P(Z_i=j|X_i)$$.

The ATT involves choosing one group to be the "treated" or focal group. Each ATT is a comparison between another treatment group and this focal group for members of the focal groups. If we let group B be the focal group, one ATT is the effect of moving from A to B for those in group B. Another ATT is the effect of moving from D to B for those in group B.

The weights for the focal group are equal to 1, and the weights for the non-focal group are equal to the probability of being in the focal group divided by the probability of being the group actually assigned. So, $$w_{ATT(f),i} = I(Z_i=j)+e_{f,i}\sum_{j \ne f}^p{\frac{I(Z_i=j)}{e_{j,i}}}= e_{f,i} w_{ATE,i}$$ where $$f$$ is the focal group. So, just as in the binary ATT case, the ATT weights are formed by multiplying the ATE weights by the propensity score for the focal group (i.e., the probability of being in the "treated" group). The binary ATT case, the focal group is group 1, so the probability of being in the focal group is just the propensity score.

Note all of these formulas apply to the binary treatment case.

Using WeightIt in R, you would specify

w.out <- weightit(Treatment ~ X1 + X2 + X2, data = data, estimand = "ATT", focal = "B")


to estimate the ATT weights for B as the focal group using multinomial logistic regression. After checking balance (e.g., using cobalt), you can estimate the outcome model as

fit <- glm(Y ~ relevel(Treatment, "B"), data = data, weights = w.out\$weights)


You need to make sure the focal group is the reference level of the treatment variable for the coefficients to be valid ATT estimates.

• thanks Noah this will give me something to chew on. I will try the weightit function as well. Thanks. – Sundown Brownbear Apr 15 at 14:02