Skip to contents

Bands of sum insured, each with an expected loss (given, or premium times a loss ratio) and its own exposure curve. Each band's representative risk has sum insured SI (its total sum insured over its number of risks, say), taken as its MPL; the band expects EL / (SI * curve@mean) losses a year.

Usage

risk_profile(
  sums_insured,
  risks,
  curves,
  expected_loss = NULL,
  premium = NULL,
  loss_ratio = NULL,
  lower = NULL,
  upper = NULL,
  spread = c("uniform", "tilted")
)

profile_simulate(profile, n_sims, seed)

profile_layer_loss(
  profile,
  limit,
  attachment,
  surplus_retention = NULL,
  surplus_lines = NULL
)

profile_surplus_loss(profile, retention, lines)

Arguments

sums_insured

One per band.

risks

Number of risks per band (for reference).

curves

An mbbefd or tabulated_curve for every band, or a list with one per band.

expected_loss

Expected annual loss per band. Give this, or premium with loss_ratio.

premium

Premium per band.

loss_ratio

Expected loss ratio: one value, or one per band.

lower, upper

Optional bounds of each band's sums insured, one per band (NA for a band without). A band with bounds spreads its risks' sums insured uniformly between them: its mean SI is (lower + upper) / 2 (in place of sums_insured), each simulated loss draws its own SI between the bounds, and the exposure-rated expectations average over the band, weighted by sum insured.

spread

How a band with bounds spreads its sums insured: "uniform", or "tilted" to keep sums_insured as the mean, so the spread matches both the bounds and the band's total sum insured (the density exp(theta * s) on the bounds, theta solved for that mean; sums_insured must lie strictly between the bounds).

profile

A risk_profile.

n_sims

Number of simulated years.

seed

Generator seed.

limit, attachment

A per-risk layer; limit = Inf for unlimited.

surplus_retention, surplus_lines

A surplus treaty the layer inures to, or NULL.

retention, lines

A surplus treaty's retention line and lines.

Value

risk_profile(): a risk_profile object with properties expected_loss (all bands) and expected_claims (per band).

Details

profile_simulate() draws years of losses: a Poisson number with the profile's expected count, each in a band with probability proportional to the band's expected count, and the band's SI times a destruction rate from its curve. Every loss carries its SI, so a surplus_treaty() and the per-risk excess of loss it inures to apply with apply_tower(). profile_layer_loss() and profile_surplus_loss() are the exposure-rated expectations, which check the simulation.

Examples

p <- risk_profile(c(1e6, 10e6), c(800, 50), swiss_re_curve(3),
                  premium = c(2e6, 1e6), loss_ratio = 0.6)
p@expected_loss
#> [1] 1800000
ev <- profile_simulate(p, 1000, seed = 7)
tw <- inuring_tower(list(list(surplus_treaty("S", 1e6, 4)),
                         list(xol_layer("XL", 1e6, 0.5e6))))
mean(total(apply_tower(tw, ev)))
#> [1] 3552136
profile_surplus_loss(p, 1e6, 4)
#> [1] 240000
profile_layer_loss(p, 1e6, 0.5e6, surplus_retention = 1e6, surplus_lines = 4)
#> [1] 350192.2