The centroid calculation, which simply averages latitude and longitude values, is accurate in most cases, but produces incorrect results near the 180th meridian. For example, with longitudes 179.649556 and -176.131694, the calculation is as follows:
(179.649556 - 176.131694) / 2 = 1.758931
As can be seen, the example produces results in the opposite hemisphere.
The centroid calculation, which simply averages latitude and longitude values, is accurate in most cases, but produces incorrect results near the 180th meridian. For example, with longitudes 179.649556 and -176.131694, the calculation is as follows:
(179.649556 - 176.131694) / 2 = 1.758931As can be seen, the example produces results in the opposite hemisphere.