Skip to content

Commit 909373c

Browse files
emcghee73migurski
authored andcommitted
Updated documentation
1 parent f025cc8 commit 909373c

2 files changed

Lines changed: 46 additions & 27 deletions

File tree

2025/README_model_no_2024_pvote.md

Lines changed: 26 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,19 @@
1818

1919
## Methodology: Models without 2024 Presidential Vote
2020

21-
### The Big Picture
21+
This is the model we use when we do not have the latest geographic
22+
election data for a particular state. When we do have such data, we use
23+
a slightly different model described in README_model_with_2024_pvote.md.
24+
25+
To run this model for Congress, use the code in
26+
planscore_models_congress.R in the section headed “CONGRESS: 2024
27+
PRESIDENTIAL VOTE NOT AVAILABLE.” To run the model for state
28+
legislatures, use the code in planscore_models_state_leg.R. In both
29+
cases, the code asks the user at the top of the file to designate a
30+
pathname for saving output. The code otherwise automatically draws the
31+
necessary data from this github page.
32+
33+
### The Models: The Big Picture
2234

2335
We use the correlation between the presidential vote on the one hand and
2436
state legislative or congressional votes on the other to predict how new
@@ -33,10 +45,6 @@ which partisan tides have changed party performance from one election to
3345
the next. This enables us to generate the most accurate, data-driven,
3446
and transparent prediction we can.
3547

36-
This is the model we use when we do not have the latest geographic
37-
election data for a particular state. When we do have such data, we use
38-
a slightly different model described here.
39-
4048
### The Details
4149

4250
We use a Bayesian hierarchical model of district-level election returns,
@@ -159,7 +167,7 @@ partisan tides that occurred over the last decade.
159167

160168
Full results for our four separate models can be found below.
161169

162-
## ### Congress prediction model with incumbency ($k=2$)
170+
### Congress prediction model with incumbency ($k=2$)
163171

164172
| Term | Estimate | 95% Credible Interval |
165173
|:---|---:|---:|
@@ -180,7 +188,7 @@ Full results for our four separate models can be found below.
180188
| Intercept – Incumbency ($\rho\,\sigma_{\beta_{0c}}\sigma_{\beta_{2c}}$) | -0.15 | \[-0.73, 0.53\] |
181189
| Pres. vote – Incumbency ($\rho\,\sigma_{\beta_{1c}}\sigma_{\beta_{2c}}$) | -0.55 | \[-0.94, 0.25\] |
182190

183-
## ### Congress prediction model without incumbency ($k=1$)
191+
### Congress prediction model without incumbency ($k=1$)
184192

185193
| Term | Estimate | 95% Credible Interval |
186194
|:---|---:|---:|
@@ -196,10 +204,11 @@ Full results for our four separate models can be found below.
196204
| **CYCLE-LEVEL** *Correlations* | | |
197205
| Intercept – Pres. vote ($\rho\,\sigma_{\beta_{0c}}\sigma_{\beta_{1c}}$) | -0.50 | \[-0.93, 0.35\] |
198206

199-
##
200-
## > Note: Model estimated in brms for R. Model based on 4 MCMC chains run for 6000 iterations each with a 2000 iteration warm-up. All model parameters converged well with $\hat{R}\le 1.01$.
207+
> Note: Model estimated in brms for R. Model based on 4 MCMC chains run
208+
> for 6000 iterations each with a 2000 iteration warm-up. All model
209+
> parameters converged well with $\hat{R}\le 1.01$.
201210
202-
## ### State legislature prediction model with incumbency ($k=2$)
211+
### State legislature prediction model with incumbency ($k=2$)
203212

204213
| Term | Estimate | 95% Credible Interval |
205214
|:---|---:|---:|
@@ -220,10 +229,11 @@ Full results for our four separate models can be found below.
220229
| Intercept – Incumbency ($\rho\,\sigma_{\beta_{0c}}\sigma_{\beta_{2c}}$) | 0.20 | \[-0.50, 0.77\] |
221230
| Pres. vote – Incumbency ($\rho\,\sigma_{\beta_{1c}}\sigma_{\beta_{2c}}$) | -0.75 | \[-0.97, -0.21\] |
222231

223-
##
224-
## > Note: Model estimated in brms for R. Model based on 4 MCMC chains run for 6000 iterations each with a 2000 iteration warm-up. All model parameters converged well with $\hat{R}\le 1.01$.
232+
> Note: Model estimated in brms for R. Model based on 4 MCMC chains run
233+
> for 6000 iterations each with a 2000 iteration warm-up. All model
234+
> parameters converged well with $\hat{R}\le 1.01$.
225235
226-
## ### State legislature prediction model without incumbency ($k=1$)
236+
### State legislature prediction model without incumbency ($k=1$)
227237

228238
| Term | Estimate | 95% Credible Interval |
229239
|:---|---:|---:|
@@ -239,5 +249,6 @@ Full results for our four separate models can be found below.
239249
| **CYCLE-LEVEL** *Correlations* | | |
240250
| Intercept – Pres. vote ($\rho\,\sigma_{\beta_{0c}}\sigma_{\beta_{1c}}$) | -0.40 | \[-0.87, 0.33\] |
241251

242-
##
243-
## > Note: Model estimated in brms for R. Model based on 4 MCMC chains run for 6000 iterations each with a 2000 iteration warm-up. All model parameters converged well with $\hat{R}\le 1.01$.
252+
> Note: Model estimated in brms for R. Model based on 4 MCMC chains run
253+
> for 6000 iterations each with a 2000 iteration warm-up. All model
254+
> parameters converged well with $\hat{R}\le 1.01$.

2025/README_model_with_2024_pvote.md

Lines changed: 20 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,21 @@
1818

1919
## Methodology: Models with 2024 Presidential Vote
2020

21+
This is the model we use when we have the latest geographic election
22+
data for a particular state. When we do not have such data, we use a
23+
slightly different model described in README_model_no_2024_pvote.md. At
24+
present we only have fully updated data for Congress, so only
25+
congressional results are reported on this methods page. See the
26+
companion page for state legislative results, and for the results of a
27+
modified version of the congressional model for states that do not have
28+
fully updated data.
29+
30+
To run this model for Congress, use the code in
31+
planscore_models_congress.R in the section headed “CONGRESS: 2024
32+
PRESIDENTIAL VOTE AVAILABLE.” The code asks the user at the top of the
33+
file to designate a pathname for saving output. The code otherwise
34+
automatically draws the necessary data from this github page.
35+
2136
### The Big Picture
2237

2338
We use the correlation between the presidential vote on the one hand and
@@ -33,14 +48,6 @@ which partisan tides have changed party performance from one election to
3348
the next. This enables us to generate the most accurate, data-driven,
3449
and transparent prediction we can.
3550

36-
This is the model we use when we have the latest geographic election
37-
data for a particular state. When we do not have such data, we use a
38-
slightly different model described here. At present we only have fully
39-
updated data for Congress, so only congressional results are reported on
40-
this methods page. See the companion page for state legislative results,
41-
and for the results of a modified version of the congressional model for
42-
states that do not have fully updated data.
43-
4451
### The Details
4552

4653
We use a Bayesian hierarchical model of district-level election returns,
@@ -155,7 +162,7 @@ partisan tides that occurred over the last decade.
155162

156163
Full results for our four separate models can be found below.
157164

158-
## ### Congress prediction model with incumbency ($k=2$)
165+
### Congress prediction model with incumbency ($k=2$)
159166

160167
| Term | Estimate | 95% Credible Interval |
161168
|:---|---:|---:|
@@ -176,7 +183,7 @@ Full results for our four separate models can be found below.
176183
| Intercept – Incumbency ($\rho\,\sigma_{\beta_{0c}}\sigma_{\beta_{2c}}$) | -0.37 | \[-0.87, 0.34\] |
177184
| Pres. vote – Incumbency ($\rho\,\sigma_{\beta_{1c}}\sigma_{\beta_{2c}}$) | -0.59 | \[-0.94, 0.16\] |
178185

179-
## ### Congress prediction model without incumbency ($k=1$)
186+
### Congress prediction model without incumbency ($k=1$)
180187

181188
| Term | Estimate | 95% Credible Interval |
182189
|:---|---:|---:|
@@ -192,5 +199,6 @@ Full results for our four separate models can be found below.
192199
| **CYCLE-LEVEL** *Correlations* | | |
193200
| Intercept – Pres. vote ($\rho\,\sigma_{\beta_{0c}}\sigma_{\beta_{1c}}$) | -0.55 | \[-0.95, 0.29\] |
194201

195-
##
196-
## > Note: Model estimated in brms for R. Model based on 4 MCMC chains run for 6000 iterations each with a 2000 iteration warm-up. All model parameters converged well with $\hat{R}\le 1.01$.
202+
> Note: Model estimated in brms for R. Model based on 4 MCMC chains run
203+
> for 6000 iterations each with a 2000 iteration warm-up. All model
204+
> parameters converged well with $\hat{R}\le 1.01$.

0 commit comments

Comments
 (0)