You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
update It looks like there are some bugs, some options seem to be ignored,
e.g. I don't see any offset handling in the code for endpoint transformation confint, it just uses linpred = x b.
looks like false alarm
more in later comments
The get_prediction_glm function in genmod has weights handling copy pasted from regression linear model version. weights are not used in GLM.
GLM and GLMResults predict do not support weights, no freq_weights or var_weights. Maybe those should be added.
The function needs exog everything else we could delegate to results predict instead of using model predict.
The exog need to go through transform handling.
In GAM we also need creating the basis function for the predict exog.
The text was updated successfully, but these errors were encountered:
josef-pkt
changed the title
REF: redundant code in genmod get_prediction_glm
BUG/REF: redundant code in genmod get_prediction_glm, ignores link, ignores offset in confint
Nov 9, 2021
predicted mean looks correct it goes through model.predict with keywords predicted_mean = self.model.predict(self.params, exog, **pred_kwds) PredictionResults uses the linear prediction result only in EP confint
regression linear PredictionResult also goes through model.predict, so pred_kwds like offset are taken into account
predicted_mean = self.model.predict(self.params, exog, **pred_kwds)
confint for linpred is predicted mean +/- crit * std. So this is also correct.
So offset handling in get_prediction looks correct
I don't see unit tests for it.
josef-pkt
changed the title
BUG/REF: redundant code in genmod get_prediction_glm, ignores link, ignores offset in confint
BUG/REF: redundant code in genmod get_prediction_glm, ignores link
Nov 9, 2021
update It looks like there are some bugs, some options seem to be ignored,
e.g.
I don't see any offset handling in the code for endpoint transformation confint, it just uses linpred = x b.looks like false alarm
more in later comments
The get_prediction_glm function in genmod has
weights
handling copy pasted from regression linear model version.weights
are not used in GLM.GLM and GLMResults predict do not support weights, no freq_weights or var_weights. Maybe those should be added.
The function needs
exog
everything else we could delegate to results predict instead of using model predict.The
exog
need to go throughtransform
handling.In GAM we also need creating the basis function for the predict exog.
The text was updated successfully, but these errors were encountered: