pytometry.io.read_and_merge

Contents

pytometry.io.read_and_merge#

pytometry.io.read_and_merge(files, sample_ids=None, sample_id_from_filename=False, sample_id_index=0, sample_id_sep='_')#

Read and merge multiple FCS files into a single AnnData object.

Parameters:
  • files (str | list[str]) – either a list of file paths or a directory path

  • sample_ids (list[Any] | None (default: None)) – list of sample ids to use as a column in the AnnData object

  • sample_id_from_filename (bool (default: False)) – whether to use the filename to extract the sample id

  • sample_id_index (int (default: 0)) – which index of the filename to use as the sample id

  • sample_id_sep (str (default: '_')) – separator to use when splitting the filename

Return type:

AnnData

Returns:

Merged AnnData object