DemographicSummary API¶
Introduction¶
This initial public release of the DemographicSummary API includes a simple set of urls and associated parameters to allow developers to query the 2000 Census data and associated SF1 and SF3 attributes. Currently, only a small subset of SF1 and SF3 demographic attributes are publicly available, however paying clients have access to a wider set of data.
Limitations¶
The free public API is not intended for large-scale studies. Use of this API without an authorized API Key is limited to 50 queries per day, and only 5 attributes can be returned for any query.
Usage¶
The base URL for all demographic summary queries is: http://demographicsummary.com/summary/
The following parameters are available:
Location¶
Your location can be defined with a Point, Circle, Square, or Polygon.
- Point: http://demographicsummary.com/summary/?shape=point&x=-121.5&y=37.6
- Circle: http://demographicsummary.com/summary/?shape=circle&radius=100&x=-121.5&y=37.6
- Square: http://demographicsummary.com/summary/?shape=square&radius=500&x=-121.5&y=37.6
- Polygon: http://demographicsummary.com/summary/?shape=polygon&geom=POLYGON((-121.5 37.6,-121.1 37.7,-121.0 37.5,-121.5 37.6))
Detailed Output¶
The default response is a summary, based on either the single geometry your point intersected, or the set of geometries your polygon intersected.
In the case of large circle, square, or custom polygon, it is likely you intersected a number of census geometries. In this situation, each block or block group is weighted by the percent of it’s geometry that your custom polygon intersected. Summary results are based on that weighting. For example, if your polygon intersected 50% of Census Block A (population 80) and 25% of Census Block B (population 20), your total summary population would be 45.
However, you may also choose to retrieve a detailed list of every census block (group) that your polygon intersects. These results include the block group ID, and the percentage of it’s intersection with your shape.
- Detailed Results: - Circle: http://demographicsummary.com/summary/?shape=circle&radius=30000&x=-121.5&y=37.6&detailed=true
Projection¶
The default for all Locations is “EPSG:4326”), but you may provide your Location in all projections that are defined in the standard EPSG reference, as well as a few others (such as using 900913 for “spherical mercator”)
Census Summary¶
By default, all queries are run on the census block-group level. However, you can specify to use either Summary File 1 (SF1) or Summary File 3 (SF3) as your source geometries for analysis.
All SF1 queries are run at the census block level, which is the most detailed. All SF3 based queries are run at the census block-group level.
- Census Block Population: http://demographicsummary.com/summary/?shape=point&x=-121.5&y=37.6&census_summary=sf1
- Census Block Group Population: http://demographicsummary.com/summary/?shape=point&x=-121.5&y=37.6&census_summary=sf3
Demographic Attributes¶
The majority of the SF1 and SF3 attributes have been imported for use in the query system, however only a small subset are available to the public API. These are listed on the homepage. A listing of all attributes can are available for “SF1”) and “SF3”) summary files.
You may not mix SF1 and SF3 attributes in a single query, as different geometries are used to calculate the results.
- Housing Units and Median Family Income: http://demographicsummary.com/summary/?shape=point&x=-121.5&y=37.6&census_summary=sf3&fields=hu100,p53
Note
Total Number based attributes, such as housing units, are summed over each block (group) your polygon intersects with, while average based attributes, such as median income, are averaged.
API Key¶
Please contact us for pricing.
