windwhisper.health_impacts ========================== .. py:module:: windwhisper.health_impacts Attributes ---------- .. autoapisummary:: windwhisper.health_impacts.geod Classes ------- .. autoapisummary:: windwhisper.health_impacts.HumanHealth Functions --------- .. autoapisummary:: windwhisper.health_impacts.load_human_health_parameters windwhisper.health_impacts.load_disease_data windwhisper.health_impacts.guess_country windwhisper.health_impacts.approximate_grid_cell_areas Module Contents --------------- .. py:function:: load_human_health_parameters() Load DALY parameter curves from the packaged JSON file. :returns: Mapping of health impact identifiers to parameter sets. :rtype: dict .. py:function:: load_disease_data(country) Return disease burden statistics for the requested country. :param country: ISO alpha-2 code identifying the country of interest. :type country: str :returns: DataFrame limited to the requested country or the European baseline when no data is available. :rtype: pandas.DataFrame .. py:function:: guess_country(bbox_geom) Infer the country overlapping the analysis bounding box. :param bbox_geom: Bounding box geometry in EPSG:4326 coordinates. :type bbox_geom: shapely.geometry.base.BaseGeometry :returns: Tuple containing the ISO alpha-2 code and the estimated population of the matching country. :rtype: tuple[str, float] .. py:data:: geod .. py:function:: approximate_grid_cell_areas(lat, lon) Approximate cell areas for a rectilinear latitude/longitude grid. :param lat: One-dimensional latitude coordinates. :type lat: numpy.ndarray :param lon: One-dimensional longitude coordinates. :type lon: numpy.ndarray :returns: Two-dimensional array containing the area of each grid cell in square metres. :rtype: numpy.ndarray .. py:class:: HumanHealth(noiseanalysis, lifetime = 20) Evaluate human health impacts resulting from noise exposure. .. py:attribute:: lifetime :value: 20 .. py:attribute:: load_factor .. py:attribute:: electricity_production .. py:attribute:: population .. py:attribute:: noiseanalysis .. py:attribute:: disease_data .. py:attribute:: human_health_parameters .. py:attribute:: population_rate .. py:attribute:: human_health_wo_turbines .. py:attribute:: human_health_per_kWh_wo_turbines .. py:attribute:: human_health .. py:attribute:: human_health_per_kWh .. py:method:: get_disease_totals(disease) Return YLD and YLL totals for the active country. :param disease: Disease identifier (e.g. ``"ischemic_heart_disease"``). :type disease: str :returns: Tuple containing the YLD and YLL values. :rtype: tuple[float, float] :raises ValueError: If no statistics are available for the disease. .. py:method:: calculate_highly_annoyed_dalys(lden, noise_type_ha) Calculate DALYs for the highly annoyed indicator. :param lden: Day-evening-night noise level raster. :type lden: xarray.DataArray :param noise_type_ha: Human health parameter set identifier. :type noise_type_ha: str :returns: DALY raster for the highly annoyed population. :rtype: xarray.DataArray .. py:method:: calculate_high_sleep_disorder_dalys(lnight, noise_type_hsd) Calculate DALYs for the high sleep disorder indicator. :param lnight: Night noise level raster. :type lnight: xarray.DataArray :param noise_type_hsd: Human health parameter set identifier. :type noise_type_hsd: str :returns: DALY raster for the high sleep disorder population. :rtype: xarray.DataArray .. py:method:: calculate_ihd_dalys(lden, noise_type) Calculate DALYs attributable to ischemic heart disease. :param lden: Day-evening-night noise level raster. :type lden: xarray.DataArray :param noise_type: Human health parameter set identifier. :type noise_type: str :returns: DALY raster for ischemic heart disease. :rtype: xarray.DataArray .. py:method:: calculate_diabetes_dalys(lden, noise_type) Calculate DALYs attributable to diabetes. :param lden: Day-evening-night noise level raster. :type lden: xarray.DataArray :param noise_type: Human health parameter set identifier. :type noise_type: str :returns: DALY raster for diabetes. :rtype: xarray.DataArray .. py:method:: calculate_stroke_dalys(lden, noise_type) Calculate DALYs attributable to stroke. :param lden: Day-evening-night noise level raster. :type lden: xarray.DataArray :param noise_type: Human health parameter set identifier. :type noise_type: str :returns: DALY raster for stroke. :rtype: xarray.DataArray .. py:method:: calculate_total_dalys(lden, lnight, noise_type_ha = 'road_without_alpinestudies', noise_type_hsd = 'combined', noise_type = 'road middle') Aggregate DALY layers across all health indicators. :param lden: Day-evening-night noise level raster. :type lden: xarray.DataArray :param lnight: Night noise level raster. :type lnight: xarray.DataArray :param noise_type_ha: Parameter set for the highly annoyed metric. :type noise_type_ha: str :param noise_type_hsd: Parameter set for the sleep disorder metric. :type noise_type_hsd: str :param noise_type: Parameter set for chronic disease metrics. :type noise_type: str :returns: Dataset containing the DALY layers for each impact. :rtype: xarray.Dataset .. py:method:: export_to_excel(filepath = 'human_health_results.xlsx') Export human health inputs and results to an Excel workbook. :param filepath: Destination path for the generated workbook. :type filepath: str