Skip to contents

Applies the tower to consecutive years of the same simulated paths: years[[t]] holds year t's losses, and simulation j of every year belongs to path j. Each year's ceded and net loss and premiums are what apply_tower() gives for that year alone; a profit commission or sliding scale that carries deficits or credits forward (with_profit_commission_carry_forward()) reads what the path's earlier years left. term_years() splits one simulation into the years of a term.

Usage

apply_tower_term(tower, years)

Arguments

tower

A reinsurance_tower.

years

A list of event_sets, or of predictive_distributions (each simulation's total taken as one aggregate loss), one per year, each with the same number of simulations.

Value

A predictive_distribution with dimensions kind, layer and year: each of apply_tower()'s components once per year, year from 1.

Examples

qs <- with_premium_rate(quota_share("QS", 1), 1, 100)
qs <- with_profit_commission_carry_forward(with_profit_commission(qs, 0.25, 0.1))
ev <- simulate_events(poisson_count(2), lognormal_from_mean_cv(30, 1), 3000, seed = 7)
term <- apply_tower_term(reinsurance_tower(list(qs)), term_years(ev, 3))
term@dims
#> [1] "kind"  "layer" "year"