add_democracy()
allows you to add estimates of democracy to your data.
Value
add_democracy()
takes a (dyad-year, leader-year, leader-dyad-year,
state-year) data frame and adds information about the level of democracy
for the state or two states in the dyad in a given year. If the data are
dyad-year or leader-dyad-year, the function adds six total columns for
the first state (i.e. ccode1
or gwcode1
) and the second state (i.e.
ccode2
or gwcode2
) about the level of democracy measured by the
Varieties of Democracy project (v2x_polyarchy
), the Polity project
(polity2
), and Xavier Marquez' QuickUDS
extensions/estimates. If the
data are state-year or leader-year, the function returns three additional
columns to the original data that contain that same information for a given
state in a given year.
Details
Be mindful that the data are fundamentally state-year and that extensions to leader-level data should be understood as approximations for leaders in a given state-year.
A vignette on the package's website talks about how these data are here
primarily to encourage you to maximize the number of observations in the
analysis to follow. Xavier Marquez' QuickUDS
estimates have the best
coverage. If democracy is ultimately a control variable, or otherwise a
variable not of huge concern for the analysis (i.e. the user has no
particular stake on the best measurement of democracy or the best
conceptualization and operationalization of "democracy"), please
use Marquez' estimates instead of Polity or V-dem. If the user is
doing an analysis of inter-state conflict, and across the standard
post-1816 domain in conflict studies, definitely don't use
the Polity data because the extent of its missingness is both large and
unnecessary. Please read the vignette describing these issues
here: http://svmiller.com/peacesciencer/articles/democracy.html
References
Coppedge, Michael, John Gerring, Carl Henrik Knutsen, Staffan I. Lindberg, Jan Teorell, David Altman, Michael Bernhard, M. Steven Fish, Adam Glynn, Allen Hicken, Anna Luhrmann, Kyle L. Marquardt, Kelly McMann, Pamela Paxton, Daniel Pemstein, Brigitte Seim, Rachel Sigman, Svend-Erik Skaaning, Jeffrey Staton, Agnes Cornell, Lisa Gastaldi, Haakon Gjerlow, Valeriya Mechkova, Johannes von Romer, Aksel Sundtrom, Eitan Tzelgov, Luca Uberti, Yi-ting Wang, Tore Wig, and Daniel Ziblatt. 2020. "V-Dem Codebook v10" Varieties of Democracy (V-Dem) Project.
Marshall, Monty G., Ted Robert Gurr, and Keith Jaggers. 2017. "Polity IV Project: Political Regime Characteristics and Transitions, 1800-2017." Center for Systemic Peace.
Marquez, Xavier, "A Quick Method for Extending the Unified Democracy Scores" (March 23, 2016). doi: 10.2139/ssrn.2753830
Pemstein, Daniel, Stephen Meserve, and James Melton. 2010. "Democratic Compromise: A Latent Variable Analysis of Ten Measures of Regime Type." Political Analysis 18(4): 426-449.
Examples
# just call `library(tidyverse)` at the top of the your script
library(magrittr)
cow_ddy %>% add_democracy()
#> # A tibble: 2,139,270 × 9
#> ccode1 ccode2 year v2x_polyarchy1 polity21 xm_qudsest1 v2x_polyarchy2
#> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl>
#> 1 2 20 1920 0.446 10 1.19 0.442
#> 2 2 20 1921 0.509 10 1.19 0.576
#> 3 2 20 1922 0.51 10 1.19 0.622
#> 4 2 20 1923 0.516 10 1.19 0.622
#> 5 2 20 1924 0.514 10 1.20 0.622
#> 6 2 20 1925 0.505 10 1.20 0.622
#> 7 2 20 1926 0.511 10 1.20 0.661
#> 8 2 20 1927 0.53 10 1.20 0.672
#> 9 2 20 1928 0.533 10 1.25 0.672
#> 10 2 20 1929 0.549 10 1.25 0.672
#> # ℹ 2,139,260 more rows
#> # ℹ 2 more variables: polity22 <dbl>, xm_qudsest2 <dbl>
create_stateyears(system="gw") %>% add_democracy()
#> Joining with `by = join_by(gwcode, year)`
#> # A tibble: 18,637 × 6
#> gwcode statename year v2x_polyarchy polity2 xm_qudsest
#> <dbl> <chr> <dbl> <dbl> <dbl> <dbl>
#> 1 2 United States of America 1816 0.367 9 0.707
#> 2 2 United States of America 1817 0.37 9 0.707
#> 3 2 United States of America 1818 0.365 9 0.707
#> 4 2 United States of America 1819 0.362 9 0.707
#> 5 2 United States of America 1820 0.349 9 0.707
#> 6 2 United States of America 1821 0.336 9 0.707
#> 7 2 United States of America 1822 0.341 9 0.707
#> 8 2 United States of America 1823 0.345 9 0.707
#> 9 2 United States of America 1824 0.345 9 0.707
#> 10 2 United States of America 1825 0.341 9 0.707
#> # ℹ 18,627 more rows
create_stateyears(system="cow") %>% add_democracy()
#> Joining with `by = join_by(ccode, year)`
#> # A tibble: 17,121 × 6
#> ccode statenme year v2x_polyarchy polity2 xm_qudsest
#> <dbl> <chr> <dbl> <dbl> <dbl> <dbl>
#> 1 2 United States of America 1816 0.367 9 0.707
#> 2 2 United States of America 1817 0.37 9 0.707
#> 3 2 United States of America 1818 0.365 9 0.707
#> 4 2 United States of America 1819 0.362 9 0.707
#> 5 2 United States of America 1820 0.349 9 0.707
#> 6 2 United States of America 1821 0.336 9 0.707
#> 7 2 United States of America 1822 0.341 9 0.707
#> 8 2 United States of America 1823 0.345 9 0.707
#> 9 2 United States of America 1824 0.345 9 0.707
#> 10 2 United States of America 1825 0.341 9 0.707
#> # ℹ 17,111 more rows