Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: skforecast/skforecast
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v0.8.1
Choose a base ref
...
head repository: skforecast/skforecast
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: v0.9.0
Choose a head ref

Commits on May 27, 2023

  1. update link image logo

    Joaquin Amat committed May 27, 2023

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature.
    Copy the full SHA
    34ba059 View commit details
  2. deleted html folder docs

    Joaquin Amat committed May 27, 2023
    Copy the full SHA
    1426757 View commit details

Commits on May 28, 2023

  1. update google collab links

    Joaquin Amat committed May 28, 2023
    Copy the full SHA
    0187c2e View commit details
  2. Merge pull request #462 from JoaquinAmatRodrigo/feature_google_colab_…

    …links
    
    update google collab links
    JoaquinAmatRodrigo authored May 28, 2023
    Copy the full SHA
    ee2a746 View commit details
  3. Copy the full SHA
    c4c1b08 View commit details
  4. added summary table forecasters

    Joaquin Amat committed May 28, 2023
    Copy the full SHA
    177a110 View commit details
  5. update summary table forecasters

    Joaquin Amat committed May 28, 2023
    Copy the full SHA
    b113632 View commit details
  6. update summary table

    Joaquin Amat committed May 28, 2023
    Copy the full SHA
    fb3f93c View commit details
  7. Copy the full SHA
    efd0d9b View commit details

Commits on May 29, 2023

  1. Copy the full SHA
    65360a5 View commit details
  2. Copy the full SHA
    9343b21 View commit details
  3. update_license

    JavierEscobarOrtiz committed May 29, 2023
    Copy the full SHA
    6fc50d7 View commit details
  4. Update README.md

    JavierEscobarOrtiz committed May 29, 2023
    Copy the full SHA
    5bc3b2a View commit details
  5. update_docs

    JavierEscobarOrtiz committed May 29, 2023
    Copy the full SHA
    ab27b12 View commit details
  6. Copy the full SHA
    281638e View commit details
  7. Copy the full SHA
    bb93c38 View commit details
  8. update_docs

    JavierEscobarOrtiz committed May 29, 2023
    Copy the full SHA
    05e4c3d View commit details

Commits on May 30, 2023

  1. update mkdocs, and docstrings

    Joaquin Amat committed May 30, 2023
    Copy the full SHA
    efb42f4 View commit details
  2. update api docs

    Joaquin Amat committed May 30, 2023
    Copy the full SHA
    0ca1038 View commit details

Commits on May 31, 2023

  1. Copy the full SHA
    036309d View commit details
  2. Copy the full SHA
    b0d6769 View commit details
  3. Copy the full SHA
    3700225 View commit details
  4. update_docstrings

    JavierEscobarOrtiz committed May 31, 2023
    Copy the full SHA
    876cd05 View commit details
  5. update_docstrings

    JavierEscobarOrtiz committed May 31, 2023
    Copy the full SHA
    526210c View commit details
  6. update banner landing page

    Joaquin Amat committed May 31, 2023
    Copy the full SHA
    b9d7964 View commit details
  7. Copy the full SHA
    a5f5831 View commit details
  8. Copy the full SHA
    fc20cda View commit details

Commits on Jun 1, 2023

  1. fix_link

    JavierEscobarOrtiz committed Jun 1, 2023
    Copy the full SHA
    03f2184 View commit details
  2. update_docstrings

    JavierEscobarOrtiz committed Jun 1, 2023
    Copy the full SHA
    e4550ae View commit details
  3. update

    JavierEscobarOrtiz committed Jun 1, 2023
    Copy the full SHA
    9d1e916 View commit details
  4. Copy the full SHA
    61f0dfa View commit details
  5. Copy the full SHA
    398b788 View commit details
  6. Merge pull request #471 from JoaquinAmatRodrigo/feature_update_docs

    Update ForecasterAutoregDirect.py
    JavierEscobarOrtiz authored Jun 1, 2023
    Copy the full SHA
    136a14f View commit details
  7. Copy the full SHA
    fd6de1f View commit details

Commits on Jun 2, 2023

  1. Copy the full SHA
    3c9d099 View commit details

Commits on Jun 3, 2023

  1. update

    JavierEscobarOrtiz committed Jun 3, 2023
    Copy the full SHA
    035c4cd View commit details
  2. Copy the full SHA
    92ce421 View commit details
  3. Merge pull request #472 from JoaquinAmatRodrigo/feature_faq_cyclical_…

    …features
    
    added faq cyclical features
    JoaquinAmatRodrigo authored Jun 3, 2023
    Copy the full SHA
    8570651 View commit details
  4. update

    JoaquinAmatRodrigo committed Jun 3, 2023
    Copy the full SHA
    d32b48d View commit details
  5. update

    Joaquin Amat committed Jun 3, 2023
    Copy the full SHA
    080cd4e View commit details
  6. update

    Joaquin Amat committed Jun 3, 2023
    Copy the full SHA
    450aff0 View commit details

Commits on Jun 4, 2023

  1. updated icon in examples

    Joaquin Amat committed Jun 4, 2023
    Copy the full SHA
    fbe7466 View commit details
  2. Copy the full SHA
    0efe2ed View commit details
  3. first attemp parallel forecasting

    Joaquin Amat committed Jun 4, 2023
    Copy the full SHA
    556dd10 View commit details

Commits on Jun 5, 2023

  1. Copy the full SHA
    de8c2ff View commit details
  2. Copy the full SHA
    d12392a View commit details
  3. update

    Joaquin Amat committed Jun 5, 2023
    Copy the full SHA
    4e17edb View commit details
  4. update

    Joaquin Amat committed Jun 5, 2023
    Copy the full SHA
    f67d764 View commit details
  5. Copy the full SHA
    075ad53 View commit details
  6. Update README.md

    JavierEscobarOrtiz committed Jun 5, 2023
    Copy the full SHA
    4cbd3a9 View commit details
Showing with 25,696 additions and 38,305 deletions.
  1. +3 −3 CITATION.cff
  2. +47 −63 CONTRIBUTING.md
  3. +73 −54 README.md
  4. +7 −0 dev/00_template.ipynb
  5. +318 −0 dev/01_backtesting_execution_time.ipynb
  6. +38 −31 dev/01_gif_backtestings_creator.ipynb
  7. +49 −0 dev/javi_profiling_results_ForecasterAutoregDirect_1000.csv
  8. +49 −0 dev/javi_profiling_results_ForecasterAutoregMultiSeries_1000.csv
  9. +49 −0 dev/javi_profiling_results_ForecasterAutoregMultivariate_1000.csv
  10. +49 −0 dev/javi_profiling_results_ForecasterAutoreg_1000.csv
  11. +3,142 −0 dev/parallel_direct.ipynb
  12. +49 −0 dev/profiling_results_ForecasterAutoregDirect_1000.csv
  13. +49 −0 dev/profiling_results_ForecasterAutoregMultiSeries_1000.csv
  14. +49 −0 dev/profiling_results_ForecasterAutoregMultivariate_1000.csv
  15. +49 −0 dev/profiling_results_ForecasterAutoreg_1000.csv
  16. +49 −0 dev/profiling_results_ForecasterAutoreg_5000.csv
  17. +5,279 −0 dev/profiling_skforecast_javi.ipynb
  18. +5,274 −0 dev/profiling_skforecast_ximo.ipynb
  19. +830 −0 dev/select_n_jobs.ipynb
  20. +55 −27 docs/README.md
  21. +1 −7 docs/api/ForecasterAutoreg.md
  22. +1 −5 docs/api/ForecasterAutoregCustom.md
  23. +1 −5 docs/api/ForecasterAutoregDirect.md
  24. +1 −7 docs/api/ForecasterMultiSeries.md
  25. +1 −5 docs/api/ForecasterMultiSeriesCustom.md
  26. +1 −5 docs/api/ForecasterMultiVariate.md
  27. +3 −1 docs/api/exceptions.md
  28. +1 −0 docs/api/utils.md
  29. +8 −8 docs/examples/examples.md
  30. +1,382 −0 docs/faq/cyclical-features-time-series.ipynb
  31. +5 −3 docs/faq/faq.md
  32. +18 −19 docs/faq/forecasting-time-series-with-missing-values.ipynb
  33. +42 −28 docs/faq/non-negative-predictions.ipynb
  34. +74 −69 docs/faq/profiling-skforecast.ipynb
  35. +0 −16,147 docs/html/py27-forecasting-series-temporales-python-scikitlearn.html
  36. +0 −16,122 docs/html/py27-time-series-forecasting-python-scikitlearn.html
  37. BIN docs/img/backtesting_intermittent_refit.gif
  38. +15 −17 docs/introduction-forecasting/forecaster-attributes.ipynb
  39. +6 −5 docs/introduction-forecasting/forecaster-parameters.md
  40. +132 −44 docs/introduction-forecasting/introduction-forecasting.md
  41. +54 −0 docs/releases/releases.md
  42. +16 −2 docs/stylesheets/extra.css
  43. +19 −15 docs/user_guides/autoregresive-forecaster.ipynb
  44. +239 −50 docs/user_guides/backtesting.ipynb
  45. +26 −28 docs/user_guides/categorical-features.ipynb
  46. +14 −14 docs/user_guides/custom-predictors.ipynb
  47. +186 −118 docs/user_guides/dependent-multi-series-multivariate-forecasting.ipynb
  48. +66 −40 docs/user_guides/direct-multi-step-forecasting.ipynb
  49. +46 −26 docs/user_guides/exogenous-variables.ipynb
  50. +4 −5 docs/user_guides/feature-importances.ipynb
  51. +3 −3 docs/user_guides/forecaster-in-production.ipynb
  52. +118 −88 docs/user_guides/forecasting-sarimax-arima.ipynb
  53. +26 −27 docs/user_guides/forecasting-xgboost-lightgbm.ipynb
  54. +619 −506 docs/user_guides/hyperparameter-tuning-and-lags-selection.ipynb
  55. +419 −151 docs/user_guides/independent-multi-time-series-forecasting.ipynb
  56. +3 −4 docs/user_guides/input-data.ipynb
  57. +10 −10 docs/user_guides/plot-forecaster-residuals.ipynb
  58. +893 −219 docs/user_guides/probabilistic-forecasting.ipynb
  59. +75 −53 docs/user_guides/quick-start-skforecast.ipynb
  60. +21 −21 docs/user_guides/save-load-forecaster.ipynb
  61. +28 −14 docs/user_guides/shap-values-skforecast.ipynb
  62. +3 −3 docs/user_guides/skforecast-in-GPU.ipynb
  63. +62 −48 docs/user_guides/sklearn-transformers-and-pipeline.ipynb
  64. +23 −24 docs/user_guides/weighted-time-series-forecasting.ipynb
  65. +15 −10 mkdocs.yml
  66. +5 −5 requirements.txt
  67. +10 −10 requirements_docs.txt
  68. +1 −1 requirements_optional.txt
  69. +3 −3 requirements_test.txt
  70. +1 −1 setup.py
  71. +74 −161 skforecast/ForecasterAutoreg/ForecasterAutoreg.py
  72. +36 −134 skforecast/ForecasterAutoregCustom/ForecasterAutoregCustom.py
  73. +205 −241 skforecast/ForecasterAutoregDirect/ForecasterAutoregDirect.py
  74. +15 −23 skforecast/ForecasterAutoregDirect/tests/test_create_lags.py
  75. +278 −166 skforecast/ForecasterAutoregDirect/tests/test_create_train_X_y.py
  76. +2 −2 skforecast/ForecasterAutoregDirect/tests/test_filter_train_X_y_for_step.py
  77. +21 −11 skforecast/ForecasterAutoregDirect/tests/test_fit.py
  78. +17 −6 skforecast/ForecasterAutoregDirect/tests/test_init.py
  79. +4 −1 skforecast/ForecasterAutoregDirect/tests/test_predict.py
  80. +28 −28 skforecast/ForecasterAutoregDirect/tests/test_predict_bootstrapping.py
  81. +2 −4 skforecast/ForecasterAutoregDirect/tests/test_predict_dist.py
  82. +2 −2 skforecast/ForecasterAutoregDirect/tests/test_predict_interval.py
  83. +193 −256 skforecast/ForecasterAutoregMultiSeries/ForecasterAutoregMultiSeries.py
  84. +1 −1 skforecast/ForecasterAutoregMultiSeries/tests/fixtures_ForecasterAutoregMultiSeries.py
  85. +5 −5 skforecast/ForecasterAutoregMultiSeries/tests/test_create_lags.py
  86. +77 −13 skforecast/ForecasterAutoregMultiSeries/tests/test_create_sample_weights.py
  87. +182 −1 skforecast/ForecasterAutoregMultiSeries/tests/test_create_train_X_y.py
  88. +2 −2 skforecast/ForecasterAutoregMultiSeries/tests/test_fit.py
  89. +51 −3 skforecast/ForecasterAutoregMultiSeries/tests/test_predict.py
  90. +183 −242 skforecast/ForecasterAutoregMultiSeriesCustom/ForecasterAutoregMultiSeriesCustom.py
  91. +79 −7 skforecast/ForecasterAutoregMultiSeriesCustom/tests/test_create_sample_weights.py
  92. +199 −1 skforecast/ForecasterAutoregMultiSeriesCustom/tests/test_create_train_X_y.py
  93. +2 −3 skforecast/ForecasterAutoregMultiSeriesCustom/tests/test_fit.py
  94. +52 −3 skforecast/ForecasterAutoregMultiSeriesCustom/tests/test_predict.py
  95. +237 −290 skforecast/ForecasterAutoregMultiVariate/ForecasterAutoregMultiVariate.py
  96. +13 −21 skforecast/ForecasterAutoregMultiVariate/tests/test_create_lags.py
  97. +301 −172 skforecast/ForecasterAutoregMultiVariate/tests/test_create_train_X_y.py
  98. +2 −2 skforecast/ForecasterAutoregMultiVariate/tests/test_filter_train_X_y_for_step.py
  99. +21 −12 skforecast/ForecasterAutoregMultiVariate/tests/test_fit.py
  100. +20 −9 skforecast/ForecasterAutoregMultiVariate/tests/test_init.py
  101. +5 −2 skforecast/ForecasterAutoregMultiVariate/tests/test_predict.py
  102. +13 −13 skforecast/ForecasterAutoregMultiVariate/tests/test_predict_bootstrapping.py
  103. +2 −2 skforecast/ForecasterAutoregMultiVariate/tests/test_predict_dist.py
  104. +2 −2 skforecast/ForecasterAutoregMultiVariate/tests/test_predict_interval.py
  105. +37 −31 skforecast/ForecasterBase/ForecasterBase.py
  106. +27 −85 skforecast/ForecasterSarimax/ForecasterSarimax.py
  107. +1 −1 skforecast/__init__.py
  108. +1 −1 skforecast/exceptions/exceptions.py
  109. +1 −1 skforecast/model_selection/__init__.py
  110. +455 −612 skforecast/model_selection/model_selection.py
  111. +2 −0 skforecast/model_selection/tests/test_backtesting_forecaster.py
  112. +119 −92 skforecast/model_selection/tests/test_backtesting_forecaster_no_refit.py
  113. +247 −89 skforecast/model_selection/tests/test_backtesting_forecaster_refit.py
  114. +1 −0 skforecast/model_selection/tests/test_bayesian_search_optuna.py
  115. +486 −83 skforecast/model_selection/tests/test_create_backtesting_folds.py
  116. +409 −616 skforecast/model_selection_multiseries/model_selection_multiseries.py
  117. +635 −89 skforecast/model_selection_multiseries/tests/test_backtesting_forecaster_multiseries.py
  118. +259 −381 skforecast/model_selection_sarimax/model_selection_sarimax.py
  119. +18 −9 skforecast/model_selection_sarimax/test/test_backtesting_sarimax.py
  120. +13 −18 skforecast/plot/plot.py
  121. +110 −2 skforecast/utils/tests/test_check_backtesting_input.py
  122. +43 −0 skforecast/utils/tests/test_select_n_jobs_backtesting.py
  123. +25 −0 skforecast/utils/tests/test_select_n_jobs_fit_forecaster.py
  124. +273 −179 skforecast/utils/utils.py
  125. +1 −1 tests/test_skforecast_version.py
6 changes: 3 additions & 3 deletions CITATION.cff
Original file line number Diff line number Diff line change
@@ -25,6 +25,6 @@ keywords:
- forecasting
- machine learning
- python
license: MIT
version: 0.8.1
date-released: '2023-05'
license: BSD 3-Clause License
version: 0.9.0
date-released: '2023-07'
110 changes: 47 additions & 63 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -8,7 +8,7 @@ Primarily, skforecast development consists of adding and creating new *Forecaste

- Submit a bug report or feature request on [GitHub Issues](https://github.com/JoaquinAmatRodrigo/skforecast/issues).
- Contribute a Jupyter notebook to our [examples](https://joaquinamatrodrigo.github.io/skforecast/latest/examples/examples.html).
- Write [unit or integration tests](https://docs.pytest.org/en/7.2.x/) for our project.
- Write [unit or integration tests](https://docs.pytest.org/en/latest/) for our project.
- Answer questions on our issues, Stack Overflow, and elsewhere.
- Translate our documentation into another language.
- Write a blog post, tweet, or share our project with others.
@@ -47,130 +47,111 @@ class ForecasterAutoreg(ForecasterBase):
"""
This class turns any regressor compatible with the scikit-learn API into a
recursive autoregressive (multi-step) forecaster.
Parameters
----------
regressor : regressor or pipeline compatible with the scikit-learn API
An instance of a regressor or pipeline compatible with the scikit-learn API.
lags : int, list, 1d numpy ndarray, range
Lags used as predictors. Index starts at 1, so lag 1 is equal to t-1.
`int`: include lags from 1 to `lags` (included).
`list`, `numpy ndarray` or `range`: include only lags present in `lags`,
all elements must be int.
An instance of a regressor or pipeline compatible with the scikit-learn API
lags : int, list, numpy ndarray, range
Lags used as predictors. Index starts at 1, so lag 1 is equal to t-1.
- `int`: include lags from 1 to `lags` (included).
- `list`, `1d numpy ndarray` or `range`: include only lags present in
`lags`, all elements must be int.
transformer_y : object transformer (preprocessor), default `None`
An instance of a transformer (preprocessor) compatible with the scikit-learn
preprocessing API with methods: fit, transform, fit_transform and inverse_transform.
ColumnTransformers are not allowed since they do not have inverse_transform method.
The transformation is applied to `y` before training the forecaster.
transformer_exog : object transformer (preprocessor), default `None`
An instance of a transformer (preprocessor) compatible with the scikit-learn
preprocessing API. The transformation is applied to `exog` before training the
forecaster. `inverse_transform` is not available when using ColumnTransformers.
weight_func : Callable, default `None`
Function that defines the individual weights for each sample based on the
index. For example, a function that assigns a lower weight to certain dates.
Ignored if `regressor` does not have the argument `sample_weight` in its `fit`
method. The resulting `sample_weight` cannot have negative values.
fit_kwargs : dict, default `None`
Additional arguments to be passed to the `fit` method of the regressor.
**New in version 0.8.0**
forecaster_id : str, int, default `None`
Name used as an identifier of the forecaster.
**New in version 0.7.0**
Attributes
----------
regressor : regressor or pipeline compatible with the scikit-learn API
An instance of a regressor or pipeline compatible with the scikit-learn API.
lags : numpy ndarray
Lags used as predictors.
transformer_y : object transformer (preprocessor), default `None`
transformer_y : object transformer (preprocessor)
An instance of a transformer (preprocessor) compatible with the scikit-learn
preprocessing API with methods: fit, transform, fit_transform and inverse_transform.
ColumnTransformers are not allowed since they do not have inverse_transform method.
The transformation is applied to `y` before training the forecaster.
transformer_exog : object transformer (preprocessor), default `None`
transformer_exog : object transformer (preprocessor)
An instance of a transformer (preprocessor) compatible with the scikit-learn
preprocessing API. The transformation is applied to `exog` before training the
forecaster. `inverse_transform` is not available when using ColumnTransformers.
weight_func : Callable
Function that defines the individual weights for each sample based on the
index. For example, a function that assigns a lower weight to certain dates.
Ignored if `regressor` does not have the argument `sample_weight` in its `fit`
method.
**New in version 0.6.0**
method. The resulting `sample_weight` cannot have negative values.
source_code_weight_func : str
Source code of the custom function used to create weights.
**New in version 0.6.0**
max_lag : int
Maximum value of lag included in `lags`.
window_size : int
Size of the window needed to create the predictors. It is equal to
`max_lag`.
Size of the window needed to create the predictors. It is equal to `max_lag`.
last_window : pandas Series
Last window the forecaster has seen during trained. It stores the
values needed to predict the next `step` right after the training data.
Last window the forecaster has seen during training. It stores the
values needed to predict the next `step` immediately after the training data.
index_type : type
Type of index of the input used in training.
index_freq : str
Frequency of Index of the input used in training.
training_range : pandas Index
First and last values of index of the data used during training.
included_exog : bool
If the forecaster has been trained using exogenous variable/s.
exog_type : type
Type of exogenous variable/s used in training.
Type of exogenous data (pandas Series or DataFrame) used in training.
exog_dtypes : dict
Type of each exogenous variable/s used in training. If `transformer_exog`
is used, the dtypes are calculated after the transformation.
exog_col_names : list
Names of columns of `exog` if `exog` used in training was a pandas
DataFrame.
X_train_col_names : list
Names of columns of the matrix created internally for training.
fit_kwargs : dict
Additional arguments to be passed to the `fit` method of the regressor.
**New in version 0.8.0**
in_sample_residuals : numpy ndarray
Residuals of the model when predicting training data. Only stored up to
1000 values. If `transformer_y` is not `None`, residuals are stored in the
transformed scale.
out_sample_residuals : numpy ndarray
Residuals of the model when predicting non training data. Only stored
up to 1000 values. If `transformer_y` is not `None`, residuals
are assumed to be in the transformed scale. Use `set_out_sample_residuals` to
set values.
are assumed to be in the transformed scale. Use `set_out_sample_residuals`
method to set values.
fitted : bool
Tag to identify if the regressor has been fitted (trained).
creation_date : str
Date of creation.
fit_date : str
Date of last fit.
skforcast_version : str
Version of skforecast library used to create the forecaster.
python_version : str
Version of python used to create the forecaster.
forecaster_id : str, int default `None`
Name used as an identifier of the forecaster.
**New in version 0.7.0**
"""
```

@@ -179,27 +160,30 @@ def preprocess_y(
y: pd.Series
) -> Tuple[np.ndarray, pd.Index]:
"""
Returns values and index of series separately. Index is overwritten
Return values and index of series separately. Index is overwritten
according to the next rules:
If index is of type DatetimeIndex and has frequency, nothing is
- If index is of type `DatetimeIndex` and has frequency, nothing is
changed.
If index is of type RangeIndex, nothing is changed.
If index is of type DatetimeIndex but has no frequency, a
RangeIndex is created.
If index is not of type DatetimeIndex, a RangeIndex is created.
- If index is of type `RangeIndex`, nothing is changed.
- If index is of type `DatetimeIndex` but has no frequency, a
`RangeIndex` is created.
- If index is not of type `DatetimeIndex`, a `RangeIndex` is created.
Parameters
----------
y : pandas Series
----------
y : pandas Series, pandas DataFrame
Time series.
return_values : bool, default `True`
If `True` return the values of `y` as numpy ndarray. This option is
intended to avoid copying data when it is not necessary.
Returns
Returns
-------
y_values : numpy ndarray
y_values : None, numpy ndarray
Numpy array with values of `y`.
y_index : pandas Index
Index of `y` modified according to the rules.
"""
```
Loading