py-why / EconML

ALICE (Automated Learning and Intelligence for Causation and Economics) is a Microsoft Research project aimed at applying Artificial Intelligence concepts to economic decision making. One of its goals is to build a toolkit that combines state-of-the-art machine learning techniques with econometrics in order to bring automation to complex causal inference problems. To date, the ALICE Python SDK (econml) implements orthogonal machine learning algorithms such as the double machine learning work of Chernozhukov et al. This toolkit is designed to measure the causal effect of some treatment variable(s) t on an outcome variable y, controlling for a set of features x.
https://www.microsoft.com/en-us/research/project/alice/
Other
3.75k stars 711 forks source link

CATE intercept vs ATE #405

Open shrabasteebanerjee opened 3 years ago

shrabasteebanerjee commented 3 years ago

Hi,

I had a question about how to interpret the CATE intercept beta_t for linearDRLearner. Suppose I fit a model with 3 X's for heterogeneity. Does b_t give me the "average" heterogeneity for these 3 X's, and each individual X coefficient tells me the incremental effect? Somehow I was expecting beta_t to capture the ATE in the absence of heterogeneity but that doesn't seem to be the case (e.g beta_t is not significant although the ATE estimates obtained by setting X=None are, consistent with OLS results)..

vsyrgkanis commented 3 years ago

That would only be the case if your variables X_t have been centered. Other wise the ATE is theta_t' E[X_t] + beta_t.

You can make them coincide by first centering your X's and then calling the LinearDRLearner.

If you want an ATE, I would also advise that you just run LinearDRLearner, with X=None and appending X to W. This would estimate an unbiased ATE with correct confidence intervals.

Another way to get an ATE is to call: effect_inference(X).population_summary(). This also provides an ATE, but with conserivative confidence intervals as it combines the uncertainty estimates for the CATEs.

Or you could also just center the X's first and then call the LinearDRLearner and then look at the beta_t and it's inference, using the est.summary() function or est.intercept__inference()