My application uses a MapView which will display multiple places.
I have the latitude and longitude of these places stored in a database in degrees.
The latitudes, longitudes have a precision of 14 digits after the decimal.
If I have to determine if two geo locations are the same, how much precision should I consider
or rather how much precision I can overlook so that I do not have pins very close to each
other in the map view ?
If two positions are same then I plan to position a single pin on the map and then when the pin is clicked, it will display a list of places located at that location
There is a function in the Location class called distance between:
you can use this to calculate a distance between the points and mark a minimum.
The calculation for distance is not just about calculating distance between 2 points on a straight line, but rather takes the earths eliptical shape into account so its as accurate as it can be.
for the use case, there is the float array which you need to provide at the end of the method where the results will actually be written.
DistanceBetween