circularEV (version 0.1.0)

ThrSelection: Threshold selection

Description

This function selects a moving threshold for circular data using an automatic procedure for selecting the local number of exceedances

Usage

ThrSelection(
  Data,
  drc,
  h = 30,
  b = 0.35,
  thetaGrid,
  EVIestimator = "ML",
  useKernel = TRUE,
  concent = 10,
  bw = 30,
  numCores = 2
)

Arguments

Data

Response variable

drc

Directional covariate

h

Bandwidth value

b

Parameter used in the automatic procedure for selection of local number of exceedances

thetaGrid

Grid values at which the estimation is performed

EVIestimator

It can be either "ML" or "Mom"

useKernel

Logical. If TRUE (default), use kernel to assign weights depending on the directional distance.

concent

Concentration parameter value for von Mises kernel

bw

Bandwidth parameter value for smoothing the sample path of the selected threshold

numCores

Number of CPU cores to be used

Value

List containing the selected threshold and selected number of local exceedances at each direction in the grid.

Details

See Konzen, E., Neves, C., and Jonathan, P. (2020+). Modelling non-stationary extremes of storm severity: comparing parametric and semi-parametric inference. Environmetrics (to appear).

See Also

PlotData and PolarPlotData to see how the threshold can be visualised.

Examples

Run this code
# NOT RUN {
data(HsSP)
data(drc)
timeRange <- 54.5

idx <- order(drc)
drc <- drc[idx]
Data <- HsSP[idx]
set.seed(1234)
Data <- Data + runif(length(Data), -1e-4, 1e-4)

thetaVec <- 1:360

# }
# NOT RUN {
thrResultMom <- ThrSelection(Data=Data, drc=drc, h=60, b=0.35, thetaGrid=thetaVec,
                             EVIestimator="Mom", useKernel=T, concent=10, bw=30,
                             numCores=2)$thr
thrResultML <- ThrSelection(Data=Data, drc=drc, h=60, b=0.35, thetaGrid=thetaVec,
                            EVIestimator="ML", useKernel=T, concent=10, bw=30,
                            numCores=2)$thr
# }
# NOT RUN {

## See also examples in vignettes:
# vignette("localMethods", package = "circularEV")
# vignette("splineML", package = "circularEV")

# }

Run the code above in your browser using DataLab