code: def _compare(value, cv_median, cv_sigma, n_sigma):
      """Identify an outlier.
  
      Parameters
      ----------
      value : int/float
      cv_median : int/float
      cv_sigma : int/float
      n_sigma : int/float
  
      Returns
      -------
      int/float or np.nan
          Returns value if value it is not an outlier,
          else np.nan (or True/False if return_bool==True)
      """
      if np.abs(value - cv_median) > n_sigma * cv_sigma:
          return np.nan
      else:
          return value
  
file_path: sktime/sktime/transformations/series/outlier_detection.py
imports: import warnings
  from math import ceil
  import numpy
  import pandas
  from sktime.split import SlidingWindowSplitter
  from sktime.transformations.base import BaseTransformer
label_desc: Use image node_id 2 for calling a global function with example usage: _compare(value, cv_median, cv_sigma, n_sigma) and returns: np, value