Description Usage Arguments Value Examples
In the ACS PUMS data, many fields are integer-coded categoricals.
There is a data dictionary (a text document) that describes the mapping
from integers to level definitions. Function acs.recode
takes
the data dicitonary as a string and uses it to construct a factor variable
that recodes integer levels to the text definitions given in the data
dictionary.
1 | acs.recode(x, field, dd, max.len = NULL)
|
x |
ACS PUMS data frame |
field |
column name for a variable in the ACS PUMS data |
dd |
the ACS data dictionary loaded as a string |
max.len |
max length of description in characters, default is all |
factor column with integer levels in x[field]
replaced
with the desciption for that level from the data dictionary.
1 2 | wa.pop16$employment <- acs.recode(wa.pop16, 'ESR', data.dict16, max.len=40)
group.count(wa.pop16, 'employment')
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.