-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathapp02_notes.qmd
85 lines (45 loc) · 3.46 KB
/
app02_notes.qmd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
# Notes {#notes}
## Chapter 2
### section 2.4 p. 31
The second sentence of the last paragraph on p. 33 says
> We also need the `car` package in order for the summary() function to operate on boot objects the way we describe.
This sentence is **not required** if we use the `boot::boot.ci()` which simplifies `lmodboot.r()` and does not require the `car` package. See the code in this document for `lmodboot.r` in chapter 2.
## Chapter 3
The chi-square test on p. 37 gives a different result. Not clear how the author arrive at her result.
## Chapter 4
### Section 4.1
See the plots in section 4.2. They could be helpful to visualize the changes in effect measures from one level of modifier to the other.
### Section 4.2
#### Monte Carlo Simulation
A Monte Carlo is provided in section 4.2 and coded in a function called `betasim_effect_measures()`. It uses the $Beta$ distribution. It is helpful in that it
- confirms the same results as in @shanninbrumback2021
- is less CPU intensive as it needs only 5000 iterations to confirm @shanninbrumback2021
- is easier to code than `java` and uses `R` which is the declared language of @brumback2022
- allows some extra flexibility with the shape parameters of $Beta$ to investigate the conclusion with diffferent curves. See the suggestion for applications below.
#### page 72, Figure 4.1
> The probabilites shown in the Venn diagram do not add up to 100% because, for example, the event that RR changes in the same direction as RD but not in the same direction as the other two measures \[...\]. It would akward to arbitrarily one of those 2 chances as zero.
@shanninbrumback2021 mentions that it is the result of *not mutually exclusive events*. That is true. Yet, these events, properly grouped are actually mutually exclusive. In section 4.2 they are called **Opposite pairwise events**. Using these definitions then yes, they are mutually exclusive but cannot be properly shown in the Venn diagram. This can be easily solved by splitting the probabilities. See section 4.2 for details.
The end result a proper partitioning of the sample space $\Omega$ and is, in fact, a $\sigma-field$ (See @grimmett, section 1.2). Yet it does not change the conclusions reached in @shanninbrumback2021.
#### Applications
See my sub-section 4.2 called *Applications* where 2 possible applications are mentioned.
- Data pre-processing (data cleaning)
- Bayesian prior for Beta-binomial model
### Exercises
#### Exercise 1
Using the causal power, the conclusion is different than the official answer. It is not obvious why the official solution does not make use of the *causal power*.
#### Exercise 5
The official solution uses `gee` with the default family, that is `gaussian`.
Since the outcome $attend$ is binary isn't it better to use the `binomial` family?
We quote p. 50 from chapter 3 in that respect
> Because our outcome is binary, we choose to fit the logistic parametric model
## Chapter 6
### Section 6.1.1 ATT
The function `bootstandatt` is not necessary. The small change is taken care of in `bootstand` with the argument `att`.
### Section 6.3
The conclusions with the simulation are the same as Brumback's. However her sd for the estimators $EY1exp$ and $EY1dr$ for both $ss=40$ and $ss=100$ don't agree with my results. They are so large that they raise questions.
## Chapter 9
### Section 9.3
Replace `IV` with `NA` when its value is too close to zero
## Chapter 10
## Section 10.1
Add subsection to highlight the *checking of overlap*.