Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

univfit

Fits univariate extreme value distributions to data


Description

These functions fit the generalised extreme value and generalised Pareto distribution to data using maximum likelihood.

Usage

gevmle(x, ..., method = "Nelder")
gpdmle(x, threshold, ..., method = "Nelder")

Arguments

x

Numeric vector of observations

...

Optional arguments to be passed to the optim function.

threshold

Numeric. The threshold value.

method

The numerical optimisation method to be used.

Details

These two functions are “extremely light” functions to fit the GEV/GPD. These functions are mainly useful to compute starting values for the Schlather and Smith model - see fitmaxstab.

If more refined (univariate) analysis have to be performed, users should use more specialised packages - e.g. POT, evd, ismev, ....

Value

A vector for the estimated parameters of the GEV/GPD.

Author(s)

Mathieu Ribatet

Examples

## 1 - GEV fit
x <- rep(NA, 100)
for (i in 1:100)
  x[i] <- max(rnorm(365))

gevmle(x)

## 2- GPD fit
x <- rnorm(10000)
##we need to fix a threshold
u <- quantile(x, 0.99)
gpdmle(x, u)

SpatialExtremes

Modelling Spatial Extremes

v2.0-9
GPL (>= 2)
Authors
Mathieu Ribatet [aut, cre], Richard Singleton [ctb], R Core team [ctb]
Initial release
2020-09-22

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.