skgrf
skgrf copied to clipboard
ATE+Clustering
Hey! two questions:
- is there an analogous function to
average_treatment_effect()in R? - Does
GRFForestCausalRegressorallows clustering?
Thanks!
- No, not yet.
- It should! The fit params should allow you to pass a cluster array. ref
Thanks for answering!
- is there a way you recommend to calculate it in a setup with observational data?
I don't have a recommendation. The best thing would be to port the implementation from R into python, which lives here: https://github.com/grf-labs/grf/blob/ad1b781f2a9dec120eb6e5c03e6e111556f81ada/r-package/grf/R/average_treatment_effect.R
If you are in a setting with binary W you can have a look at the first expression for Gamma https://grf-labs.github.io/grf/articles/muhats.html to understand what the code above is doing. If you have clusters specified you'd want to adjust your sample std. of Gamma for that.