Title: | Utilise Catastrophe Model Event Loss Table Outputs |
---|---|
Description: | Provides a tool to run Monte Carlo simulation of catastrophe model event loss tables, using a Poisson frequency and Beta severity distribution. |
Authors: | Randhir Bilkhu [aut, cre] |
Maintainer: | Randhir Bilkhu <[email protected]> |
License: | LGPL (>= 2.1) |
Version: | 0.1.0 |
Built: | 2025-01-24 03:23:55 UTC |
Source: | https://github.com/randhirbilkhu/eltr |
Create parameters for ELT simulation
create_elt(dt, ann_rate, mu, sdev_i, sdev_c, expval)
create_elt(dt, ann_rate, mu, sdev_i, sdev_c, expval)
dt |
an ELT (Event Loss Table) |
ann_rate |
a vector of annual rates for each event |
mu |
a vector of mean event loss |
sdev_i |
a vector of independent standard deviations |
sdev_c |
a vector of correlated standard deviations |
expval |
the total values exposed in each event |
a data.table object with mean damage ratio, total standard deviation and alpha/beta parameters
create_elt (eltr::example_elt, ann_rate="rate", mu="mean", sdev_i = "sdevi" , sdev_c = "sdevc", expval = "exp")
create_elt (eltr::example_elt, ann_rate="rate", mu="mean", sdev_i = "sdevi" , sdev_c = "sdevc", expval = "exp")
OEP Curve
create_oep_curve( dt, y, z, rp = c(10000, 5000, 1000, 500, 250, 200, 100, 50, 25, 10, 5, 2) )
create_oep_curve( dt, y, z, rp = c(10000, 5000, 1000, 500, 250, 200, 100, 50, 25, 10, 5, 2) )
dt |
aggregate annual YLT |
y |
vector of year |
z |
vector of loss amount |
rp |
return period default points= c(10000,5000,1000,500,250,200,100,50, 25,10,5 , 2) |
a vector of OEP at return periods as specified by the argument rp
create_oep_curve(data.table::data.table("Year" = c(1,2,3,4,5) , "Loss" =c(1 , 20 , 500 , 100 , 10000)) , y= "Year", z="Loss")
create_oep_curve(data.table::data.table("Year" = c(1,2,3,4,5) , "Loss" =c(1 , 20 , 500 , 100 , 10000)) , y= "Year", z="Loss")
Create a YLT from ELT via monte carlo simulation
create_ylt(dt, sims, ann_rate, event_id, expval, mu)
create_ylt(dt, sims, ann_rate, event_id, expval, mu)
dt |
a data.table with modified ELT |
sims |
number of years to simulate |
ann_rate |
event frequency |
event_id |
unique event identifier |
expval |
total amount exposed |
mu |
mean event loss |
a tidy data.table with Loss, Year and ID. Where a year simulated with zero events will show as "none"
create_ylt(create_elt(eltr::example_elt, ann_rate="rate", mu="mean", sdev_i = "sdevi" , sdev_c = "sdevc", expval="exp"), sims=10,ann_rate = "rate" ,event_id = "id",expval = "exp",mu ="mean")
create_ylt(create_elt(eltr::example_elt, ann_rate="rate", mu="mean", sdev_i = "sdevi" , sdev_c = "sdevc", expval="exp"), sims=10,ann_rate = "rate" ,event_id = "id",expval = "exp",mu ="mean")
eltr provides functions to help
The eltr functions...
This is a mock up of an ELT to help show case the typical structure of the data set and attributes
example_elt
example_elt
a data.table with 10 rows and 6 variables:
unique event identifier
the expected annual frequency of occurence of each event
the mean event loss if it occurs
independent component of standard deviation of event loss if it occurs
correlated component of standard deviation of event loss if it occurs
maximum loss equivalent to total limit exposed
Limited loss to the layer
layer_loss(x, Excess, Limit)
layer_loss(x, Excess, Limit)
x |
event loss |
Excess |
treaty retention |
Limit |
treaty limit |
limited loss to the layer
layer_loss(5,2,6) layer_loss(5,10,6)
layer_loss(5,2,6) layer_loss(5,10,6)