class_docstr: Base class for forecasters that use sliding windows.
class_docstr_tok: ["Base","class","for","forecasters","that","use","sliding","windows","."]
docstr: Make in-sample prediction using single-step moving-cutoff predictions.
  
  Parameters
  ----------
  fh : np.array
      all non-positive (<= 0)
  X : pd.DataFrame
  
  Returns
  -------
  y_pred : pd.DataFrame or pd.Series
docstr_tok: ["Make","in-sample","prediction","using","single-step","moving-cutoff","predictions",".","Parameters","--","--","--","--","--","fh",":","np.array","all","non-positive","(","<","=","0",")","X",":","pd.DataFrame","Returns","--","--","--","-","y_pred",":","pd.DataFrame","or","pd.Series"]
code: def _predict_in_sample(self, fh, X=None, **kwargs):
      """Make in-sample prediction using single-step moving-cutoff predictions.
  
      Parameters
      ----------
      fh : np.array
          all non-positive (<= 0)
      X : pd.DataFrame
  
      Returns
      -------
      y_pred : pd.DataFrame or pd.Series
      """
      y_train = self._y
  
      # generate cutoffs from forecasting horizon, note that cutoffs are
      # still based on integer indexes, so that they can be used with .iloc
      cutoffs = fh.to_relative(self.cutoff) + len(y_train) - 2
      cv = CutoffSplitter(
          cutoffs, fh=1, window_length=self.window_length_
      )
      return self._predict_moving_cutoff(
          y_train, cv, X, update_params=False
      )
  
file_path: sktime/sktime/forecasting/base/_sktime.py
imports: import numpy
  import pandas
  from sktime.forecasting.base._base import BaseForecaster
  from sktime.split import CutoffSplitter
  from sktime.utils.datetime import _shift
label_desc: Use image node_id 5 for calling the _BaseWindowForecaster obj's underlying member method code with example usage: obj._predict_in_sample(fh, X) and returns: self