## methods.OneYearCDRResult


What [one_year_cdr()](methods.one_year_cdr.md#ibnr.methods.one_year_cdr) returns: pyarrow Tables with fixed column types.


Usage

``` python
methods.OneYearCDRResult(
    method,
    as_of,
    dev_grain_months,
    n_draws,
    seed,
    origins,
    totals,
    quantiles,
    draws
)
```


A missing number is an Arrow null, never NaN. `to_polars(name)` gives any of the tables as a polars DataFrame.

Every simulated number is about `ultimate_change`, next year's re-estimated ultimate minus today's: positive when the reserve is strengthened, negative when it is released. That is the opposite sign of the claims development result in [kernels.simulate_one_year_cdr](kernels.simulate_one_year_cdr.md#ibnr.kernels.simulate_one_year_cdr), which is positive for a release.


## Attributes


`method: str`  
`"one_year_cdr"`.

`as_of: datetime.date`  
The information date, the evaluation date of the latest cell.

`dev_grain_months: int`  
Months per development step, always 12.

`n_draws: int`  
The number of simulated years.

`seed: int or None`  
The seed as passed; `None` means the draws came from fresh entropy and cannot be made again.

`origins: pyarrow.Table`  
One row per origin period: `origin` and `origin_period` (as in [ReserveResult](methods.ReserveResult.md#ibnr.methods.ReserveResult)), `latest_dev_lag` (int64), [latest](kernels.MackFit.md#ibnr.kernels.MackFit.latest), [ultimate](kernels.MackFit.md#ibnr.kernels.MackFit.ultimate) and `ibnr` (today's chain-ladder figures), `mean_ultimate_change` and `sd_ultimate_change` (the draws' mean, and their standard deviation with `ddof=1`, null when [n_draws](gallery.CohortForecast.md#ibnr.gallery.CohortForecast.n_draws) is 1), `cdr_se` (the Merz-Wuthrich standard error of the one-year claims development result) and `runoff_se` (Mack's standard error of the whole run-off, what [mack()](methods.mack.md#ibnr.methods.mack) reports as `mack_se` under the same `sigma_rule` and `zero_cells`), all float64. An origin at its last development age has a change of 0 in every draw.

`totals: pyarrow.Table`  
One row: [latest](kernels.MackFit.md#ibnr.kernels.MackFit.latest), [ultimate](kernels.MackFit.md#ibnr.kernels.MackFit.ultimate), `ibnr`, `mean_ultimate_change`, `sd_ultimate_change`, `cdr_se`, `runoff_se` (float64) and [n_draws](gallery.CohortForecast.md#ibnr.gallery.CohortForecast.n_draws) (int64), for the sum over the origins. The standard errors are not the sums of the origins': the origins share the factors.

`quantiles: pyarrow.Table`  
One row per origin, or the total, and level: `origin` and `origin_period` (null for the total), `level` (the probability, as passed), `ultimate_change` (the quantile of the draws, numpy's linear rule, which is `np.percentile` with the level times 100) and `tvar` (the mean of the draws at or above that quantile). The total's rows come first, then each origin's in origin order, each in the order of the levels.

`draws: pyarrow.Table`  
Every draw of every origin, [n_draws](gallery.CohortForecast.md#ibnr.gallery.CohortForecast.n_draws) times the number of origins rows, draw by draw: [draw](gallery.GalleryDiagonal.md#ibnr.gallery.GalleryDiagonal.draw) (int64, from 0), `origin`, `origin_period` and `ultimate_change` (float64). A draw's total is the sum of its rows.


## Methods

| Name | Description |
|----|----|
| [to_polars()](#to_polars) | One of the result's tables as a polars DataFrame. |

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


#### to_polars()


One of the result's tables as a polars DataFrame.


Usage

``` python
to_polars(table="origins")
```


`table` is `"origins"` (the default), `"totals"`, `"quantiles"` or `"draws"`. Needs polars: `pip install "ibnr[polars]"`.
