The output files collected at CMLBDA lab are in the format
cluster_centers =
[
[latitude of center 1, longitude of center 1],
[latitude of center 2, longitude of center 2],
...
]
clusters =
[
[id's of districts in cluster 1],
[id's of districts in cluster 2],
...
]
To plot these results on a shapefile, It would be better if a dictionary can be created from this format. The desirable format would look something like:
{
[cluster 1 latitude, cluster 1 longitude] : [list of names of districts in cluster 1],
[cluster 2 latitude, cluster 2 longitude] : [list of names of districts in cluster 2],
...
}
To do
A code needs to be written to parse through the output files and convert this data into the desired format.
Description
The output files collected at CMLBDA lab are in the format
To plot these results on a shapefile, It would be better if a dictionary can be created from this format. The desirable format would look something like:
To do
A code needs to be written to parse through the output files and convert this data into the desired format.
Examples
converted to