# SE of a PSM with exact matching

I am evaluating and educational program with a PSM in STATA. Suppose that

T= variable of treatment
X= cofounders
Z= variable with exact matching
Y = output

Because I know that there are very important variables in education , I want to do exact matching in some variables (z1 z2 z3)

So I estimate the propensity score and I do exact matching with a tip.

First of all I estimate the scoring.

logit T x1 x2 x3 x4 x5 x6 x7 z1 z2 z3
predict Prtreatment

Second I create a variable of groups and a new score

egen     scoringGroup = group(z1 z2 z3)
replace  scoringGroup =scoringGroup *2+ Prtreatment

Then I use the command psmatch2 of STATA.

psmatch2  T   ,   caliper(0.1)  neighbor(1) out( Y )  pscore(scoringGroup) ties common
psmatch2  T   ,  caliper(0.1)  kernel  out( Y )  pscore(scoringGroup)

I estimate the SE using bootstraping when I use kernel; and I use the SE of psmatch2 after one nearest neighbor

By default psmatch2 calculates approximate standard errors on the treatment effects assuming independent observations, fixed weights, homoskedasticity of the outcome variable within the treated and within the control groups and that the variance of the outcome does not depend on the propensity score:

The command psmatch2 gives a SE that doesn´t depend on the scoring,
but the SE does not take into account that the propensity score is estimated. $$Var( \tau_{ATT} ) = \frac{Var(Y | DM=1)}{N1} + \frac{\sum_{ i \, in \, DM=0}^{} w_{i}^2 Var(Y | DM=0) }{N1^2}$$

where N1 is the number of matched treated, DM=1 denotes the matched treated, DM=0 the matched controls and $w_{i}$ is the weight given to control

My question is how sholud I estimate the standard errors with a PSM with exact matching? ; Are the SE of the command psmatch ok in this case?