mosaicmpi.dataset.Dataset.calculate_cnmf_prediction_error

mosaicmpi.dataset.Dataset.calculate_cnmf_prediction_error#

Dataset.calculate_cnmf_prediction_error(k: int | Iterable | None = None) float | Series#

Calculate cNMF prediction error using the method in the original cNMF package.

Parameters:

k (Optional[Union[int, Iterable]], optional) – Specify one or more k values to calculate prediction error. Specify None to calculate for all available k. defaults to None

Raises:

ValueError – if invalid k is specified

Returns:

scalar or vector

Return type:

_type_