Contains a variety of parsing function to view the shape.geojson files in the districts submodule in different ways...
- View each state/district as a grid of 1s and 0s (where 1 marks the point as being part of the state/district)
- Generate a list of points for each state with the districts marked districtly
- Generate a list of points for the district
Initialize/Update the submodule
$ git submodule init --recursive
$ git submodule update --recursive
In the root of the repo, you would find CommandMaster.py. Some preprocessing work is needed before running the parsing functions:
$ python CommandMaster.py
Initialize an instance of the class:
GeoJsonDistrictGridCreater.GeoJsonDistrictGridCreater(filename)
where filename is the name of the file you're interested in
instance.get_district_grid()
return a grid where the district is plotted as a Screen class
instance.get_district_array_more_info()
return an array where each point of the district is labeled by the district name
Initialize an instance of the class:
GeoJsonStateGridCreater.GeoJsonStateGridCreater(filename)
where filename is the name of the file you're interested in
instance.get_district_grid()
return a grid where the district is plotted as a Screen class
instance.get_district_array_more_info()
return an array where each point of the district is labeled by the district name