stereo.core.StPipeline.quantile

StPipeline.quantile(layer=None, inplace=True, add_layer=False, res_key='quantile')[source]

Normalize the columns of X to each have the same distribution. Given an expression matrix of M genes by N samples, quantile normalization ensures all samples have the same spread of data (by construction).

Parameters:
  • layer (Optional[str]) – the key of layer to be used instead of the data.exp_matrix.

  • inplace (bool) – whether to replace the data.exp_matrix or save the result in data.layers.

  • add_layer (bool) – whether to save the result in data.layers simultaneously when inplace is True.

  • res_key (str) – the key to save the result in data.layers when inplace is False or add_layer is True.

Return type:

Depending on inplace, if True, the data will be replaced by those normalized.