CofoldedRNA#

class biotite.application_v2.viennarna.CofoldedRNA(sequences: list[NucleotideSequence], dot_bracket: str, free_energy: float | None = None, spans: list[tuple[int, int]] | None = None)[source]#

Bases: object

The predicted secondary structure of a complex of multiple ribonucleic acid strands.

Attributes:
sequenceslist of NucleotideSequence

The strands the complex is composed of.

dot_bracketstr

The secondary structure in dot-bracket notation with strands separated by &.

free_energyfloat, optional

The free energy (kcal/mol) of the complex.

spanslist of tuple (int, int), optional

If the dot_bracket describes only local parts of the strands, the (start, stop) range (0-based, exclusive stop) each segment occupies in the respective sequence. None means each segment spans its entire sequence.

base_pairs() → ndarray[tuple[N, C4], dtype[integer]]#

Get the base pairs of the complex.

Returns:
base_pairsndarray, shape=(n,4), dtype=int

Each row is (strand_i, pos_i, strand_j, pos_j), where the strand indices refer to sequences and the positions to the respective sequence.

classmethod from_single(single: FoldedRNA) → CofoldedRNA#

Create a CofoldedRNA from a single-strand FoldedRNA.

Parameters:
singleFoldedRNA

The single-strand structure.

Returns:
cofoldedCofoldedRNA

The equivalent complex containing a single strand.