Skip to content

veteran: Veteran status

veteran title image

Description

veteran indicates whether or not the respondent has served in the military.

Availability

Sample Years
Basic All years
May All years
ORG All years

Warning

This variable is restricted to men only prior to 1989.

Values

Value Label
0 Not a veteran
1 Veteran

Code

Variable creation
********************************************************************************
* veteran: Veteran status
********************************************************************************

* first generate adjusted hourly earnings for non-paid-hourly
gen byte veteran = .

if $monthlycps == 1 | $maycps == 1 {
    if $earnerinfo == 1 {
        if tm(1973m1) <= $date & $date <= tm(1993m12) {
            replace veteran = 0 if vet == 6
            replace veteran = 1 if 1 <= vet & vet <= 5
        }
        if tm(1994m12) <= $date & $date <= tm(2005m7) {
            replace veteran = 0 if peafwhen == 6
            replace veteran = 1 if 1 <= peafwhen & peafwhen <= 5
        }
        if tm(2005m8) <= $date {
            replace veteran = 0 if peafever == 2
            replace veteran = 1 if 1 <= peafwhn1 & peafwhn1 <= 9
        }
    }
}

lab var veteran "Veteran status"
lab def veteran 0 "Not a veteran" 1 "Veteran"
lab val veteran veteran
notes veteran: universe restricted to men before 1989
notes veteran: Significant question change in 2005m8
notes veteran: 1973-1993 Unicon: vet
notes veteran: 1994-2005m7 CPS: peafwhen
notes veteran: 2005m8-present CPS: peafever, peafwhn1
Figure creation
keep if veteran ~= .
keep if age >= 18 & age ~= .
keep if female == 0

gcollapse (mean) veteran [pw=basicwgt], by(year) fast

replace veteran = veteran * 100

local color1 228 26 28
local color2 55 126 184
local color3 77 175 74
local color4 152 78 163
local color5 255 127 0

line veteran year, lcolor("`color4'") ///
legend(off) ///
xlabel(1975(5)2020) ///
ylabel(0(10)40 50 "50%", angle(0) gmin gmax) ///
xtitle("") ytitle("") ///
lcolor("`color4'") ///
graphregion(color(white)) plotregion(color(white)) ///
title("Veteran status of men, ages 18 and above", size(medsmall))
graph export ${variableimages}veteran_titleimage.svg, replace