rnalysis.filtering.FoldChangeFilter.filter_percentile

FoldChangeFilter.filter_percentile(percentile: Fraction, opposite: bool = False, inplace: bool = True)

Removes all entries above the specified percentile. For example, if the percentile was 0.5, then all features whose value is above the median value will be filtered out.

Parameters
  • percentile (float between 0 and 1) – The percentile that all features above it will be filtered out.

  • opposite (bool) – If True, the output of the filtering will be the OPPOSITE of the specified (instead of filtering out X, the function will filter out anything BUT X). If False (default), the function will filter as expected.

  • inplace (bool (default=True)) – If True (default), filtering will be applied to the current Filter object. If False, the function will return a new CountFilter instance and the current instance will not be affected.

Returns

If inplace is False, returns a new and filtered instance of the Filter object.