-
Notifications
You must be signed in to change notification settings - Fork 70
Always return dictionary from data_info #582
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
base: main
Are you sure you want to change the base?
Conversation
90c92cd
to
de748b6
Compare
de748b6
to
445d884
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Jesse, the tests looked good to me!
mode=mode, | ||
) | ||
|
||
self._needs_exog_data = exog_state_names is not None and len(exog_state_names) > 0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is len(exog_state_names)>0
intended to handle when a user inputs an empty list? What about if a user inputs a dictionary with an empty list? I think if you have something like {'endog1': [], 'endog2': []}
then you will get a True.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fair enough, I switched it to be a bit more robust to all possible cases.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think while this became a little bit wordy, it will help the user navigate input errors. I do wonder, though, since other state space models and if I'm not mistaken the structural api use a similar input schema if it would be a good idea to wrap that up in like a _validate_endog_exog_inputs()
utility?
Yes I agree the validation functionality should be moved out to a helper. Can you open an issue? :) |
Yes, I'd be happy to! |
VARMAX forecasting is broken when there is no exogenous data because the return value of
data_info
is incorrect. I also added tests that would have caught this bug.