Represents the raw structure ensemble data for an RNA. More...
#include <rna_ensemble.hh>
Public Member Functions | |
RnaEnsemble (const MultipleAlignment &ma, const PFoldParams ¶ms, bool inLoopProbs, bool use_alifold=true) | |
folding constructor (from sequence or multiple alignment) | |
RnaEnsemble (const RnaEnsemble &rna_ensemble) | |
copy constructor | |
RnaEnsemble & | operator= (const RnaEnsemble &rna_ensemble) |
assignment operator | |
virtual | ~RnaEnsemble () |
Clean up. | |
bool | has_base_pair_probs () const |
Availability of pair probabilities. | |
bool | has_stacking_probs () const |
Availability of stacking probabilities. | |
bool | has_in_loop_probs () const |
Availability of "in loop" probabilities. | |
const MultipleAlignment & | multiple_alignment () const |
Get the sequence. | |
size_type | length () const |
get length of sequence | |
double | min_free_energy () const |
get minimum free energy | |
std::string | min_free_energy_structure () const |
get minimum free energy structure | |
double | arc_prob (size_type i, size_type j) const |
Get arc probability. | |
double | arc_2_prob (size_type i, size_type j) const |
Get joint probability of stacked arcs. | |
double | arc_stack_prob (size_type i, size_type j) const |
Get conditional propability that a base pair is stacked. | |
double | paired_upstream_prob (size_type i) const |
Probability that a position is paired upstream. | |
double | paired_downstream_prob (size_type i) const |
Probability that a position is paired downstream. | |
double | unpaired_prob (size_type i) const |
Unpaired probability. | |
double | unpaired_in_loop_prob (size_type k, size_type i, size_type j) const |
Unpaired probabilty of base in a specified loop. | |
double | unpaired_external_prob (size_type k) const |
Unpaired probabilty of base in external 'loop'. | |
double | arc_in_loop_prob (size_type ip, size_type jp, size_type i, size_type j) const |
Probabilty of base pair in a specified loop. | |
double | arc_external_prob (size_type i, size_type j) const |
Probability of base pair in the external 'loop'. |
Represents the raw structure ensemble data for an RNA.
Can partition fold RNAs, stores dynamic programming matrices of the McCaskill algorithm. Computes special "in loop" probabilities.
Interprets structure annotation of the multiple alignment as structure constraint string; if existant, the string has to be valid! Fixed structure annotation is ignored.
LocARNA::RnaEnsemble::RnaEnsemble | ( | const MultipleAlignment & | ma, |
const PFoldParams & | params, | ||
bool | inLoopProbs, | ||
bool | use_alifold = true |
||
) |
folding constructor (from sequence or multiple alignment)
Computes ensemble partition functions and probabilities using McCaskill's algorithm. Optionally computes additional matrices required for in-loop probabilities.
ma | the RNA sequence or alignment as MultipleAlignment object |
params | pfolding parameters |
inLoopProbs | whether in loop probabilities should be made available |
use_alifold | whether alifold should be used |
LocARNA::RnaEnsemble::RnaEnsemble | ( | const RnaEnsemble & | rna_ensemble | ) |
copy constructor
rna_ensemble | object to be copied Copies implementation object (not only pointer) |
LocARNA::RnaEnsemble::~RnaEnsemble | ( | ) | [virtual] |
Clean up.
In most cases does nothing. If McCaskill matrices are kept, they are freed.
double LocARNA::RnaEnsemble::arc_2_prob | ( | size_type | i, |
size_type | j | ||
) | const |
Get joint probability of stacked arcs.
i | left sequence position |
j | right sequence position |
double LocARNA::RnaEnsemble::arc_external_prob | ( | size_type | i, |
size_type | j | ||
) | const |
Probability of base pair in the external 'loop'.
i | left end of inner base pair |
j | right end of inner base pair |
double LocARNA::RnaEnsemble::arc_in_loop_prob | ( | size_type | ip, |
size_type | jp, | ||
size_type | i, | ||
size_type | j | ||
) | const |
Probabilty of base pair in a specified loop.
ip | left end of inner base pair |
jp | right end of inner base pair |
i | left end of loop enclosing base pair |
j | right end of loop enclosing base pair |
Computes the joint probability that there is a base pair (i,j) and a base pair (k,l) (i<k<l<j) that is inner base pair of the loop closed by (i,j).
double LocARNA::RnaEnsemble::arc_prob | ( | size_type | i, |
size_type | j | ||
) | const |
Get arc probability.
i | left sequence position |
j | right sequence position |
double LocARNA::RnaEnsemble::arc_stack_prob | ( | size_type | i, |
size_type | j | ||
) | const |
Get conditional propability that a base pair is stacked.
i | left sequence position |
j | right sequence position |
bool LocARNA::RnaEnsemble::has_base_pair_probs | ( | ) | const |
Availability of pair probabilities.
bool LocARNA::RnaEnsemble::has_in_loop_probs | ( | ) | const |
Availability of "in loop" probabilities.
bool LocARNA::RnaEnsemble::has_stacking_probs | ( | ) | const |
Availability of stacking probabilities.
size_type LocARNA::RnaEnsemble::length | ( | ) | const |
get length of sequence
double LocARNA::RnaEnsemble::min_free_energy | ( | ) | const |
get minimum free energy
std::string LocARNA::RnaEnsemble::min_free_energy_structure | ( | ) | const |
get minimum free energy structure
const MultipleAlignment & LocARNA::RnaEnsemble::multiple_alignment | ( | ) | const |
Get the sequence.
RnaEnsemble& LocARNA::RnaEnsemble::operator= | ( | const RnaEnsemble & | rna_ensemble | ) |
assignment operator
rna_ensemble | object to be assigned Assigns implementation object (not only pointer) |
double LocARNA::RnaEnsemble::paired_downstream_prob | ( | size_type | i | ) | const |
Probability that a position is paired downstream.
i | sequence position |
double LocARNA::RnaEnsemble::paired_upstream_prob | ( | size_type | i | ) | const |
Probability that a position is paired upstream.
i | sequence position |
double LocARNA::RnaEnsemble::unpaired_external_prob | ( | size_type | k | ) | const |
Unpaired probabilty of base in external 'loop'.
k | unpaired sequence position |
double LocARNA::RnaEnsemble::unpaired_in_loop_prob | ( | size_type | k, |
size_type | i, | ||
size_type | j | ||
) | const |
Unpaired probabilty of base in a specified loop.
k | unpaired sequence position |
i | left end of loop enclosing base pair |
j | right end of loop enclosing base pair |
Computes the joint probability that there is a base pair (i,j) and a base k (i<k<j) is unpaired such that there is no base pair i<i'<k<j'<j.
double LocARNA::RnaEnsemble::unpaired_prob | ( | size_type | i | ) | const |
Unpaired probability.
i | sequence position |