# unpaidClaims

Compute unpaid claims estimates for `capeCod` object

Since R2021a

## Syntax

``unpaidClaimsEstimate = unpaidClaims(cc)``

## Description

````unpaidClaimsEstimate = unpaidClaims(cc)` computes unpaid claims estimates for a `capeCod` object. ```

example

## Examples

collapse all

This example shows how to compute the unpaid claims estimates for a `capeCod` object for simulated insurance claims data.

```load InsuranceClaimsData.mat; head(data)```
``` OriginYear DevelopmentYear ReportedClaims PaidClaims __________ _______________ ______________ __________ 2010 12 3995.7 1893.9 2010 24 4635 3371.2 2010 36 4866.8 4079.1 2010 48 4964.1 4487 2010 60 5013.7 4711.4 2010 72 5038.8 4805.6 2010 84 5059 4853.7 2010 96 5074.1 4877.9 ```

Use `developmentTriangle` to convert the data to a development triangle, which is the standard form for representing claims data. Create two `developmentTriangle` objects, one for reported claims and one for paid claims.

`dT_reported = developmentTriangle(data,'Origin','OriginYear','Development','DevelopmentYear','Claims','ReportedClaims')`
```dT_reported = developmentTriangle with properties: Origin: {10x1 cell} Development: {10x1 cell} Claims: [10x10 double] LatestDiagonal: [10x1 double] Description: "" TailFactor: 1 CumulativeDevelopmentFactors: [1.3069 1.1107 1.0516 1.0261 1.0152 1.0098 1.0060 1.0030 1.0010 1] SelectedLinkRatio: [1.1767 1.0563 1.0249 1.0107 1.0054 1.0038 1.0030 1.0020 1.0010] ```
`dT_paid = developmentTriangle(data,'Origin','OriginYear','Development','DevelopmentYear','Claims','PaidClaims')`
```dT_paid = developmentTriangle with properties: Origin: {10x1 cell} Development: {10x1 cell} Claims: [10x10 double] LatestDiagonal: [10x1 double] Description: "" TailFactor: 1 CumulativeDevelopmentFactors: [2.4388 1.4070 1.1799 1.0810 1.0378 1.0178 1.0080 1.0030 1.0010 1] SelectedLinkRatio: [1.7333 1.1925 1.0914 1.0417 1.0196 1.0097 1.0050 1.0020 1.0010] ```

Create a `capeCod` object where the first input argument is the reported development triangle, the second input argument is the paid development triangle, and the third input is the earned premium.

```earnedPremium = [17000; 18000; 10000; 19000; 16000; 10000; 11000; 10000; 14000; 10000]; cc = capeCod(dT_reported, dT_paid,earnedPremium)```
```cc = capeCod with properties: ReportedTriangle: [1x1 developmentTriangle] PaidTriangle: [1x1 developmentTriangle] EarnedPremium: [10x1 double] UsedUpPremium: [10x1 double] EstimatedClaimRatios: [10x1 double] ExpectedClaimRatio: 0.4258 EstimatedExpectedClaims: [10x1 double] PercentUnreported: [10x1 double] CaseOutstanding: [10x1 double] ```

Use `unpaidClaims` to compute the unpaid claims estimates.

`unpaidClaimsEstimate = unpaidClaims(cc)`
```unpaidClaimsEstimate = 10×1 103 × 0.1968 0.0531 0.1259 0.1232 0.1856 0.0731 0.3609 0.8920 1.7032 3.1811 ```

## Input Arguments

collapse all

Cape Cod object, specified as a previously created `capeCod` object.

Data Types: `object`

## Output Arguments

collapse all

Unpaid claims estimates, returned as an array.