pymc-examples icon indicating copy to clipboard operation
pymc-examples copied to clipboard

Add more causal thinking into moderation notebook

Open drbenvincent opened this issue 1 month ago • 1 comments

WIP do not merge This PR partially addresses #555 in that it adds more causal thinking into the existing moderation notebook, but not the mediation notebook.

  • [x] Add in the introduction that we will make a distinction between statistical and causal ideas.
  • [x] Ensure the ordering of terms is consistent in all equations
  • [ ] Add a section on data visualisation
  • [x] Clarify that we are focussing on observational data and don't consider experimental/interventional approaches
  • [X] We currently have a “statistical” diagram, but we should add a causal DAG
  • [ ] Discuss the DAG. If this is our entire causal DAG then we have no real complexities in terms of backdoor paths etc. We can simply collect data and make inferences about the strengths of the causal relationships given the DAG and assumptions (e.g. linearity of relationships).
  • [x] ConstantData -> Data nodes in the pymc model
  • [x] Clarify that the “Related issues: mean centering and multicollinearity” section comes from the statistical literature
  • [ ] ~~Definitely bring in insights from Rohrer, J. M., Hünermund, P., Arslan, R. C., & Elson, M. (2022). That’s a lot to process! Pitfalls of popular path models. Advances in Methods and Practices in Psychological Science, 5(2), 25152459221095827.~~ I've added this into Further Reading, but there isn't much concrete actionable information in this paper to add here.
  • [ ] Maybe bring in insights from Wu, A. D., & Zumbo, B. D. (2008). Understanding and using mediators and moderators. Social Indicators Research, 87, 367-392.
  • [ ] ~~Almost certainly add this reference as a good primer for causal thinking with observational data: Rohrer, Julia M. "Thinking clearly about correlations and causation: Graphical causal models for observational data." Advances in methods and practices in psychological science 1.1 (2018): 27-42.~~ I've added this into Further Reading, but there isn't much concrete actionable information in this paper to add here.
  • [ ] Another useful resource: Rohrer, J. M., & Arslan, R. C. (2021). Precise answers to vague questions: Issues with interactions. Advances in Methods and Practices in Psychological Science, 4(2).
  • [x] Add those references to the Further Reading section
  • [ ] Check updates to style guide

  • [ ] Notebook follows style guide https://docs.pymc.io/en/latest/contributing/jupyter_style.html
  • [x] PR description contains a link to the relevant issue:
    • a tracker one for existing notebooks (tracker issues have the "tracker id" label)
    • or a proposal one for new notebooks
  • [ ] Check the notebook is not excluded from any pre-commit check: https://github.com/pymc-devs/pymc-examples/blob/main/.pre-commit-config.yaml

📚 Documentation preview 📚: https://pymc-examples--662.org.readthedocs.build/en/662/

drbenvincent avatar May 16 '24 20:05 drbenvincent