Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cum_to_incr() not working as expected on full_triangle_ #157

Closed
cbalona opened this issue May 3, 2021 · 2 comments
Closed

cum_to_incr() not working as expected on full_triangle_ #157

cbalona opened this issue May 3, 2021 · 2 comments

Comments

@cbalona
Copy link
Contributor

cbalona commented May 3, 2021

As of 0.8.3, cum_to_incr() does not actually convert to an incremental triangle.

import chainladder as cl
raa = cl.load_sample('raa')
cl.Chainladder().fit(raa).full_triangle_.cum_to_incr()

This will display the cumulative triangle. Running the same under 0.8.2 converts to incremental. Possibly a side effect from #143 ?

@jbogaardt
Copy link
Collaborator

Definitely is a regression. Sorry about that. The quick way around it ahead of a fix is:

import chainladder as cl
raa = cl.load_sample('raa')
full = cl.Chainladder().fit(raa).full_triangle_
full.is_cumulative = True
full.cum_to_incr()

cum_to_incr checks whether the triangle is already incremental before doing any calculations, if it is, then it just hands you the same triangle.

@jbogaardt
Copy link
Collaborator

Fixed in master, I'll fast track moving to 0.8.4, probably this weekend.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants