py-why / dowhy

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.
https://www.pywhy.org/dowhy
MIT License
6.99k stars 923 forks source link

Clarification on implications of refutation tests #285

Open vicbeldo98 opened 3 years ago

vicbeldo98 commented 3 years ago

Hi! I have some doubts about which are the deducible implications the refutation test provides. Imagine I have a model where placebo treatment, bootstrap validation, random common causa and subset validation fail. The only thing I can conclude is that my model is wrong somewhere, or is there any more information implied?

Thank you in advanced!

amit-sharma commented 3 years ago

That's a great question. In general, these tests simply detect that there is an error, but do not provide an obvious way of correcting it.

They do provide some hints though. In particular, there are two kinds of refutations: step-level refutations, and end-to-end refutations. Step-level refutation tells you that something is wrong in a particular step (Model, Identify, Estimate) whereas end-to-end refutations tell you that there is an error but nothing more. They are analogous to unit tests and integration tests in software engineering.

Placebo treatment refuter and dummy outcome refuter are examples of end-to-end refutations. Here we have no idea why the test failed. But these tests, being end-to-end, can capture errors that step-level tests may miss.

Hope this was helpful.