reserving.FutureCells
Projected future increments of one segment, one per origin and age, for
Usage
reserving.FutureCells()re-inflation.
Parameters
origins: list of str or int-
The origin periods, such as
["2020", "2021"]. origin: list of str or int-
Each cell’s origin, one of origins.
age: list of int-
Each cell’s development age in months: 0 or more.
valuation: list of str or date-
The month each cell’s development period ends in (
"YYYY-MM"or a date): its index period is the cell’s payment period. value: list of float- Each cell’s increment, at the base price level.
Examples
>>> from prospicio.reserving import FutureCells
>>> cells = FutureCells(["2020"], ["2020", "2020"], [24, 36],
... ["2021-12", "2022-12"], [50.0, 25.0])
>>> cells.reserves()[75.0]
>>> cells.cells["age"][24, 36]
Attributes
| Name | Description |
|---|---|
| cells |
The cells as a dict of columns: origin, age, valuation
|
| origins | The origin periods the cells refer to. |
cells
The cells as a dict of columns: origin, age, valuation
cells: dict
("YYYY-MM") and value.
origins
The origin periods the cells refer to.
origins: list[str]
Methods
| Name | Description |
|---|---|
| from_chain_ladder() | A chain ladder’s future increments: at each age of the grid after an |
| from_odp_glm() | An ODP GLM’s future increments and their means. |
| reserves() | The sum of the cells by origin. |
from_chain_ladder()
A chain ladder’s future increments: at each age of the grid after an
Usage
from_chain_ladder(fit, segment=None)origin’s latest one, the projected cumulative value less the one before, then the rest of the ultimate (the tail) as one increment one development period after the oldest age. The cells sum to the fit’s reserves.
Parameters
fit: ChainLadderFitsegment: dict of str to object = None-
The key values choosing one segment of a fit over several, as
fit.segment; without it the fit must have one segment.
Returns
FutureCells
Raises
ValueError- If the fit has several segments and segment does not choose exactly one.
Examples
>>> from prospicio.reserving import ChainLadder, FutureCells, Triangle
>>> tri = Triangle.from_long(
... [2020, 2020, 2021], [12, 24, 12], {"paid": [100.0, 150.0, 110.0]}
... )
>>> cells = FutureCells.from_chain_ladder(ChainLadder().fit(tri, "paid"))
>>> cells.cells["origin"], cells.cells["age"]([‘2021’], [24])
from_odp_glm()
An ODP GLM’s future increments and their means.
Usage
from_odp_glm(fit)Parameters
fit: OdpGlmFit
Returns
FutureCells
reserves()
The sum of the cells by origin.
Usage
reserves()Returns
list of float