Description Usage Arguments Details Author(s) See Also Examples
Building a sevdist object with a spliced distribution
1 | buildSplicedSevdist(body.distr, body.param, tail.distr, tail.param, thresh, weight)
|
body.distr |
A string giving the name of the body distribution. |
body.param |
Vector of the parameters for the given body distribution. |
tail.distr |
A string giving the name of the tail distribution. Distributions "lgamma", "weibull", "gpd", "gh" are recognised. |
tail.param |
Vector of the parameters for the given tail distribution. |
thresh |
Numeric value giving the threshold of the distribution, the severity follows a truncated 'body.distr' distribution below the threshold and a truncated 'tail.distr' distribution above the threshold. |
weight |
Numeric value in [0,1] giving the probability that the severity distribution takes values below the threshold. |
A sevdist object with type 'spliced' is generated, i.e. the severity has distribution 'body.distr' in the body with parameters given by 'body.param' and distribution 'tail.distr' in the tail with parameters given by 'tail.param'.
The density f(x) for a spliced distribution with threshold τ, weights w, body distribution with density g and cumulative distribution function G and tail distribution with density h and cumulative distribution function H is given as below:
If x≤ τ: f(x) = w* g(x)/G(τ)
If x>τ: f(x) = (1-w)* h(x)/(1-H(τ))
Christina Zou
Other sevdist objects with type 'plain' and 'mixing' are built via buildPlainSevdist
and buildMixingSevdist
.
1 2 3 4 5 6 | # Spliced distributed severity with gamma distributed body with shape = 1.23, rate = 0.12
# and GPD distributed tail with shape = 716 and scale = 0.1 and threshold = 2000.
# The weight for the body is 0.8.
sevdist1 = buildSplicedSevdist("gamma", c(2.5, 0.012), "gpd", c(2000, 716, 0.1), 2000, 0.8)
plot(sevdist1)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.