System and method for computing region centers by point clustering
A system and a method are disclosed that calculate the center of a geographic region. A set of topological/geographical points is received. A set of clusters is determined. A weight for each cluster is computed. The highest weighted cluster is selected. The geographic region center is calculated using the selected cluster. The geographical points can include a key for each point and be filtered by an indicated key before calculating the center of a geographic location.
1 . A method comprising:
receiving a set of geographical points within a geographic region;
determining a set of clusters from the set of geographical points;
calculate weights for clusters in the set of clusters, wherein one cluster is a highest weighted cluster; and
identify a center of the geographic region using a centroid of the highest weighted cluster; and
wherein the set of geographical points include a time associated with geographical points and wherein computing the center of the geographic region includes using progression of a computed center over time to calculate a present city center.
2 . The method of claim 1 further comprising:
calculating a points center for the set of geographical points when multiple clusters from the set of clusters have the same highest weight; and
selecting the centroid of the cluster having its centroid closest to the points center of the set of geographical points as an updated center.
3 . The method of claim 1 , wherein the set of geographical points includes a latitude and longitude for points of the set of geographical points.
4 . The method of claim 3 , wherein computing centers of geographic regions for the highest weighted cluster includes performing computations:
Latitude
center
=
Xjl
,
Latitudei
*
Weighti
^
=
1
Weighti
Longitude
center
=
SjLi
,
Longitudei
*
Weighti
Z
^
Weighti
wherein “n” represents number of points in the highest weighted cluster and “Weightr” represents weight of a respective point and the summation is across the latitudes and longitudes of the points in the highest weighted cluster.
5 . The method of claim 1 , wherein the weight is calculated based on number of points within a respective cluster.
6 . The method of claim 1 , wherein the set of geographical points include respective point weights and weights for clusters are calculated as sums of weights of point weights within the respective clusters.
7 . The method of claim 1 , wherein weights for geographical points in the set of geographical points are calculated as the number of people living at residences identified by the respective geographical points.
8 . The method of claim 1 , wherein determining a set of clusters includes repeating clustering with a different set of parameters when a difference between the highest weighted cluster and a second-highest weighted cluster is below a threshold.
9 . The method of claim 1 , wherein computing the center of the geographic region includes selecting a nearest point to the centroid of the highest weighted cluster as the center of the geographic region.
10 . A non-transitory computer-readable medium storing instructions that, if executed by one or more computers, would cause the one or more computers to:
receive a set of geographical points within a geographic region;
determine a set of clusters from the set of geographical points;
determine weights for clusters in the set of clusters, wherein one cluster is a highest weighted cluster; and
determine a center of the geographic region using a centroid of the highest weighted cluster; and
wherein the set of geographical points include a time associated with geographical points and wherein computing the center of the geographic region includes using progression of a computed center over time to calculate a present city center.