Learn R Programming

bootruin (version 1.2-4)

ruinprob.test: A Bootstrap Test for the Probability of Ruin in the Classical Risk Process

Description

This function provides a testing framework for the probability of ruin in the classical, compound Poisson risk process. The test can be performed using the bootstrap method or using normal approximation.

Usage

ruinprob.test(x, prob.null, type = c("bootstrap", "normal"), nboot, bootmethod = c("nonp", "exp", "lnorm"), ...)

Arguments

x
a numeric vector of data values (claims)
prob.null
a number indicating the hypothesized true probability of ruin.
type
a character string determining the type of test that is performed.
nboot
a number indicating the number of bootstrap replications.
bootmethod
a character string determining how the bootstrap replications are created.
...
further arguments to be passed to ruinprob.

Value

A list with class "htest" containing the following components:

Details

The null hypothesis is that the probability of ruin is equal to prob.null versus the one-sided alternative that probability of ruin is smaller than prob.null.

If type = "bootstrap", a bootstrap test is performed. The arguments nboot and bootmethod have to be specified. bootmethod determines the kind of bootstrap: "nonp" creates the usual nonparametric bootstrap replications, while "exp" and "lnorm" create parametric bootstrap replications, the former assuming exponentially distributed claims, the latter log-normally distributed ones.

type = "normal" makes use of an asymptotic normal approximation. The computations are a lot faster, but from a theoretical point of view the bootstrap method is more accurate, see References.

For details about the necessary and valid arguments that might have to be supplied for ..., see ruinprob.

References

Baumgartner, B. and Gatto, R. (2010) A Bootstrap Test for the Probability of Ruin in the Compound Poisson Risk Process. ASTIN Bulletin, 40(1), pp. 241--255.

See Also

ruinprob

Examples

Run this code
# Generating a sample of 50 exponentially distributed claims with mean 10
x <- rexp(50, 0.1)

## Not run: 
# # Given this sample, test whether the probability of ruin is smaller than
# # 0.1 using a bootstrap test with 100 bootstrap replications.
# ruinprob.test(
#     x = x, prob.null = 0.10, type = "bootstrap",
#     loading = 0.2, reserve = 100, interval = 1,
#     bootmethod = "nonp", nboot = 100
# )
# ## End(Not run)

# The same test using normal approximation. This is a lot faster.
ruinprob.test(
    x = x, prob.null = 0.15, type = "normal",
    loading = 0.2, reserve = 100, interval = 1
)

Run the code above in your browser using DataLab