DoWhy is a Python library for causal inference that supports explicit modeling and testing of causal assumptions. DoWhy is based on a unified language for causal inference, combining causal graphical models and potential outcomes frameworks.
Describe the bugThe docs for estimate_effect indicate that if effect_modifiers=None (the default), then the effect modifiers from the CausalModel are used, but this doesn't appear to be the case; rather, the effect_modifiers=None case is treated as if effect_modifiers=[] were used instead.
Expected behavior
The estimates from est1 and est2 should be the same (the CATE estimates conditional on the X column) while est3 should be different (the ATE, conditional on no variables).
Actual behavior
The estimates from est1 and est3 are the same instead.
Version information:
DoWhy version 0.9, 0.9.1 (this worked in dowhy<0.9)
Describe the bug The docs for
estimate_effect
indicate that ifeffect_modifiers=None
(the default), then the effect modifiers from the CausalModel are used, but this doesn't appear to be the case; rather, theeffect_modifiers=None
case is treated as ifeffect_modifiers=[]
were used instead.Steps to reproduce the behavior
Expected behavior The estimates from est1 and est2 should be the same (the CATE estimates conditional on the X column) while est3 should be different (the ATE, conditional on no variables).
Actual behavior The estimates from est1 and est3 are the same instead.
Version information: