1

For a mobile app, we are using the Google APIs for geolocation and geocoding. The basic use case is to find entities within a certain radius (in the range of a couple of kilometers) of each other.

Often, due to people being either in high rise urban areas or city outskirts, the location accuracy gets thrown off, and the margin of error is up to a few hundred meters.

To tackle this issue, we built a workaround where the app first gets the geolocation coordinates from the system, then we call the geocoding API to get the address corresponding to that location. Now the user has the ability to update/edit this address as they see fit. Now again we use the geocoding API to extract the coordinates corresponding to this address.

These are the coordinates that we actually use.

But it turns out that sometimes the geocoding API is not that reliable either. So the coordinates it returns for an address can also be inaccurate, leading us to a conundrum.

What can be a good approach to tackle this?

Off the top of my head, I think we could try to use both the system coordinates and the coordinates generated by the address (updated by the user) and use both of them. So the region of interest would be the union of the regions of interest based on both the sets of coordinates.

Or we could somehow factor in the number for the "inaccuracy".

ahron
  • 165
  • 6
  • 2
    How precise do you need to be and how important is it to not have false positives? If your API is off by as much as 100m, why not just add 100m to the search radius if you want to make absolutely sure you get everything? How bad would it be to catch one in your search that is actually 100m outside of what you told people is your search radius? – nvoigt Nov 11 '21 at 10:44
  • False positives are okay, as long as the error is not too high (say, upto 500m off is fine). But false negatives people will complain about. I think this is a good and easy to implement solution - simply factor in the "inaccuracy" in the search radius, assuming ofc that the inaccuracy estimate is reasonably accurate. – ahron Nov 11 '21 at 12:00

1 Answers1

4

Showing a map with markers for each location is about the only way to mitigate this issue. Center the map on the user's current location, but don't put a marker. This gives the user information so they can judge for themselves whether or not they want to travel to one of those locations.

Using GPS-enabled devices is commonplace now in most developed countries. If your users do not use GPS-enabled devices often, place a note on screen what the accuracy is, if this is available from the map API.

The best thing you can do is give the user information, so they can make the decision themselves.

Greg Burghardt
  • 34,276
  • 8
  • 63
  • 114