![]() ![]() Ex.: a map of Boston showing the spatial distribution of English language ability (Statistics Without Borders project).SAS makes it easy to create heat maps (choropleth maps), plotting different levels of a variable for different geographic areas.strt=index(x,'') 14 INPUT DO UNTIL(lon=.) INPUT LON ? LAT ? ELEVATION ? IF LON ^=. Ex.: reading in the coordinates for the proposed route of the Northern Gateway pipeline (AB and BC): FILENAME ng "C:\NG\Northern Gateway path.kml" DATA ng_0 INFILE ng DSD dlm=', ' LRECL=32767 RECFM=n FORMAT LON LAT 20.16 FORMAT LON LAT 20.16 INPUT x $char1024.Coordinates are stored as in-stream data, so they can be extracted with some clever DATA step programming.As popular as these kinds of mapping tools have become, there is no automatic way to import their data into SAS.Reading in spatial data: Google Earth (.kml) files Google Earth can be a source of spatial data – e.g., the Northern Gateway (Canada) and Keystone XL (US) pipelines (publicized by NGOs) Ex.: reading in the Statistics Canada 2011 Census forward sortation area (FSA) polygon shapefile: PROC MAPIMPORT DATAFILE= "C:\Census11\gfsa000b11a_e.shp" OUT=map_0 RUN.Reads in the main types of map shapefiles used by GIS packages, both polygon and line shapefiles.US Census Bureau TIGER/Line files – states, CBSAs, states, counties, tracts, blocks, ZCTAs:.Statistics Canada Census Cartographic Boundary Files (CBFs) – provinces, MSAs, federal electoral districts, tracts, dissemination areas:.Geocoding business and survey data (that may not have been intended to be geocoded in the first place).But I’m not a GIS analyst! I don’t have/can’t afford/don’t have time to learn GIS software!.Existing data may not contain precise location data. ![]() Many data analysis projects do not start out with spatial analysis in mind (e.g., secondary data analyses).Gravelle (2014) “Partisanship, Border Proximity, and Canadian Attitudes toward North American Integration.” International Journal of Public Opinion Research, vol. Business data, survey data, administrative data come from somewhere… 2.E.g., proximity to/distance from: – Geographic features (e.g., borders) – Various sites (e.g., retail locations, energy infrastructure).Location and proximity/distance also have explanatory power.Implicit in most data (e.g., a survey of Ontario voters, bank branch IDs, etc.).Gravelle, Independent Statistical Consultant A Tour of Geospatial Data Analysis Tools in SAS Timothy B. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |