morphing_epw() takes an epw_cmip6_data object generated using extract_data() and calculates future core EPW weather variables using Morphing Method.

morphing_epw(
  data,
  years = NULL,
  labels = NULL,
  methods = NULL,
  warning = FALSE
)

Arguments

data

An epw_cmip6_dataobject generated using extract_data()

years

An integer vector indicating the target years to be considered. If NULL, all years in input data will be considered. Default: NULL.

labels

A character or factor vector used for grouping input years. Usually are the outputs of base::cut(). labels should have the same length as years. If given, climate data of years grouped by labels will be averaged. Default: NULL.

methods

A named character giving the methods of morphing procedures of each variables. Possible variable names are tdb, rh, p, hor_ir, glob_rad, wind. Possible values are: "stretch", "shift" and "combined". For example: c(tdb = "stretch", rh = "shift"). "combined" is only applicable to tdb. The default morphing method for each variable is listed in the Return section. If NULL, the default methods will be used. Default: NULL.

warning

If TRUE, warnings will be issued for cases with input data less than a decade (10 years). This is because using data that only covers a short period of time may not be able to capture the average of future climate. Default: FALSE.

Value

An epw_cmip6_morphed object, which is basically a list of 12 elements:

No.ElementTypeMorphing MethodDescription
1epweplusr::EpwN/AThe original EPW file used for morphing
2tdbdata.table::data.table()StretchData of dry-bulb temperature after morphing
3tdewdata.table::data.table()DerivedData of dew-point temperature after morphing
4rhdata.table::data.table()StretchData of relative humidity after morphing
5pdata.table::data.table()StretchData of atmospheric pressure after morphing
6hor_irdata.table::data.table()StretchData of horizontal infrared radiation from the sky after morphing
7glob_raddata.table::data.table()StretchData of global horizontal radiation after morphing
8norm_raddata.table::data.table()DerivedData of direct normal radiation after morphing
9diff_raddata.table::data.table()StretchData of diffuse horizontal radiation after morphing
10winddata.table::data.table()StretchData of wind speed after morphing
11total_coverdata.table::data.table()DerivedData of total sky cover after morphing
12opaque_coverdata.table::data.table()DerivedData of opaque sky cover after morphing

Each data.table::data.table() listed above contains 19 columns below or an empty data.table::data.table() if the corresponding variables cannot be found in the input epw_cmip6_data object.

No.ColumnTypeDescription
1activity_drsCharacterActivity DRS (Data Reference Syntax)
2institution_idCharacterInstitution identifier
3source_idCharacterModel identifier
4experiment_idCharacterRoot experiment identifier
5member_idCharacterA compound construction from sub_experiment_id and variant_label
6table_idCharacterTable identifier
7lonDoubleThe averaged values of input longitude
8latDoubleThe averaged values of input latitude
9distDoubleThe averaged spherical distances in km between EPW location and grid coordinates
10intervalFactorThe label value used to average raw input data
11datetimePOSIXctThe datetime value with fake year generated by calling the Epw$data() method with the input EPW
12yearIntegerThe original year of the raw EPW data
13monthIntegerThe month value of the morphed data
14dayIntegerThe day of the morphed data
15hourIntegerThe hour of the morphed data
16minuteIntegerThe minute of the morphed data
17Variable NameDoubleThe morphed data, where Variable Name is the corresponding EPW weather variable name
18deltaDoubleThe shift factor. Will be NA for derived values
19alphaDoubleThe stretch factor. Will be NA for derived values

Details

The EPW weather variables that get morphed are listed in details.

The Morphing procedure

Here Morphing is an algorithm proposed by Belcher etc. 2005 used to morph the present-day observed weather files (here the EPWs) to produce future climate weather files. The EPW data is used as the 'baseline climate'.

The first step before morphing is to calculate the monthly means of climatological variables in the EPW file, denoted by \(<x_0>_m\). The subscript '0' is to denote the present day weather record, and 'm' is to denote the month.

The morphing involves three generic operations, i.e. 1) a shift; 2) a linear stretch (scaling factor); and 3) a shift and a stretch:

$$ \textrm{Shift: } x = x_0 + \Delta x_m $$

$$ \textrm{Stretch: }x = \alpha_m x_m $$

$$ \textrm{Shift + Stretch: } x = x_0 + \Delta x_m + \alpha_m (x_0 - <x_0>_m) $$

Shift

If using a shift, for each month, a shift \(\Delta x_m\) is applied to \(x_0\). \(\Delta x_m\) is the absolute change in the monthly mean value of the variable for the month \(m\), i.e. \(\Delta x_m = <x_0>_m - <x>_m\). Here the monthly variance of the variable is unchanged.

Stretch

If using a stretch, for each month, a stretch \(\alpha _m\) is applied to \(x_0\), where \(\alpha _m\) is the fractional change in the monthly-mean value of a variable, i.e. \(\alpha _m = <x>_m / <x_0>_m\). In this case, the variance will be multiplied by to \(\alpha^2_m\)

Combined Shift and Stretch

When using a combined shift and stretch factor, both the mean and the variance will be switched off altogether.

For more details about morphing, please see (Belcher etc. 2005)

References

Belcher, S., Hacker, J., Powell, D., 2005. Constructing design weather data for future climates. Building Services Engineering Research and Technology 26, 49–61. https://doi.org/10.1191/0143624405bt112oa