codino.process.Converter

Module Contents

Classes

Converter

class codino.process.Converter.Converter[source]
cd_to_aa(self, first: dict, second: dict, third: dict, refresh: bool = True) dict[source]

Convert codon design to AA frequencies

Takes as input the nucleotide frequencies at each position in a codon, then calculates the predicted AA frequencies.

Parameters
  • first (dict) – nucleotide frequencies for first position.

  • second (dict) – nucleotide frequencies for second position.

  • third (dict) – nucleotide frequencies for third position.

  • refresh (bool) – Whether to refresh the frequencies in the Convertor

  • frequencies. (after obtaining the AA) –

    Returns:

    dict: Frequencies of the AA which are predicted to be generated from the codon design.

aa_to_cd(self, aa: dict, refresh: bool = True) tuple[source]

Convert AA frequencies to codon design

Parameters
  • aa (dict) – AA frequencies.

  • refresh (bool) – Whether to refresh the frequencies in the Convertor

  • design. (after obtaining the codon) –

    Returns:

    tuple: Estimated codon design to obtain the inputted AA frequencies.

_cd_to_ct(self) None[source]

Convert codon design into codon frequencies

_ct_to_aa(self) None[source]

Convert codon frequencies to AA frequencies

_aa_to_cd(self) None[source]

Convert AA frequencies to codon frequencies

refresh(self) None[source]

Refresh the frequencies in the codon design, codon table and AA table back to 0.