Repository navigation
Accurately transcribe Chapter 7: Confounding (pp. 77–92) - #62
Conversation
Agent-Logs-Url: https://github.com/ucdavis/win/sessions/df029107-dae5-4006-b73b-ee8b2afb2ae9 Co-authored-by: d-morrison <2474437+d-morrison@users.noreply.github.com>
There was a problem hiding this comment.
Pull request overview
This PR rewrites Chapter 7 to better match the textbook’s treatment of confounding, replacing placeholder material with a fuller causal-diagram-based exposition and updated figures. It fits into the codebase as part of the ongoing transcription/modernization of the Quarto textbook chapters.
Changes:
- Reworked
chapters/07-confounding.qmdwith a new numerical example, revised structural/backdoor-criterion discussion, new DAG-based figures, and an expanded SWIG section. - Removed the prior confounding-adjustment section and replaced it with textbook-aligned material on confounders, collider bias, and SWIGs.
- Added new terms to
inst/WORDLISTto support spell-checking for the updated chapter text.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 5 comments.
| File | Description |
|---|---|
inst/WORDLIST |
Adds spell-check dictionary entries for new Chapter 7 terminology. |
chapters/07-confounding.qmd |
Rewrites Chapter 7 content, figures, fine points, and SWIG discussion to align with the source text. |
| ### Fine Point 7.1: Descendants of Treatment and Adjustment Bias | ||
|
|
||
| ::: {.callout-note} | ||
| ## Fine Point 7.1: Do Not Adjust for Descendants of Treatment | ||
|
|
| ::: {.callout-note} | ||
| ## Fine Point 7.2: Limitations of Association-Based Confounder Criteria |
| }') | ||
| dag_b <- dagitty('dag { | ||
| U [pos="1,2"]; L [pos="1,1"]; A [pos="0,0"]; Y [pos="2,0"] | ||
| U -> L; L -> A; L -> Y; A -> Y |
| - $L \to a$ (the fixed intervention value is determined, but $L$ still affects what the natural value of $A$ would have been) | ||
| - $a \to Y^a$ (the intervention value $a$ causes $Y^a$) | ||
| - $L \to Y^a$ (the confounder $L$ also causes $Y^a$) | ||
| - $L \to A$ (the natural value of $A$ is caused by $L$) |
| patchwork | ||
| perp | ||
| positivity | ||
| pre |
|
@copilot apply changes based on the comments in this thread |
…dges, remove 'pre' from WORDLIST Agent-Logs-Url: https://github.com/ucdavis/win/sessions/efa9c6a7-bc2c-46e0-93d3-bc9c7c7cd2ca Co-authored-by: d-morrison <2474437+d-morrison@users.noreply.github.com>
Agent-Logs-Url: https://github.com/ucdavis/win/sessions/efa9c6a7-bc2c-46e0-93d3-bc9c7c7cd2ca Co-authored-by: d-morrison <2474437+d-morrison@users.noreply.github.com>
Applied all five changes from the review (commit
Also added Warning Firewall rules blocked me from connecting to one or more addresses (expand for details)I tried to connect to the following addresses, but was blocked by firewall rules:
If you need me to access, download, or install something from one of these locations, you can either:
|
|
@copilot resolve the merge conflicts in this pull request |
…anscribe-ch-7 Co-authored-by: d-morrison <2474437+d-morrison@users.noreply.github.com>
Resolved in commit |
|
chapters/07-confounding.qmdto accurately follow Chapter 7 of Hernán & RobinsU -> Yedge; update text to list both backdoor paths::: {.callout-note title="..."}without outer heading (repo convention)L -> aedge; L's arrow stays on natural-valueAprefrominst/WORDLIST*.logto.gitignore; remove accidentally committed LaTeX log filesorigin/main: keep{{< include ../latex-macros/macros.qmd >}}from main before the setup chunk