calour.transforming.binarize

calour.transforming.binarize(exp: calour.experiment.Experiment, threshold=1, inplace=False)[source]

Binarize the data with a threshold.

It calls scikit-learn to do the real work.

Note

This function is also available as a class method Experiment.binarize()

Parameters:
  • exp (Experiment) – Input experiment object.
  • threshold (Numeric) – the cutoff value. Any values below or equal to this will be replaced by 0, above it by 1.
Returns:

Return type:

Experiment