Should forecast_fitted_values
also work for fitted models in addition to when forecast(fitted=True) is called?
#835
Labels
Description
Please correct my understanding if it's incorrect. Relatively new to the library!
sf.forecast
is to optimize memory burden & be parallel / optimization friendly.sf.fit
+sf.predict
lets us examine the fitted models closely.sf.forecast_fitted_values()
sf.forecast(..., fitted=True)
is called. It doesn't work on models fit usingsf.fit
.sf.fit
, there are currently two choices, both suboptimal:predict_in_sample
, e.g.,sf.fitted_[0, 0].predict_in_sample()
- requires deeper understanding of architecture + additional step of converting to a dataframe.My proposal would involve one or both of the following:
sf.forecast_fitted_values()
to any StatsForecast object where.fit()
has been called, in addition to ones thatsf.forecast(..., fitted=True)
was called. Unless there's something in the code I missed, implementation would simply be (ii) above.fitted=True
, i.e., stores insample predictions to a"fcst_fitted_values_"
object.I am happy to work on this if there's interest. Let me know your thoughts.
Use case
The primary reason one would use
.fit()
would be to examine the models more closely, including looking at in-sample fit. I think the use case in this issue well-encapsulates the utility of this function.#639 (comment)
The text was updated successfully, but these errors were encountered: