code: def make_forecasting_problem(
      n_timepoints=50,
      all_positive=True,
      index_type=None,
      make_X=False,
      n_columns=1,
      random_state=None,
  ):
      """Return test data for forecasting tests.
  
      Parameters
      ----------
      n_timepoints : int, optional
          Length of data, by default 50
      all_positive : bool, optional
          Only positive values or not, by default True
      index_type : e.g. pd.PeriodIndex, optional
          pandas Index type, by default None
      make_X : bool, optional
          Should X data also be returned, by default False
      n_columns : int, optional
          Number of columns of y, by default 1
      random_state : inst, str, float, optional
          Set seed of random state, by default None
  
      Returns
      -------
      ps.Series, pd.DataFrame
          y, if not make_X
          y, X if make_X
      """
      y = _make_series(
          n_timepoints=n_timepoints,
          n_columns=n_columns,
          all_positive=all_positive,
          index_type=index_type,
          random_state=random_state,
      )
  
      if not make_X:
          return y
  
      X = _make_series(
          n_timepoints=n_timepoints,
          n_columns=2,
          all_positive=all_positive,
          index_type=index_type,
          random_state=random_state,
      )
      X.index = y.index
      return y, X
  
file_path: sktime/sktime/utils/_testing/forecasting.py
imports: import numpy
  import pandas
  from sktime.forecasting.base import ForecastingHorizon
  from sktime.utils._testing.series import _make_series
  from sktime.utils.validation.forecasting import check_fh
label_desc: Use image node_id 4 for calling a global function with example usage: make_forecasting_problem(n_timepoints, all_positive, index_type, make_X, n_columns, random_state) and returns: y,  X, y