Actuarial studies · 2025
Medical Cost Modelling
Day hospital versus private hospital, resolved to a margin.
The application answers one practical question: given a specialty mix and a set of scheduling assumptions, how do day-hospital and private-hospital economics actually compare? Reference cost data provides the market anchor; the operator supplies billing, volume, work mix and cost base; the model resolves the two into per-procedure margin.
- Status
- Shipped
- Domain
- Health economics · Scenario modelling
- Role
- Model design, application
- Year
- 2025
Stack
- Python
- SQLite
- Excel interchange
- JavaScript
- Scenario engine
A scenario modelling application for specialist economics — combining a national procedure-cost reference set with operator assumptions to compute revenue, cost and margin per procedure, per modality, and in aggregate.
Reference data and entered assumptions, kept separate
Procedure reference data and operator-entered assumptions live in different stores and are never merged in place.
Comparisons can therefore be run against either the reference baseline or a second entered scenario, and it is always unambiguous which numbers came from the market and which came from the operator.
Up to four modalities at once
A real specialist practice is a mix, not a single procedure, so the model carries several specialty contexts simultaneously and aggregates across them.
Every state is persisted, and versioned snapshots export to spreadsheet form — because the finance conversation that follows the model always happens in a spreadsheet.
The answer is a distribution of decisions, not a number
The useful output is not "day hospital is better".
It is the set of conditions under which each setting wins — the volume threshold, the work mix, the cost base at which the ordering flips. The interface is built to make that boundary visible rather than to produce a single headline figure, because the headline figure changes with assumptions the operator controls and the boundary does not.
Exports are the deliverable
The model is not the last step in anyone’s process.
Whatever it computes will be pulled into a board pack, a lender’s template or an accountant’s workbook, so versioned spreadsheet export is treated as a primary output rather than a convenience — with the provenance of every figure carried across, so a number can still say where it came from after it has left the application.
Pipeline
Two sources, one margin
Stage Can reject
-
01
Reference data
Market anchor
-
02
Operator inputs
Billing · volume · mix
-
03
Cost base
Fixed + variable
-
04
Scenario engine
Per-procedure margin
-
05
Compare
Crossover point
Where the ordering flips
-
06
Export
Versioned workbook
The mathematics
What the model
actually computes.
Equations and every symbol defined. Fitted parameters — shares, tapers, elasticities, reconciliation bands — stay in the configuration they belong to.
Two ways to reach procedures per month
Operators think in either caseload or session time, and forcing one onto the other loses information. The model accepts both and reconciles them to the same monthly figure.
- q
- Procedures per month
- v, k
- Volume per period and its period multiplier
- H
- Hours per week available
- ψ
- Share of the week allocated to the procedure
- t
- Hours per procedure
- φ
- Work share for the modality
The hours path is the one that surprises operators: because throughput divides by time per procedure, a shorter procedure absorbs the same allocated hours at higher volume, and margin per session moves in the opposite direction to margin per case.
Margin, and where the ordering flips
Each setting is resolved to a monthly margin under the same volume assumptions, so the comparison isolates the cost and billing structure rather than the caseload.
- Π
- Monthly margin for a setting
- b
- Billing per procedure
- c
- Cost per procedure
- cj
- Cost category j
- Δ
- Advantage of one setting over the other
The useful output is not the sign of Δ but the volume and work-mix at which it changes sign. A headline that says one setting wins is only true for the assumptions it was computed under; the crossover is stable enough to plan against.
Skills exercised
What the build
actually demanded.
Against the corpus · 15 systems
This system Corpus median
Actuarial
- Revenue, cost and margin decomposition per procedure
- Scenario comparison against a market reference
- Cost-base modelling across fixed and variable components
- Sensitivity of margin to volume and work mix
Application
- Persisted multi-scenario state in a local database
- Versioned spreadsheet export for downstream finance
- Reference-versus-entered data separation
- Interactive comparison interface without a build step
What it establishes
-
Two-scenario comparison
Against reference data or a second entered case
-
Four concurrent modalities
Aggregated to a practice-level view
-
Versioned exports
Snapshots leave as spreadsheets, with provenance
-
Boundaries, not headlines
Where the ordering flips, not which one wins