# Generalized Pareto Distribution

Fit, evaluate, and generate random samples from generalized Pareto distribution

To model extreme events from a distribution, use the generalized Pareto distribution (GPD). Statistics and Machine Learning Toolbox™ offers several ways to work with the GPD.

• Create a probability distribution object `GeneralizedParetoDistribution` by fitting a probability distribution to sample data or by specifying parameter values. Then, use the object functions to evaluate the distribution, generate random numbers, and so on.

• Work with the GPD interactively by using the Distribution Fitter app. You can export an object from the app and use the object functions.

• Use distribution-specific functions with specified distribution parameters. The distribution-specific functions can accept parameters of multiple GPDs.

• Use generic distribution functions (`cdf`, `icdf`, `pdf`, `random`) with a specified distribution name (```'Generalized Pareto'```) and parameters.

• Create a `paretotails` object to model the tails of a distribution by using the GPDs, with another distribution for the center. A `paretotails` object is a piecewise distribution that consists of one or two GPDs in the tails and another distribution in the center. You can specify the distribution type for the center by using the `cdffun` argument of `paretotails` when you create the object. Valid values of `cdffun` are `'ecdf'` (interpolated empirical cumulative distribution), `'kernel'` (interpolated kernel smoothing estimator), and a function handle. After creating an object, you can use the object functions to evaluate the distribution and generate random numbers.

To learn about the generalized Pareto distribution, see Generalized Pareto Distribution.

## Objects

 `GeneralizedParetoDistribution` Generalized Pareto probability distribution object

## Apps

 Distribution Fitter Fit probability distributions to data Probability Distribution Function Interactive density and distribution plots

## Functions

expand all

#### Create `GeneralizedParetoDistribution` Object

 `makedist` Create probability distribution object `fitdist` Fit probability distribution object to data

#### Work with `GeneralizedParetoDistribution` Object

 `cdf` Cumulative distribution function `gather` Gather properties of Statistics and Machine Learning Toolbox object from GPU `icdf` Inverse cumulative distribution function `iqr` Interquartile range of probability distribution `mean` Mean of probability distribution `median` Median of probability distribution `negloglik` Negative loglikelihood of probability distribution `paramci` Confidence intervals for probability distribution parameters `pdf` Probability density function `plot` Plot probability distribution object `proflik` Profile likelihood function for probability distribution `random` Random numbers `std` Standard deviation of probability distribution `truncate` Truncate probability distribution object `var` Variance of probability distribution

#### Create `paretotails` Object

 `paretotails` Piecewise distribution with Pareto tails

#### Work with `paretotails` Object

 `boundary` Piecewise distribution boundaries `cdf` Cumulative distribution function `icdf` Inverse cumulative distribution function `lowerparams` Lower Pareto tail parameters `nsegments` Number of segments in piecewise distribution `pdf` Probability density function `random` Random numbers `segment` Piecewise distribution segments containing input values `upperparams` Upper Pareto tail parameters
 `gpcdf` Generalized Pareto cumulative distribution function `gppdf` Generalized Pareto probability density function `gpinv` Generalized Pareto inverse cumulative distribution function `gplike` Generalized Pareto negative loglikelihood `gpstat` Generalized Pareto mean and variance `gpfit` Generalized Pareto parameter estimates `gprnd` Generalized Pareto random numbers
 `mle` Maximum likelihood estimates `mlecov` Asymptotic covariance of maximum likelihood estimators
 `histfit` Histogram with a distribution fit `probplot` Probability plots `plot` Plot probability distribution object `qqplot` Quantile-quantile plot `randtool` Interactive random number generation