laser.measles.demographics.admin_shapefile
admin_shapefile
Admin level shapefiles
AdminShapefile
Bases: BaseShapefile
Shapefile of administrative units.
Attributes:
| Name | Type | Description |
|---|---|---|
admin_level |
int | None
|
Admin level of the shapefile. |
dotname_fields |
list[str] | None
|
List of fields to use for dotname. e.g., ["ADMIN0", "ADMIN1", "ADMIN2"] |
Examples:
1 2 3 4 | |
add_dotname()
Add a DOTNAME to the shapefil (e.g., ADMIN0:ADMIN1:ADMIN2)
get_shapefile_parent()
Get the parent directory of the shapefile.
shape_subdivide(patch_size_km)
Subdivide the shapefile for a given administrative level into patches of approximately equal area.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
patch_size_km
|
int
|
Size of the patch in square kilometers. |
required |