Con_Sampling_2D_Lag: Conditionally sampling a two dimensional dataset

Description Usage Arguments Value Examples

Description

Creates a data frame where the declustered excesses of a (conditioning) variable are paired with the maximum value of a second variable over a specified lag.

Usage

1
2
Con_Sampling_2D_Lag(Data_Detrend, Data_Declust, Con_Variable,
  Thres = 0.97, Lag_Backward = 0, Lag_Forward = 0)

Arguments

Data_Detrend

Data frame containing two at least partially concurrent time series, detrended if necessary. Time steps must be equally spaced, with missing values assigned NA. First object may be a "Date" object. Can be Dataframe_Combine output.

Data_Declust

Data frame containing two (independently) declustered at least partially concurrent time series. Time steps must be equally spaced, with missing values assigned NA. Columns must be in the same order as in Data_Detrend. First object may be a "Date" object. Can be Dataframe_Combine output.

Con_Variable

Column number (1 or 2) or the column name of the conditioning variable. Default is 1.

Thres

Threshold, as a quantile of the observations of the conditioning variable. Default is 0.97.

Lag_Backward

Positieve lag applied to variable not assigned as the Con_Variable. Default is 0

Lag_Forward

Negative lag to variable not assigned as the Con_Variable. Default is 0

Value

List comprising the specifyied Threshold as the quantile of the conditioning variable above which declustered excesses are paired with co-occurences of the other variable, the resulting two-dimensional sample data and name of the conditioning variable.

Examples

1
2
3
S20.Rainfall<-Con_Sampling_2D(Data_Detrend=S20.Detrend.df[,-c(1,4)],
                              Data_Declust=S20.Detrend.Declustered.df[,-c(1,4)],
                              Con_Variable="Rainfall",Thres=0.97)

rjaneUCF/MultiHazard-R-Package documentation built on Jan. 28, 2021, 12:07 a.m.