add_sdp_gdp() allows you to add estimated GDP and "surplus" domestic product data from a 2020 analysis published in International Studies Quarterly by Anders, Fariss, and Markowitz.

add_sdp_gdp(data)

Arguments

data

a dyad-year data frame (either "directed" or "non-directed") or a state-year data frame.

Value

add_sdp_gdp() takes a dyad-year data frame or state-year data frame and adds information about the estimated gross domestic product (in 2011 USD) for that year, the estimated population in that year, the GDP per capita in that year, and what Anders, Fariss and Markowitz term the "surplus domestic product" in that year. If the data are dyad-year, the function adds eight total columns for the first state (i.e. ccode1) and the second state (i.e. ccode2) for all these estimates. If the data are state-year, the function returns four additional columns to the original data that contain that same information for a given state in a given year.

Details

The function leans on attributes of the data that are provided by the create_dyadyear() or create_stateyear() function. Make sure that function (or data created by that function) appear at the top of the proverbial pipe. Users will also want to note that the underlying function access two different data sets. It appears that the results published in the International Studies Quarterly used Correlates of War classification, but a follow-up repository on Github uses Gleditsch-Ward classification. The extent to which these estimates are generated by simulation, it does mean the estimates will be slightly different across both data sets even for common observations (e.g. the United States in 1816).

Because these are large nominal numbers, the estimates have been log-transformed. Users can always exponentiate these if they choose. Researchers can use these data to construct reasonable estimates of surplus GDP per capita, but must exponentiate the underlying variables before doing this.

References

Anders, Therese, Christopher J. Fariss, and Jonathan N. Markowitz. 2020. "Bread Before Guns or Butter: Introducing Surplus Domestic Product (SDP)" International Studies Quarterly 64(2): 392--405.

Author

Steven V. Miller

Examples

# just call `library(tidyverse)` at the top of the your script library(magrittr) cow_ddy %>% add_sdp_gdp()
#> # A tibble: 2,063,670 x 11 #> ccode1 ccode2 year wbgdp2011est1 wbpopest1 sdpest1 wbgdppc2011est1 #> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl> #> 1 2 20 1920 27.6 18.4 27.5 9.19 #> 2 2 20 1921 27.6 18.5 27.5 9.18 #> 3 2 20 1922 27.7 18.5 27.6 9.21 #> 4 2 20 1923 27.8 18.5 27.7 9.26 #> 5 2 20 1924 27.8 18.5 27.7 9.30 #> 6 2 20 1925 27.9 18.5 27.8 9.32 #> 7 2 20 1926 27.9 18.5 27.8 9.34 #> 8 2 20 1927 27.9 18.6 27.8 9.35 #> 9 2 20 1928 27.9 18.6 27.8 9.36 #> 10 2 20 1929 27.9 18.6 27.8 9.35 #> # … with 2,063,660 more rows, and 4 more variables: wbgdp2011est2 <dbl>, #> # wbpopest2 <dbl>, sdpest2 <dbl>, wbgdppc2011est2 <dbl>
create_stateyears() %>% add_sdp_gdp()
#> Joining, by = c("ccode", "year")
#> # A tibble: 16,731 x 7 #> ccode statenme year wbgdp2011est wbpopest sdpest wbgdppc2011est #> <dbl> <chr> <dbl> <dbl> <dbl> <dbl> <dbl> #> 1 2 United States of Ame… 1816 23.6 15.9 22.9 7.66 #> 2 2 United States of Ame… 1817 23.6 16.0 22.9 7.64 #> 3 2 United States of Ame… 1818 23.6 16.0 22.9 7.64 #> 4 2 United States of Ame… 1819 23.7 16.0 23.0 7.66 #> 5 2 United States of Ame… 1820 23.7 16.1 23.0 7.66 #> 6 2 United States of Ame… 1821 23.8 16.1 23.1 7.68 #> 7 2 United States of Ame… 1822 23.8 16.1 23.1 7.70 #> 8 2 United States of Ame… 1823 23.8 16.1 23.1 7.69 #> 9 2 United States of Ame… 1824 23.9 16.2 23.2 7.69 #> 10 2 United States of Ame… 1825 23.9 16.2 23.3 7.72 #> # … with 16,721 more rows
create_stateyears(system = "gw") %>% add_sdp_gdp()
#> Joining, by = c("gwcode", "year")
#> # A tibble: 18,289 x 7 #> gwcode statename year wbgdp2011est wbpopest sdpest wbgdppc2011est #> <dbl> <chr> <dbl> <dbl> <dbl> <dbl> <dbl> #> 1 2 United States of Am… 1816 23.6 15.9 22.8 7.66 #> 2 2 United States of Am… 1817 23.6 16.0 22.8 7.64 #> 3 2 United States of Am… 1818 23.6 16.0 22.9 7.64 #> 4 2 United States of Am… 1819 23.7 16.0 22.9 7.66 #> 5 2 United States of Am… 1820 23.7 16.1 23.0 7.66 #> 6 2 United States of Am… 1821 23.8 16.1 23.0 7.68 #> 7 2 United States of Am… 1822 23.8 16.1 23.1 7.70 #> 8 2 United States of Am… 1823 23.8 16.1 23.1 7.69 #> 9 2 United States of Am… 1824 23.9 16.2 23.2 7.69 #> 10 2 United States of Am… 1825 23.9 16.2 23.2 7.72 #> # … with 18,279 more rows