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
{{ message }}
Repository navigation
BUG: BetaModel, df_xxx warning, and init kwargs #8779
BetaModel does have _init_keys added in #7543
maybe there is a missing call to the check method
update
Those are two different usages of init_keys. #7569 refers to replicating the model, creating a new model with the same arguments. #7741 is the check for invalid kwargs in __init__
BetaModel has the former init_keys, but not applied to the kwargs issue.
I don't see it right now, is _init_keys enough or do we need to set kwargs_allowed additionally?
AFAIR, init keys should be enough, but I don't see the code yet.
strange: I don't get the df_model, ... k_params mismatch warning anymore in my notebook
all values look correct
???
about allowed keys:
BetaModel uses kwds['extra_params_names'] = extra_names before the super call to add the extra names for the precision parameters. (AFAIR, this also sets the df_model, df_resid)
'extra_params_names' is not listed in the allowed keywords.
In my planned change, I delete it again from the kwargs/kwds before calling check_kwargs
There is no option for users to use 'extra_params_names' as __init__ argument, it's hard coded.
Aside: wrong name: kwargs are called kwds here. "kwds" should be only used for dict keywords like cov_kwds.
Activity
josef-pkt commentedon Apr 7, 2023
That's weird
Part of this issue looks like duplicate of #7569
BetaModel does have
_init_keysadded in #7543maybe there is a missing call to the check method
update
Those are two different usages of init_keys.
#7569 refers to replicating the model, creating a new model with the same arguments.
#7741 is the check for invalid kwargs in
__init__BetaModel has the former init_keys, but not applied to the kwargs issue.
I don't see it right now, is
_init_keysenough or do we need to setkwargs_allowedadditionally?AFAIR, init keys should be enough, but I don't see the code yet.
josef-pkt commentedon Apr 7, 2023
strange: I don't get the df_model, ... k_params mismatch warning anymore in my notebook
all values look correct
???
about allowed keys:
BetaModel uses
kwds['extra_params_names'] = extra_namesbefore the super call to add the extra names for the precision parameters. (AFAIR, this also sets the df_model, df_resid)'extra_params_names' is not listed in the allowed keywords.
In my planned change, I delete it again from the kwargs/kwds before calling check_kwargs
There is no option for users to use 'extra_params_names' as
__init__argument, it's hard coded.Aside: wrong name:
kwargsare calledkwdshere. "kwds" should be only used for dict keywords like cov_kwds.ENH: BetaModel warn if invalid `__init__` kwargs closes statsmodels#8779