PUMS ACS codebook and the mysterious "b" code

Does anyone know how the Census assigns the PUMS codebook value "b" code to a text value in the downloaded (API) data?

I was looking at the LNGI "Limited English speaking household" PUMS variable.  When you fetch PUMS data via the API the variable values are text fields.

It turns out that for LNGI the "b" in the codebook corresponds to the text string (in the sense of a SAS format)   "b .N/A (GQ/vacant)"   data value "0"

In the LNGI case,the PUMS data field contains the value "0" which it turns means N/A (GQ/vacant). You can guess this because there are no " " fields in the PUMS data and "0" value doesn't appear in the codebook.  By doing a little detective work using the codebook and some downloaded data you can figure this out.  However, "0" isn't used for the "b" in the code book for all variables because sometimes  "0" is a valid non-missing value (i.e. not N/A).

When I asked the people at ACSO they sent me a SAS format statement for LNGI which makes everything clear in the case of this one variable.  But wouldn't it be nice if the Census published their PUMS SAS format catalog so we don't have to keep guessing what data value corresponds to "N/A"  Do people have another way to find out what data value corresponds to "b" in the codebook?  Some PUMS variables have over 100 coded values.   If I'm working late on Friday, do I have to wait until Monday to get an answer ?  How about a holiday weekend ?

Any help appreciated.

Dave Dorer

Parents
  • Hi Dave!

    The API does not handle 'blank' as a value, so in the processing of the data into the data API format those blank values get assigned to a new value. This new value is typically the variable's minimum value minus 1, for numeric fields. For character fields they may get stored as an 'N'. The best way to know how the values are defined for the API is to use the API discovery documentation (for info on this, see https://www.census.gov/data/developers/updates/new-discovery-tool.html).
     
    For example, for the ACS 1-Year 2021 PUMS file, you can look here: https://api.census.gov/data/2021/acs/acs1/pums.html and go the the 'variables' link.
    This brings you to a page listing every available item, an each item name is clickable to take you to the definition of the item and its values.
    Thank you!
    -Amanda
  • Trying to keep this positive (and failing), I'm not a researcher or in the industry. But I'm old and have probably pulled 100 API sources and have never seen such a funky system. Even the PubMed API which uses strange 20-year-old syntax has a clear methodology for nulls \ blanks \ and zero values. Taking a random value based on min is a mix between Dilbert and Steven King. Accepting this is a failure on our part.

Reply
  • Trying to keep this positive (and failing), I'm not a researcher or in the industry. But I'm old and have probably pulled 100 API sources and have never seen such a funky system. Even the PubMed API which uses strange 20-year-old syntax has a clear methodology for nulls \ blanks \ and zero values. Taking a random value based on min is a mix between Dilbert and Steven King. Accepting this is a failure on our part.

Children
No Data