CodonU.analyzer.gravy_comp

Module Contents

Functions

calculate_gravy(→ dict[str, float] | float)

Calculates the gravy score for a given protein sequence according to Kyte and Doolittle (1982)

CodonU.analyzer.gravy_comp.calculate_gravy(handle: str, min_len_threshold: int = 66, gene_analysis: bool = False, save_file: bool = False, file_name: str = 'GRAVY_report', folder_path: str = 'Report') dict[str, float] | float

Calculates the gravy score for a given protein sequence according to Kyte and Doolittle (1982)

Parameters:
  • handle – Handle to the file, or the filename as a string

  • min_len_threshold – Minimum length of protein sequence to be considered as gene

  • gene_analysis – Option if gene analysis (True) or genome analysis (False) (optional)

  • save_file – Option for saving the values in xlsx format (Optional)

  • file_name – Intended file name (Optional)

  • folder_path – Folder path where image should be saved (optional)

Returns:

The GRAVY score of given sequence if gene_analysis is false, else the dictionary containing gene number and corresponding GRAVY score