Summary
Instructions provided describe two methods for creating a list of GeoEnrichment Variables for use in Python Notebooks. The first method is recommended, and the second method is offered as an alternative.
Procedure
Method 1
- Open the Esri Demographics Data Browser.
- Browse the data categories for the country of interest and select the desired variables. They are added to the Selected Variables list in the top right corner.
- When all desired variables are added to the list, click Copy Selected Variables to Clipboard in the bottom right corner.
- The list of variables can then be used in a Python notebook, in the following example, a 1-mile ring study area in San Diego is enriched with the selected variables.
from arcgis.gis import *
from arcgis.geoenrichment import *
gis = GIS('https://www.arcgis.com', 'username', 'password') *
vars = ["populationtotals.totpop_cy", "householdtotals.tothh_cy", "householdincome.medhinc_cy", "generations.millenn_cy", "industry.unemprt_cy", "5yearincrements.medage_cy"]
enrich(study_areas=[‘111 W Harbor Dr, San Diego, CA’], analysis_variables=vars)

Method 2
- Open ArcGIS Pro and create a new map template project.
- On the Analysis ribbon, click Environments.
- Scroll to the bottom and confirm that the Business Analyst Data Source is selected for the desired country.
- In the Catalog pane, expand Toolboxes, right-click the project .tbx, and select New > Model.
- On the Analysis ribbon, click Tools to open the Geoprocessing pane, then click Toolboxes and expand Business Analyst Tools > Analysis. Locate the Enrich Layer tool and drag and drop it into the Model pane.
- Double-click on Enrich Layer in the Model pane to open the tool dialog.
- Click the plus sign (+) next to Variables to open the Data Browser, this allows searching and browsing data by category. When selecting the variables, they are added to the list in the top right corner. Add the desired variables to the list, and click OK.
- Click OK to close the tool dialog.
- On the ModelBuilder ribbon, expand the options for Export and select Send To Python Window.
- Copy the array of variables from the Python window, for example:
["populationtotals.totpop_cy", "householdtotals.tothh_cy", "householdincome.medhinc_cy", "generations.millenn_cy", "industry.unemprt_cy", "5yearincrements.medage_cy"]
- This list can then be used in a Python Notebook, in the following example, we are enriching a 1-mile ring study area in San Diego.
from arcgis.gis import *
from arcgis.geoenrichment import *
gis = GIS('https://www.arcgis.com', 'username', 'password') *
vars = ["populationtotals.totpop_cy", "householdtotals.tothh_cy", "householdincome.medhinc_cy", "generations.millenn_cy", "industry.unemprt_cy", "5yearincrements.medage_cy"]
enrich(study_areas=[‘111 W Harbor Dr, San Diego, CA’], analysis_variables=vars)