Skip to contents

Returns the standard household, individual, and enumeration area ID column names used in a given IHS round. This is a convenience helper for users building longitudinal panels or merging modules.

Usage

ihs_panel_ids(round = "IHS5")

Arguments

round

A character string specifying the IHS round (e.g., "IHS5", "IHS4"). Use "all" for a comparison across all rounds.

Value

If a single round is specified, a named character vector of standard ID columns. If "all", a data.frame comparing ID columns across rounds.

Examples

# Get IHS5 ID columns
ihs_panel_ids("IHS5")
#> Standard ID columns for "IHS5":
#>     hh_id  indiv_id     ea_id    strata    weight 
#> "case_id"     "PID"   "ea_id" "stratum"  "hh_wgt" 

# Compare across all rounds
ihs_panel_ids("all")
#> Panel ID columns across all supported IHS rounds.
#>       role     IHS2     IHS3    IHS4    IHS5
#> 1    hh_id  case_id  case_id case_id case_id
#> 2 indiv_id      PID      PID     PID     PID
#> 3    ea_id    ea_id    ea_id   ea_id   ea_id
#> 4   strata  stratum  stratum stratum stratum
#> 5   weight hhweight hhweight  hh_wgt  hh_wgt