starling.frontend.starling_viz.plot_protein_arcs
- plot_protein_arcs(sequence, links, color_dict={'A': '#171616', 'C': '#ffe70d', 'D': '#ff0d0d', 'E': '#ff0d0d', 'F': '#ff9d00', 'G': '#04700d', 'H': '#04700d', 'I': '#171616', 'K': '#2900f5', 'L': '#171616', 'M': '#171616', 'N': '#04700d', 'P': '#cf30b7', 'Q': '#04700d', 'R': '#2900f5', 'S': '#04700d', 'T': '#04700d', 'V': '#171616', 'W': '#ff9d00', 'Y': '#ff9d00'}, contacts=False, norm_lower_thresh=1, number_freq=10, filename=None)[source]
Plot a protein sequence with arcs connecting residues.
- Parameters:
sequence (str) – The protein sequence to plot.
links (list) – A list of links between residues. Each link is represented as a list with three elements: the start residue index, the end residue index, and the contact score. The contact score can either be a contact score (i.e. value between 0 and 1) reporting on the fraction of the ensemble in which the residues are in contact. It can also be a normalized distance; typically the ratio of the actual distances normalized by some limiting theoretical model distance.
contacts (bool, optional) – If True, the contact scores are interpreted as contact scores. If False, the contact scores are interpreted as distances. Default is False.
norm_lower_thresh (float, optional) – The threshold for the lower bound of the normalized distance. Default is 1.
number_freq (int) – The frequency of the number labels on the x-axis. Default is 10.
- Return type:
None, but if filename is provided, the plot is saved to disk.