You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
_After updating the code chunks below, change `eval = TRUE` before knitting._
55
+
*After updating the code chunks below, change `eval: true` before rendering*
55
56
56
57
Add the ATE weights to the data frame, `seven_dwarfs_prop`
57
58
@@ -76,16 +77,6 @@ Stretch Goal 2:
76
77
77
78
Update the code below to examine the distribution of the weighted sample. **HINT** the part that needs to be updated is the `weight` parameter in two of the `geom_mirror_histogram()` call.
Copy file name to clipboardExpand all lines: exercises/07-pscores-diagnostics-exercises.qmd
+4-2Lines changed: 4 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -5,10 +5,12 @@ format: html
5
5
6
6
7
7
```{r}
8
+
#| label: setup
8
9
library(tidyverse)
9
10
library(broom)
10
11
library(touringplans)
11
12
library(halfmoon)
13
+
library(propensity)
12
14
```
13
15
14
16
We are interested in examining the relationship between whether there were "Extra Magic Hours" in the morning (the **exposure**) and the average wait time for the Seven Dwarfs Mine Train the same day between 9am and 10am (the **outcome**).
@@ -28,12 +30,12 @@ propensity_model <- glm(
28
30
29
31
seven_dwarfs_ps <- propensity_model |>
30
32
augment(type.predict = "response", data = seven_dwarfs) |>
Copy file name to clipboardExpand all lines: exercises/08-outcome-model-exercises.qmd
+2-1Lines changed: 2 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -5,6 +5,7 @@ format: html
5
5
6
6
7
7
```{r}
8
+
#| label: setup
8
9
library(tidyverse)
9
10
library(broom)
10
11
library(touringplans)
@@ -18,7 +19,7 @@ We are interested in examining the relationship between whether there were "Extr
18
19
19
20
## Your turn
20
21
21
-
_After updating the code chunks below, change `eval = TRUE` before knitting._
22
+
*After updating the code chunks below, change `eval: true` before rendering*
22
23
23
24
Create a function called `ipw_fit` that fits the propensity score model from Exercise 03, incorporates the ATE weights calculated in Exercise 04, and fits a weighted outcome model.
<h3id="causal-inference-comprehensive-text-on-causal-inference.-free-online."><ahref="https://www.hsph.harvard.edu/miguel-hernan/causal-inference-book/">Causal Inference</a>: Comprehensive text on causal inference. Free online.</h3>
727
-
<h3id="causal-inference-notebook-r-code-to-go-along-with-causal-inference"><ahref="http://causalinferencebookr.netlify.com">Causal Inference Notebook</a>: R code to go along with Causal Inference</h3>
728
731
<h3id="bootstrap-confidence-intervals-with-rsample"><ahref="https://rsample.tidymodels.org/articles/Applications/Intervals.html">Bootstrap confidence intervals with {rsample}</a></h3>
732
+
<h3id="r-causal-our-github-org-with-r-packages-and-examples"><ahref="https://github.com/r-causal">R-causal</a>: Our GitHub org with R packages and examples</h3>
0 commit comments