|
3 | 3 | <head>
|
4 | 4 | <title>Causal Modeling in R: Whole Game</title>
|
5 | 5 | <meta charset="utf-8" />
|
| 6 | + <meta name="author" content="Malcolm Barrett" /> |
6 | 7 | <script src="libs/header-attrs/header-attrs.js"></script>
|
7 | 8 | <link href="libs/remark-css/default.css" rel="stylesheet" />
|
8 | 9 | <link rel="stylesheet" href="theme.css" type="text/css" />
|
|
12 | 13 | class: center, middle, inverse, title-slide
|
13 | 14 |
|
14 | 15 | # Causal Modeling in R: Whole Game
|
15 |
| -### 2020-07-29 (updated: 2020-12-01) |
| 16 | +### Malcolm Barrett |
| 17 | +### Teladoc Health |
| 18 | +### 2021-09-01 (updated: 2021-08-30) |
16 | 19 |
|
17 | 20 | ---
|
18 | 21 |
|
|
45 | 48 | ```
|
46 | 49 |
|
47 | 50 | ```
|
48 |
| -## # A tibble: 1,566 x 67 |
| 51 | +## # A tibble: 1,566 × 67 |
49 | 52 | ## seqn qsmk death yrdth modth dadth sbp dbp sex
|
50 | 53 | ## <dbl> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl> <fct>
|
51 | 54 | ## 1 233 0 0 NA NA NA 175 96 0
|
|
67 | 70 |
|
68 | 71 | ## Did those who quit smoking gain weight?
|
69 | 72 |
|
70 |
| -<img src="01-causal_modeling_whole_game_files/figure-html/unnamed-chunk-2-1.png" style="display: block; margin: auto;" /> |
| 73 | +<img src="01-causal_modeling_whole_game_files/figure-html/unnamed-chunk-2-1.png" width="80%" style="display: block; margin: auto;" /> |
71 | 74 |
|
72 | 75 | ---
|
73 | 76 |
|
|
86 | 89 | ```
|
87 | 90 |
|
88 | 91 | ```
|
89 |
| -## # A tibble: 2 x 3 |
| 92 | +## # A tibble: 2 × 3 |
90 | 93 | ## qsmk mean_weight_change sd
|
91 | 94 | ## <dbl> <dbl> <dbl>
|
92 | 95 | *## 1 0 1.98 7.45
|
|
101 | 104 |
|
102 | 105 | ---
|
103 | 106 |
|
104 |
| -<img src="01-causal_modeling_whole_game_files/figure-html/unnamed-chunk-4-1.png" style="display: block; margin: auto;" /> |
| 107 | +<img src="01-causal_modeling_whole_game_files/figure-html/unnamed-chunk-4-1.png" width="80%" style="display: block; margin: auto;" /> |
105 | 108 |
|
106 | 109 | ---
|
107 | 110 |
|
108 |
| -<img src="01-causal_modeling_whole_game_files/figure-html/unnamed-chunk-5-1.png" style="display: block; margin: auto;" /> |
| 111 | +<img src="01-causal_modeling_whole_game_files/figure-html/unnamed-chunk-5-1.png" width="80%" style="display: block; margin: auto;" /> |
109 | 112 |
|
110 | 113 | ---
|
111 | 114 |
|
|
115 | 118 |
|
116 | 119 | ---
|
117 | 120 |
|
118 |
| -<img src="01-causal_modeling_whole_game_files/figure-html/unnamed-chunk-6-1.png" style="display: block; margin: auto;" /> |
| 121 | +<img src="01-causal_modeling_whole_game_files/figure-html/unnamed-chunk-6-1.png" width="80%" style="display: block; margin: auto;" /> |
119 | 122 |
|
120 | 123 | ---
|
121 | 124 |
|
|
154 | 157 | ```
|
155 | 158 |
|
156 | 159 | ```
|
157 |
| -## # A tibble: 1 x 7 |
| 160 | +## # A tibble: 1 × 7 |
158 | 161 | ## term estimate std.error statistic p.value conf.low
|
159 | 162 | ## <chr> <dbl> <dbl> <dbl> <dbl> <dbl>
|
160 | 163 | *## 1 qsmk 3.46 0.438 7.90 5.36e-15 2.60
|
|
213 | 216 |
|
214 | 217 | ## What's the distribution of weights?
|
215 | 218 |
|
216 |
| -<img src="01-causal_modeling_whole_game_files/figure-html/unnamed-chunk-11-1.png" style="display: block; margin: auto;" /> |
| 219 | +<img src="01-causal_modeling_whole_game_files/figure-html/unnamed-chunk-11-1.png" width="80%" style="display: block; margin: auto;" /> |
217 | 220 |
|
218 | 221 |
|
219 | 222 | ---
|
220 | 223 |
|
221 | 224 |
|
222 | 225 |
|
223 | 226 |
|
224 |
| -<img src="01-causal_modeling_whole_game_files/figure-html/unnamed-chunk-13-1.png" style="display: block; margin: auto;" /> |
| 227 | +<img src="01-causal_modeling_whole_game_files/figure-html/unnamed-chunk-13-1.png" width="80%" style="display: block; margin: auto;" /> |
225 | 228 |
|
226 | 229 | ---
|
227 | 230 |
|
228 |
| -<img src="01-causal_modeling_whole_game_files/figure-html/unnamed-chunk-14-1.png" style="display: block; margin: auto;" /> |
| 231 | +<img src="01-causal_modeling_whole_game_files/figure-html/unnamed-chunk-14-1.png" width="80%" style="display: block; margin: auto;" /> |
229 | 232 |
|
230 | 233 | ---
|
231 | 234 | class: inverse, center, middle
|
|
259 | 262 | ```
|
260 | 263 |
|
261 | 264 | ```
|
262 |
| -## # A tibble: 1 x 7 |
| 265 | +## # A tibble: 1 × 7 |
263 | 266 | ## term estimate std.error statistic p.value conf.low
|
264 | 267 | ## <chr> <dbl> <dbl> <dbl> <dbl> <dbl>
|
265 | 268 | *## 1 qsmk 3.44 0.408 8.43 7.47e-17 2.64
|
|
354 | 357 | ```
|
355 | 358 |
|
356 | 359 | ```
|
357 |
| -## # A tibble: 1 x 6 |
| 360 | +## # A tibble: 1 × 6 |
358 | 361 | ## term .lower .estimate .upper .alpha .method
|
359 | 362 | ## <chr> <dbl> <dbl> <dbl> <dbl> <chr>
|
360 | 363 | *## 1 qsmk 2.49 3.45 4.37 0.05 student-t
|
|
364 | 367 |
|
365 | 368 | class: middle
|
366 | 369 |
|
367 |
| -<img src="01-causal_modeling_whole_game_files/figure-html/unnamed-chunk-21-1.png" style="display: block; margin: auto;" /> |
| 370 | +<img src="01-causal_modeling_whole_game_files/figure-html/unnamed-chunk-21-1.png" width="80%" style="display: block; margin: auto;" /> |
368 | 371 |
|
369 | 372 | ---
|
370 | 373 |
|
|
0 commit comments