## reserving.MunichFit


A fitted Munich chain ladder of every segment.


Usage

``` python
reserving.MunichFit()
```


Per-origin lists run over the origins of each segment in turn, like the rows of [to_frame()](reserving.MackFit.md#prospicio.reserving.MackFit.to_frame). Per-age lists and the lambdas need a single-segment fit; for several segments use [development_frame()](reserving.MackFit.md#prospicio.reserving.MackFit.development_frame), [totals_frame()](reserving.MackFit.md#prospicio.reserving.MackFit.totals_frame) or `segment(...)`.


## Attributes

| Name | Description |
|----|----|
| [chain_ladder_incurred](#chain_ladder_incurred) | The separate chain ladder's incurred ultimate per origin. |
| [chain_ladder_paid](#chain_ladder_paid) | The separate chain ladder's paid ultimate per origin. |
| [development](#development) | Development ages in months. |
| [ibnr_incurred](#ibnr_incurred) | Incurred ultimate minus latest incurred per origin. |
| [index](#index) | Label of each segment, as [Triangle.index](reserving.Triangle.md#prospicio.reserving.Triangle.index). |
| [keys](#keys) | Names of the triangle's key columns; empty without keys. |
| [lambda_incurred](#lambda_incurred) | The slope of the incurred link-ratio residuals on the |
| [lambda_paid](#lambda_paid) | The slope of the paid link-ratio residuals on the incurred-to-paid |
| [latest_incurred](#latest_incurred) | Latest incurred per origin. |
| [latest_paid](#latest_paid) | Latest paid per origin. |
| [latest_ratio](#latest_ratio) | Latest paid over latest incurred per origin. |
| [mack_incurred](#mack_incurred) | Mack's model of the incurred column alone. |
| [mack_paid](#mack_paid) | Mack's model of the paid column alone. |
| [n_residuals_incurred](#n_residuals_incurred) | The number of residual pairs behind [lambda_incurred](reserving.MunichFit.md#prospicio.reserving.MunichFit.lambda_incurred): fewer than |
| [n_residuals_paid](#n_residuals_paid) | The number of residual pairs behind [lambda_paid](reserving.MunichFit.md#prospicio.reserving.MunichFit.lambda_paid). |
| [origins](#origins) | Origin period of each per-origin value. |
| [q](#q) | The paid-to-incurred ratio at each age, `sum P / sum I` (R's |
| [q_inverse](#q_inverse) | The incurred-to-paid ratio at each age, fitted on its own, |
| [reserve_paid](#reserve_paid) | Paid ultimate minus latest paid per origin. |
| [rho_incurred](#rho_incurred) | The deviation of `P/I` around [q](reserving.MunichFit.md#prospicio.reserving.MunichFit.q) (R's `rhoI.sigma`). |
| [rho_paid](#rho_paid) | The deviation of `I/P` around [q_inverse](reserving.MunichFit.md#prospicio.reserving.MunichFit.q_inverse) (R's `rhoP.sigma`). |
| [total_ultimate_incurred](#total_ultimate_incurred) | Total Munich incurred ultimate over every segment. |
| [total_ultimate_paid](#total_ultimate_paid) | Total Munich paid ultimate over every segment. |
| [ultimate_incurred](#ultimate_incurred) | The Munich incurred ultimate per origin. |
| [ultimate_paid](#ultimate_paid) | The Munich paid ultimate per origin. |
| [ultimate_ratio](#ultimate_ratio) | Paid ultimate over incurred ultimate per origin. |

------------------------------------------------------------------------


#### chain_ladder_incurred


The separate chain ladder's incurred ultimate per origin.


`chain_ladder_incurred: list[float]`


------------------------------------------------------------------------


#### chain_ladder_paid


The separate chain ladder's paid ultimate per origin.


`chain_ladder_paid: list[float]`


------------------------------------------------------------------------


#### development


Development ages in months.


`development: list[int]`


------------------------------------------------------------------------


#### ibnr_incurred


Incurred ultimate minus latest incurred per origin.


`ibnr_incurred: list[float]`


------------------------------------------------------------------------


#### index


Label of each segment, as [Triangle.index](reserving.Triangle.md#prospicio.reserving.Triangle.index).


`index: list[Any]`


------------------------------------------------------------------------


#### keys


Names of the triangle's key columns; empty without keys.


`keys: list[str]`


------------------------------------------------------------------------


#### lambda_incurred


The slope of the incurred link-ratio residuals on the


`lambda_incurred: float`


paid-to-incurred residuals (R's `lambdaI`).


------------------------------------------------------------------------


#### lambda_paid


The slope of the paid link-ratio residuals on the incurred-to-paid


`lambda_paid: float`


residuals (R's `lambdaP`); 0 when the ratios carry no information.


------------------------------------------------------------------------


#### latest_incurred


Latest incurred per origin.


`latest_incurred: list[float]`


------------------------------------------------------------------------


#### latest_paid


Latest paid per origin.


`latest_paid: list[float]`


------------------------------------------------------------------------


#### latest_ratio


Latest paid over latest incurred per origin.


`latest_ratio: list[float]`


------------------------------------------------------------------------


#### mack_incurred


Mack's model of the incurred column alone.


`mack_incurred: MackFit`


------------------------------------------------------------------------


#### mack_paid


Mack's model of the paid column alone.


`mack_paid: MackFit`


------------------------------------------------------------------------


#### n_residuals_incurred


The number of residual pairs behind [lambda_incurred](reserving.MunichFit.md#prospicio.reserving.MunichFit.lambda_incurred): fewer than


`n_residuals_incurred: int`


paid's where incurred's sigma is 0 at a link (residuals 0/0, left out of incurred's regression only, as in R).


------------------------------------------------------------------------


#### n_residuals_paid


The number of residual pairs behind [lambda_paid](reserving.MunichFit.md#prospicio.reserving.MunichFit.lambda_paid).


`n_residuals_paid: int`


------------------------------------------------------------------------


#### origins


Origin period of each per-origin value.


`origins: list[str]`


------------------------------------------------------------------------


#### q


The paid-to-incurred ratio at each age, `sum P / sum I` (R's


`q: list[float]`


`q.f`).


------------------------------------------------------------------------


#### q_inverse


The incurred-to-paid ratio at each age, fitted on its own,


`q_inverse: list[float]`


`sum I / sum P` (R's `qinverse.f`).


------------------------------------------------------------------------


#### reserve_paid


Paid ultimate minus latest paid per origin.


`reserve_paid: list[float]`


------------------------------------------------------------------------


#### rho_incurred


The deviation of `P/I` around [q](reserving.MunichFit.md#prospicio.reserving.MunichFit.q) (R's `rhoI.sigma`).


`rho_incurred: list[float]`


------------------------------------------------------------------------


#### rho_paid


The deviation of `I/P` around [q_inverse](reserving.MunichFit.md#prospicio.reserving.MunichFit.q_inverse) (R's `rhoP.sigma`).


`rho_paid: list[float]`


------------------------------------------------------------------------


#### total_ultimate_incurred


Total Munich incurred ultimate over every segment.


`total_ultimate_incurred: float`


------------------------------------------------------------------------


#### total_ultimate_paid


Total Munich paid ultimate over every segment.


`total_ultimate_paid: float`


------------------------------------------------------------------------


#### ultimate_incurred


The Munich incurred ultimate per origin.


`ultimate_incurred: list[float]`


------------------------------------------------------------------------


#### ultimate_paid


The Munich paid ultimate per origin.


`ultimate_paid: list[float]`


------------------------------------------------------------------------


#### ultimate_ratio


Paid ultimate over incurred ultimate per origin.


`ultimate_ratio: list[float]`


## Methods

| Name | Description |
|----|----|
| [development_frame()](#development_frame) | One row per segment and age: [q](reserving.MunichFit.md#prospicio.reserving.MunichFit.q), [q_inverse](reserving.MunichFit.md#prospicio.reserving.MunichFit.q_inverse), [rho_paid](reserving.MunichFit.md#prospicio.reserving.MunichFit.rho_paid), |
| [segment()](#segment) | The fit of one segment, chosen by key values as |
| [to_frame()](#to_frame) | One row per segment and origin: the key columns, `origin`, |
| [totals_frame()](#totals_frame) | One row per segment: the totals of [to_frame()](reserving.MackFit.md#prospicio.reserving.MackFit.to_frame)'s columns (the |

------------------------------------------------------------------------


#### development_frame()


One row per segment and age: [q](reserving.MunichFit.md#prospicio.reserving.MunichFit.q), [q_inverse](reserving.MunichFit.md#prospicio.reserving.MunichFit.q_inverse), [rho_paid](reserving.MunichFit.md#prospicio.reserving.MunichFit.rho_paid),


Usage

``` python
development_frame()
```


[rho_incurred](reserving.MunichFit.md#prospicio.reserving.MunichFit.rho_incurred), and each column's `ldf_paid`, `sigma_paid`, `ldf_incurred` and `sigma_incurred` (NaN at the oldest age). Needs pandas.


##### Returns


`pandas.DataFrame`  


------------------------------------------------------------------------


#### segment()


The fit of one segment, chosen by key values as


Usage

``` python
segment(**keys)
```


[ChainLadderFit.segment](reserving.ChainLadderFit.md#prospicio.reserving.ChainLadderFit.segment).


##### Returns


`MunichFit`  


------------------------------------------------------------------------


#### to_frame()


One row per segment and origin: the key columns, `origin`,


Usage

``` python
to_frame()
```


[latest_paid](reserving.MunichFit.md#prospicio.reserving.MunichFit.latest_paid), [latest_incurred](reserving.MunichFit.md#prospicio.reserving.MunichFit.latest_incurred), [latest_ratio](reserving.MunichFit.md#prospicio.reserving.MunichFit.latest_ratio), [ultimate_paid](reserving.MunichFit.md#prospicio.reserving.MunichFit.ultimate_paid), [ultimate_incurred](reserving.MunichFit.md#prospicio.reserving.MunichFit.ultimate_incurred), [ultimate_ratio](reserving.MunichFit.md#prospicio.reserving.MunichFit.ultimate_ratio), [reserve_paid](reserving.MunichFit.md#prospicio.reserving.MunichFit.reserve_paid), [ibnr_incurred](reserving.MunichFit.md#prospicio.reserving.MunichFit.ibnr_incurred), [chain_ladder_paid](reserving.MunichFit.md#prospicio.reserving.MunichFit.chain_ladder_paid) and [chain_ladder_incurred](reserving.MunichFit.md#prospicio.reserving.MunichFit.chain_ladder_incurred). Needs pandas.


##### Returns


`pandas.DataFrame`  


------------------------------------------------------------------------


#### totals_frame()


One row per segment: the totals of [to_frame()](reserving.MackFit.md#prospicio.reserving.MackFit.to_frame)'s columns (the


Usage

``` python
totals_frame()
```


ratios of the totals), [lambda_paid](reserving.MunichFit.md#prospicio.reserving.MunichFit.lambda_paid), [lambda_incurred](reserving.MunichFit.md#prospicio.reserving.MunichFit.lambda_incurred), [n_residuals_paid](reserving.MunichFit.md#prospicio.reserving.MunichFit.n_residuals_paid) and [n_residuals_incurred](reserving.MunichFit.md#prospicio.reserving.MunichFit.n_residuals_incurred). Needs pandas.


##### Returns


`pandas.DataFrame`
