Learn R Programming

ChainLadder (version 0.1.1-1)

summary.MunichChainLadder: ~~function to do ... ~~

Description

~~ A concise (1-5 lines) description of what the function does. ~~

Usage

summary.MunichChainLadder(MCL)

Arguments

MCL
~~Describe MCL here~~

Value

  • ~Describe the value returned If it is a LIST, use
  • comp1Description of 'comp1'
  • comp2Description of 'comp2'

Details

~~ If necessary, more details than the description above ~~

References

~put references to the literature/web site here ~

See Also

~~objects to See Also as help, ~~~

Examples

Run this code
##---- Should be DIRECTLY executable !! ----
##-- ==>  Define data, use random,
##--	or do  help(data=index)  for the standard data sets.

## The function is currently defined as
function (MCL) 
{
    n <- ncol(MCL[["MCLPaid"]])
    .Paid <- as.matrix(MCL[["Paid"]])
    .Incurred <- as.matrix(MCL[["Incurred"]])
    LatestPaid = rev(.Paid[row(.Paid) == (n + 1 - col(.Paid))])
    LatestIncurred = rev(.Incurred[row(.Incurred) == (n + 1 - 
        col(.Incurred))])
    UltimatePaid = MCL[["MCLPaid"]][, n]
    UltimateIncurred = MCL[["MCLIncurred"]][, n]
    Result <- data.frame(LatestPaid, LatestIncurred, Latest.P.I.Ratio = LatestPaid/LatestIncurred, 
        UltimatePaid, UltimateIncurred, Ultimate.P.I.Ratio = UltimatePaid/UltimateIncurred)
    return(Result)
  }

Run the code above in your browser using DataLab