Skip to contents

Rendered from docs/guides/ratemaking-werner-modlin.qmd. The code runs each time the site is built, so the output below is current.

Geoff Werner and Claudine Modlin wrote Basic Ratemaking (5th edition, CAS, 2016), the CAS study note on the overall rate level indication for personal and small commercial lines. Chapters 5 to 8 and 12 build it step by step (premium at current rates, loss development and trend, expenses and profit, credibility). Appendices A to C apply it to an auto, a homeowners and a medical malpractice book.

This guide follows those exhibits in prospicio’s R package (its ratemaking functions, with the credibility and reserving functions for two steps), with the book’s numbers beside prospicio’s. The companion guide, ratemaking-werner-modlin-indications.qmd, runs Appendices A to C end to end and reproduces chapter 11’s increased limits and deductible figures.

This is the R twin of the Python guide ratemaking-werner-modlin.md, with the same sections, examples and numbers, because both packages call the same Rust code. The text after each chunk is what it prints (a table prints as its column labels and formatted cells), and R/prospicio/tests/test-guides.R requires an exact match. half_up() and comma() in the first chunk are the book’s rounding and thousands separators.

The book’s text and exhibits are the authors’. This guide recomputes the numbers and explains them in new words. Table names are the book’s. Money is in dollars. The parity suite is validation/tests/pricing.rs (modules ratemaking and indication). To rate a reinsurance layer, see experience-and-exposure-rating.md.

The book rounds each cell half up to its printed precision and uses the rounded value in the next step. prospicio does not round. Where this changes a printed digit, the code shows the exact value and applies the book’s rounding by hand. knowledge/references/werner-modlin-ratemaking.md lists the rounding rules.

1. The process, its data and its dates

An indication compares, for the period when the new rates are in effect, the premium from the current rates with the losses, expenses and profit that this premium must pay. The data (chapters 3 and 4) are exposures, premium (written, earned, in force) and losses including loss adjustment expense (LAE), by calendar, accident or policy year. Three adjustments follow: premium to the current rate level, losses to ultimate, and both trended to the cost level of the future period.

Trend needs the time between two average dates. The book puts each date on a half-month grid, so June 30 and July 1 are the same point and November 15 is ten and a half months into the year. year_fraction() uses the same grid. For a policy term, average_written_date() and average_earned_date() give the average dates of a period. A period is a "calendar" period (premium earned or losses that occur in it) or a "policy" period (policies written in it). half_up is the book’s rounding:

library(prospicio)

# Round half up to dp places, as the book's exhibits do (after clearing binary noise at 10 places).
half_up <- function(x, dp) {
  y <- round(x, 10) * 10^dp
  sign(y) * floor(abs(y) + 0.5 + 1e-9) / 10^dp
}
# Thousands separators, as Python's {:,.0f}.
comma <- function(x, digits = 0) formatC(round(x, digits), format = "f", digits = digits, big.mark = ",")

cat(year_fraction(2013, 6, 30), year_fraction(2013, 7, 1), year_fraction(2011, 11, 15), "\n")
## 2013.5 2013.5 2011.875
library(gt)
trend_lengths <- data.frame(
  length = c("premium, CY2011 to 1/1/2013, annual", "premium, CY2011 to 1/1/2013, 6-month",
             "losses, AY2011 to 1/1/2015, annual", "losses, AY2011 to 1/1/2015, 6-month",
             "losses, PY2011 to 1/1/2015, annual"),
  prospicio = c(
    average_written_date(2013, 2014, 1, "policy") - average_written_date(2011, 2012, 1),
    average_written_date(2013, 2014, 0.5, "policy") - average_written_date(2011, 2012, 0.5),
    average_earned_date(2015, 2016, 1, "policy") - average_earned_date(2011, 2012, 1),
    average_earned_date(2015, 2016, 0.5, "policy") - average_earned_date(2011, 2012, 0.5),
    average_earned_date(2015, 2016, 1, "policy") - average_earned_date(2011, 2012, 1, "policy")
  ),
  book = c(2.5, 2.25, 4.5, 4.25, 4.0)
)
gt(trend_lengths, rowname_col = "length") |>
  tab_header("Trend lengths, Tables 5.26 to 5.28 and 6.15 to 6.18", "Years between average dates") |>
  fmt_number(columns = c(prospicio, book), decimals = 2)
Trend lengths, Tables 5.26 to 5.28 and 6.15 to 6.18
Years between average dates
prospicio book
premium, CY2011 to 1/1/2013, annual 2.50 2.50
premium, CY2011 to 1/1/2013, 6-month 2.25 2.25
losses, AY2011 to 1/1/2015, annual 4.50 4.50
losses, AY2011 to 1/1/2015, 6-month 4.25 4.25
losses, PY2011 to 1/1/2015, annual 4.00 4.00

The book trends premium between average written dates and losses between average accident dates. On average, a calendar year’s premium was written half a term before the year’s midpoint, and a policy year’s losses occur half a term after it. So the book’s rule “effective date plus half the rate period, plus half the term for losses” needs no special case.

2. Premium at the current rate level: the parallelogram method

The parallelogram method (Tables 5.15 to 5.23) restates historical premium at the current rates. It assumes that policies are written evenly over time and draws each rate change as a diagonal in the square of written date against earned date. The share of a year’s earned premium in each region of constant rate level gives the year’s average level. The on-level factor is the current cumulative level divided by that average.

rate_level() takes the effective dates and changes, a period and a policy term, and returns the shares, average level and factor. Chapter 5’s example has +5% on 7/1/2010, +10% on 1/1/2011 and -1% on 4/1/2012:

ch5 <- function(start, end, term, period = "calendar") {
  rate_level(c(2010.5, 2011, 2012.25), c(0.05, 0.10, -0.01),
             start = start, end = end, term = term, period = period)
}
cat(sprintf("current level %.5f  (book 1.1435, Table 5.19)\n", ch5(2011, 2012, 1)$current_level))
## current level 1.14345  (book 1.1435, Table 5.19)
cases <- list(
  list("CY2011, annual policies (Tables 5.17-5.19)", ch5(2011, 2012, 1), 1.0963, 1.0431),
  list("CY2011, 6-month policies (Table 5.20)", ch5(2011, 2012, 0.5), 1.1288, 1.0130),
  list("PY2012, annual policies (Table 5.21)", ch5(2012, 2013, 1, "policy"), 1.1464, 0.9975)
)
ch5_table <- do.call(rbind, lapply(cases, function(cs) {
  lv <- cs[[2]]
  data.frame(case = cs[[1]], shares = paste(round(lv$portions$share, 4), collapse = ", "),
             average = lv$average_level, book_average = cs[[3]],
             on_level = lv$on_level_factor, book_on_level = cs[[4]])
}))
gt(ch5_table, rowname_col = "case") |>
  tab_header("Chapter 5's rate changes: shares, average level and on-level factor") |>
  tab_spanner("average level", columns = c(average, book_average)) |>
  tab_spanner("on-level factor", columns = c(on_level, book_on_level)) |>
  cols_label(average = "prospicio", book_average = "book", on_level = "prospicio", book_on_level = "book") |>
  fmt_number(columns = average, decimals = 5) |>
  fmt_number(columns = c(book_average, on_level, book_on_level), decimals = 4)
Chapter 5's rate changes: shares, average level and on-level factor
shares
average level
on-level factor
prospicio book prospicio book
CY2011, annual policies (Tables 5.17-5.19) 0.125, 0.375, 0.5 1.09625 1.0963 1.0431 1.0431
CY2011, 6-month policies (Table 5.20) 0.25, 0.75 1.12875 1.1288 1.0130 1.0130
PY2012, annual policies (Table 5.21) 0.25, 0.75 1.14634 1.1464 0.9975 0.9975

Two averages (1.09625 and 1.12875) lie exactly on a rounding boundary, so the table shows five places. The book rounds them up. It also rounds the cumulative index to 1.1435 (exact 1.14345) before it divides, so its policy-year average is 1.1464, not 1.14634.

A law change (Tables 5.22 and 5.23) applies to all policies in force on its date, so its line in the square is vertical. Add the book’s -5% benefit change on 7/1/2011 as an in_force change:

lv <- rate_level(c(2010.5, 2011, 2011.5, 2012.25), c(0.05, 0.10, -0.05, -0.01),
                 start = 2011, end = 2012, term = 1,
                 applies = c("written", "written", "in_force", "written"))
cat(sprintf("current level %.4f  factor %.6f  (book 1.0171)\n", lv$current_level, lv$on_level_factor))
## current level 1.0863  factor 1.017084  (book 1.0171)
cells <- data.frame(
  cell = as.character(1:5),
  share = lv$portions$share,
  level = lv$portions$level,
  book_level = c(1.0, 1.05, 0.9975, 1.155, 1.0973)
)
gt(cells, rowname_col = "cell") |>
  tab_header("Table 5.23: the five cells of 2011", "Share of the year's earned premium and its rate level") |>
  fmt_number(columns = share, decimals = 3, drop_trailing_zeros = TRUE) |>
  fmt_number(columns = c(level, book_level), decimals = 4) |>
  tab_spanner("level", columns = c(level, book_level), id = "level_span") |>
  cols_label(level = "prospicio", book_level = "book")
Table 5.23: the five cells of 2011
Share of the year's earned premium and its rate level
share
level
prospicio book
1 0.125 1.0000 1.0000
2 0.25 1.0500 1.0500
3 0.125 0.9975 0.9975
4 0.125 1.1550 1.1550
5 0.375 1.0973 1.0973

Appendix A: six-month auto policies

Appendix A’s Current Rate Level exhibits apply six changes to six-month policies, by calendar year: -5% on 4/1/2011, +10% on 7/1/2012, +5% on 10/1/2013, -2% on 7/1/2014, +5% on 10/1/2015 and +5% on 1/1/2016. The book rounds the cumulative index to four places at each change (it ends at 1.1857, where the exact chain gives 1.18552), rounds the average level to four places, and divides the current level by the average level.

rate_level(level = ...) takes the printed cumulative indices and so gives the book’s chain exactly. rate_level() with the changes gives the exact chain:

eff <- c(2011.25, 2012.5, 2013.75, 2014.5, 2015.75, 2016)
changes <- c(-0.05, 0.10, 0.05, -0.02, 0.05, 0.05)
book_index <- c(0.9500, 1.0450, 1.0973, 1.0754, 1.1292, 1.1857)
book_avg <- c(0.9750, 0.9738, 1.0483, 1.0886, 1.0788)
book_factor <- c(1.2161, 1.2176, 1.1311, 1.0892, 1.0991)

exact_current <- rate_level(eff, changes, start = 2015, end = 2016, term = 0.5)$current_level
cat(sprintf("exact current level %.6f  (book 1.1857)\n", exact_current))
## exact current level 1.185524  (book 1.1857)
years_a <- 2011:2015
average_a <- sapply(years_a, function(y) {
  rate_level(eff, level = book_index, start = y, end = y + 1, term = 0.5)$average_level
})
on_level_a <- data.frame(
  year = as.character(years_a),
  average = average_a,
  book_average = book_avg,
  on_level = half_up(1.1857 / half_up(average_a, 4), 4),  # the book divides by its rounded average
  book_on_level = book_factor,
  exact = sapply(years_a, function(y) {
    rate_level(eff, changes, start = y, end = y + 1, term = 0.5)$on_level_factor
  })
)
gt(on_level_a, rowname_col = "year") |>
  tab_header("Appendix A: on-level factors of six-month policies, by calendar year",
             "Exact is the chain without the book's rounding") |>
  tab_spanner("average level", columns = c(average, book_average)) |>
  tab_spanner("on-level factor", columns = c(on_level, book_on_level, exact)) |>
  cols_label(average = "prospicio", book_average = "book", on_level = "prospicio", book_on_level = "book") |>
  fmt_number(columns = average, decimals = 5) |>
  fmt_number(columns = c(book_average, on_level, book_on_level, exact), decimals = 4)
Appendix A: on-level factors of six-month policies, by calendar year
Exact is the chain without the book's rounding
average level
on-level factor
prospicio book prospicio book exact
2011 0.97500 0.9750 1.2161 1.2161 1.2159
2012 0.97375 0.9738 1.2176 1.2176 1.2175
2013 1.04827 1.0483 1.1311 1.1311 1.1309
2014 1.08856 1.0886 1.0892 1.0892 1.0891
2015 1.07876 1.0788 1.0991 1.0991 1.0991

The 2012 average (0.97375) is a half-up boundary that binary floating point can put just below, so half_up first rounds to ten places. Rounding the index at each change moves the factors by up to 0.0002.

Appendix C: annual medical malpractice policies

Appendix C has annual policies and three changes: -7.6% on 10/1/2011, +14.6% on 3/1/2014 and +13.6% on 7/1/2015. Its cumulative indices 0.9240, 1.0589 and 1.2029 are the exact chain, rounded. Its factors divide rounded figures, so the code rounds the current and average levels to four places first:

book_factor <- c(1.2029, 1.2058, 1.2724, 1.3018, 1.2391, 1.1190)
mm_levels <- lapply(2010:2015, function(year) {
  rate_level(c(2011.75, 2014 + 2 / 12, 2015.5), c(-0.076, 0.146, 0.136),
             start = year, end = year + 1, term = 1)
})
on_level_c <- data.frame(
  year = as.character(2010:2015),
  on_level = sapply(mm_levels, function(lv) half_up(half_up(lv$current_level, 4) / half_up(lv$average_level, 4), 4)),
  book = book_factor,
  exact = sapply(mm_levels, function(lv) lv$on_level_factor),
  shares = sapply(mm_levels, function(lv) paste(sprintf("%.3f%%", 100 * lv$portions$share), collapse = " "))
)
gt(on_level_c, rowname_col = "year") |>
  tab_header("Appendix C: on-level factors of annual policies, by calendar year",
             "Exact is the factor without rounding the levels") |>
  cols_label(on_level = "prospicio") |>
  fmt_number(columns = c(on_level, book, exact), decimals = 4)
Appendix C: on-level factors of annual policies, by calendar year
Exact is the factor without rounding the levels
prospicio book exact shares
2010 1.2029 1.2029 1.2029 100.000%
2011 1.2058 1.2058 1.2058 96.875% 3.125%
2012 1.2724 1.2724 1.2724 28.125% 71.875%
2013 1.3018 1.3018 1.3019 100.000%
2014 1.2391 1.2391 1.2390 65.278% 34.722%
2015 1.1190 1.1190 1.1190 1.389% 86.111% 12.500%

Without rounding the levels, the 2013 and 2014 factors move by 0.0001.

3. Premium trend

Average premium also changes with the mix of business (newer cars, higher amounts of insurance). The book projects average written premium at current rate level with (1 + trend) ** years. trend_factor() is that formula.

Two-step trending (Table 5.29) first moves the historical average to the latest observed average written premium, then projects from there. The book rounds the average earned premium to the cent and each factor to four places:

avg_earned <- half_up(1440788 / 1947, 2)
step1 <- 753.00 / avg_earned
step2 <- trend_factor(-0.01, 1.625)
total <- half_up(half_up(step1, 4) * half_up(step2, 4), 4)
steps <- data.frame(
  step = c("one step, 2% for 2.5 years", "average earned premium", "current step", "projected step",
           "total factor", "projected premium", "total factor, unrounded"),
  prospicio = c(trend_factor(0.02, 2.5), avg_earned, step1, step2, total, 1440788 * total,
                753.00 / (1440788 / 1947) * step2),
  book = c(1.0508, 740.00, 1.0176, 0.9838, 1.0011, 1442373, NA)
)
gt(steps, rowname_col = "step") |>
  tab_header("Premium trend: one step and two steps (Table 5.29)") |>
  fmt_number(columns = c(prospicio, book), rows = c(1, 3, 4, 5), decimals = 4) |>
  fmt_number(columns = c(prospicio, book), rows = 2, decimals = 2) |>
  fmt_number(columns = c(prospicio, book), rows = 6, decimals = 0) |>
  fmt_number(columns = prospicio, rows = 7, decimals = 6) |>
  sub_missing(missing_text = "")
Premium trend: one step and two steps (Table 5.29)
prospicio book
one step, 2% for 2.5 years 1.0508 1.0508
average earned premium 740.00 740.00
current step 1.0176 1.0176
projected step 0.9838 0.9838
total factor 1.0011 1.0011
projected premium 1,442,373 1,442,373
total factor, unrounded 1.001078

Appendix A selects its premium trend from exponential fits (Premium Trend-1) to average written premium at current rate level over the 12 months ending at each quarter. With times in years and quarterly points a quarter apart, trend_fit() gives the annual change directly. The book regresses on a quarter index and annualizes with the fourth power, the same fit:

awp <- c(
  103.05, 103.58, 104.15, 104.72, 105.29, 105.84, 106.39, 106.92, 107.42, 107.96, 108.55, 109.16,
  109.75, 110.32, 110.87, 111.40, 111.95, 112.54, 113.10, 113.69, 114.25, 114.79, 115.35
)
n_points <- c(20, 16, 12, 8, 6, 4)
trend_fits <- data.frame(
  points = paste(n_points, "points"),
  prospicio = sapply(n_points, function(n) 100 * trend_fit((0:(n - 1)) / 4, tail(awp, n))[["annual_change"]]),
  book = c(2.1, 2.1, 2.0, 2.0, 2.0, 1.9)
)
gt(trend_fits, rowname_col = "points") |>
  tab_header("Premium Trend-1: annual change by number of latest points", "Percent a year") |>
  fmt_number(columns = prospicio, decimals = 3, pattern = "{x}%") |>
  fmt_number(columns = book, decimals = 1, pattern = "{x}%")
Premium Trend-1: annual change by number of latest points
Percent a year
prospicio book
20 points 2.062% 2.1%
16 points 2.058% 2.1%
12 points 2.023% 2.0%
8 points 2.018% 2.0%
6 points 1.994% 2.0%
4 points 1.947% 1.9%
library(ggplot2, exclude = "layer")   # keeps prospicio's layer()
awp_points <- data.frame(year = (seq_along(awp) - 1) / 4, premium = awp)
awp_fits <- do.call(rbind, lapply(c(20, 4), function(n) {
  t <- (0:(n - 1)) / 4
  fit <- trend_fit(t, tail(awp, n))
  data.frame(fit = sprintf("latest %d points: %.1f%% a year", n, 100 * fit[["annual_change"]]),
             year = t + (length(awp) - n) / 4,
             premium = exp(fit[["intercept"]] + fit[["slope"]] * t))
}))
ggplot() +
  geom_point(aes(year, premium), data = awp_points, colour = "grey75") +
  geom_line(aes(year, premium, colour = fit), data = awp_fits, linewidth = 0.8) +
  labs(x = "years since the first quarter",
       y = "average written premium, current rates ($)", colour = NULL,
       title = "Premium Trend-1: two exponential fits to 23 quarters") +
  theme(legend.position = "top")
102.5105.0107.5110.0112.5115.0024years since the first quarteraverage written premium, current rates ($)latest 20 points: 2.1% a yearlatest 4 points: 1.9% a yearPremium Trend-1: two exponential fits to 23 quarters

The book selects 2.0%. In Premium Trend-3 it trends each calendar year’s average earned premium at current rate level to the latest 115.35, then at 2.0% a year for two years, from 6/30/2015 (the average written date of the latest 12 months) to 6/30/2017. The exhibit’s footnote prints “06/30/2017 to 06/30/2017”, a typo: the 2.0 years printed next to it and the text agree with 6/30/2015.

ep_crl <- c(1364916.59, 1405728.94, 1448424.45, 1492177.86, 1536267.03)
exposures <- c(12900, 13020, 13130, 13258, 13380)
book <- c(1.1342, 1.1116, 1.0879, 1.0663, 1.0452)
years <- average_written_date(2017, 2018, 0.5, "policy") - average_written_date(2015, 2016, 0.5, "policy")
projected <- half_up(trend_factor(0.02, years), 4)
premium_trend <- half_up(half_up(115.35 / half_up(ep_crl / exposures, 2), 4) * projected, 4)
cat("projected period", years, "years, factor", projected, "\n")
## projected period 2 years, factor 1.0404
gt(data.frame(year = as.character(2011:2015), prospicio = premium_trend, book = book), rowname_col = "year") |>
  tab_header("Premium Trend-3: trend factors to the future period",
             "Average earned premium at current rate level, by calendar year") |>
  fmt_number(columns = c(prospicio, book), decimals = 4)
Premium Trend-3: trend factors to the future period
Average earned premium at current rate level, by calendar year
prospicio book
2011 1.1342 1.1342
2012 1.1116 1.1116
2013 1.0879 1.0879
2014 1.0663 1.0663
2015 1.0452 1.0452

4. Loss development

Chapter 6 develops recent accident years to ultimate by the chain ladder: link ratios, an average and a selected factor for each age, and the product of the selected factors. chain_ladder() runs it. Table 6.11’s triangle is in thousands, by accident year 2002 to 2007 at 15 to 75 months:

long_triangle <- function(first_origin, ages, columns) {
  d <- do.call(rbind, Map(function(a, col) {
    data.frame(origin = first_origin + seq_along(col) - 1, age = a, reported = as.double(col))
  }, ages, columns))
  triangle(d, "origin", "age", "reported")
}
t611 <- long_triangle(2002, c(15, 27, 39, 51, 63, 75), list(
  c(1000, 1030, 1061, 1093, 1126, 1159),
  c(1500, 1584, 1560, 1651, 1662),
  c(1925, 2020, 2070, 2125),
  c(2145, 2209, 2276),
  c(2190, 2240),
  2188
))
m <- as.matrix(t611)  # one row per accident year, NA past the latest diagonal
links <- lapply(1:5, function(j) { r <- m[, j + 1] / m[, j]; r[!is.na(r)] })
rounded <- sapply(links, function(x) mean(half_up(x, 2)))
simple <- chain_ladder(t611, average = "simple")
volume <- chain_ladder(t611)
averages <- data.frame(
  ages = c("15-27", "27-39", "39-51", "51-63", "63-75"),
  exact = simple@ldf,
  rounded = half_up(rounded, 2),
  book = c(1.50, 1.30, 1.10, 1.02, 1.00),
  volume = half_up(volume@ldf, 2),
  book_volume = c(1.50, 1.29, 1.10, 1.02, 1.00)
)
gt(averages, rowname_col = "ages") |>
  tab_header("Table 6.11: averages of the link ratios by age pair", "Months") |>
  tab_spanner("arithmetic average", columns = c(exact, rounded, book)) |>
  tab_spanner("ratio of totals", columns = c(volume, book_volume)) |>
  cols_label(exact = "exact", rounded = "rounded links", book = "book", volume = "prospicio",
             book_volume = "book") |>
  fmt_number(columns = exact, decimals = 4) |>
  fmt_number(columns = c(rounded, book, volume, book_volume), decimals = 2)
Table 6.11: averages of the link ratios by age pair
Months
arithmetic average
ratio of totals
exact rounded links book prospicio book
15-27 1.4989 1.50 1.50 1.50 1.50
27-39 1.2932 1.30 1.30 1.29 1.29
39-51 1.1025 1.10 1.10 1.10 1.10
51-63 1.0175 1.02 1.02 1.02 1.02
63-75 0.9991 1.00 1.00 1.00 1.00
steps <- c("15-27", "27-39", "39-51", "51-63", "63-75")
ratio_points <- do.call(rbind, lapply(1:5, function(j) {
  data.frame(step = factor(steps[j], levels = steps), ratio = links[[j]])
}))
ratio_averages <- data.frame(
  step = factor(rep(steps, 2), levels = steps),
  average = rep(c("arithmetic average", "volume-weighted average"), each = 5),
  ratio = c(simple@ldf, volume@ldf)
)
ggplot() +
  geom_point(aes(step, ratio), data = ratio_points, colour = "grey75") +
  geom_point(aes(step, ratio, colour = average, shape = average), data = ratio_averages,
             size = 2.5, position = position_dodge(width = 0.4)) +
  labs(x = "development age (months)", y = "link ratio (next age / this age)",
       colour = NULL, shape = NULL,
       title = "Table 6.11: link ratios and their averages") +
  theme(legend.position = "top")
1.01.21.415-2727-3939-5151-6363-75development age (months)link ratio (next age / this age)arithmetic averagevolume-weighted averageTable 6.11: link ratios and their averages

The book averages link ratios that it first rounds to two places. At 27 to 39 months this gives 1.295, which rounds up to 1.30, where the exact average is 1.2932. The book’s “ratio of total losses” is the volume-weighted average, the chain ladder’s default.

With the book’s selections (the rounded arithmetic averages) as a selected pattern, chain_ladder() gives the factors to ultimate and the ultimate losses of Table 6.13. The book rounds the factors to two places before it multiplies:

fit <- chain_ladder(t611, ldf = c("15" = 1.50, "27" = 1.30, "39" = 1.10, "51" = 1.02, "63" = 1.00),
                    ldf_kind = "ldf")
book_cdf <- c(1.00, 1.00, 1.02, 1.12, 1.46, 2.19)
book_ult <- c(2188, 2240, 2322, 2380, 2427, 2538)
cdf <- rev(half_up(fit@cdf, 2))  # oldest accident year first
ult <- half_up(fit@latest * cdf, 0)
cat(sprintf("exact chain ladder total %s\n", comma(fit@total_ultimate, 1)))
## exact chain ladder total 14,093.7
gt(data.frame(
  year = c(as.character(2002:2007), "total"),
  cdf = c(cdf, NA), book_cdf = c(book_cdf, NA),
  ult = c(ult, sum(ult)), book_ult = c(book_ult, sum(book_ult))
), rowname_col = "year") |>
  tab_header("Table 6.13: factors to ultimate and ultimate losses", "Thousands, by accident year") |>
  tab_spanner("factor to ultimate", columns = c(cdf, book_cdf)) |>
  tab_spanner("ultimate loss", columns = c(ult, book_ult)) |>
  cols_label(cdf = "prospicio", book_cdf = "book", ult = "prospicio", book_ult = "book") |>
  fmt_number(columns = c(cdf, book_cdf), decimals = 2) |>
  fmt_integer(columns = c(ult, book_ult)) |>
  sub_missing(missing_text = "")
Table 6.13: factors to ultimate and ultimate losses
Thousands, by accident year
factor to ultimate
ultimate loss
prospicio book prospicio book
2002 1.00 1.00 2,188 2,188
2003 1.00 1.00 2,240 2,240
2004 1.02 1.02 2,322 2,322
2005 1.12 1.12 2,380 2,380
2006 1.46 1.46 2,427 2,427
2007 2.19 2.19 2,538 2,538
total

14,095 14,095

Unrounded, the 15-month factor is 2.1879, not 2.19, which gives a total of 14,093.7 thousand.

Appendix A’s Loss Development exhibit applies the same method to reported losses and paid ALAE for accident years 2009 to 2015, with the straight average without the highest and lowest link ratio: chain_ladder(average = "simple", drop_high = 1, drop_low = 1), where n_links counts the link ratios kept. The book averages link ratios rounded to four places and chains its selections rounded to four places, so the code passes that rounded selection as a selected pattern:

ta <- long_triangle(2009, c(15, 27, 39, 51, 63), list(
  c(705088, 712475, 714196, 764101, 774384, 785068, 797866),
  c(725592, 753295, 763913, 861114, 846167, 821509),
  c(738686, 782248, 855150, 884498, 835120),
  c(753027, 800258, 874106, 867184),
  c(732239, 813949, 856495)
))
m <- as.matrix(ta)
links <- lapply(1:4, function(j) { r <- m[, j + 1] / m[, j]; half_up(r[!is.na(r)], 4) })
all_year <- chain_ladder(ta, average = "simple")@ldf
exact <- chain_ladder(ta, average = "simple", drop_high = 1, drop_low = 1)
hi_lo <- sapply(links, function(x) half_up((sum(x) - max(x) - min(x)) / (length(x) - 2), 4))
fit <- chain_ladder(ta, ldf = stats::setNames(hi_lo, c(15, 27, 39, 51)), ldf_kind = "ldf")
gt(data.frame(
  ages = c("15-27", "27-39", "39-51", "51-63"),
  all_exact = all_year,
  all_rounded = sapply(links, function(x) half_up(mean(x), 4)),
  all_book = c(1.0704, 1.0380, 1.0113, 0.9898),
  hl_exact = exact@ldf,
  hl_rounded = hi_lo,
  hl_book = c(1.0665, 1.0279, 1.0208, 0.9799),
  n_links = exact@n_links
), rowname_col = "ages") |>
  tab_header("Appendix A: link ratio averages by age pair", "Months; the average is of link ratios rounded to four places") |>
  tab_spanner("all-year average", columns = c(all_exact, all_rounded, all_book)) |>
  tab_spanner("without highest and lowest", columns = c(hl_exact, hl_rounded, hl_book, n_links)) |>
  cols_label(all_exact = "exact", all_rounded = "rounded links", all_book = "book",
             hl_exact = "exact", hl_rounded = "rounded links", hl_book = "book", n_links = "links kept") |>
  fmt_number(columns = c(all_exact, all_rounded, all_book, hl_exact, hl_rounded, hl_book), decimals = 4) |>
  fmt_integer(columns = n_links)
Appendix A: link ratio averages by age pair
Months; the average is of link ratios rounded to four places
all-year average
without highest and lowest
exact rounded links book exact rounded links book links kept
15-27 1.0703 1.0704 1.0704 1.0665 1.0665 1.0665 4
27-39 1.0380 1.0380 1.0380 1.0279 1.0279 1.0279 3
39-51 1.0113 1.0113 1.0113 1.0208 1.0208 1.0208 2
51-63 0.9898 0.9898 0.9898 0.9799 0.9799 0.9799 1
gt(data.frame(
  age = c("15", "27", "39", "51", "63"),
  exact = exact@cdf, rounded = fit@cdf, book = c(1.0966, 1.0282, 1.0003, 0.9799, 1.0000)
), rowname_col = "age") |>
  tab_header("Appendix A: factors to ultimate", "From each age in months; rounded is the chain of the rounded selection") |>
  fmt_number(columns = c(exact, rounded, book), decimals = 4)
Appendix A: factors to ultimate
From each age in months; rounded is the chain of the rounded selection
exact rounded book
15 1.0965 1.0966 1.0966
27 1.0281 1.0282 1.0282
39 1.0002 1.0003 1.0003
51 0.9799 0.9799 0.9799
63 1.0000 1.0000 1.0000

The rounded chain is the development column of the companion guide’s Appendix A indication. The 15-to-27 average is 1.07035 on the rounded link ratios (printed 1.0704) and 1.0703 on the exact ones. Factors below 1 at 51 months are valid: property damage claims develop downward when the insurer recovers salvage and subrogation.

5. Loss trend

The book fits exponential trends to quarterly frequency, severity and pure premium (Table 6.14, 12 months ending at each quarter) over the latest 20, 16, 12, 8, 6 and 4 points:

freq <- c(0.0587, 0.0587, 0.0593, 0.0587, 0.0582, 0.0578, 0.0565, 0.0555, 0.0552, 0.0553,
          0.0556, 0.0560, 0.0559, 0.0554, 0.0551, 0.0549, 0.0550, 0.0549, 0.0547, 0.0544)
sev <- c(1061.45, 1076.56, 1085.56, 1098.02, 1102.46, 1107.52, 1117.71, 1123.70, 1127.63, 1124.01,
         1116.42, 1109.48, 1105.38, 1102.61, 1096.67, 1093.77, 1100.67, 1108.79, 1122.13, 1126.46)
pp <- c(62.32, 63.16, 64.33, 64.44, 64.17, 64.04, 63.20, 62.41, 62.24, 62.11,
        62.09, 62.19, 61.82, 61.13, 60.48, 60.03, 60.49, 60.86, 61.37, 61.28)
book <- list(
  "frequency" = list(freq, c(-1.7, -1.3, -0.7, -1.2, -0.9, -1.5)),
  "severity" = list(sev, c(0.5, -0.1, -0.2, 1.2, 2.5, 3.3)),
  "pure premium" = list(pp, c(-1.2, -1.4, -0.9, -0.1, 1.6, 1.9))
)
points <- c(20, 16, 12, 8, 6, 4)
trend_row <- function(series, x) setNames(data.frame(series, t(x)), c("series", paste0("p", points)))
trend_table <- do.call(rbind, unlist(lapply(names(book), function(name) {
  values <- book[[name]][[1]]
  got <- sapply(points, function(n) 100 * trend_fit((0:(n - 1)) / 4, tail(values, n))[["annual_change"]])
  list(trend_row(name, got), trend_row(paste0(name, ", book"), book[[name]][[2]]))
}), recursive = FALSE))
line <- trend_fit((0:19) / 4, pp, kind = "linear")
cat(sprintf("linear fit to 20 pure premiums: %+.2f a year (book -0.75)\n", line[["annual_change"]]))
## linear fit to 20 pure premiums: -0.75 a year (book -0.75)
gt(trend_table, rowname_col = "series") |>
  tab_header("Table 6.14: annual loss trend by number of latest points", "Percent a year, exponential fit") |>
  tab_spanner("latest points", columns = starts_with("p")) |>
  cols_label(p20 = "20", p16 = "16", p12 = "12", p8 = "8", p6 = "6", p4 = "4") |>
  fmt_number(columns = starts_with("p"), rows = c(1, 3, 5), decimals = 2) |>
  fmt_number(columns = starts_with("p"), rows = c(2, 4, 6), decimals = 1)
Table 6.14: annual loss trend by number of latest points
Percent a year, exponential fit
latest points
20 16 12 8 6 4
frequency −1.72 −1.28 −0.69 −1.24 −0.87 −1.45
frequency, book −1.7 −1.3 −0.7 −1.2 −0.9 −1.5
severity 0.54 −0.09 −0.21 1.24 2.52 3.31
severity, book 0.5 −0.1 −0.2 1.2 2.5 3.3
pure premium −1.19 −1.39 −0.91 −0.07 1.59 1.91
pure premium, book −1.2 −1.4 −0.9 −0.1 1.6 1.9
panel_names <- c("frequency (claims per exposure)", "severity ($ per claim)",
                 "pure premium ($ per exposure)")
loss_series <- list(freq, sev, pp)
trend_points <- do.call(rbind, lapply(1:3, function(k) {
  data.frame(panel = factor(panel_names[k], levels = panel_names),
             year = (0:19) / 4, value = loss_series[[k]])
}))
trend_lines <- do.call(rbind, lapply(1:3, function(k) {
  do.call(rbind, lapply(c(20, 8), function(n) {
    t <- (0:(n - 1)) / 4
    fit <- trend_fit(t, tail(loss_series[[k]], n))
    data.frame(panel = factor(panel_names[k], levels = panel_names),
               fit = sprintf("latest %d points", n), year = t + (20 - n) / 4,
               value = exp(fit[["intercept"]] + fit[["slope"]] * t))
  }))
}))
ggplot() +
  geom_point(aes(year, value), data = trend_points, colour = "grey75") +
  geom_line(aes(year, value, colour = fit), data = trend_lines, linewidth = 0.8) +
  facet_wrap(~panel, scales = "free_y") +
  labs(x = "years since the first quarter", y = NULL, colour = NULL,
       title = "Table 6.14: quarterly values with two exponential fits") +
  theme(legend.position = "top")
frequency (claims per exposure)severity ($ per claim)pure premium ($ per exposure)012340123401234606162636410601080110011200.0540.0560.058years since the first quarterlatest 20 pointslatest 8 pointsTable 6.14: quarterly values with two exponential fits

The frequencies must be the printed four-place values, because the book fits what it prints. Unrounded counts over exposures move the 8-point frequency fit from -1.24% to -1.30%.

The loss trend runs from the average accident date of each experience period to that of the future policies (section 1, Tables 6.15 to 6.18). Appendix A trends in two steps: -0.5% a year from the midpoint of each accident year to 6/30/2015, then +0.5% for the 2.25 years to 9/30/2017 (six-month policies written in 2017):

years <- average_earned_date(2017, 2018, 0.5, "policy") - average_earned_date(2015, 2016, 0.5)
projected <- half_up(trend_factor(0.005, years), 4)
book <- c(0.9912, 0.9962, 1.0012, 1.0062, 1.0113)
loss_trend <- sapply(2011:2015, function(year) {
  half_up(half_up(trend_factor(-0.005, 2015 - year), 4) * projected, 4)
})
cat("projected period", years, "years, factor", projected, "\n")
## projected period 2.25 years, factor 1.0113
gt(data.frame(year = as.character(2011:2015), prospicio = loss_trend, book = book), rowname_col = "year") |>
  tab_header("Appendix A: loss trend factors to the future period", "By accident year") |>
  fmt_number(columns = c(prospicio, book), decimals = 4)
Appendix A: loss trend factors to the future period
By accident year
prospicio book
2011 0.9912 0.9912
2012 0.9962 0.9962
2013 1.0012 1.0012
2014 1.0062 1.0062
2015 1.0113 1.0113

Appendix C is a long-tailed line with few claims. It fits severity and an adjusted frequency on annual points by accident year (Net Trend-1 and -2) and selects one net trend of 8.9% for losses relative to premium, with each trend length rounded to two places. For accident year 2010 the length to 5/1/2017 (the average accident date of annual policies written from 5/1/2016) is 6.83 years:

severity <- c(91032, 56271, 49372, 100052, 69625, 166764, 169710, 78630, 217319, 299634)
frequency <- c(2.92, 2.22, 4.31, 3.91, 5.87, 3.90, 3.78, 4.35, 4.35, 3.45)
fits <- list(
  list("severity, 2005-2011", severity[1:7], 17.0), list("frequency, 2005-2011", frequency[1:7], 8.2),
  list("severity, 2005-2014", severity, 16.3), list("severity, 2010-2014", severity[6:10], 15.2),
  list("frequency, 2005-2014", frequency, 3.5), list("frequency, 2010-2014", frequency[6:10], -1.0)
)
gt(data.frame(
  fit = sapply(fits, `[[`, 1),
  prospicio = sapply(fits, function(f) 100 * trend_fit(seq_along(f[[2]]) - 1, f[[2]])[["annual_change"]]),
  book = sapply(fits, `[[`, 3)
), rowname_col = "fit") |>
  tab_header("Net Trend-1 and -2: annual trend of severity and frequency", "Percent a year") |>
  fmt_number(columns = prospicio, decimals = 2, pattern = "{x}%") |>
  fmt_number(columns = book, decimals = 1, pattern = "{x}%")
Net Trend-1 and -2: annual trend of severity and frequency
Percent a year
prospicio book
severity, 2005-2011 16.95% 17.0%
frequency, 2005-2011 8.21% 8.2%
severity, 2005-2014 16.34% 16.3%
severity, 2010-2014 15.25% 15.2%
frequency, 2005-2014 3.54% 3.5%
frequency, 2010-2014 −1.04% −1.0%
length_2010 <- average_earned_date(year_fraction(2016, 5, 1), year_fraction(2017, 5, 1), 1, "policy") -
  average_earned_date(2010, 2011, 1)
cat(sprintf("AY2010 trend length %.4f years, factor %.4f unrounded\n", length_2010, trend_factor(0.089, length_2010)))
## AY2010 trend length 6.8333 years, factor 1.7907 unrounded
book_years <- list(c(6.83, 1.7902), c(5.83, 1.6439), c(4.83, 1.5095), c(3.83, 1.3862), c(2.83, 1.2729))
gt(data.frame(
  length = sapply(book_years, function(p) sprintf("%.2f years", p[1])),
  prospicio = sapply(book_years, function(p) trend_factor(0.089, p[1])),
  book = sapply(book_years, function(p) p[2])
), rowname_col = "length") |>
  tab_header("Trend factors at 8.9% a year", "Accident years 2010 to 2014 to 5/1/2017") |>
  fmt_number(columns = c(prospicio, book), decimals = 4)
Trend factors at 8.9% a year
Accident years 2010 to 2014 to 5/1/2017
prospicio book
6.83 years 1.7902 1.7902
5.83 years 1.6439 1.6439
4.83 years 1.5095 1.5095
3.83 years 1.3862 1.3862
2.83 years 1.2729 1.2729

The book’s 1.7902 uses the length rounded to 6.83, not the exact 6.8333 years.

A constant trend is leveraged in an excess layer and damped under a basic limit (Tables 6.20 and 6.21). distributions-for-actuaries-claim-size.md computes it.

6. Expenses, profit and the permissible loss ratio

Chapter 7 divides a policy’s cost into losses and LAE, fixed expenses, variable expenses and the profit provision. Fixed expenses are the same for each policy. Variable expenses and profit are shares of premium. The fundamental insurance equation gives the rate per exposure: the pure premium plus the fixed expense, divided by one minus the variable expense and profit ratios. indicated_rate() applies the equation with the variable expense V and profit Q:

cat(sprintf("chapter 7: %.2f  (book 250.00)\n", indicated_rate(180, 0.15, 0.05, fixed_per_exposure = 20)))
## chapter 7: 250.00  (book 250.00)
e <- premium_based_expenses(0.059, 0.75)
cat(sprintf("Table 7.4: 5.9%% general expense, 75%% fixed: fixed %.3f%% (book 4.4%%), variable %.3f%% (book 1.5%%)\n",
            100 * e[["fixed"]], 100 * e[["variable"]]))
## Table 7.4: 5.9% general expense, 75% fixed: fixed 4.425% (book 4.4%), variable 1.475% (book 1.5%)
loss <- c(135, 180, 225)
rate <- sapply(loss, function(l) indicated_rate(l, 0.15, 0.05, fixed_per_exposure = 20))
flat <- sapply(loss, function(l) indicated_rate(l, 0.15 + 0.08, 0.05))  # the $20 fixed treated as 8% of the average premium
gt(data.frame(
  loss = as.character(loss), rate = rate, book_rate = c(193.75, 250.00, 306.25),
  flat = flat, book_flat = c(187.50, 250.00, 312.50), change = half_up(flat / rate - 1, 6)
), rowname_col = "loss") |>
  tab_header("Table 7.3: the rate per exposure by expected loss", "Fixed $20 as such, or as 8% of the average premium") |>
  tab_spanner("fixed expense as such", columns = c(rate, book_rate)) |>
  tab_spanner("all variable", columns = c(flat, book_flat)) |>
  cols_label(rate = "prospicio", book_rate = "book", flat = "prospicio", book_flat = "book", change = "all variable vs as such") |>
  fmt_number(columns = c(rate, book_rate, flat, book_flat), decimals = 2) |>
  fmt_percent(columns = change, decimals = 1, force_sign = TRUE)
Table 7.3: the rate per exposure by expected loss
Fixed $20 as such, or as 8% of the average premium
fixed expense as such
all variable
all variable vs as such
prospicio book prospicio book
135 193.75 193.75 187.50 187.50 −3.2%
180 250.00 250.00 250.00 250.00 0.0%
225 306.25 306.25 312.50 312.50 +2.0%

Table 7.3 shows the problem of the all variable expense method: if it treats a fixed $20 as 8% of premium, it undercharges small risks and overcharges large risks. The premium-based projection method (Table 7.4) divides each historical expense ratio into a fixed part and a variable part by a fixed share. premium_based_expenses() does this for several categories at once.

Table 7.5, the exposure-based projection, divides fixed dollars by exposures and trends them, with trend_factor(). Its printed 1.4% uses 2015 earned premium of 545,250,000, but Table 7.4 shows 530,000,000.

Chapter 8 gives two methods. The pure premium method gives the indicated rate per exposure from the projected pure premium and fixed expense per exposure. The loss ratio method gives the change to the current rates: the projected loss and LAE ratio plus the fixed expense ratio, divided by the variable permissible loss ratio 1 - V - Q, minus 1. On consistent data they agree:

cat(sprintf("pure premium method: %.2f  (book 500.00)\n", indicated_rate(300, 0.25, 0.10, fixed_per_exposure = 25)))
## pure premium method: 500.00  (book 500.00)
cat(sprintf("loss ratio method:   %+.1f%%  (book +10%%)\n", 100 * indicated_change(0.65, 0.25, 0.10, fixed_ratio = 0.065)))
## loss ratio method:   +10.0%  (book +10%)
cat(sprintf("permissible loss ratios: variable %.2f, with 6.5%% fixed %.3f\n",
            permissible_loss_ratio(0.25, 0.10), permissible_loss_ratio(0.25, 0.10, fixed_ratio = 0.065)))
## permissible loss ratios: variable 0.65, with 6.5% fixed 0.585
exposure <- 1000; current_rate <- 480; losses <- 310000; fixed_dollars <- 26000
premium <- exposure * current_rate
by_lr <- current_rate * (1 + indicated_change(losses / premium, 0.22, 0.04, fixed_ratio = fixed_dollars / premium))
by_pp <- indicated_rate(losses / exposure, 0.22, 0.04, fixed_per_exposure = fixed_dollars / exposure)
cat(sprintf("same book both ways: %.4f and %.4f\n", by_lr, by_pp))
## same book both ways: 454.0541 and 454.0541

The last line uses made-up figures to show chapter 8’s identity: the loss ratio method’s factor times the current rate is the pure premium method’s rate, when premium at current rates is the exposure times the current average rate.

7. Credibility

Chapter 12 weights the indication with a complement when the experience is too thin to use alone. The classical (limited fluctuation) method assumes a Poisson count. The standard is the number of claims at which the observed frequency is within k of its mean with probability p: (z / k) ** 2, with z the normal quantile at (1 + p) / 2. Below the standard, credibility follows the square root rule. Table 12.1:

book <- list(c(0.05, 0.90, 1.645, 1082), c(0.10, 0.90, 1.645, 271), c(0.05, 0.95, 1.960, 1537),
             c(0.10, 0.95, 1.960, 384), c(0.05, 0.99, 2.575, 2652), c(0.10, 0.99, 2.575, 663))
gt(data.frame(
  k = sapply(book, function(b) b[1]),
  p = sapply(book, function(b) b[2]),
  standard = sapply(book, function(b) credibility_standard(b[2], b[1])[["frequency"]]),
  book = sapply(book, function(b) b[4]),
  book_z = sapply(book, function(b) (b[3] / b[1])^2)
)) |>
  tab_header("Table 12.1: full-credibility standards for claim frequency", "Claims") |>
  tab_spanner("full-credibility standard", columns = c(standard, book, book_z)) |>
  cols_label(standard = "prospicio", book = "book", book_z = "prospicio with the book's z") |>
  fmt_percent(columns = c(k, p), decimals = 0) |>
  fmt_number(columns = c(standard, book_z), decimals = 2) |>
  fmt_integer(columns = book)
Table 12.1: full-credibility standards for claim frequency
Claims
k p
full-credibility standard
prospicio book prospicio with the book's z
5% 90% 1,082.22 1,082 1,082.41
10% 90% 270.55 271 270.60
5% 95% 1,536.58 1,537 1,536.64
10% 95% 384.15 384 384.16
5% 99% 2,653.96 2,652 2,652.25
10% 99% 663.49 663 663.06
z <- limited_fluctuation_credibility(100, round(credibility_standard(0.90, 0.05)[["frequency"]]))
cat(sprintf("100 claims: Z %.4f (book 0.30); %.0f (book 270)\n", z, credibility_weighted(200, round(z, 2), 300)))
## 100 claims: Z 0.3040 (book 0.30); 270 (book 270)

Five rows round to the printed standards. The 99% rows use the book’s three-figure z of 2.575. The exact quantile, 2.5758, gives 2,654 claims for k = 5% and still 663 for k = 10%. The book’s exposure standards are these counts divided by a 5% frequency. credibility_standard() also returns the severity and pure premium standards, which the appendices do not use.

The book’s second method is Bühlmann (least squares) credibility, Z = N / (N + K). K is the expected process variance (EVPV) divided by the variance of the hypothetical means (VHM). The book gives both and does not estimate them: with 21 observations, EVPV 2.00, VHM 0.50 and a prior mean of $225, an observed $200 becomes $204. credibility_premiums() calculates the Bühlmann-Straub premium at given variances. A tight prior on the collective mean sets it at the book’s $225. The function needs at least two groups, so the code adds a second, arbitrary group:

cp <- credibility_premiums(rbind(rep(200, 21), rep(250, 21)), matrix(1, 2, 21),
                           within_variance = 2.00, between_variances = 0.50,
                           collective_mean = c(225, 1e-6))
cat(sprintf("K %.2f  Z %.2f (book 0.84)  estimate %.2f (book 204)\n",
            2.00 / 0.50, cp$credibility[1], cp$premiums[1]))
## K 4.00  Z 0.84 (book 0.84)  estimate 204.00 (book 204)

buhlmann_straub() estimates both variances from a panel of groups, as R’s actuar::cm does, with exposures as weights. The example uses made-up pure premiums for three territories over four years. A territory’s credibility is its exposure divided by exposure plus K:

pure_premiums <- rbind(c(310, 240, 365, 290), c(262, 330, 228, 301), c(402, 296, 348, 441))
exposures <- rbind(c(120, 125, 130, 134), c(80, 76, 82, 79), c(30, 32, 28, 31))
bs <- buhlmann_straub(pure_premiums, exposures)
cat(sprintf("EVPV %s  VHM %s  K %s\n", comma(bs$within_variance), comma(bs$between_variance, 1), comma(bs$k, 1)))
## EVPV 207,908  VHM 600.7  K 346.1
cat(sprintf("collective mean %.2f\n", bs$collective_mean))
## collective mean 307.15
gt(data.frame(
  territory = LETTERS[1:3],
  exposure = bs$group_weights,
  z = bs$credibility,
  z_check = bs$group_weights / (bs$group_weights + bs$k),
  mean = bs$group_means,
  premium = bs$premiums
), rowname_col = "territory") |>
  tab_header("Bühlmann-Straub credibility by territory") |>
  cols_label(z = "Z", z_check = "exposure / (exposure + K)") |>
  fmt_integer(columns = exposure) |>
  fmt_number(columns = c(z, z_check), decimals = 4) |>
  fmt_number(columns = c(mean, premium), decimals = 2)
Bühlmann-Straub credibility by territory
exposure Z exposure / (exposure + K) mean premium
A 509 0.5952 0.5952 301.59 303.84
B 317 0.4780 0.4780 279.23 293.80
C 121 0.2590 0.2590 371.46 323.81

Classical credibility needs only a claim count and a full standard, and it reaches 1. Bühlmann credibility needs the two variances, never reaches 1, and gives Z = 0 for identical risks (VHM of 0). prospicio also has Bayesian hierarchical credibility (hierarchical_credibility()).

The complement matters as much as Z. For an overall indication the book prefers trended present rates: the change indicated last time but not taken, trended forward. Chapter 12’s example has a prior indication of +10%, +6% taken and a 5% loss trend over two years:

c_tpr <- trended_present_rates(0.10, 0.06, trend_factor(0.05, 2.0))
cat(sprintf("complement %+.2f%%, on a $200 rate: %.0f  (book 229)\n", 100 * c_tpr, 200 * (1 + c_tpr)))
## complement +14.41%, on a $200 rate: 229  (book 229)

Next

The companion guide ratemaking-werner-modlin-indications.qmd combines these factors into the book’s three overall indications (Appendices A to C) and ends with a table of each place where the book’s rounding moves a printed digit.