geosnap.Community.harmonize¶
-
Community.
harmonize
(self, target_year=None, weights_method='area', extensive_variables=None, intensive_variables=None, allocate_total=True, raster='nlcd_2011', codes='developed', force_crs_match=True)[source]¶ Standardize inconsistent boundaries into time-static ones.
- Parameters
- target_year: int
Polygons from this year will become the target boundaries for spatial interpolation.
- weights_method
str
The method that the harmonization will be conducted. This can be set to:
“area” : harmonization according to area weights.
“land_type_area” : harmonization according to the Land Types considered ‘populated’ areas.
“land_type_Poisson_regression” : NOT YET INTRODUCED.
“land_type_Gaussian_regression” : NOT YET INTRODUCED.
- extensive_variables
list
extensive variables to be used in interpolation.
- intensive_variablestype
intensive variables to be used in interpolation.
- allocate_totalbool
True if total value of source area should be allocated. False if denominator is area of i. Note that the two cases would be identical when the area of the source polygon is exhausted by intersections. See (3) in Notes for more details
- raster_path
str
path to the raster image that has the types of each pixel in the spatial context. Only taken into consideration for harmonization raster based.
- codes
list
ofints
pixel values that should be included in the regression (the default “developed” includes [21, 22, 23, 24]).
- force_crs_matchbool
whether source and target dataframes should be reprojected to match (the default is True).
- Returns
None
New data are added to the input Community