Skip to content

REF/ENH: GLM predict which and get_prediction - #8505

Merged
josef-pkt merged 3 commits into
statsmodels:mainfrom
josef-pkt:glm_predict_which
Nov 11, 2022
Merged

josef-pkt merged 3 commits into
statsmodels:mainfrom
josef-pkt:glm_predict_which

Conversation

@josef-pkt

Copy link
Copy Markdown
Member

add "which" option to GLM predict

GLM get_prediction returns generic Prediction results classes if which is not None

This is currently backwards compatible, but we will remove the old version when "linear" keyword is removed.
Then only the which is not None path will remain, with default which="mean"

@josef-pkt
josef-pkt merged commit 3c15d04 into statsmodels:main Nov 11, 2022
@josef-pkt

Copy link
Copy Markdown
Member Author

I just saw that GAM inherits from GLM GLMGamResults(GLMResults)
get_prediction calls the super method
extra keywords are in kwargs, so which support and behavior should be inherited from GLM

needs specific unit tests
get_distribution and other post-estimation features will also be inherited
needs new issue

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant