.gpd_2D_fit | R Documentation |

Maximum-likelihood estimation for the generalized Pareto model, including generalized linear modelling of each parameter. This function was adapted by Paul Northrop to include the gradient in the `gpd.fit`

routine from `ismev`

.

```
.gpd_2D_fit(
xdat,
threshold,
npy = 365,
ydat = NULL,
sigl = NULL,
shl = NULL,
siglink = identity,
shlink = identity,
siginit = NULL,
shinit = NULL,
show = TRUE,
method = "Nelder-Mead",
maxit = 10000,
...
)
```

`xdat` |
numeric vector of data to be fitted. |

`threshold` |
a scalar or a numeric vector of the same length as |

`npy` |
number of observations per year/block. |

`ydat` |
matrix of covariates for generalized linear modelling of the parameters (or |

`sigl` |
numeric vector of integers, giving the columns of |

`shl` |
numeric vector of integers, giving the columns of |

`siglink` |
inverse link functions for generalized linear modelling of the scale parameter |

`shlink` |
inverse link functions for generalized linear modelling of the shape parameter |

`siginit` |
numeric giving initial value(s) for parameter estimates. If |

`shinit` |
numeric giving initial value(s) for the shape parameter estimate; if |

`show` |
logical; if |

`method` |
optimization method (see |

`maxit` |
maximum number of iterations. |

`...` |
other control parameters for the optimization. These are passed to components of the |

For non-stationary fitting it is recommended that the covariates within the generalized linear models are (at least approximately) centered and scaled (i.e. the columns of `ydat`

should be approximately centered and scaled).

The form of the GP model used follows Coles (2001) Eq (4.7). In particular, the shape parameter is defined so that positive values imply a heavy tail and negative values imply a bounded upper value.

a list with components

- nexc
scalar giving the number of threshold exceedances.

- nllh
scalar giving the negative log-likelihood value.

- mle
numeric vector giving the MLE's for the scale and shape parameters, resp.

- rate
scalar giving the estimated probability of exceeding the threshold.

- se
numeric vector giving the standard error estimates for the scale and shape parameter estimates, resp.

- trans
logical indicator for a non-stationary fit.

- model
list with components

`sigl`

and`shl`

.- link
character vector giving inverse link functions.

- threshold
threshold, or vector of thresholds.

- nexc
number of data points above the threshold.

- data
data that lie above the threshold. For non-stationary models, the data are standardized.

- conv
convergence code, taken from the list returned by

`optim`

. A zero indicates successful convergence.- nllh
negative log likelihood evaluated at the maximum likelihood estimates.

- vals
matrix with three columns containing the maximum likelihood estimates of the scale and shape parameters, and the threshold, at each data point.

- mle
vector containing the maximum likelihood estimates.

- rate
proportion of data points that lie above the threshold.

- cov
covariance matrix.

- se
numeric vector containing the standard errors.

- n
number of data points (i.e., the length of

`xdat`

).- npy
number of observations per year/block.

- xdata
data that has been fitted.

Coles, S., 2001. An Introduction to Statistical Modeling of Extreme Values. Springer-Verlag, London.

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.