average_mean_temp: Calculate average variable of extreme events
Description
This function takes a dataframe of extreme events, as created by
gen_hw_set, and calculates the average of the variable
(e.g., temperature0 during each extreme event across all events in the
dataframe.
Usage
average_mean_temp(hw_datafr)
Arguments
hw_datafr
A dataframe of extreme events and their characteristics, as
created by gen_hw_set
Value
A numeric value with the average variable
during all heat waves for a dataset of heat waves, as generated by
gen_hw_set. This value is the mean of the average variable
within each event, not the average variable across all
event days (to calculate that, you would need to calculate a weighted
mean, weighted by the number of days in each heat wave).