Simulates present values of a discrete single-life insurance payable at the
end of the year of death, or at maturity for an endowment insurance.
Monetary values retain the original log interest rate, even when the
displayed annual effective rate loses range. Finite-horizon survivors
are censored: Kx = n is a placeholder and
died_within_horizon = FALSE, not an observed death at that duration.
Arguments
- lt
A life table or a
tidyact_life_contract.- x
Integer actuarial age.
- i
Numeric scalar interest-rate input.
- i_type
Interest-rate convention.
- m
Positive integer nominal conversion frequency.
- type
"whole","term", or"endowment".- n
Positive integer term, or
Inffor whole life.- benefit
Nonnegative insurance benefit.
- method
Simulation method. Currently only
"inverse".- n_sim
Positive integer number of simulations.
- seed
Optional nonnegative integer seed.
- output
"simulations"or"summary".- ...
Transitional compatibility for
mortality_table,age,rate,rate_type,insurance_type, andterm_years.
Value
A tibble with one row per simulation, or a summary. Simulation
output includes benefit_indicator, benefit_time,
present_value, and pv_benefit.
See also
Other simulation:
simulate_annuity_x()
Other life-contingencies:
add_insurance(),
add_premium_schedule(),
annuity_multi(),
annuity_x(),
annuity_xy(),
insurance_variable_k(),
insurance_x(),
insurance_xy(),
life_contract(),
premium_gross(),
premium_x(),
premium_xy(),
reserve_x(),
reserve_xy(),
simulate_annuity_x()
Examples
lt <- data.frame(
x = 60:66,
lx = c(100000, 99000, 97500, 95500, 93000, 90000, 0)
)
simulate_insurance_x(
lt = lt,
x = 60,
i = 0.05,
type = "term",
n = 5,
benefit = 100000,
n_sim = 25,
seed = 123
)
#> # A tibble: 25 × 26
#> sim_id simulation_id contract_type x age n term_years type
#> <int> <int> <chr> <int> <int> <int> <int> <chr>
#> 1 1 1 term_insurance 60 60 5 5 term
#> 2 2 2 term_insurance 60 60 5 5 term
#> 3 3 3 term_insurance 60 60 5 5 term
#> 4 4 4 term_insurance 60 60 5 5 term
#> 5 5 5 term_insurance 60 60 5 5 term
#> 6 6 6 term_insurance 60 60 5 5 term
#> 7 7 7 term_insurance 60 60 5 5 term
#> 8 8 8 term_insurance 60 60 5 5 term
#> 9 9 9 term_insurance 60 60 5 5 term
#> 10 10 10 term_insurance 60 60 5 5 term
#> # ℹ 15 more rows
#> # ℹ 18 more variables: insurance_type <chr>, benefit <dbl>, i <dbl>,
#> # rate <dbl>, i_type <chr>, rate_type <chr>, m <int>, i_effective <dbl>,
#> # Kx <int>, curtate_lifetime <int>, death_age <dbl>,
#> # died_within_horizon <lgl>, covered <lgl>, benefit_indicator <dbl>,
#> # payment_time <dbl>, benefit_time <dbl>, present_value <dbl>,
#> # pv_benefit <dbl>