CausalPy icon indicating copy to clipboard operation
CausalPy copied to clipboard

New example: ANCOVA for confounding

Open drbenvincent opened this issue 1 year ago • 0 comments

The existing ANCOVA notebook focusses clearly on a pre-test post-test experimental design. However, the ANCOVA style approach can also be used in situations where we have:

  • a categorical treatment variable $Z$
  • a continuous confounder $C$
  • a continuous outcome $Y$

Screenshot 2023-05-22 at 11 08 43

  • [ ] Add an example for this situation
  • [ ] ~~Change the kwarg pretreatment_variable_name. This needs to be a more general name. We'll also need to update the existing ANCOVA example to reflect this change in kwarg name.~~ This would only be required if we ended up using the PrePostNEGD class for generic ANCOVA or 'controlling for confounders', which doesn't make any sense.

Some thought needs to go into this. At the moment the pre/post ANCOVA example uses the PrePostNEGD class. I think this is reasonable for that specific situation, but if we want to just to generic ANCOVA, or a 'controlling for confounders' approach, then we'd want to use a different class.

drbenvincent avatar May 22 '23 10:05 drbenvincent