Skip to content

Instantly share code, notes, and snippets.

Avatar

Paulo Alvarado czpython

View GitHub Profile
@czpython
czpython / center_geo.py
Last active Feb 7, 2018 — forked from amites/center_geo.py
calculate center coordinate from a list of latitude, longitude pairs
View center_geo.py
# -*- coding: utf-8 -*-
import math
def center_geolocation(geolocations):
"""
Provide a relatively accurate center lat, lon returned as a list pair, given
a list of list pairs.
ex: in: geolocations = ((lat1,lon1), (lat2,lon2),)
out: (center_lat, center_lon)
You can’t perform that action at this time.