igo_dyadic: Extract joint IGO membership for state pairs

View source: R/igo_dyadic.R

igo_dyadicR Documentation

Extract joint IGO membership for state pairs

Description

Creates dyad-year IGO data. Each row represents a pair of states in one year and summarizes their joint memberships across IGOs.

Usage

igo_dyadic(country1, country2, year = 1816:2014, ioname = NULL)

Arguments

country1, country2

A state or vector of states to compare. Each value can be any state name or code in states2016.

year

An integer or vector of years to assess.

ioname

An optional IGO identifier or vector of identifiers. If NULL (the default), all IGOs are included. Use igo_search() to find valid identifiers.

Details

The arguments country1 and country2 are named for compatibility with earlier versions of igoR. Values are matched against states in states2016.

This function reproduces the structure of the original dyad-year file distributed by the Correlates of War Project (dyadic_format3.dta). That file is not included in this package due to its size.

The result contains one row for each common year selected by country1, country2 and year.

The dyadid column identifies each relationship and is computed as (1000 * ccode1) + ccode2.

For each selected IGO, the result includes a column named after its lowercase identifier and uses this coding scheme:

Category Numerical value
No Joint Membership 0
Joint Full Membership 1
Missing data -9
State Not System Member -1

Use igo_recode_dyadic() to recode the numerical values as factors.

If one state in an IGO is a full member but the other is an associate member or observer, that IGO is not coded as a joint membership.

Value

A coded data.frame with one row per state pair and year and one column per selected IGO. See Details for the coding scheme.

Differences from the original data set

For some IGOs, results differ from the original data set in the coding of "Missing data" (-9) and "State Not System Member" (-1). The available documentation does not fully specify how to reproduce those values.

See Codebook Version 3 IGO Data.

Source

Codebook Version 3 IGO Data for the full reference.

References

Pevehouse, J. C., Nordstrom, T., McManus, R. W. & Jamison, A. S. (2020). Tracking organizations in the world: The Correlates of War IGO Version 3.0 data sets. Journal of Peace Research, 57(3), 492–503. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1177/0022343319881175")}.

See Also

state_year_format3, states2016, igo_search(), igo_recode_dyadic().

Other membership functions: igo_members(), igo_state_membership()

Examples

usa_esp <- igo_dyadic("USA", "Spain")
nrow(usa_esp)
ncol(usa_esp)

dplyr::tibble(usa_esp)

# Use custom arguments.
custom <- igo_dyadic(
  country1 = c("France", "Germany"), country2 = c("Sweden", "Austria"),
  year = 1992:1993, ioname = "EU"
)

dplyr::glimpse(custom)

igoR documentation built on June 24, 2026, 9:07 a.m.