Skip to contents

Rendered from docs/guides/capital-modeling-monograph-15-practice.qmd. The code runs each time the site is built, so the output below is current.

CAS Monograph 15 is Introduction to Capital Modeling and Portfolio Management (John Major and Stephen Mildenhall, 2026). Its chapters 1, 2 and 7 describe the system around the mathematics: the structure of a capital model, the output of its business operations module, and how to judge a model or a platform.

This guide covers the numeric parts (the InsCo simulation table, balance sheets, pro forma statements) and maps the monograph’s structure and checklists onto prospicio. Table numbers are the monograph’s.

This is the R twin of the Python guide capital-modeling-monograph-15-practice.md, with the same sections and numbers. The text block after each R chunk is the output of that chunk, and R/prospicio/tests/test-guides.R checks it. Companion guides: chapters 3 and 4, chapters 5 and 6, chapter 8 and chapter 9.

1. The parts of a capital model

The monograph’s system (sections 1.4.4 and 1.5) has three modules:

  1. Business Operations simulates the firm’s results.
  2. Capital Adequacy turns the results into the assets needed for a risk tolerance.
  3. Pricing and Allocation splits those assets into premium and capital, and allocates the margin to units.

Business Operations holds the units, an optional economic scenario generator (ESG) for assets and inflation, reinsurance (gross to net) and accounting (pro formas). In prospicio’s R package:

Monograph prospicio
Units: losses by unit, frequency and severity severity families, counts, compound_distribution(), event sets, reserving models (mack_bootstrap(), odp_bootstrap(), bayes_odp())
Correlation between units iman_conover(), reorder_groups() (block Iman-Conover), copulas with copula_simulate() (chapter 8 guide)
A sample of joint outcomes (the “probabilistic database”) predictive_distribution(): one row per simulated year, one column per unit
Reinsurance, gross to net towers and treaties, or a ceded unit with negative losses (section 4)
Economic scenario generator the scenarios as columns of a predictive_distribution()
Accounting and pro formas the P&L ledger for premium, loss and expense legs, and balance sheets in code (section 5)
Capital Adequacy quantile(), TVaR(), portfolio_assets(), epd_ratio(), priority_ladder()
Pricing and Allocation distortions, calibrate_portfolio(), natural_price() (the natural allocation), bodoff_allocation()

Structural parameters (volatility, correlation) change rarely, business parameters (premium, loss ratio) in every planning run. Build the unit shapes once and pass volumes and target return as arguments.

2. InsCo: the simulation table and the funding equation

InsCo (sections 1.6 and 2.2) writes three units for one period, with ten equally likely outcomes. Table 2.1 sorts them by total and adds each unit’s expected loss (EX), CV and plan premium:

library(prospicio)
library(gt)

ROWS <- rbind(
  c(15, 7, 0), c(15, 13, 0), c(5, 20, 11), c(7, 33, 0), c(13, 20, 7),
  c(5, 27, 8), c(15, 16, 9), c(26, 19, 10), c(17, 8, 40), c(16, 20, 64)
)
colnames(ROWS) <- c("A", "B", "C")
PLAN <- c(13.9, 18.7, 19.6)
insco <- capital_portfolio(ROWS)
totals <- rowSums(ROWS)
columns <- c(lapply(1:3, function(j) ROWS[, j]), list(totals))
probs <- rep(0.1, 10)

dists <- lapply(columns, function(col) discrete_distribution(col, probs))
stats <- rbind(
  EX = sapply(dists, mean),
  CV = sapply(dists, function(d) std_dev(d) / mean(d)),
  skewness = sapply(dists, discrete_skewness),
  plan = c(PLAN, sum(PLAN))
)
colnames(stats) <- c("A", "B", "C", "Total")
sim <- data.frame(row = c(as.character(1:10), rownames(stats)),
                  rbind(cbind(ROWS, Total = totals), stats), row.names = NULL)
gt(sim, rowname_col = "row") |>
  tab_header("InsCo, Table 2.1: ten equally likely outcomes", "Loss by unit and plan premium, money units") |>
  fmt_number(columns = c(A, B, C, Total), rows = c(1:10, 11, 14), decimals = 1) |>
  fmt_number(columns = c(A, B, C, Total), rows = c(12, 13), decimals = 3)
InsCo, Table 2.1: ten equally likely outcomes
Loss by unit and plan premium, money units
A B C Total
1 15.0 7.0 0.0 22.0
2 15.0 13.0 0.0 28.0
3 5.0 20.0 11.0 36.0
4 7.0 33.0 0.0 40.0
5 13.0 20.0 7.0 40.0
6 5.0 27.0 8.0 40.0
7 15.0 16.0 9.0 40.0
8 26.0 19.0 10.0 55.0
9 17.0 8.0 40.0 65.0
10 16.0 20.0 64.0 100.0
EX 13.4 18.3 14.9 46.6
CV 0.453 0.412 1.324 0.455
skewness 0.281 0.269 1.603 1.420
plan 13.9 18.7 19.6 52.2

The means and CVs are the values of Table 2.1, which does not print the skewness (it shows how much of unit C’s risk is in one or two years). The monograph divides by 10, not 9, in the standard deviation, and discrete_distribution() does the same.

The funding equation of section 1.6 is assets = premium plus capital, a = P + Q. InsCo has assets of 100 and a plan premium of 52.2, so the capital is 47.8. The expected margin is the premium minus the expected loss:

assets <- 100
plan <- sum(PLAN)
loss <- insco@expected
capital <- assets - plan
margin <- plan - sum(loss)
cat(sprintf("premium %.1f  capital %.1f  expected loss %.1f  margin %.1f\n", plan, capital,
            sum(loss), margin))
## premium 52.2  capital 47.8  expected loss 46.6  margin 5.6
cat(sprintf("loss ratio %.1f%%  premium to capital %.2f  expected return %.1f%%\n",
            100 * sum(loss) / plan, plan / capital, 100 * margin / capital))
## loss ratio 89.3%  premium to capital 1.09  expected return 11.7%

The margin of 5.6 is the value in section 2.2. A 15% return needs a premium of 53.565 (see the chapter 9 guide), so at plan the investors expect 11.7%.

3. Margins, leverage and returns by unit

Section 1.4.2 (Table 1.1) compares attritional business (high loss ratio, high leverage, capital that loses money about half the time) with catastrophe business (low loss ratio, low leverage, capital that rarely loses money). InsCo’s unit A is steady, and unit C is like catastrophe business. The code uses the Wang distortion of chapter 4 and the capital allocation of section 8.3:

wang <- calibrate_portfolio(insco, "wang", assets = 100, return_on_capital = 0.15)
priced <- natural_price(insco, wang, assets = 100, allocation = "lifted")
priced <- priced[priced$unit != "total", ]
tab <- data.frame(
  unit = priced$unit[1:3],
  premium = priced$premium[1:3],
  loss_ratio = priced$loss_ratio[1:3],
  pq = priced$premium_to_capital[1:3],
  ret = priced$return_on_capital[1:3],
  p_loss = sapply(1:3, function(i) mean(columns[[i]] > priced$premium[i]))
)
gt(tab, rowname_col = "unit") |>
  tab_header("InsCo under the Wang distortion at a 15% return", "Lifted capital allocation") |>
  fmt_number(columns = premium, decimals = 3) |>
  fmt_percent(columns = c(loss_ratio, ret), decimals = 1) |>
  fmt_number(columns = pq, decimals = 2) |>
  fmt_number(columns = p_loss, decimals = 1) |>
  cols_label(loss_ratio = "loss ratio", pq = "P:Q", ret = "return", p_loss = "P(loss > premium)")
InsCo under the Wang distortion at a 15% return
Lifted capital allocation
premium loss ratio P:Q return P(loss > premium)
A 14.109 95.0% 1.68 8.4% 0.6
B 18.637 98.2% 2.14 3.9% 0.6
C 20.819 71.6% 0.71 20.2% 0.2

The loss ratio and leverage columns follow Table 1.1. A’s loss exceeds its premium in six years of ten, and C’s in two.

library(ggplot2, exclude = "layer")   # keeps prospicio's layer()
by_unit <- data.frame(
  unit = rep(priced$unit, 2),
  measure = rep(c("Leverage: premium to capital (ratio)", "Return on capital (%)"), each = 3),
  value = c(priced$premium_to_capital, 100 * priced$return_on_capital)
)
ggplot(by_unit, aes(unit, value)) +
  geom_col() +
  facet_wrap(~measure, scales = "free_y") +
  labs(x = "unit", y = NULL, title = "InsCo under the Wang distortion at a 15% return")
Leverage: premium to capital (ratio)Return on capital (%)ABCABC051015200.00.51.01.52.0unitInsCo under the Wang distortion at a 15% return

The return column does not follow Table 1.1: the volatile unit C earns the most. Ten years are too few to separate the units’ layers, and part of C’s margin comes from the bottom layer of the assets, which holds no capital (section 9 of the chapter 8 guide).

Section 1.4.3 lists the types of premium (filed, required, plan, indicated, priced, quoted, sold, market) and of margin. Only the actual margin, the margin after the fact, is not an expected value. For InsCo it is a distribution at the plan premium:

actual <- discrete_distribution(plan - totals, probs)
cat(sprintf("actual margin: mean %.1f, worst %.1f, P(margin < 0) %.1f\n", mean(actual),
            min(plan - totals), cdf(actual, -1e-9)))
## actual margin: mean 5.6, worst -47.8, P(margin < 0) 0.3

The expected margin of 5.6 hides a loss in three years of ten.

4. Reinsurance as a negative unit

Section 2.3 gives two ways to model ceded reinsurance: as a unit of its own with negative losses, beside the gross units, or downstream of the units, applied to their results. Both give the same net result. The example is InsCo’s 35 xs 65 aggregate stop loss (section 2.3, priced in chapter 5):

stop_loss <- function(total, attach = 65, limit = 35) pmin(pmax(total - attach, 0), limit)

with_ceded <- predictive_distribution(
  cbind(ROWS, Ceded = -stop_loss(totals)),
  data.frame(unit = c("A", "B", "C", "Ceded"))
)
net <- sampled(totals - stop_loss(totals))
cat(sprintf("negative unit: mean %.1f  VaR 90%% %.0f  largest %.0f\n", mean(with_ceded),
            VaR(with_ceded, 0.9), quantile(with_ceded, 1)))
## negative unit: mean 43.1  VaR 90% 65  largest 65
cat(sprintf("downstream:    mean %.1f  VaR 90%% %.0f  largest %.0f\n", mean(net), VaR(net, 0.9),
            quantile(net, 1)))
## downstream:    mean 43.1  VaR 90% 65  largest 65

The monograph recommends the downstream form when one cover protects several units, as a corporate catastrophe cover does. capital_portfolio() needs non-negative units, so for pricing the cover becomes a unit of recoveries beside the net book, as in the applications guide.

5. Capital structure and pro forma statements

Sections 2.5 to 2.7 give InsCo a capital structure and turn each outcome into financial statements. The assets are 100 in cash (Table 2.2), funded by the unearned premium of 52.2, a bond of 20 with a 3% coupon, and equity of 27.8. There are no expenses or investment income. InsCo pays the losses first, then the bond and its coupon. Equity takes the remainder:

CASH <- 100
UPR <- sum(PLAN)
BOND <- 20
COUPON <- 0.03
EQUITY <- CASH - UPR - BOND
cat(sprintf("opening balance sheet: cash %.1f = premium reserve %.1f + bond %.1f + equity %.1f\n",
            CASH, UPR, BOND, EQUITY))
## opening balance sheet: cash 100.0 = premium reserve 52.2 + bond 20.0 + equity 27.8
after_claims <- pmax(CASH - totals, 0)
bond_paid <- pmin(after_claims, BOND * (1 + COUPON))
equity_end <- after_claims - bond_paid
income <- UPR - totals - BOND * COUPON
pro <- data.frame(event = as.character(1:10), loss = totals, coupon = BOND * COUPON, income = income,
                  equity = equity_end, bond = bond_paid)
gt(pro, rowname_col = "event") |>
  tab_header("InsCo's ten outcomes: statements for each claimant", "Money units") |>
  fmt_number(columns = c(loss, coupon, income, equity, bond), decimals = 1) |>
  cols_label(income = "net income", equity = "end equity", bond = "bond paid")
InsCo's ten outcomes: statements for each claimant
Money units
loss coupon net income end equity bond paid
1 22.0 0.6 29.6 57.4 20.6
2 28.0 0.6 23.6 51.4 20.6
3 36.0 0.6 15.6 43.4 20.6
4 40.0 0.6 11.6 39.4 20.6
5 40.0 0.6 11.6 39.4 20.6
6 40.0 0.6 11.6 39.4 20.6
7 40.0 0.6 11.6 39.4 20.6
8 55.0 0.6 −3.4 24.4 20.6
9 65.0 0.6 −13.4 14.4 20.6
10 100.0 0.6 −48.4 0.0 0.0

Outcome 4 matches Tables 2.3 and 2.4. In outcome 10, the loss of 100 takes all the assets. The policyholders are paid in full, the shareholders’ 27.8 cannot absorb the loss of 48.4, and the bondholders lose their 20.6.

claimants <- data.frame(
  event = rep(1:10, 2),
  claimant = rep(c("equity, ending value", "bond, amount paid"), each = 10),
  value = c(equity_end, bond_paid)
)
ggplot(claimants, aes(event, value, colour = claimant)) +
  geom_line() +
  geom_point() +
  scale_x_continuous(breaks = 1:10) +
  labs(x = "outcome, sorted by total loss", y = "money units", colour = NULL,
       title = "What each claimant receives in the ten outcomes") +
  theme(legend.position = "top")
020406012345678910outcome, sorted by total lossmoney unitsbond, amount paidequity, ending valueWhat each claimant receives in the ten outcomes

Over the ten outcomes, each claimant’s result is a distribution:

bond <- discrete_distribution(bond_paid, probs)
equity <- discrete_distribution(equity_end, probs)
cat(sprintf("bond:   expected payment %.2f of %.1f promised, P(default) %.1f\n", mean(bond),
            BOND * (1 + COUPON), cdf(bond, BOND * (1 + COUPON) - 1e-9)))
## bond:   expected payment 18.54 of 20.6 promised, P(default) 0.1
cat(sprintf("equity: expected ending value %.2f on %.1f invested, P(wiped out) %.1f, expected return %.1f%%\n",
            mean(equity), EQUITY, cdf(equity, 1e-9), 100 * (mean(equity) / EQUITY - 1)))
## equity: expected ending value 34.86 on 27.8 invested, P(wiped out) 0.1, expected return 25.4%

The bond promises 3%, but it has a one-in-ten chance of losing everything. Its expected payment is 18.54 on 20, a return of -7.3%, so the bondholders are underpaid for their risk. The shareholders are last in line and expect 25.4%.

The monograph’s main text uses total capital Q = 47.8 and leaves the split between debt and equity to reporting. The chapter 3 and 4 guide shows how the same layers of claimants define the critical loss levels.

6. Evaluating a model

Chapter 7 asks three questions about your own model: does it do what the charter specified, does it calculate correctly, and is it realistic? The third is validation, in four steps: best estimates that agree with plan, variability that matches experience, back testing, and repetition.

Back testing uses the probability integral transform (PIT). For each past year, the PIT is the model’s probability of a result no worse than the actual result. Over many years, a good model gives uniform PIT values. Values at the ends show bias or too little spread. Values in the middle show too much spread.

The example uses InsCo as the model and six past totals (hypothetical, for illustration). The chunk calculates the PIT as the share of draws below the value plus half the share equal to it (#382).

history <- c(38, 61, 45, 52, 70, 33)
pits <- sapply(history, function(y) mean(totals < y) + 0.5 * mean(totals == y))
pit <- data.frame(year = as.character(1:6), total = history, pit = pits)
gt(pit, rowname_col = "year") |>
  tab_header("Back test: the PIT of six past totals", "InsCo as the model; totals are hypothetical") |>
  fmt_number(columns = total, decimals = 1) |>
  fmt_number(columns = pit, decimals = 2) |>
  cols_label(total = "past total", pit = "PIT")
Back test: the PIT of six past totals
InsCo as the model; totals are hypothetical
past total PIT
1 38.0 0.30
2 61.0 0.80
3 45.0 0.70
4 52.0 0.70
5 70.0 0.90
6 33.0 0.20
cat("in quintiles", tabulate(pmin(floor(pits * 5), 4) + 1, 5), "\n")
## in quintiles 0 2 0 2 2

With six values, only a gross failure shows, as the monograph warns. Keep the record and repeat the check every year. For fitted models, use ppc_check() and loo_pit(). The Rust crate also has a diagonal backtest of the reserving models against each origin’s next diagonal.

The checklist of section 7.3 for a modeling platform, answered for prospicio:

Item prospicio
Accounting bases the P&L ledger for signed premium, loss and expense legs, and the balance sheet in code (section 5)
Loss payout patterns payment patterns, discounting and the price over the payout, and reserving models for run-off
Assets an ESG’s output, joined as columns
Dependency Iman-Conover (and by blocks), Gaussian, t, Archimedean, nested Archimedean and vine copulas, common shocks through event sets
Required capital VaR, TVaR, EPD and assets at a standard (portfolio_assets())
Required margins and their allocation distortions, calibration, the natural allocation, the range of unit premiums, Bodoff
Parameter uncertainty Bayesian models and predictive distributions, blending of models
Input and output Python, R and an Excel add-in, with distributions and towers saved as JSON
Scripting and automation every step is a library call, so runs over many assumptions are loops
Version control plain code and JSON, so any version control works
Track record results checked against published references, as in these guides