solarforecastarbiter.validation.validator.detect_levels(x, count=3, num_bins=100)[source]

Detects plateau levels in data.

  • x (Series) – data to be processed
  • count (int) – number of plateaus to return
  • num_bins (int) – number of bins to use in histogram that finds plateau levels

levels (list of tuples) – (left, right) values of the interval in x with a detected plateau, in decreasing order of count of x values in the interval. List length is given by the kwarg count