# Propensity Score Matching with time-varying treatment

The basic propensity score matching procedure works with cross-section data (ie collected at a certain point in time). The popular psmatch2 command uses a dummy variable indicating that an observations belongs to either the treatment or control group.

However, in my dataset this indicator-function is time-varying. The data looks as follows: I identify individuals and track them over a period of 12 years. At some point during this time period, individuals may get treated, so they "transfer from control to treatment group". Note that this can occur at any moment in time (sic!) for each individual.

Above that, my subsequent analysis would be time-dependent: From the moment the individuals are being treated, I want to estimate the ATT but only for the following year (sic!). Thus, I do not care anymore about the treated individuals 1 year after their treatment started.

psmatch2 seems to be very restrictive when it comes to that. Do you see any possibility on how to do that? Maybe there are also Matching Methods that allow me to do that.

P.S.: There is one similar question here in the forum, however it did not help me to solve this problem.

• Many "weights" that are used for analyses use very similar methods, and have very similar justifications. However, it's important to refer to them correctly. To my knowledge, propensity scores are not used to account for time-varying treatments. I believe you are thinking of marginal structural models. Sep 29, 2014 at 19:06
• Thank you for this hint, I was not aware of this model. They seem to be very popular in the epidemiology and medecine literature, however not in economics / social sciences which is my background. Sep 29, 2014 at 20:33
• I asked a similar question some weeks ago: stats.stackexchange.com/questions/113670/… Sep 29, 2014 at 20:37

In the situation considered in the paper, subjects may start treatment at any point during an observation period. An individuals who becomes exposed at time $t$ is matched to several controls selected from the corresponding risk-set, i.e. from all subjects who are still at risk of becoming exposed at time $t$.
Matching is with respect to a time-dependent propensity score, defined as the hazard of becoming exposed at time $t$ computed from a Cox proportional hazards model: $$h(t)=h_0(t)\exp(\beta'x(t))$$ where $x(t)$ is a vector of potentially time-varying predictors of treatment status. In each risk-set, matching is actually perfomed on the linear predictor scale according to the metric $$d(x_i(t),x_j(t))=\left(\hat\beta'x_i(t)-\hat\beta'x_j(t)\right)^2.$$