tidytcells.tcr
Functions to clean and standardise TCR gene data.
Functions
- tidytcells.tcr.standardise(gene: str | None = None, species: str = 'homosapiens', enforce_functional: bool = False, precision: str = 'allele', suppress_warnings: bool = False, gene_name: str | None = None) str
Attempt to standardise a TCR gene name to be IMGT-compliant.
- Parameters:
gene (
str) – Potentially non-standardised TCR gene name.species (
str) – Species to which the TCR gene belongs (see Supported species and species strings). Defaults to'homosapiens'.enforce_functional (
bool) – IfTrue, disallows TCR genes that are recognised by IMGT but are marked as non-functional (ORF or pseudogene). Defaults toFalse.precision (
str) – The maximum level of precision to standardise to.'allele'standardises to the maximum precision possible.'gene'standardises only to the level of the gene. Defaults to'allele'.suppress_warnings (
bool) – Disable warnings that are usually emitted when standardisation fails. Defaults toFalse.gene_name (
str) – Alias for the parametergene.
- Returns:
If the specified
speciesis supported, andgenecould be standardised, then return the standardised gene name. Ifspeciesis unsupported, then the function does not attempt to standardise , and returns the unalteredgenestring. Else returnsNone.- Return type:
strorNone
- tidytcells.tcr.standardize(*args, **kwargs)
Alias for
tidytcells.tcr.standardise().