mutcleaner.cleaners.codon_dms_substitutions_custom_cleaners#

Functions

read_codon_dms_substitutions_dataset(data_path)

Read and combine all assays in the Codon DMS Substitutions Dataset.

mutcleaner.cleaners.codon_dms_substitutions_custom_cleaners.read_codon_dms_substitutions_dataset(data_path)[source]#

Read and combine all assays in the Codon DMS Substitutions Dataset.

The input can be either a directory or a ZIP archive containing MaveDB assay subdirectories. Each assay directory must contain data.csv and wt.fasta. The wild-type sequence and assay directory name are added to each dataset before all assays are concatenated.

Parameters:

data_path (Union[str, Path]) – Path to the dataset directory or ZIP archive.

Return type:

DataFrame

Returns:

Combined dataset containing all assays with name and wt_sequence columns.

Raises:
  • FileNotFoundError – If data_path does not exist.

  • ValueError – If no valid assay directories are found or an assay FASTA file does not contain exactly one sequence.