stlearn.add.labels

stlearn.add.labels(adata: AnnData, label_filepath: str, index_col: int = 0, use_label: str | None = None, sep: str = '\t', copy: bool = False) AnnData | None[source]

Add label transfer results into AnnData object

Parameters:
  • adata (AnnData) – The data object to add L-R info into

  • label_filepath (str) – The path to the label transfer results file

  • use_label (str) – Where to store the label_transfer results, defaults to ‘predictions’ in adata.obs & ‘label_transfer’ in adata.uns.

  • sep (str) – Separator of the csv file

  • copy (bool) – Copy flag indicating copy or direct edit

Returns:

adata – The data object that L-R added into

Return type:

AnnData