ladybug.stat module

class ladybug.stat.STAT(file_path)[source]

Bases: object

Import data from a local .stat file.

Parameters

file_path – Address to a local .stat file.

Properties:
  • location

  • ashrae_climate_zone

  • koppen_climate_zone

  • extreme_cold_week

  • extreme_hot_week

  • typical_winter_week

  • typical_spring_week

  • typical_summer_week

  • typical_autumn_week

  • other_typical_weeks

  • annual_heating_design_day_996

  • annual_heating_design_day_990

  • annual_cooling_design_day_004

  • annual_cooling_design_day_010

  • monthly_cooling_design_days_100

  • monthly_cooling_design_days_050

  • monthly_cooling_design_days_020

  • monthly_cooling_design_days_004

  • monthly_db_temp_050

  • monthly_wb_temp_050

  • monthly_db_temp_range_050

  • monthly_wb_temp_range_050

  • monthly_found

  • standard_pressure_at_elev

  • monthly_wind_conditions

  • monthly_ws_avg

  • monthly_wind_dirs

  • monthly_clear_sky_conditions

  • monthly_tau_beam

  • monthly_tau_diffuse

  • file_path

ToString()[source]

Overwrite .NET ToString.

classmethod from_dict(data)[source]

Create Stat from a dictionary.

Parameters

data – A python dictionary in the following format

{
"location": {},  # ladybug location schema
"ashrae_climate_zone": ""5A,  # str
"koppen_climate_zone": "Dfa", # str
"extreme_cold_week": {},  # ladybug analysis period schema
"extreme_hot_week": {},  # ladybug analysis period schema
"typical_weeks": {},  # dict of ladybug analysis period schemas
"heating_dict": {},  # dict containing heating design conditions
"cooling_dict": {},  # dict containing cooling design conditions
"monthly_db_50": [],  # list of 12 float values for each month
"monthly_wb_50": [],  # list of 12 float values for each month
"monthly_db_range_50": [],  # list of 12 float values for each month
"monthly_wb_range_50": [],  # list of 12 float values for each month
"monthly_db_100": [],  # list of 12 float values for each month
"monthly_wb_100": [],  # list of 12 float values for each month
"monthly_db_20": [],  # list of 12 float values for each month
"monthly_wb_20": [],  # list of 12 float values for each month
"monthly_db_04": [],  # list of 12 float values for each month
"monthly_wb_04": [],  # list of 12 float values for each month
"monthly_wind": [],  # list of 12 float values for each month
"monthly_wind_dirs": [],  # matrix with 12 cols for months of the year
                          #and 8 rows for the cardinal directions.
"standard_pressure_at_elev": 101325,  # float value for pressure in Pa
"monthly_tau_beam":[],  # list of 12 float values for each month
"monthly_tau_diffuse": []  # list of 12 float values for each month
}
to_ddy(file_path, percentile=0.4)[source]

Produce a DDY file with a heating + cooling design day from this STAT.

If design days following the input percentile are not found in the STAT data, a ValueError will be raised.

Parameters
  • file_path – Full file path for output ddy file.

  • percentile – A number for the percentile difference from the most extreme conditions for the design days. Choose from 0.4 and 1.0. (Default: 0.4).

to_ddy_monthly_cooling(file_path, annual_percentile=0.4, monthly_percentile=5)[source]

Produce a DDY file with 1 heating and 12 cooling design days.

The heating design day represents a cold and completely dark day whereas the cooling design days represent the warmest conditions in each month. If design days following the input percentile are not found in the STAT data, a ValueError will be raised.

Parameters
  • file_path – Full file path for output ddy file.

  • annual_percentile – A number for the percentile difference from the most extreme conditions for the design days. Choose from 0.4 and 1.0. (Default: 0.4).

  • monthly_percentile – A number between for the percentile difference from the most extreme conditions within each month to be used for the cooling design days. Choose from 10, 5, 2 or 0.04. (Default: 5).

to_dict()[source]

Convert the stat object to a dictionary.

property annual_cooling_design_day_004

A design day object representing the annual 0.4% cooling design day.

property annual_cooling_design_day_010

A design day object representing the annual 1.0% cooling design day.

property annual_heating_design_day_990

A design day object representing the annual 99.0% heating design day.

property annual_heating_design_day_996

A design day object representing the annual 99.6% heating design day.

property ashrae_climate_zone

Return a text string indicating the ASHRAE climate zone.

Numbers in the zone denote average temperature (0 = Hottest; 8 = Coldest) Letters in the zone denote wetness (A = Humid; B = Dry; C = Marine)

property extreme_cold_week

AnalysisPeriod for the coldest week within the corresponding EPW.

property extreme_hot_week

AnalysisPeriod for the hottest week within the corresponding EPW.

property file_path

Get the path to the stat file.

property koppen_climate_zone

Return a text string indicating the Koppen climate zone.

The Koppen climate classification is the most widely used climate classification system and combines average annual and monthly temperatures, precipitation, and the seasonality of precipitation.

property location

Return ladybug location object.

property monthly_clear_sky_conditions

A list of 12 monthly clear sky conditions that are used on the design days.

property monthly_cooling_design_days_004

A list of 12 objects representing monthly 0.4% cooling design days.

property monthly_cooling_design_days_020

A list of 12 objects representing monthly 2.0% cooling design days.

property monthly_cooling_design_days_050

A list of 12 objects representing monthly 5.0% cooling design days.

property monthly_cooling_design_days_100

A list of 12 objects representing monthly 10.0% cooling design days.

property monthly_db_temp_050

A list of 12 float values for monthly 5.0% dry bulb temperature.

property monthly_db_temp_range_050

A list of 12 values for monthly ranges of dry bulb temperatures at 5.0%.

property monthly_found
property monthly_tau_beam

A list of 12 float values for monthly beam optical depth.

These values can be used to generate ASHRAE Revised Clear Skies, which are intended to determine peak solar load and sizing parmeters for HVAC systems.

property monthly_tau_diffuse

Return a list of 12 float values for monthly diffuse optical depth.

These values can be used to generate ASHRAE Revised Clear Skies, which are intended to determine peak solar load and sizing parmeters for HVAC systems.

property monthly_wb_temp_050

A list of 12 float values for monthly 5.0% wet bulb temperature.

property monthly_wb_temp_range_050

A list of 12 values for monthly ranges of wet bulb temperatures at 5.0%.

property monthly_wind_conditions

A list of 12 monthly wind conditions that are used on the design days.

property monthly_wind_dirs

A list of prevailing wind directions for each month.

property monthly_ws_avg

A list of 12 float values for monthly average wind speeds.

property other_typical_weeks

List of AnalysisPeriods for typical weeks outside of the seasonal weeks.

property standard_pressure_at_elev

The standard pressure on pascals at the elevation of the location.

property typical_autumn_week

AnalysisPeriod for a typical autumn week within the corresponding EPW.

property typical_spring_week

AnalysisPeriod for a typical spring week within the corresponding EPW.

property typical_summer_week

AnalysisPeriod for a typical summer week within the corresponding EPW.

property typical_winter_week

AnalysisPeriod for a typical winter week within the corresponding EPW.