https://github.com/seungwoo-stat/20th-pe-forecast
Forecasting the four-party vote share of the 20th presidential election of Republic of Korea
https://github.com/seungwoo-stat/20th-pe-forecast
compositional-data presidential-election
Last synced: 12 days ago
JSON representation
Forecasting the four-party vote share of the 20th presidential election of Republic of Korea
- Host: GitHub
- URL: https://github.com/seungwoo-stat/20th-pe-forecast
- Owner: seungwoo-stat
- License: mit
- Created: 2022-05-06T05:44:08.000Z (about 4 years ago)
- Default Branch: main
- Last Pushed: 2023-11-23T07:32:49.000Z (over 2 years ago)
- Last Synced: 2025-10-30T03:13:21.874Z (9 months ago)
- Topics: compositional-data, presidential-election
- Language: R
- Homepage:
- Size: 16.8 MB
- Stars: 1
- Watchers: 1
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# 20th Presidential Election Forecast
Forecasting the four-party vote share of the 20th presidential election of the Republic of Korea

## Overview
- Execute the `R` files in each folder in the order of the folders' name: `1a_data_generate` - `1b_summary` - `2_fundamental_model` - `3_poll_model`
- `1a_data_generate` folder
- `save_RData.R` executes all three `R` files in the same folder. By result, it generates `pe.RData` file that saves historical presidential election results and 20th presidential election pre-election polls.
- `1b_summary` folder
- Use `basic_plot.R` to plot summary of the historical two-party vote share of the Democratic Party. This plot is included in our manuscript as figure 1.
- `2_fundamental_model` folder
- Run `run-fund-model.R` to conduct posterior sampling using Rstan. Rstan codes are in `fund-model-simple.stan` file.
- Use `fund-model-plot.R` to make summary plots from the posterior samples.
- `3_poll_model` folder
- Run `run-poll-model.R` to conduct posterior sampling using Rstan. Rstan codes are in `poll-model.stan` file.
- Use `poll-model-plot.R` to make summary plots from the posterior samples.
## Reference
- Seungwoo Kang and Hee-Seok Oh. (2024) [Forecasting South Korea's Presidential Election via Multiparty Dynamic Bayesian Modeling](https://doi.org/10.1016/j.ijforecast.2023.01.004). *International Journal of Forecasting*. **40**(1), pp. 124-141.