class_docstr: Slope-by-segment transformation.
  
  Class to perform the Slope transformation on a time series
  dataframe. It splits a time series into num_intervals segments.
  Then within each segment, it performs a total least
  squares regression to extract the gradient of the segment.
  
  Parameters
  ----------
  num_intervals : int, number of approx equal segments
                  to split the time series into.
class_docstr_tok: ["Slope-by-segment","transformation",".","Class","to","perform","the","Slope","transformation","on","a","time","series","dataframe",".","It","splits","a","time","series","into","num_intervals","segments",".","Then","within","each","segment",",","it","performs","a","total","least","squares","regression","to","extract","the","gradient","of","the","segment",".","Parameters","--","--","--","--","--","num_intervals",":","int",",","number","of","approx","equal","segments","to","split","the","time","series","into","."]
docstr: Check values of parameters for Slope transformer.
  
  Throws
  ------
  ValueError or TypeError if a parameters input is invalid.
docstr_tok: ["Check","values","of","parameters","for","Slope","transformer",".","Throws","--","--","--","ValueError","or","TypeError","if","a","parameters","input","is","invalid","."]
code: def _check_parameters(self, n_timepoints):
      """Check values of parameters for Slope transformer.
  
      Throws
      ------
      ValueError or TypeError if a parameters input is invalid.
      """
      if isinstance(self.num_intervals, int):
          if self.num_intervals <= 0:
              raise ValueError(
                  "num_intervals must have the value \
                                    of at least 1"
              )
          if self.num_intervals > n_timepoints:
              raise ValueError(
                  "num_intervals cannot be higher than \
                                    subsequence_length"
              )
      else:
          raise TypeError(
              "num_intervals must be an 'int'. Found '"
              + type(self.num_intervals).__name__
              + "'instead."
          )
  
file_path: sktime/sktime/transformations/panel/slope.py
imports: import math
  import statistics
  import numpy
  import pandas
  from sktime.datatypes import convert
  from sktime.transformations.base import BaseTransformer
label_desc: Use image node_id 6 for calling the SlopeTransformer obj's underlying member method code with example usage: obj._check_parameters(n_timepoints) without return types