Description Usage Arguments Details Value Author(s) References See Also Examples

Fit spliced distribution of a mixed Erlang distribution and Pareto distribution(s). The shape parameter(s) of the Pareto distribution(s) is determined using the Hill estimator.

1 2 3 4 5 6 7 8 9 | ```
SpliceFitPareto(X, const = NULL, tsplice = NULL, M = 3, s = 1:10, trunclower = 0,
truncupper = Inf, EVTtruncation = FALSE, ncores = NULL,
criterium = c("BIC","AIC"), reduceM = TRUE,
eps = 10^(-3), beta_tol = 10^(-5), maxiter = Inf)
SpliceFitHill(X, const = NULL, tsplice = NULL, M = 3, s = 1:10, trunclower = 0,
truncupper = Inf, EVTtruncation = FALSE, ncores = NULL,
criterium = c("BIC","AIC"), reduceM = TRUE,
eps = 10^(-3), beta_tol = 10^(-5), maxiter = Inf)
``` |

`X` |
Data used for fitting the distribution. |

`const` |
Vector of length |

`tsplice` |
Vector of length |

`M` |
Initial number of Erlang mixtures, default is 3. This number can change when determining an optimal mixed Erlang fit using an information criterion. |

`s` |
Vector of spread factors for the EM algorithm, default is |

`trunclower` |
Lower truncation point. Default is 0. |

`truncupper` |
Upper truncation point. Default is |

`EVTtruncation` |
Logical indicating if the |

`ncores` |
Number of cores to use when determining an optimal mixed Erlang fit using an information criterion.
When |

`criterium` |
Information criterion used to select the number of components of the ME fit and |

`reduceM` |
Logical indicating if M should be reduced based on the information criterion, default is |

`eps` |
Covergence threshold used in the EM algorithm (ME part). Default is |

`beta_tol` |
Threshold for the mixing weights below which the corresponding shape parameter vector is considered neglectable (ME part). Default is |

`maxiter` |
Maximum number of iterations in a single EM algorithm execution (ME part). Default is |

See Reynkens et al. (2017), Section 4.3.1 of Albrecher et al. (2017) and Verbelen et al. (2015) for details. The code follows the notation of the latter. Initial values follow from Verbelen et al. (2016).

The `SpliceFitHill`

function is the same function but with a different name for compatibility with old versions of the package.

Use `SpliceFiticPareto`

when censoring is present.

A `SpliceFit`

object.

Tom Reynkens with `R`

code from Roel Verbelen for fitting the mixed Erlang distribution.

Albrecher, H., Beirlant, J. and Teugels, J. (2017). *Reinsurance: Actuarial and Statistical Aspects*, Wiley, Chichester.

Beirlant, J., Fraga Alves, M.I. and Gomes, M.I. (2016). "Tail fitting for Truncated and Non-truncated Pareto-type Distributions." *Extremes*, 19, 429–462.

Reynkens, T., Verbelen, R., Beirlant, J. and Antonio, K. (2017). "Modelling Censored Losses Using Splicing:
a Global Fit Strategy With Mixed Erlang and Extreme Value Distributions". *Insurance: Mathematics and Economics*, 77, 65–77.

Verbelen, R., Gong, L., Antonio, K., Badescu, A. and Lin, S. (2015). "Fitting Mixtures of
Erlangs to Censored and Truncated Data Using the EM Algorithm." *Astin Bulletin*, 45, 729–758.

Verbelen, R., Antonio, K. and Claeskens, G. (2016). "Multivariate Mixtures
of Erlangs for Density Estimation Under Censoring." *Lifetime Data Analysis*, 22, 429–455.

`SpliceFiticPareto`

, `SpliceFitGPD`

, `Splice`

,
`Hill`

, `trHill`

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 | ```
## Not run:
# Pareto random sample
X <- rpareto(1000, shape = 2)
# Splice ME and Pareto
splicefit <- SpliceFitPareto(X, 0.6)
x <- seq(0, 20, 0.01)
# Plot of spliced CDF
plot(x, pSplice(x, splicefit), type="l", xlab="x", ylab="F(x)")
# Plot of spliced PDF
plot(x, dSplice(x, splicefit), type="l", xlab="x", ylab="f(x)")
# Fitted survival function and empirical survival function
SpliceECDF(x, X, splicefit)
# Log-log plot with empirical survival function and fitted survival function
SpliceLL(x, X, splicefit)
# PP-plot of empirical survival function and fitted survival function
SplicePP(X, splicefit)
# PP-plot of empirical survival function and
# fitted survival function with log-scales
SplicePP(X, splicefit, log=TRUE)
# Splicing QQ-plot
SpliceQQ(X, splicefit)
## End(Not run)
``` |

```
sh: 1: wc: Permission denied
sh: 1: cannot create /dev/null: Permission denied
```

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.