
getLatestCumulative(Triangle, na.values = NULL)
names
of the vector equal the origin names of the Triangle.
The vector will have additional attributes:
"latestcol" equalling the index of the column in Triangle corresponding
to the row's rightmost entry;
"rowsname" equalling the name of the row dimension of Triangle, if any;
"colnames" equalling the corresponding column name of Triangle, if any;
"colsname" equalling the name of the column dimension of Triangle, if any.as.triangle
.RAA
getLatestCumulative(RAA)
Y <- matrix(c(1, 2, 3,
4, 5, 0,
6, NA, NA), byrow=TRUE, nrow=3)
getLatestCumulative(Y) # c(3, 0, 6)
getLatestCumulative(Y, na.values = 0) # c(3, 5, 6)
Run the code above in your browser using DataLab