Accessing Externally Sourced Socioeconomic Status Data
A selection of socioeconomic status (SES) summary statistics, sourced from the U.S. Census American Community Survey via a three digit zip code linkage, are made available within the Controlled Tier dataset. These data are stored in an appended table and cover a selection of domains on a per Census block basis. Please see the Controlled Tier CDR Data Dictionary for details about the specific data elements available.
These data can be accessed via both the Researcher Workbench tools and through direct query/import from a workspace notebook. Please see details about each method below.
- Import via the Researcher Workbench Workspace Concept Set Selector Tool
The Concept Set Selector tool can be used to import and join a pre-packaged set of available SES concepts with a cohort within a dataset.
- Direct Query/Import from CDR
- The appended table can be directly queried/imported from the CDR via the table aou-res-curation-output-prod:C2022Q2R2.zip3_ses_map, which is only available in the Controlled Tier.
- Each row in the Controlled Tier Data Dictionary "Socioeconomic Status" tab" describes a column in this table.
- Data can be joined on the Controlled Tier observation table for a participant by linking the participant’s generalized zip code with the zip3_as_string field in this table.
This can be done by joining with the observation table with the corrected_table as (
/* the table improperly prefixes all zip3 strings with 0, so the case statement here is fixing that for the join to work */
CASE WHEN LENGTH(zip3_as_string) > 5 THEN SUBSTR(zip3_as_string, 2) ELSE zip3_as_string END as zip3_as_string,
count(*) as n
from `aou-res-curation-output-prod.C2022Q2R1.observation` o
join `corrected_table` z
on o.value_as_string = z.zip3_as_string
group by 1, 2, 3, 4, 5, 6