EvalApp#

class biotite.application_v2.viennarna.EvalApp(path: PathLike[str] | str = 'RNAeval')[source]#

Bases: LocalApp

A handle to ViennaRNA’s RNAeval software.

Parameters:
pathstr, optional

Path of the RNAeval binary.

Notes

RNAeval ignores base pairs inside pseudoknots.

Examples

Evaluate the free energy of a secondary structure taken from a 3D structure:

>>> pdbx_file = BinaryCIFFile.read(path_to_structures / "4p5j.bcif")
>>> atoms = get_structure(pdbx_file, model=1)
>>> nucleotide = atoms[filter_nucleotides(atoms)]
>>> sequence = to_sequence(nucleotide)[0][0]
>>> atom_pairs = base_pairs(nucleotide)
>>> residue_pairs = get_residue_positions(nucleotide, atom_pairs.flatten()).reshape(-1, 2)
>>> # 'from_base_pairs()' drops non-canonical pairs that RNAeval cannot score
>>> folded = FoldedRNA.from_base_pairs(sequence, residue_pairs)
>>> result = EvalApp().run(folded).result()
>>> print(result.free_energy)
-23.6
run(folded: FoldedRNA | CofoldedRNA, temperature: float = 37, **kwargs: Any) → CommandSetup[FoldedRNA | CofoldedRNA]#

Evaluate the free energy of a secondary structure.

Both single strands and complexes of multiple strands are supported.

Parameters:
foldedFoldedRNA or CofoldedRNA

The RNA sequence(s) and secondary structure to evaluate. Its free_energy is ignored and may be None.

temperaturefloat, optional

The temperature (°C) to be assumed for the energy parameters.

**kwargs

Additional command line options.

Returns:
futureFuture of FoldedRNA or CofoldedRNA

A handle to the running computation. The returned structure equals the input, with its evaluated free energy attached, and is of the same type as folded.