-
Notifications
You must be signed in to change notification settings - Fork 23
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
Is sklearn_fork handling tweedie correctly? #67
Comments
The fork follows actuarial practice:
The documentation mentions the use of the log for the Gamma and the Inverse Gaussian, but it left the Tweedie out, which we should presumably fix. Actuaries never use the canonical link function for the Tweedie or the Gamma, since they aren't terribly interpretable. I am fine with keeping current behavior. |
@lbittarello Thanks for clarifying. The sklearn-fork logic still doesn't seem to follow the actuarial convention. Is this correct?
|
Are you referring to the error if power is between zero and one? That is correct: the Tweedie family is not defined in that interval (i.e. no distribution exists). |
And |
What I find odd about the sklearn-fork code is that the link is identity if power < 0; based on your comment it sounds like it should be log |
To be honest, there is no actuarial practice for |
Conclusion: It's fine. This will be further clarified in the code by #68 |
This looks wrong to me, based on this: https://stats.stackexchange.com/questions/137227/what-is-the-canonical-link-function-for-a-tweedie-glm
power == 1
should be the special case of the log link, and otherwise there should be something like aTweedieLink
equal tomu ** (1 - p) / (1 - p)
, which doesn't currently exist.@MarcAntoineSchmidtQC : Could you add a test for whether we're getting the right answer in the tweedie-1.5 benchmark? (Regarding Issue #43 )
The text was updated successfully, but these errors were encountered: