Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Score difference #47

Merged
merged 13 commits into from
Apr 26, 2017
Merged

Score difference #47

merged 13 commits into from
Apr 26, 2017

Conversation

steveoh
Copy link
Member

@steveoh steveoh commented Apr 26, 2017

add score difference param to address geocoding api.

image

{
 "result": {
  "addresses": [
   {
    "id": 1,
    "location": {
     "x": 416300.626283878,
     "y": 4569533.98219385
    },
    "score": 90.87,
    "locator": "Centerlines.StatewideRoads",
    "matchAddress": "766 N DEPOT DR, OGDEN",
    "inputAddress": "766 south Depot Drive, riverdale",
    "addressGrid": "OGDEN",
    "scoreDifference": 0
   },
   {
    "id": 3,
    "location": {
     "x": 430178.9702896076,
     "y": 4506818.444710031
    },
    "score": 90.87,
    "locator": "AddressPoints.AddressGrid",
    "matchAddress": "2236 E ATKIN AVE, SALT LAKE CITY",
    "inputAddress": "2236 atkin ave, slc",
    "standardizedAddress": "2236 atkin avenue",
    "addressGrid": "SALT LAKE CITY",
    "scoreDifference": 21
   }
  ]
 },
 "status": 200
}

closes #34 refs #32

@steveoh
Copy link
Member Author

steveoh commented Apr 26, 2017

Does this seem to answer your problem from earlier @JustinBerger?

@JustinBerger
Copy link

Absolutely. It gives a simple way to do big batches of records, and still know when there are very similar potential matches. Is it possible for 2 different endpoints to return the same geocode? It makes sense to drop those 'ties' since they are really the same.

@steveoh
Copy link
Member Author

steveoh commented Apr 26, 2017

On the example I showed the ties are different addresses with the same score so I wouldn't recommend dropping them. The locators themselves would not return the same address unless it is an apartment but we already handle that. The address points could return similar to a range geocode but the address points are weighted in the case of a tie. I'll release this today so you can give it a spin.

@steveoh steveoh merged commit 9b58b38 into master Apr 26, 2017
@steveoh steveoh deleted the score-difference branch April 26, 2017 20:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

calculate difference between match and best candidate
2 participants