Geocoder Web Service for the Metro Geocoder Web Service for the Metro Area Nancy Read Metro. Mosquito Control District MetroGIS Policy Board, January 27, 2010
Geocoder Background – how it works Update Addition – Landmarks – –Parks, Schools, City Halls, …
Text string Location coordinates Metro Counties Govt. Center 2099 University Ave. W ° St. Paul, MN ° Coordinates used to put point on map: Geocoder
Text string Location coordinates 2099 University Ave. W ° St. Paul, MN ° Match Street Name Interpolate along Range Address – Streets File University Ave. W 2099
Text string Location coordinates 2099 University Ave. W ° St. Paul, MN ° Match a Point Address – Parcel Points 2001UniversityAve. W University Ave W 2099UniversityAve. W2151UniversityAve. W
Text string Location coordinates Metro Counties Govt. Center 2099 University Ave. W ° St. Paul, MN ° Match a Point Point of Interest / Landmark BakerElem.School Text match Metro CountiesGovt. Center McDonalds
Geocoder: 3 Parts Data Format Accuracy Up-to-date Abbreviations Spelling errors
Geocoder Parts Match, Score Data ST = Street ST = Saint Geocoder Engine Standardizers Comparison Settings Weights Rules
Geocoder Parts Web Service Match, Score Data ST = Street ST = Saint Input, Output formats
Why build a geocoder service? Use point data as well as interpolated Local data more current, Better Unlimited use, no fees or license issues Complex tool, only build once One data set to update
MetroGIS Geocoder Project MetroGIS project funding MetroGIS project funding Dave Bitner (MAC) Dave Bitner (MAC) Jim Maxwell (TLG) Jim Maxwell (TLG) Mark Kotz (Met.Co.) Mark Kotz (Met.Co.) Gordy Chinander (MESB) Gordy Chinander (MESB) Bob Basques (St. Paul) Bob Basques (St. Paul) Chris Cialek, Jim Dickerson & Pete Olson (LMIC) Chris Cialek, Jim Dickerson & Pete Olson (LMIC) Kent Treichel (MN Dept. of Revenue) Kent Treichel (MN Dept. of Revenue) Nancy Read (MMCD)- Project Manager Nancy Read (MMCD)- Project Manager
MetroGIS Geocoder Project PAGC open source geocoder PAGC open source geocoder –reworked from batch to multi-user –created code for a service –has community of interested developers
Set up service with Metro data Set up service with Metro data –TLG Streets –7-county Parcel Layer (centroids) –Address Points (as available) House + Street or Intersection House + Street or Intersection Host Host –MnGEO (Minnesota Geographic Information Office) MetroGIS Geocoder Project
Metro Geocoder Up continuously since June 2008 Up continuously since June 2008 Automated data update Automated data update Streets – weekly from NCompass (TLG) Parcels – quarterly from MetroGIS/ Met. Council (as provided by counties) Usage 10,000 – 90,000 hits per month Usage 10,000 – 90,000 hits per month
Tools, Docs, Users Sample form - try address, see responses Sample form - try address, see responses Technical documents Technical documents –Geocoder Request Protocol documentation Geocoder Request Protocol documentationGeocoder Request Protocol documentation –Geocoder Response API documentation Geocoder Response API documentationGeocoder Response API documentation SOAP wrapper for.Net (Matt McGuire, Metro Council) SOAP wrapper for.Net (Matt McGuire, Metro Council) ArcMap Tool (Steve Jakala, Scott Co.) ArcMap Tool (Steve Jakala, Scott Co.) Public sites using Geocoder Web Service: Public sites using Geocoder Web Service: –Metro Mosquito Control web map (Houston Engineering) –DNR LandView (Craig Perrault, MnDNR) –Carver County
Using Geocoder in Applications Web Service takes urlencoded Address or Intersection requests Web Service takes urlencoded Address or Intersection requests returns closest matches with latitude- longitude, in XML, CSV or JSON. returns closest matches with latitude- longitude, in XML, CSV or JSON.
Example Request methodName=GeocodeRequest &Version=1.1 &CountryCode=US &maximumResponses=10 &CompleteAddressNumber=2099 &CompleteStreetName=UNIVERSITY%20AVE%20W &PlaceName=Saint%20Paul &ZipCode=55104% &ResponseFormat=XML
Response (xml) …. … UNIVERSITY - UNIVERSITY - AVENUE WEST AVENUE WEST SAINT PAUL SAINT PAUL parcels_all7_points_lat83_point - parcels_all7_points_lat83_point
Geocode by Intersection
Call Tracking application Geocode while customer is on the phone Geocode while customer is on the phone
Assigns Service Area uses st_within PostGIS SQL function with lat,long from geocoder service to populate other fields from spatial tables uses st_within PostGIS SQL function with lat,long from geocoder service to populate other fields from spatial tables
Field staff select their calls, map
Geocoding calls reduced time field staff spend locating call by 80% North service area calls, 2008
How well is Geocoder working? Web Service Match, Score Data Inputs, parsing Separate fields or one string Geocoder Engine Standardizers Comparison Settings Weights Rules Point or Ranges Loc. Accuracy Current Parsing Abbreviations Free of spelling errors Strange but true PAGC ST = Street ST = Saint
How well is Geocoder working? Web Service Match, Score Data Inputs, parsing Separate fields or one string Geocoder Engine Standardizers Comparison Settings Weights Rules Point or Ranges Loc. Accuracy Current Parsing Abbreviations Free of spelling errors Strange but true PAGC ST = Street ST = Saint
How well is Geocoder working? Web Service Match, Score Data Inputs, parsing Separate fields or one string Geocoder Engine Standardizers Comparison Settings Weights Rules Point or Ranges Loc. Accuracy Current Parsing Abbreviations Free of spelling errors Strange but true PAGC ST = Street ST = Saint
Points of Interest / Landmarks Change match/scoring engine (PAGC) – –International interest – some areas do not use house numbers + street name addressing – –Scores based on Each (significant) word Soundex Approximate (whole name) Web Service Match, Score Data
One service handles address, intersection, and named feature Change web service inputs allowed – –LandmarkName, LandmarkType, CountyName Web Service Match, Score Data Points of Interest / Landmarks
Try data file with x,y (not shp file) Data available? Web Service Match, Score Data Points of Interest / Landmarks
Data GNIS – Geographic Names, USGS NCompass / TLG Landmarks – –Part of MetroGIS streets package – –Some points, some polygon centroids (water) Metro. Council – –Transit, from bus route requests – –Other data? 911 – –Each Public Service Answering Point (PSAP) has their own data HSIP + state creation/update CAP grant – –Hospitals, Fire Stations, Police, Schools Commercial data sources?
Data: examples
TLG
Data: examples GNIS
Data: examples Transit
Data: examples
Data Data for testing: TLG Landmarks Could assemble a more complete dataset – –Eliminate duplicates – –Check positional accuracy – –Check spelling and consistency – –Feature types? Data maintenance??
Points of Interest / Landmark Example of raw output EAST BETHEL CITY HALL D65A ANOKA EAST BETHEL MINNESOTA clipped_to_metro2_lat_point BETHEL CITY HALL D65A ANOKA BETHEL MINNESOTA clipped_to_metro2_lat_point - EAST BETHEL ICE ARENA D67 ANOKA EAST BETHEL MINNESOTA clipped_to_metro2_lat_point
Geocoder Enhancements Change candidate matches returned – alt. street names before alternate numbers Fix corrected names returned with pre-types (no County Road County Road B) Allow entry of House # + Street Name as continuous text string
MetroGIS Geocoder Project Continuing Work – –Address points dataset, with automated data update – –Adjusting performance – –More Hosts? Batch service? – –Open source – anyone can contribute to code Web Service – Contacts List ? Outreach ?