Type: | Package |
Title: | Computation of the Probability of Ruin Within a Finite Time Horizon |
Version: | 0.6 |
Date: | 2016-12-30 |
Maintainer: | Benjamin Baumgartner <benjamin@baumgrt.com> |
Description: | In the Cramér–Lundberg risk process perturbed by a Wiener process, this packages provides approximations to the probability of ruin within a finite time horizon. Currently, there are three methods implemented: The first one uses saddlepoint approximation (two variants are provided), the second one uses importance sampling and the third one is based on the simulation of a dual process. This last method is not very accurate and only given here for completeness. |
License: | AGPL-3 |
Imports: | sdprisk, numDeriv, utils, methods |
Encoding: | UTF-8 |
NeedsCompilation: | no |
Packaged: | 2016-12-30 16:38:46 UTC; benjamin |
Author: | Benjamin Baumgartner [aut, cre], Riccardo Gatto [ctb, ths] |
Repository: | CRAN |
Date/Publication: | 2016-12-30 19:38:40 |
Computation of the Probability of Ruin Within a Finite Time Horizon
Description
In the Cramér–Lundberg risk process perturbed by a Wiener process, this packages provides approximations to the probability of ruin within a finite time horizon. Currently, there are three methods implemented: The first one uses saddlepoint approximation (two variants are provided), the second one uses importance sampling and the third one is based on the simulation of a dual process. This last method is not very accurate and only given here for completeness.
Author(s)
Benjamin Baumgartner <benjamin@baumgrt.com>
References
Gatto, R. and Baumgartner, B. (2016) Saddlepoint approximations to the probability of ruin in finite time for the compound Poisson risk process perturbed by diffusion. Methodology and Computing in Applied Probability 18(1), pp. 217-235.
Simulation of a risk process that is perturbed by a Wiener process
Description
This function simulates paths of a compound Poisson risk process that is perturbed by a Wiener process. Multiple paths can be simulated simultaneously.
Usage
rriskproc(m = 1001, window = c(0, 1), num = 1,
sigma = 1, freq = 1, drift = 0, jumpdist, ...)
Arguments
m |
Number of sample points for each path |
window |
Beginning and end of the time window |
num |
Number of paths to be simulated |
sigma |
Volatility of the Wiener process |
freq |
Frequency of the claims |
drift |
Drift (premium intensity) of the process |
jumpdist |
A function that returns realizations of the claim distribution |
... |
Additional arguments for |
Details
Possible choices for jumpdist
include rexp
,
rgamma
and rlnorm
.
It is assumed that the function specified for jumpdist
interprets
its first argument as the vector length of its return value, i. e. the
number of simultaneously generated random variables.
The path realizations of the Wiener process are generated using the circulant embedding method (see references).
Value
A time-series object/time-series object containing the simulated sample path(s).
References
Dietrich, C. and Newsam, G. (1997) Fast and Exact Simulation of Stationary Gaussian Processes through Circulant Embedding of the Covariance Matrix. SIAM Journal on Scientific Computing 18(4), pp. 1088-1107
See Also
Examples
require(sdprisk)
rriskproc(m = 1001,
window = c(0, 5),
num = 1,
sigma = sqrt(0.4),
freq = 1,
drift = 2,
jumpdist = rhypoexp,
rate = c(1, 10))
# The same can be achieved using
# jumpdist = function(n) rexp(n, 1) + rexp(n, 10)
rriskproc(window = c(0, 10),
jumpdist = function(n) {
rexp(n, 1) + rexp(n, 10)
})
Computation of the probability of ruin within a finite time horizon using a dual process
Description
This function calculates an approximation to the probability of ruin within a finite time horizon for a compound Poisson risk process that is perturbed by a Wiener process. The approximation is based on a dual process to the risk process.
Usage
ruinprob.finite.dsim(Z)
Arguments
Z |
A time-series object, e.g. one generated by rriskproc, containing at least two series |
Details
This function computes an approximation to the probability of ruin within a finite time horizon using a dual process. See the references for more details.
Value
A function taking one numeric argument, the initial capital. This function returns the
approximation for the specified initial reserve and for all values of the time horizon
that are sampling points of Z
.
References
Gatto, R. and Baumgartner, B. (2016) Saddlepoint approximations to the probability of ruin in finite time for the compound Poisson risk process perturbed by diffusion. Methodology and Computing in Applied Probability 18(1), pp. 217-235.
Approximation of the probability of ruin within a finite time horizon using importance sampling
Description
This function calculates an approximation to the probability of ruin within a finite time horizon for a compound Poisson risk process that is perturbed by a Wiener process. The approximation is based on importance sampling.
Usage
ruinprob.finite.imps()
Value
This function is not yet fully implemented. At the moment it invisibly returns
NULL
.
References
Gatto, R. and Baumgartner, B. (2016) Saddlepoint approximations to the probability of ruin in finite time for the compound Poisson risk process perturbed by diffusion. Methodology and Computing in Applied Probability 18(1), pp. 217-235.
Approximation of the probability of ruin within a finite time horizon using saddlepoint methods
Description
This function calculates an approximation to the probability of ruin within a finite time horizon for a compound Poisson risk process that is perturbed by a Wiener process. The approximation makes use of saddlepoint methods.
Usage
ruinprob.finite.sdp(mgf, mgf.d1, mgf.d2, premium, freq, variance,
endpoint, verbose = FALSE)
Arguments
mgf |
The moment-generating function of the individual claim amounts |
mgf.d1 |
The first derivative of |
mgf.d2 |
The second derivative of |
premium |
The premium force |
freq |
Frequency of the claims |
variance |
The variance of the Wiener process by which the risk process is perturbed |
endpoint |
The upper endpoint of |
verbose |
Return additional diagnostic information as an attribute of the output |
Details
If neither or only the first derivative of mgf
is provided,
a numerical approximation to the missing derivative(s) will be used
instead (see grad and hessian).
The argument endpoint
is the (smallest) positive pole of
mgf
. Omitting this information will issue a warning and the value
1.0e+6 will be used instead, possibly yielding unexpected and unreliable
output or leading to further errors.
Value
A function psi(x, t)
taking as inputs the initial capital x
and the time horizon t
. This function returns a list, the first
element of which contains a Lugannani–Rice-type approximation, the second
one contains a Skovgaard-type approximation.
References
Gatto, R. and Baumgartner, B. (2016) Saddlepoint approximations to the probability of ruin in finite time for the compound Poisson risk process perturbed by diffusion. Methodology and Computing in Applied Probability 18(1), pp. 217-235.