load_regression#

load_regression(name, split=None, extract_path=None, return_metadata=True)[source]#

Download/load forecasting problem from https://forecastingdata.org/.

Parameters:
namestring, file name to load from
extract_pathoptional (default = None)

Path of the location for the data file. If none, data is written to os.path.dirname(__file__)/data/<name>/

splitNone or str{“train”, “test”}, default=None

Whether to load the train or test partition of the problem. By default it loads both into a single dataset, otherwise it looks only for files of the format <name>_TRAIN.ts or <name>_TEST.ts.

return_metadataboolean, default = True

If True, returns a tuple (X, y, metadata)

Returns:
X: np.ndarray or list of np.ndarray
y: numpy array

The target response variable for each case in X

metadata: optional

returns the following meta data ‘problemname’,timestamps, missing,univariate,equallength. targetlabel should be true, and classlabel false

Raises:
Raise ValueException if the requested return type is not supported