CPSPPOTevents: Identifying the occurrence points of the indicator processes...

Description Usage Arguments Details Value References See Also Examples

View source: R/CPSPPOTevents.R

Description

This function calculates the occurrence times and other characteristics (length, maximum and mean intensity) of the extreme events of the three indicator processes of a bivariate Common Poisson Shock Process (CPSP) obtained from a Peak Over Threshold (POT) approach.

Usage

1
2
CPSPPOTevents(N1,N2,thres1,thres2, date=NULL, dplot=T, pmfrow=c(2,1), 
	axispoints=NULL,...)

Arguments

N1

Numeric vector. Series (x_i) whose threshold exceedances define the first CPSP marginal process.

N2

Numeric vector. Series (y_i) whose threshold exceedances define the second CPSP marginal process.

thres1

Numeric value. Threshold used to define the extreme events in (x_i).

thres2

Numeric value. Threshold used to define the extreme events in (y_i).

date

Optional. A vector or matrix indicating the date of each observation.

dplot

Optional. A logical flag. If it is TRUE, the marginal and indicator processes are plotted.

pmfrow

Optional. A vector of the form (nr, nc) to be supplied as value of the argument mfrow in par.

axispoints

Optional. Numeric vector with the points in the time index where axis ticks and labels (from the first column in date) have to be drawn.

...

Further arguments to be passed to the function plot.

Details

A CPSP N can be decomposed into three independent indicator processes: N_{(1)}, N_{(2)} and N_{(12)}, the processes of the points occurring only in the first marginal process, only in the second and in both of them (simultaneous points). In the CPSP resulting from applying a POT approach, the events in N_{(1)} are a run of consecutive observations where x_i exceeds its extreme threshold but y_i does not exceed its extreme threshold. An extreme event in N_{(2)} is defined analogously. A simultaneous event, or event in N_{(12)}, is a run where both series exceed their thresholds.

For the events defined in each indicator process, three magnitudes (length, maximum intensity and mean intensity) are calculated together with the initial point and the point of maximum excess of each event. In N_{(12)}, the maximum and the mean intensity in both series (x_i) and (y_i) are calculated.

The occurrence point of each event is the time in the run where the maximum of the sum of the excesses of (x_i) and (y_i) over their threholds occurs; if an observation does not exceed its corresponding threshold, that excess is 0. According to this definition, the occurrence point in N_{(1)} is the point with maximum intensity in (x_i) within the run.

The vectors inddat1, inddat2 and inddat12, elements of the output list, mark the observations that should be used in the estimation of each indicator process. The observations in an extreme event which are not the occurrence point are marked with 0 and treated as non observed in the estimation process. The rest are marked with 1 and must be included in the likelihood function. See function fitPP.fun in package NHPoisson for more details on the use of these indexes in the estiamtion of a point process.

The points in the marginal N_{1}, N_{2} and indicator N_{(1)}, N_{(2)} and N_{(12)} processes can be optionally plotted. If date is NULL, default axis are used. Otherwise, the values in axispoints are used as the points in the time index where axis ticks and labels, from the first column in date, have to be drawn. If axispoints is NULL, a default grid of points is built using the function marca.

Value

A list with components

Im1

Vector of mean excesses (over the threshold) of the extreme events in N_{(1)}.

Ix1

Vector of maximum excesses (over the threshold) of the extreme events in N_{(1)}.

L1

Vector of lengths of the extreme events in N_{(1)}.

Px1

Vector of points of maximum excess of the extreme events in N_{(1)}.

Pi1

Vector of initial points of the extreme events in N_{(1)}.

inddat1

Index of the observations to be used in the estimation process of N_{(1)}.

Im2

Vector of mean excesses (over the threshold) of the extreme events in N_{(2)}.

IxY

Vector of maximum excesses (over the threshold) of the extreme events in N_{(2)}.

L2

Vector of lengths of the extreme events in N_{(2)}.

Px2

Vector of points of maximum excess of the extreme events in N_{(2)}.

Pi2

Vector of initial points of the extreme events in N_{(2)}.

inddat2

Index of the observations to be used in the estimation process of N_{(2)}.

Im121

Vector of mean excesses of the series (x_i) in N_{(12)}.

Ix121

Vector of maximum excesses the series (x_i) in N_{(12)}.

Im122

Vector of mean excesses of the series (y_i) in N_{(12)}.

Ix122

Vector of maximum excesses the series (y_i) in N_{(12)}.

L12

Vector of lengths of the extreme events in N_{(12)}.

Px12

Vector of points of maximum excess of the extreme events in N_{(12)}.

Pi12

Vector of initial points of the extreme events in N_{(12)}.

inddat12

Index of the observations to be used in the estimation process of N_{(12)}.

N1

Input argument.

N2

Input argument.

thres1

Input argument.

thres1

Input argument.

date

Input argument.

References

Abaurrea, J. Asin, J. and Cebrian, A.C. (2015). A Bootstrap Test of Independence Between Three Temporal Nonhomogeneous Poisson Processes and its Application to Heat Wave Modeling. Environmental and Ecological Statistics, 22(1), 127-144.

See Also

CPSPpoints, PlotMCPSP, PlotICPSP

Examples

1
2
3
4
5
data(TxBHZ)
dateT<-cbind(TxBHZ$year,TxBHZ$month,TxBHZ$day)  #year, month and day of the month
marca<- c(1:length(TxBHZ$TxH))[c(1,diff(dateT[,1]))==1]  # points at  first day  of the year
BivEv<-CPSPPOTevents(N1=TxBHZ$TxH,N2=TxBHZ$TxZ,thres1=378,thres2=364, date=dateT, 
       axispoints=marca)

IndTestPP documentation built on Aug. 29, 2020, 1:06 a.m.