cjerzak commited on
Commit
b27fd42
·
verified ·
1 Parent(s): 943901c

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +63 -1
README.md CHANGED
@@ -9,4 +9,66 @@ license: mit
9
  short_description: Descriptive representation by country
10
  ---
11
 
12
- Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
9
  short_description: Descriptive representation by country
10
  ---
11
 
12
+ # Overview
13
+
14
+ This Shiny dashboard visualizes country-level representation indices from the Global Leadership Project (GLP). It allows users to explore how closely a country's political leadership mirrors its demographic makeup across various dimensions, including ethnicity, gender, religion, and language. The app features an interactive world map and detailed data displays to facilitate understanding of global leadership representation.
15
+
16
+ ## Features
17
+
18
+ - **Interactive Map:** A world map where countries are colored based on the selected representation index, using the Mollweide projection for accurate area representation.
19
+ - **Index Selection:** Choose from the following indices via a dropdown menu:
20
+ - Overall
21
+ - Representation Gap
22
+ - Ethnicity
23
+ - Gender
24
+ - Religion
25
+ - Language
26
+ - **Country Details:** Click on a country to view its specific representation indices in a side panel, with tooltips providing additional information on hover.
27
+ - **Data Source:** Combines data from the Global Leadership Project (GLP) and Natural Earth for map rendering.
28
+
29
+ ## Usage
30
+
31
+ 1. **Select an Index:** Use the dropdown menu in the sidebar to choose a representation index to visualize on the map.
32
+ 2. **Explore the Map:**
33
+ - Hover over countries to see a tooltip with detailed index values.
34
+ - Click a country to display its full representation data in the side panel.
35
+ 3. **Interpret the Data:**
36
+ - Larger positive scores indicate a closer match between leaders and citizens.
37
+ - More negative gaps suggest a greater shortfall in representation.
38
+
39
+ ## Data and Methodology
40
+
41
+ The representation indices are derived from the Global Leadership Project (GLP) dataset, with map data provided by Natural Earth. Custom country code matches are applied for Kosovo (XKX) and Somaliland (SOM) to ensure accurate representation. For comprehensive methodological details, refer to the accompanying paper:
42
+
43
+ - John Gerring, Connor T. Jerzak, Erzen Öncel. "The Composition of Descriptive Representation." *American Political Science Review*, 118(2): 784-801, 2024.
44
+ [Download PDF][BibTeX]
45
+
46
+ **Technical Note:** Some data points did not meet a 75% completeness threshold and were imputed using an algorithm. Interpret individual country values with caution due to potential imputation effects.
47
+
48
+ The data is loaded from the file `CountryRepresentationRankings.csv`, which should be included in the app's directory or repository for proper functionality.
49
+
50
+ ## Setup and Deployment
51
+
52
+ This application is built using R and Shiny. To run it locally, install the required R packages and execute the app as follows:
53
+
54
+ ```R
55
+ # Install necessary packages
56
+ install.packages(c("shiny", "shinydashboard", "dplyr", "readr", "sf", "rnaturalearth", "rnaturalearthdata", "countrycode", "ggplot2", "ggiraph"))
57
+
58
+ # Run the app
59
+ shiny::runApp()
60
+ ```
61
+
62
+ # References
63
+ John Gerring, Connor T. Jerzak, Erzen Öncel. "The Composition of Descriptive Representation." *American Political Science Review*, 118(2): 784-801, 2024. [\[PDF\]](https://www.cambridge.org/core/services/aop-cambridge-core/content/view/7EAEA1CA4C553AB9D76054D1FA9C0840/S0003055423000680a.pdf/the-composition-of-descriptive-representation.pdf) [\[Dataverse\]](https://dataverse.harvard.edu/dataset.xhtml?persistentId=doi:10.7910/DVN/BIQZNT)
64
+ ```
65
+ @article{GJO-CompDR,
66
+ title={The Composition of Descriptive Representation},
67
+ author={Gerring, John and Connor T. Jerzak and Erzen Öncel},
68
+ journal={American Political Science Review},
69
+ year={2023},
70
+ volume={118},
71
+ number={2},
72
+ pages={784-801}
73
+ }
74
+ ```