fetch_hospital¶
yohou.datasets.fetch_hospital(*, n_series=None, data_home=None, download_if_missing=True, n_retries=3, delay=1.0)
¶
Fetch the Hospital dataset from Monash/Zenodo.
767 monthly time series representing patient counts related to medical products from January 2000 to December 2006.
Parameters ¶
| Name | Type | Description | Default |
|---|---|---|---|
n_series
|
int or None
|
Maximum number of series to include. |
None
|
data_home
|
str, PathLike, or None
|
Specify another download and cache folder for the datasets.
By default all yohou data is stored in |
None
|
download_if_missing
|
bool
|
If |
True
|
n_retries
|
int
|
Number of retries when HTTP errors are encountered. |
3
|
delay
|
float
|
Number of seconds between retries. |
1.0
|
Returns ¶
| Type | Description |
|---|---|
Bunch
|
Dictionary-like object with the following attributes: frame : pl.DataFrame
DataFrame with |
See Also ¶
fetch_tourism_monthly: Monthly tourism series.fetch_dominick: Weekly retail profit series.get_data_home: Return the path of the data directory.
References ¶
- Godahewa, R., Bergmeir, C., Webb, G. I., Hyndman, R. J., & Montero-Manso, P. (2021). "Monash Time Series Forecasting Archive." Neural Information Processing Systems Track on Datasets and Benchmarks. https://doi.org/10.5281/zenodo.4656014
Examples ¶
>>> from yohou.datasets import fetch_hospital
>>> bunch = fetch_hospital()
>>> bunch.frame.columns[:2]
['time', 'T1__patients']
Source Code ¶
Source code in src/yohou/datasets/_fetchers.py
749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 | |
Tutorials¶
The following example notebooks use this component:
-
How to Use Lagged Forecasts as Features
Compare ForecastedFeatureForecaster strategies (actual, predicted, rewind) and split ratio tuning for chaining feature and target forecasters.