FLAML icon indicating copy to clipboard operation
FLAML copied to clipboard

HOW TO FORECAST FEATURE? meaning of period parameter

Open luigif2000 opened this issue 3 years ago • 3 comments

Dear all, in a multivariate time series forecast the flaml website example show how to run automl and then predict set test data for scoring; well. this is a regression approach, i think. in order to forecast in the feature the label is necessary to lag the label before training or not? sorry for my ignorance but this is a very important question

luigif2000 avatar Sep 04 '22 01:09 luigif2000

https://towardsdatascience.com/the-complete-guide-to-time-series-analysis-and-forecasting-70d476b

luigif2000 avatar Sep 04 '22 02:09 luigif2000

If you are referring to sklearn regressor models, we do lag the label before training. See https://github.com/microsoft/FLAML/blob/9901156deec8eb2a603e2fbf74ca01ceac5e9b5c/flaml/model.py#L2050. We use hcrystalball's _transform_data_to_tsmodel_input_format function to do this.

int-chaos avatar Sep 05 '22 06:09 int-chaos

Hi and thanks for the kindly reply. I'm referring to what is magically explain in the following document: https://towardsdatascience.com/the-complete-guide-to-time-series-forecasting-using-sklearn-pandas-and-numpy-7694c90e45c1 Now I ask You:

how to forecast a time series 5days(for example) in the feature, without lagged the label BEFORE training ?

I think the procedure should be:

  1. lagged the label of 5days (for example)
  2. training the model
  3. predict on the last row, only one row, of the data

is it right?

in the flaml websitedoc/example i can't find any lagged procedure I'm very confused, honestly waiting your kindly reply

luigi

luigif2000 avatar Sep 06 '22 08:09 luigif2000