Data » What's Available » Metadata Summary

2004 HRS Core (Final Release, Version 1.0): Primary identifiers (PN) are missing from the file H04PR_SB.

April 02, 2007

The primary identifiers (PN) are missing from the file H04PR_SB. The following code will allow you to add PN to H04PR_SB.

The code to correct the errors, by section, is as follows:

Data pr_r;
set .H04PR_R;
keep hhid jsubhh jpn_sp pn;
proc sort;by hhid jsubhh jpn_sp;

proc sort data=.h04pr_sb out=pr_sb;
by hhid jsubhh jpn_sp;

data .h04pr_sb;
merge pr_r pr_sb(in=y);
by hhid jsubhh jpn_sp;
if y;

The above code pulls PN from the Respondent Level Preload file (H04PR_R), along with three identifiers that make each line unique. The last data step merges the identifiers onto H04PR_SB.

Copyright © 2015 The Regents of the University of Michigan