Free Energy Evaluation#
Energy Parameters#
Functions related to the set of thermodynamic Nearest Neighbor energy parameters.
Defines
-
VRNA_GQUAD_MAX_STACK_SIZE#
#include <ViennaRNA/params/basic.h>
-
VRNA_GQUAD_MIN_STACK_SIZE#
#include <ViennaRNA/params/basic.h>
-
VRNA_GQUAD_MAX_LINKER_LENGTH#
#include <ViennaRNA/params/basic.h>
-
VRNA_GQUAD_MIN_LINKER_LENGTH#
#include <ViennaRNA/params/basic.h>
-
VRNA_GQUAD_MIN_BOX_SIZE#
#include <ViennaRNA/params/basic.h>
-
VRNA_GQUAD_MAX_BOX_SIZE#
#include <ViennaRNA/params/basic.h>
Typedefs
-
typedef struct vrna_param_s vrna_param_t#
Typename for the free energy parameter data structure vrna_params.
#include <ViennaRNA/params/basic.h>
-
typedef struct vrna_exp_param_s vrna_exp_param_t#
Typename for the Boltzmann factor data structure vrna_exp_params.
#include <ViennaRNA/params/basic.h>
-
typedef struct vrna_param_s paramT#
Old typename of vrna_param_s.
#include <ViennaRNA/params/basic.h>
- Deprecated:
Use vrna_param_t instead!
-
typedef struct vrna_exp_param_s pf_paramT#
Old typename of vrna_exp_param_s.
#include <ViennaRNA/params/basic.h>
- Deprecated:
Use vrna_exp_param_t instead!
Functions
-
void vrna_params_dirty(void)#
Set internal parameters-dirty flag.
#include <ViennaRNA/params/basic.h>
Calling this function sets an internal flag that instructs vrna_params() or vrna_exp_params() to actually re-read the underlying energy parameters before creating the parameters data structure.
Calling this function might be useful after tempering with any of the global energy parameter variables. Loading energy parameters via one of the vrna_params_load() or vrna_params_load_from_string() functions will call this one automatically.
-
vrna_param_t *vrna_params(vrna_md_t *md)#
Get a data structure containing prescaled free energy parameters.
#include <ViennaRNA/params/basic.h>
If a NULL pointer is passed for the model details parameter, the default model parameters are stored within the requested vrna_param_t structure.
See also
- Parameters:
md – A pointer to the model details to store inside the structure (Maybe NULL)
- Returns:
A pointer to the memory location where the requested parameters are stored
-
vrna_param_t *vrna_params_copy(vrna_param_t *par)#
Get a copy of the provided free energy parameters.
#include <ViennaRNA/params/basic.h>
If NULL is passed as parameter, a default set of energy parameters is created and returned.
See also
- Parameters:
par – The free energy parameters that are to be copied (Maybe NULL)
- Returns:
A copy or a default set of the (provided) parameters
-
vrna_exp_param_t *vrna_exp_params(vrna_md_t *md)#
Get a data structure containing prescaled free energy parameters already transformed to Boltzmann factors.
#include <ViennaRNA/params/basic.h>
This function returns a data structure that contains all necessary precomputed energy contributions for each type of loop.
In contrast to vrna_params(), the free energies within this data structure are stored as their Boltzmann factors, i.e.
\( exp(-E / kT) \)
where \( E \) is the free energy.
If a NULL pointer is passed for the model details parameter, the default model parameters are stored within the requested vrna_exp_param_t structure.
See also
vrna_md_t, vrna_md_set_default(), vrna_params(), vrna_rescale_pf_params()
- Parameters:
md – A pointer to the model details to store inside the structure (Maybe NULL)
- Returns:
A pointer to the memory location where the requested parameters are stored
-
vrna_exp_param_t *vrna_exp_params_comparative(unsigned int n_seq, vrna_md_t *md)#
Get a data structure containing prescaled free energy parameters already transformed to Boltzmann factors (alifold version).
#include <ViennaRNA/params/basic.h>
If a NULL pointer is passed for the model details parameter, the default model parameters are stored within the requested vrna_exp_param_t structure.
See also
vrna_md_t, vrna_md_set_default(), vrna_exp_params(), vrna_params()
- Parameters:
n_seq – The number of sequences in the alignment
md – A pointer to the model details to store inside the structure (Maybe NULL)
- Returns:
A pointer to the memory location where the requested parameters are stored
-
vrna_exp_param_t *vrna_exp_params_copy(vrna_exp_param_t *par)#
Get a copy of the provided free energy parameters (provided as Boltzmann factors).
#include <ViennaRNA/params/basic.h>
If NULL is passed as parameter, a default set of energy parameters is created and returned.
See also
- Parameters:
par – The free energy parameters that are to be copied (Maybe NULL)
- Returns:
A copy or a default set of the (provided) parameters
-
void vrna_params_subst(vrna_fold_compound_t *fc, vrna_param_t *par)#
Update/Reset energy parameters data structure within a vrna_fold_compound_t.
#include <ViennaRNA/params/basic.h>
Passing NULL as second argument leads to a reset of the energy parameters within fc to their default values. Otherwise, the energy parameters provided will be copied over into fc.
- SWIG Wrapper Notes:
This function is attached to vrna_fc_s objects as overloaded
params_subst()method.When no parameter is passed, the resulting action is the same as passing
NULLas second parameter to vrna_params_subst(), i.e. resetting the parameters to the global defaults. See, e.g.RNA.fold_compound.params_subst()in the The RNA Python module.
See also
- Parameters:
fc – The vrna_fold_compound_t that is about to receive updated energy parameters
par – The energy parameters used to substitute those within fc (Maybe NULL)
-
void vrna_exp_params_subst(vrna_fold_compound_t *fc, vrna_exp_param_t *params)#
Update the energy parameters for subsequent partition function computations.
#include <ViennaRNA/params/basic.h>
This function can be used to properly assign new energy parameters for partition function computations to a vrna_fold_compound_t. For this purpose, the data of the provided pointer
paramswill be copied intofcand a recomputation of the partition function scaling factor is issued, if thepf_scaleattribute ofparamsis less than1.0.Passing NULL as second argument leads to a reset of the energy parameters within fc to their default values
- SWIG Wrapper Notes:
This function is attached to vrna_fc_s objects as overloaded
exp_params_subst()method.When no parameter is passed, the resulting action is the same as passing
NULLas second parameter to vrna_exp_params_subst(), i.e. resetting the parameters to the global defaults. See, e.g.RNA.fold_compound.exp_params_subst()in the The RNA Python module.
See also
vrna_exp_params_reset(), vrna_exp_params_rescale(), vrna_exp_param_t, vrna_md_t, vrna_exp_params()
- Parameters:
fc – The fold compound data structure
params – A pointer to the new energy parameters
-
void vrna_exp_params_rescale(vrna_fold_compound_t *fc, double *mfe)#
Rescale Boltzmann factors for partition function computations.
#include <ViennaRNA/params/basic.h>
This function may be used to (automatically) rescale the Boltzmann factors used in partition function computations. Since partition functions over subsequences can easily become extremely large, the RNAlib internally rescales them to avoid numerical over- and/or underflow. Therefore, a proper scaling factor \(s\) needs to be chosen that in turn is then used to normalize the corresponding partition functions \(\hat{q}[i,j] = q[i,j] / s^{(j-i+1)}\).
This function provides two ways to automatically adjust the scaling factor.
Automatic guess
Automatic adjustment according to MFE
Passing
NULLas second parameter activates the automatic guess mode. Here, the scaling factor is recomputed according to a mean free energy of184.3*lengthcal for random sequences.
On the other hand, if the MFE for a sequence is known, it can be used to recompute a more robust scaling factor, since it represents the lowest free energy of the entire ensemble of structures, i.e. the highest Boltzmann factor. To activate this second mode of
automatic adjustment according to MFE, a pointer to the MFE value needs to be passed as second argument. This value is then taken to compute the scaling factor as \( s = exp((sfact * MFE) / kT / length )\), where sfact is an additional scaling weight located in the vrna_md_t data structure ofexp_paramsinfc.The computed scaling factor \(s\) will be stored as
pf_scaleattribute of theexp_paramsdata structure infc.- SWIG Wrapper Notes:
This function is attached to vrna_fc_s objects as overloaded
exp_params_rescale()method.When no parameter is passed to this method, the resulting action is the same as passing
NULLas second parameter to vrna_exp_params_rescale(), i.e. default scaling of the partition function. Passing an energy in kcal/mol, e.g. as retrieved by a previous call to themfe()method, instructs all subsequent calls to scale the partition function accordingly. See, e.g.RNA.fold_compound.exp_params_rescale()in the The RNA Python module.
Note
This recomputation only takes place if the
pf_scaleattribute of theexp_paramsdata structure contained infchas a value below1.0.- Parameters:
fc – The fold compound data structure
mfe – A pointer to the MFE (in kcal/mol) or NULL
-
void vrna_params_reset(vrna_fold_compound_t *fc, vrna_md_t *md)#
Reset free energy parameters within a vrna_fold_compound_t according to provided, or default model details.
#include <ViennaRNA/params/basic.h>
This function allows one to rescale free energy parameters for subsequent structure prediction or evaluation according to a set of model details, e.g. temperature values. To do so, the caller provides either a pointer to a set of model details to be used for rescaling, or NULL if global default setting should be used.
- SWIG Wrapper Notes:
This function is attached to vrna_fc_s objects as overloaded
params_reset()method.When no parameter is passed to this method, the resulting action is the same as passing
NULLas second parameter to vrna_params_reset(), i.e. global default model settings are used. Passing an object of type vrna_md_s resets the fold compound according to the specifications stored within the vrna_md_s object. See, e.g.RNA.fold_compound.params_reset()in the The RNA Python module.
See also
vrna_exp_params_reset(), vrna_params_subs()
- Parameters:
fc – The fold compound data structure
md – A pointer to the new model details (or NULL for reset to defaults)
-
void vrna_exp_params_reset(vrna_fold_compound_t *fc, vrna_md_t *md)#
Reset Boltzmann factors for partition function computations within a vrna_fold_compound_t according to provided, or default model details.
#include <ViennaRNA/params/basic.h>
This function allows one to rescale Boltzmann factors for subsequent partition function computations according to a set of model details, e.g. temperature values. To do so, the caller provides either a pointer to a set of model details to be used for rescaling, or NULL if global default setting should be used.
- SWIG Wrapper Notes:
This function is attached to vrna_fc_s objects as overloaded
exp_params_reset()method.When no parameter is passed to this method, the resulting action is the same as passing
NULLas second parameter to vrna_exp_params_reset(), i.e. global default model settings are used. Passing an object of type vrna_md_s resets the fold compound according to the specifications stored within the vrna_md_s object. See, e.g.RNA.fold_compound.exp_params_reset()in the The RNA Python module.
- Parameters:
fc – The fold compound data structure
md – A pointer to the new model details (or NULL for reset to defaults)
-
void vrna_params_prepare(vrna_fold_compound_t *fc, unsigned int options)#
#include <ViennaRNA/params/basic.h>
-
vrna_param_t *get_parameter_copy(vrna_param_t *par)#
#include <ViennaRNA/params/basic.h>
-
vrna_exp_param_t *get_scaled_pf_parameters(void)#
#include <ViennaRNA/params/basic.h>
get a data structure of type vrna_exp_param_t which contains the Boltzmann weights of several energy parameters scaled according to the current temperature
- Deprecated:
Use vrna_exp_params() instead!
- Returns:
The data structure containing Boltzmann weights for use in partition function calculations
-
vrna_exp_param_t *get_boltzmann_factors(double temperature, double betaScale, vrna_md_t md, double pf_scale)#
Get precomputed Boltzmann factors of the loop type dependent energy contributions with independent thermodynamic temperature.
#include <ViennaRNA/params/basic.h>
This function returns a data structure that contains all necessary precalculated Boltzmann factors for each loop type contribution.
In contrast to
get_scaled_pf_parameters(), this function enables setting of independent temperatures for both, the individual energy contributions as well as the thermodynamic temperature used in \( exp(-\Delta G / kT) \)- Deprecated:
Use vrna_exp_params() instead!
- Parameters:
temperature – The temperature in degrees Celcius used for (re-)scaling the energy contributions
betaScale – A scaling value that is used as a multiplication factor for the absolute temperature of the system
md – The model details to be used
pf_scale – The scaling factor for the Boltzmann factors
- Returns:
A set of precomputed Boltzmann factors
-
vrna_exp_param_t *get_boltzmann_factor_copy(vrna_exp_param_t *parameters)#
Get a copy of already precomputed Boltzmann factors.
#include <ViennaRNA/params/basic.h>
- Deprecated:
Use vrna_exp_params_copy() instead!
- Parameters:
parameters – The input data structure that shall be copied
- Returns:
A copy of the provided Boltzmann factor data set
-
vrna_exp_param_t *get_scaled_alipf_parameters(unsigned int n_seq)#
Get precomputed Boltzmann factors of the loop type dependent energy contributions (alifold variant).
#include <ViennaRNA/params/basic.h>
- Deprecated:
Use vrna_exp_params_comparative() instead!
-
vrna_exp_param_t *get_boltzmann_factors_ali(unsigned int n_seq, double temperature, double betaScale, vrna_md_t md, double pf_scale)#
Get precomputed Boltzmann factors of the loop type dependent energy contributions (alifold variant) with independent thermodynamic temperature.
#include <ViennaRNA/params/basic.h>
- Deprecated:
Use vrna_exp_params_comparative() instead!
-
vrna_param_t *scale_parameters(void)#
Get precomputed energy contributions for all the known loop types.
#include <ViennaRNA/params/basic.h>
- Deprecated:
Use vrna_params() instead!
Note
OpenMP: This function relies on several global model settings variables and thus is not to be considered threadsafe. See get_scaled_parameters() for a completely threadsafe implementation.
- Returns:
A set of precomputed energy contributions
-
vrna_param_t *get_scaled_parameters(double temperature, vrna_md_t md)#
Get precomputed energy contributions for all the known loop types.
#include <ViennaRNA/params/basic.h>
Call this function to retrieve precomputed energy contributions, i.e. scaled according to the temperature passed. Furthermore, this function assumes a data structure that contains the model details as well, such that subsequent folding recursions are able to retrieve the correct model settings
- Deprecated:
Use vrna_params() instead!
See also
- Parameters:
temperature – The temperature in degrees Celcius
md – The model details
- Returns:
precomputed energy contributions and model settings
-
vrna_param_t *copy_parameters(void)#
#include <ViennaRNA/params/basic.h>
-
vrna_param_t *set_parameters(vrna_param_t *dest)#
#include <ViennaRNA/params/basic.h>
-
vrna_exp_param_t *scale_pf_parameters(void)#
#include <ViennaRNA/params/basic.h>
-
vrna_exp_param_t *copy_pf_param(void)#
#include <ViennaRNA/params/basic.h>
-
vrna_exp_param_t *set_pf_param(vrna_param_t *dest)#
#include <ViennaRNA/params/basic.h>
-
float **get_ribosum(const char **Alseq, int n_seq, int length)#
Retrieve a RiboSum Scoring Matrix for a given Alignment.
#include <ViennaRNA/params/ribosum.h>
-
struct vrna_param_s#
- #include <ViennaRNA/params/basic.h>
The datastructure that contains temperature scaled energy parameters.
Public Members
-
int id#
#include <ViennaRNA/params/basic.h>
-
int stack[7 + 1][7 + 1]#
#include <ViennaRNA/params/basic.h>
-
int hairpin[31]#
#include <ViennaRNA/params/basic.h>
-
int bulge[30 + 1]#
#include <ViennaRNA/params/basic.h>
-
int internal_loop[30 + 1]#
#include <ViennaRNA/params/basic.h>
-
int mismatchExt[7 + 1][5][5]#
#include <ViennaRNA/params/basic.h>
-
int mismatchI[7 + 1][5][5]#
#include <ViennaRNA/params/basic.h>
-
int mismatch1nI[7 + 1][5][5]#
#include <ViennaRNA/params/basic.h>
-
int mismatch23I[7 + 1][5][5]#
#include <ViennaRNA/params/basic.h>
-
int mismatchH[7 + 1][5][5]#
#include <ViennaRNA/params/basic.h>
-
int mismatchM[7 + 1][5][5]#
#include <ViennaRNA/params/basic.h>
-
int dangle5[7 + 1][5]#
#include <ViennaRNA/params/basic.h>
-
int dangle3[7 + 1][5]#
#include <ViennaRNA/params/basic.h>
-
int int11[7 + 1][7 + 1][5][5]#
#include <ViennaRNA/params/basic.h>
-
int int21[7 + 1][7 + 1][5][5][5]#
#include <ViennaRNA/params/basic.h>
-
int int22[7 + 1][7 + 1][5][5][5][5]#
#include <ViennaRNA/params/basic.h>
-
int ninio[5]#
#include <ViennaRNA/params/basic.h>
-
double lxc#
#include <ViennaRNA/params/basic.h>
-
int MLbase#
#include <ViennaRNA/params/basic.h>
-
int MLintern[7 + 1]#
#include <ViennaRNA/params/basic.h>
-
int MLclosing#
#include <ViennaRNA/params/basic.h>
-
int TerminalAU#
#include <ViennaRNA/params/basic.h>
-
int DuplexInit#
#include <ViennaRNA/params/basic.h>
-
int Tetraloop_E[200]#
#include <ViennaRNA/params/basic.h>
-
char Tetraloops[1401]#
#include <ViennaRNA/params/basic.h>
-
int Triloop_E[40]#
#include <ViennaRNA/params/basic.h>
-
char Triloops[241]#
#include <ViennaRNA/params/basic.h>
-
int Hexaloop_E[40]#
#include <ViennaRNA/params/basic.h>
-
char Hexaloops[1801]#
#include <ViennaRNA/params/basic.h>
-
int TripleC#
#include <ViennaRNA/params/basic.h>
-
int MultipleCA#
#include <ViennaRNA/params/basic.h>
-
int MultipleCB#
#include <ViennaRNA/params/basic.h>
-
int gquad[7 + 1][3 * 15 + 1]#
#include <ViennaRNA/params/basic.h>
-
int gquadLayerMismatch#
#include <ViennaRNA/params/basic.h>
-
unsigned int gquadLayerMismatchMax#
#include <ViennaRNA/params/basic.h>
-
double temperature#
Temperature used for loop contribution scaling.
#include <ViennaRNA/params/basic.h>
-
vrna_md_t model_details#
Model details to be used in the recursions.
#include <ViennaRNA/params/basic.h>
-
char param_file[256]#
The filename the parameters were derived from, or empty string if they represent the default.
#include <ViennaRNA/params/basic.h>
-
int SaltStack#
#include <ViennaRNA/params/basic.h>
-
int SaltLoop[30 + 2]#
#include <ViennaRNA/params/basic.h>
-
double SaltLoopDbl[30 + 2]#
#include <ViennaRNA/params/basic.h>
-
int SaltMLbase#
#include <ViennaRNA/params/basic.h>
-
int SaltMLintern#
#include <ViennaRNA/params/basic.h>
-
int SaltMLclosing#
#include <ViennaRNA/params/basic.h>
-
int SaltDPXInit#
#include <ViennaRNA/params/basic.h>
-
int id#
-
struct vrna_exp_param_s#
- #include <ViennaRNA/params/basic.h>
The data structure that contains temperature scaled Boltzmann weights of the energy parameters.
Public Members
-
int id#
An identifier for the data structure.
#include <ViennaRNA/params/basic.h>
- Deprecated:
This attribute will be removed in version 3
-
double expstack[7 + 1][7 + 1]#
#include <ViennaRNA/params/basic.h>
-
double exphairpin[31]#
#include <ViennaRNA/params/basic.h>
-
double expbulge[30 + 1]#
#include <ViennaRNA/params/basic.h>
-
double expinternal[30 + 1]#
#include <ViennaRNA/params/basic.h>
-
double expmismatchExt[7 + 1][5][5]#
#include <ViennaRNA/params/basic.h>
-
double expmismatchI[7 + 1][5][5]#
#include <ViennaRNA/params/basic.h>
-
double expmismatch23I[7 + 1][5][5]#
#include <ViennaRNA/params/basic.h>
-
double expmismatch1nI[7 + 1][5][5]#
#include <ViennaRNA/params/basic.h>
-
double expmismatchH[7 + 1][5][5]#
#include <ViennaRNA/params/basic.h>
-
double expmismatchM[7 + 1][5][5]#
#include <ViennaRNA/params/basic.h>
-
double expdangle5[7 + 1][5]#
#include <ViennaRNA/params/basic.h>
-
double expdangle3[7 + 1][5]#
#include <ViennaRNA/params/basic.h>
-
double expint11[7 + 1][7 + 1][5][5]#
#include <ViennaRNA/params/basic.h>
-
double expint21[7 + 1][7 + 1][5][5][5]#
#include <ViennaRNA/params/basic.h>
-
double expint22[7 + 1][7 + 1][5][5][5][5]#
#include <ViennaRNA/params/basic.h>
-
double expninio[5][30 + 1]#
#include <ViennaRNA/params/basic.h>
-
double lxc#
#include <ViennaRNA/params/basic.h>
-
double expMLbase#
#include <ViennaRNA/params/basic.h>
-
double expMLintern[7 + 1]#
#include <ViennaRNA/params/basic.h>
-
double expMLclosing#
#include <ViennaRNA/params/basic.h>
-
double expTermAU#
#include <ViennaRNA/params/basic.h>
-
double expDuplexInit#
#include <ViennaRNA/params/basic.h>
-
double exptetra[40]#
#include <ViennaRNA/params/basic.h>
-
double exptri[40]#
#include <ViennaRNA/params/basic.h>
-
double exphex[40]#
#include <ViennaRNA/params/basic.h>
-
char Tetraloops[1401]#
#include <ViennaRNA/params/basic.h>
-
double expTriloop[40]#
#include <ViennaRNA/params/basic.h>
-
char Triloops[241]#
#include <ViennaRNA/params/basic.h>
-
char Hexaloops[1801]#
#include <ViennaRNA/params/basic.h>
-
double expTripleC#
#include <ViennaRNA/params/basic.h>
-
double expMultipleCA#
#include <ViennaRNA/params/basic.h>
-
double expMultipleCB#
#include <ViennaRNA/params/basic.h>
-
double expgquad[7 + 1][3 * 15 + 1]#
#include <ViennaRNA/params/basic.h>
-
double expgquadLayerMismatch#
#include <ViennaRNA/params/basic.h>
-
unsigned int gquadLayerMismatchMax#
#include <ViennaRNA/params/basic.h>
-
double kT#
#include <ViennaRNA/params/basic.h>
-
double pf_scale#
Scaling factor to avoid over-/underflows.
#include <ViennaRNA/params/basic.h>
-
double temperature#
Temperature used for loop contribution scaling.
#include <ViennaRNA/params/basic.h>
-
double alpha#
Scaling factor for the thermodynamic temperature.
#include <ViennaRNA/params/basic.h>
This allows for temperature scaling in Boltzmann factors independently from the energy contributions. The resulting Boltzmann factors are then computed by \( e^{-E/(\alpha \cdot K \cdot T)} \)
-
vrna_md_t model_details#
Model details to be used in the recursions.
#include <ViennaRNA/params/basic.h>
-
char param_file[256]#
The filename the parameters were derived from, or empty string if they represent the default.
#include <ViennaRNA/params/basic.h>
-
double expSaltStack#
#include <ViennaRNA/params/basic.h>
-
double expSaltLoop[30 + 2]#
#include <ViennaRNA/params/basic.h>
-
double SaltLoopDbl[30 + 2]#
#include <ViennaRNA/params/basic.h>
-
int SaltMLbase#
#include <ViennaRNA/params/basic.h>
-
int SaltMLintern#
#include <ViennaRNA/params/basic.h>
-
int SaltMLclosing#
#include <ViennaRNA/params/basic.h>
-
int SaltDPXInit#
#include <ViennaRNA/params/basic.h>
-
int id#
-
VRNA_GQUAD_MAX_STACK_SIZE#
Salt Corrections#
All relevant functions to compute salt correction at a given salt concentration and temperature.
Functions
-
double vrna_salt_loop(int L, double salt, double T, double backbonelen)#
Get salt correction for a loop at a given salt concentration and temperature.
#include <ViennaRNA/params/salt.h>
- Parameters:
L – backbone number in loop
salt – salt concentration (M)
T – absolute temperature (K)
backbonelen – Backbone Length, phosphate-to-phosphate distance (typically 6 for RNA, 6.76 for DNA)
- Returns:
Salt correction for loop in dcal/mol
-
int vrna_salt_loop_int(int L, double salt, double T, double backbonelen)#
Get salt correction for a loop at a given salt concentration and temperature.
#include <ViennaRNA/params/salt.h>
This functions is same as vrna_salt_loop but returns rounded salt correction in integer
See also
- Parameters:
L – backbone number in loop
salt – salt concentration (M)
T – absolute temperature (K)
backbonelen – Backbone Length, phosphate-to-phosphate distance (typically 6 for RNA, 6.76 for DNA)
- Returns:
Rounded salt correction for loop in dcal/mol
-
int vrna_salt_stack(double salt, double T, double hrise)#
Get salt correction for a stack at a given salt concentration and temperature.
#include <ViennaRNA/params/salt.h>
- Parameters:
salt – salt concentration (M)
T – absolute temperature (K)
hrise – Helical Rise (typically 2.8 for RNA, 3.4 for DNA)
- Returns:
Rounded salt correction for stack in dcal/mol
-
void vrna_salt_ml(double saltLoop[], int lower, int upper, int *m, int *b)#
Fit linear function to loop salt correction.
#include <ViennaRNA/params/salt.h>
For a given range of loop size (backbone number), we perform a linear fitting on loop salt correction
\[ \text{Loop correction} \approx m \cdot L + b. \]See also
- Parameters:
saltLoop – List of loop salt correction of size from 1
lower – Define the size lower bound for fitting
upper – Define the size upper bound for fitting
m – pointer to store the parameter m in fitting result
b – pointer to store the parameter b in fitting result
-
int vrna_salt_duplex_init(vrna_md_t *md)#
Get salt correction for duplex initialization at a given salt concentration.
#include <ViennaRNA/params/salt.h>
- Parameters:
md – Model details data structure that specfifies salt concentration in buffer (M)
- Returns:
Rounded correction for duplex initialization in dcal/mol
-
double vrna_salt_loop(int L, double salt, double T, double backbonelen)#
Loading / Saving Energy Parameter Sets#
Read and Write energy parameter sets from and to files or strings
Defines
-
VRNA_PARAMETER_FORMAT_DEFAULT#
Default Energy Parameter File format.
#include <ViennaRNA/params/io.h>
Enums
-
enum parset#
#include <ViennaRNA/params/io.h>
Values:
-
enumerator UNKNOWN#
-
enumerator QUIT#
-
enumerator S#
-
enumerator S_H#
-
enumerator HP#
-
enumerator HP_H#
-
enumerator B#
-
enumerator B_H#
-
enumerator IL#
-
enumerator IL_H#
-
enumerator MMH#
-
enumerator MMH_H#
-
enumerator MMI#
-
enumerator MMI_H#
-
enumerator MMI1N#
-
enumerator MMI1N_H#
-
enumerator MMI23#
-
enumerator MMI23_H#
-
enumerator MMM#
-
enumerator MMM_H#
-
enumerator MME#
-
enumerator MME_H#
-
enumerator D5#
-
enumerator D5_H#
-
enumerator D3#
-
enumerator D3_H#
-
enumerator INT11#
-
enumerator INT11_H#
-
enumerator INT21#
-
enumerator INT21_H#
-
enumerator INT22#
-
enumerator INT22_H#
-
enumerator ML#
-
enumerator TL#
-
enumerator TRI#
-
enumerator HEX#
-
enumerator NIN#
-
enumerator MISC#
-
enumerator UNKNOWN#
Functions
-
int vrna_params_load(const char fname[], unsigned int options)#
Load energy parameters from a file.
#include <ViennaRNA/params/io.h>
- SWIG Wrapper Notes:
This function is available as overloaded function
params_load(fname=””, options=VRNA_PARAMETER_FORMAT_DEFAULT). Here, the empty filename string indicates to load default RNA parameters, i.e. this is equivalent to calling vrna_params_load_defaults(). See, e.g.RNA.fold_compound.params_load()in the The RNA Python module.
See also
vrna_params_load_from_string(), vrna_params_save(), vrna_params_load_defaults(), vrna_params_load_RNA_Turner2004(), vrna_params_load_RNA_Turner1999(), vrna_params_load_RNA_Andronescu2007(), vrna_params_load_RNA_Langdon2018(), vrna_params_load_RNA_misc_special_hairpins(), vrna_params_load_DNA_Mathews2004(), vrna_params_load_DNA_Mathews1999()
- Parameters:
fname – The path to the file containing the energy parameters
options – File format bit-mask (usually VRNA_PARAMETER_FORMAT_DEFAULT)
- Returns:
Non-zero on success, 0 on failure
-
int vrna_params_save(const char fname[], unsigned int options)#
Save energy parameters to a file.
#include <ViennaRNA/params/io.h>
- SWIG Wrapper Notes:
This function is available as overloaded function
params_save(fname, options=VRNA_PARAMETER_FORMAT_DEFAULT). See, e.g.RNA.params_save()in the The RNA Python module.
See also
- Parameters:
fname – A filename (path) for the file where the current energy parameters will be written to
options – File format bit-mask (usually VRNA_PARAMETER_FORMAT_DEFAULT)
- Returns:
Non-zero on success, 0 on failure
-
int vrna_params_load_from_string(const char *string, const char *name, unsigned int options)#
Load energy paramters from string.
#include <ViennaRNA/params/io.h>
The string must follow the default energy parameter file convention! The optional
nameargument allows one to specify a name for the parameter set which is stored internally.- SWIG Wrapper Notes:
This function is available as overloaded function
params_load_from_string(string, name=””, options=VRNA_PARAMETER_FORMAT_DEFAULT). See, e.g.RNA.params_load_from_string()in the The RNA Python module.
See also
vrna_params_load(), vrna_params_save(), vrna_params_load_defaults(), vrna_params_load_RNA_Turner2004(), vrna_params_load_RNA_Turner1999(), vrna_params_load_RNA_Andronescu2007(), vrna_params_load_RNA_Langdon2018(), vrna_params_load_RNA_misc_special_hairpins(), vrna_params_load_DNA_Mathews2004(), vrna_params_load_DNA_Mathews1999()
- Parameters:
string – A 0-terminated string containing energy parameters
name – A name for the parameter set in
string(MaybeNULL)options – File format bit-mask (usually VRNA_PARAMETER_FORMAT_DEFAULT)
- Returns:
Non-zero on success, 0 on failure
-
int vrna_params_load_defaults(void)#
Load default RNA energy parameter set.
#include <ViennaRNA/params/io.h>
This is a convenience function to load the Turner 2004 RNA free energy parameters. It’s the same as calling vrna_params_load_RNA_Turner2004()
- SWIG Wrapper Notes:
This function is available as overloaded function
params_load(). See, e.g.RNA.params_load()in the The RNA Python module.
See also
vrna_params_load(), vrna_params_load_from_string(), vrna_params_save(), vrna_params_load_RNA_Turner2004(), vrna_params_load_RNA_Turner1999(), vrna_params_load_RNA_Andronescu2007(), vrna_params_load_RNA_Langdon2018(), vrna_params_load_RNA_misc_special_hairpins(), vrna_params_load_DNA_Mathews2004(), vrna_params_load_DNA_Mathews1999()
- Returns:
Non-zero on success, 0 on failure
-
int vrna_params_load_RNA_Turner2004(void)#
Load Turner 2004 RNA energy parameter set.
#include <ViennaRNA/params/io.h>
- SWIG Wrapper Notes:
This function is available as function
params_load_RNA_Turner2004(). See, e.g.RNA.params_load_RNA_Turner2004()in the The RNA Python module.
See also
vrna_params_load(), vrna_params_load_from_string(), vrna_params_save(), vrna_params_load_defaults(), vrna_params_load_RNA_Turner1999(), vrna_params_load_RNA_Andronescu2007(), vrna_params_load_RNA_Langdon2018(), vrna_params_load_RNA_misc_special_hairpins(), vrna_params_load_DNA_Mathews2004(), vrna_params_load_DNA_Mathews1999()
Warning
This function also resets the default geometric parameters as stored in vrna_md_t to those of RNA. Only subsequently initialized vrna_md_t structures will be affected by this change.
- Returns:
Non-zero on success, 0 on failure
-
int vrna_params_load_RNA_Turner1999(void)#
Load Turner 1999 RNA energy parameter set.
#include <ViennaRNA/params/io.h>
- SWIG Wrapper Notes:
This function is available as function
params_load_RNA_Turner1999(). See, e.g.RNA.params_load_RNA_Turner1999()in the The RNA Python module.
See also
vrna_params_load(), vrna_params_load_from_string(), vrna_params_save(), vrna_params_load_RNA_Turner2004(), vrna_params_load_defaults(), vrna_params_load_RNA_Andronescu2007(), vrna_params_load_RNA_Langdon2018(), vrna_params_load_RNA_misc_special_hairpins(), vrna_params_load_DNA_Mathews2004(), vrna_params_load_DNA_Mathews1999()
Warning
This function also resets the default geometric parameters as stored in vrna_md_t to those of RNA. Only subsequently initialized vrna_md_t structures will be affected by this change.
- Returns:
Non-zero on success, 0 on failure
-
int vrna_params_load_RNA_Andronescu2007(void)#
Load Andronsecu 2007 RNA energy parameter set.
#include <ViennaRNA/params/io.h>
- SWIG Wrapper Notes:
This function is available as function
params_load_RNA_Andronescu2007(). See, e.g.RNA.params_load_RNA_Andronescu2007()in the The RNA Python module.
See also
vrna_params_load(), vrna_params_load_from_string(), vrna_params_save(), vrna_params_load_RNA_Turner2004(), vrna_params_load_RNA_Turner1999(), vrna_params_load_defaults(), vrna_params_load_RNA_Langdon2018(), vrna_params_load_RNA_misc_special_hairpins(), vrna_params_load_DNA_Mathews2004(), vrna_params_load_DNA_Mathews1999()
Warning
This function also resets the default geometric parameters as stored in vrna_md_t to those of RNA. Only subsequently initialized vrna_md_t structures will be affected by this change.
- Returns:
Non-zero on success, 0 on failure
-
int vrna_params_load_RNA_Langdon2018(void)#
Load Langdon 2018 RNA energy parameter set.
#include <ViennaRNA/params/io.h>
- SWIG Wrapper Notes:
This function is available as function
params_load_RNA_Langdon2018(). See, e.g.RNA.params_load_RNA_Langdon2018()in the The RNA Python module.
See also
vrna_params_load(), vrna_params_load_from_string(), vrna_params_save(), vrna_params_load_RNA_Turner2004(), vrna_params_load_RNA_Turner1999(), vrna_params_load_RNA_Andronescu2007(), vrna_params_load_defaults(), vrna_params_load_RNA_misc_special_hairpins(), vrna_params_load_DNA_Mathews2004(), vrna_params_load_DNA_Mathews1999()
Warning
This function also resets the default geometric parameters as stored in vrna_md_t to those of RNA. Only subsequently initialized vrna_md_t structures will be affected by this change.
- Returns:
Non-zero on success, 0 on failure
-
int vrna_params_load_RNA_misc_special_hairpins(void)#
Load Misc Special Hairpin RNA energy parameter set.
#include <ViennaRNA/params/io.h>
- SWIG Wrapper Notes:
This function is available as function
params_load_RNA_misc_special_hairpins(). See, e.g.RNA.params_load_RNA_misc_special_hairpins()in the The RNA Python module.
See also
vrna_params_load(), vrna_params_load_from_string(), vrna_params_save(), vrna_params_load_RNA_Turner2004(), vrna_params_load_RNA_Turner1999(), vrna_params_load_RNA_Andronescu2007(), vrna_params_load_RNA_Langdon2018(), vrna_params_load_defaults(), vrna_params_load_DNA_Mathews2004(), vrna_params_load_DNA_Mathews1999()
Warning
This function also resets the default geometric parameters as stored in vrna_md_t to those of RNA. Only subsequently initialized vrna_md_t structures will be affected by this change.
- Returns:
Non-zero on success, 0 on failure
-
int vrna_params_load_DNA_Mathews2004(void)#
Load Mathews 2004 DNA energy parameter set.
#include <ViennaRNA/params/io.h>
- SWIG Wrapper Notes:
This function is available as function
params_load_DNA_Mathews2004(). See, e.g.RNA.params_load_DNA_Mathews2004()in the The RNA Python module.
See also
vrna_params_load(), vrna_params_load_from_string(), vrna_params_save(), vrna_params_load_RNA_Turner2004(), vrna_params_load_RNA_Turner1999(), vrna_params_load_RNA_Andronescu2007(), vrna_params_load_RNA_Langdon2018(), vrna_params_load_RNA_misc_special_hairpins(), vrna_params_load_defaults(), vrna_params_load_DNA_Mathews1999()
Warning
This function also resets the default geometric parameters as stored in vrna_md_t to those of DNA. Only subsequently initialized vrna_md_t structures will be affected by this change.
- Returns:
Non-zero on success, 0 on failure
-
int vrna_params_load_DNA_Mathews1999(void)#
Load Mathews 1999 DNA energy parameter set.
#include <ViennaRNA/params/io.h>
- SWIG Wrapper Notes:
This function is available as function
params_load_DNA_Mathews1999(). See, e.g.RNA.params_load_DNA_Mathews1999()in the The RNA Python module.
See also
vrna_params_load(), vrna_params_load_from_string(), vrna_params_save(), vrna_params_load_RNA_Turner2004(), vrna_params_load_RNA_Turner1999(), vrna_params_load_RNA_Andronescu2007(), vrna_params_load_RNA_Langdon2018(), vrna_params_load_RNA_misc_special_hairpins(), vrna_params_load_DNA_Mathews2004(), vrna_params_load_defaults()
Warning
This function also resets the default geometric parameters as stored in vrna_md_t to those of DNA. Only subsequently initialized vrna_md_t structures will be affected by this change.
- Returns:
Non-zero on success, 0 on failure
-
const char *last_parameter_file(void)#
Get the file name of the parameter file that was most recently loaded.
#include <ViennaRNA/params/io.h>
- Returns:
The file name of the last parameter file, or NULL if parameters are still at defaults
-
void read_parameter_file(const char fname[])#
Read energy parameters from a file.
#include <ViennaRNA/params/io.h>
- Deprecated:
Use vrna_params_load() instead!
- Parameters:
fname – The path to the file containing the energy parameters
-
void write_parameter_file(const char fname[])#
Write energy parameters to a file.
#include <ViennaRNA/params/io.h>
- Deprecated:
Use vrna_params_save() instead!
- Parameters:
fname – A filename (path) for the file where the current energy parameters will be written to
-
VRNA_PARAMETER_FORMAT_DEFAULT#
Converting Energy Parameter Files#
Converting energy parameter files into the latest format.
Defines
-
VRNA_CONVERT_OUTPUT_ALL#
#include <ViennaRNA/params/convert.h>
Flag to indicate printing of a complete parameter set
-
VRNA_CONVERT_OUTPUT_HP#
#include <ViennaRNA/params/convert.h>
Flag to indicate printing of hairpin contributions
-
VRNA_CONVERT_OUTPUT_STACK#
#include <ViennaRNA/params/convert.h>
Flag to indicate printing of base pair stack contributions
-
VRNA_CONVERT_OUTPUT_MM_HP#
#include <ViennaRNA/params/convert.h>
Flag to indicate printing of hairpin mismatch contribution
-
VRNA_CONVERT_OUTPUT_MM_INT#
#include <ViennaRNA/params/convert.h>
Flag to indicate printing of internal loop mismatch contribution
-
VRNA_CONVERT_OUTPUT_MM_INT_1N#
#include <ViennaRNA/params/convert.h>
Flag to indicate printing of 1:n internal loop mismatch contribution
-
VRNA_CONVERT_OUTPUT_MM_INT_23#
#include <ViennaRNA/params/convert.h>
Flag to indicate printing of 2:3 internal loop mismatch contribution
-
VRNA_CONVERT_OUTPUT_MM_MULTI#
#include <ViennaRNA/params/convert.h>
Flag to indicate printing of multi loop mismatch contribution
-
VRNA_CONVERT_OUTPUT_MM_EXT#
#include <ViennaRNA/params/convert.h>
Flag to indicate printing of exterior loop mismatch contribution
-
VRNA_CONVERT_OUTPUT_DANGLE5#
#include <ViennaRNA/params/convert.h>
Flag to indicate printing of 5’ dangle conctribution
-
VRNA_CONVERT_OUTPUT_DANGLE3#
#include <ViennaRNA/params/convert.h>
Flag to indicate printing of 3’ dangle contribution
-
VRNA_CONVERT_OUTPUT_INT_11#
#include <ViennaRNA/params/convert.h>
Flag to indicate printing of 1:1 internal loop contribution
-
VRNA_CONVERT_OUTPUT_INT_21#
#include <ViennaRNA/params/convert.h>
Flag to indicate printing of 2:1 internal loop contribution
-
VRNA_CONVERT_OUTPUT_INT_22#
#include <ViennaRNA/params/convert.h>
Flag to indicate printing of 2:2 internal loop contribution
-
VRNA_CONVERT_OUTPUT_BULGE#
#include <ViennaRNA/params/convert.h>
Flag to indicate printing of bulge loop contribution
-
VRNA_CONVERT_OUTPUT_INT#
#include <ViennaRNA/params/convert.h>
Flag to indicate printing of internal loop contribution
-
VRNA_CONVERT_OUTPUT_ML#
#include <ViennaRNA/params/convert.h>
Flag to indicate printing of multi loop contribution
-
VRNA_CONVERT_OUTPUT_MISC#
#include <ViennaRNA/params/convert.h>
Flag to indicate printing of misc contributions (such as terminalAU)
-
VRNA_CONVERT_OUTPUT_SPECIAL_HP#
#include <ViennaRNA/params/convert.h>
Flag to indicate printing of special hairpin contributions (tri-, tetra-, hexa-loops)
-
VRNA_CONVERT_OUTPUT_VANILLA#
#include <ViennaRNA/params/convert.h>
Flag to indicate printing of given parameters only
Note
This option overrides all other output options, except VRNA_CONVERT_OUTPUT_DUMP !
-
VRNA_CONVERT_OUTPUT_NINIO#
#include <ViennaRNA/params/convert.h>
Flag to indicate printing of internal loop asymmetry contribution
-
VRNA_CONVERT_OUTPUT_DUMP#
#include <ViennaRNA/params/convert.h>
Flag to indicate dumping the energy contributions from the library instead of an input file
Functions
-
void convert_parameter_file(const char *iname, const char *oname, unsigned int options)#
#include <ViennaRNA/params/convert.h>
Convert/dump a Vienna 1.8.4 formatted energy parameter file
The options argument allows one to control the different output modes.
Currently available options are:
VRNA_CONVERT_OUTPUT_ALL, VRNA_CONVERT_OUTPUT_HP, VRNA_CONVERT_OUTPUT_STACKVRNA_CONVERT_OUTPUT_MM_HP, VRNA_CONVERT_OUTPUT_MM_INT, VRNA_CONVERT_OUTPUT_MM_INT_1NVRNA_CONVERT_OUTPUT_MM_INT_23, VRNA_CONVERT_OUTPUT_MM_MULTI, VRNA_CONVERT_OUTPUT_MM_EXTVRNA_CONVERT_OUTPUT_DANGLE5, VRNA_CONVERT_OUTPUT_DANGLE3, VRNA_CONVERT_OUTPUT_INT_11VRNA_CONVERT_OUTPUT_INT_21, VRNA_CONVERT_OUTPUT_INT_22, VRNA_CONVERT_OUTPUT_BULGEVRNA_CONVERT_OUTPUT_INT, VRNA_CONVERT_OUTPUT_ML, VRNA_CONVERT_OUTPUT_MISCVRNA_CONVERT_OUTPUT_SPECIAL_HP, VRNA_CONVERT_OUTPUT_VANILLA, VRNA_CONVERT_OUTPUT_NINIOVRNA_CONVERT_OUTPUT_DUMPThe defined options are fine for bitwise compare- and assignment-operations, e. g.: pass a collection of options as a single value like this:
convert_parameter_file(ifile, ofile, option_1 | option_2 | option_n)
- Parameters:
iname – The input file name (If NULL input is read from stdin)
oname – The output file name (If NULL output is written to stdout)
options – The options (as described above)
-
VRNA_CONVERT_OUTPUT_ALL#
Fine-tuning of the Implemented Models#
Functions and data structures to fine-tune the implemented secondary structure evaluation model.
Defines
-
NBASES#
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_TEMPERATURE#
Default temperature for structure prediction and free energy evaluation in $^\circ C$
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_PF_SCALE#
Default scaling factor for partition function computations.
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_BETA_SCALE#
Default scaling factor for absolute thermodynamic temperature in Boltzmann factors.
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_DANGLES#
Default dangling end model.
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_SPECIAL_HP#
Default model behavior for lookup of special tri-, tetra-, and hexa-loops.
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_NO_LP#
Default model behavior for so-called ‘lonely pairs’.
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_NO_GU#
Default model behavior for G-U base pairs.
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_NO_GU_CLOSURE#
Default model behavior for G-U base pairs closing a loop.
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_CIRC#
Default model behavior to treat a molecule as a circular RNA (DNA).
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_GQUAD#
Default model behavior regarding the treatment of G-Quadruplexes.
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_UNIQ_ML#
Default behavior of the model regarding unique multi-branch loop decomposition.
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_ENERGY_SET#
Default model behavior on which energy set to use.
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_BACKTRACK#
Default model behavior with regards to backtracking of structures.
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_BACKTRACK_TYPE#
Default model behavior on what type of backtracking to perform.
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_COMPUTE_BPP#
Default model behavior with regards to computing base pair probabilities.
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_MAX_BP_SPAN#
Default model behavior for the allowed maximum base pair span.
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_WINDOW_SIZE#
Default model behavior for the sliding window approach.
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_LOG_ML#
Default model behavior on how to evaluate the energy contribution of multi-branch loops.
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_ALI_OLD_EN#
Default model behavior for consensus structure energy evaluation.
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_ALI_RIBO#
Default model behavior for consensus structure co-variance contribution assessment.
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_ALI_CV_FACT#
Default model behavior for weighting the co-variance score in consensus structure prediction.
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_ALI_NC_FACT#
Default model behavior for weighting the nucleotide conservation? in consensus structure prediction.
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_PF_SMOOTH#
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_SALT#
Default model salt concentration (M).
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_SALT_MLLOWER#
Default model lower bound of multiloop size for salt correction fiting.
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_SALT_MLUPPER#
Default model upper bound of multiloop size for salt correction fiting.
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_SALT_DPXINIT#
Default model value to turn off user-provided salt correction for duplex initializtion.
#include <ViennaRNA/model.h>
-
VRNA_MODEL_SALT_DPXINIT_FACT_RNA#
#include <ViennaRNA/model.h>
-
VRNA_MODEL_SALT_DPXINIT_FACT_DNA#
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_SALT_DPXINIT_FACT#
#include <ViennaRNA/model.h>
-
VRNA_MODEL_HELICAL_RISE_RNA#
#include <ViennaRNA/model.h>
-
VRNA_MODEL_HELICAL_RISE_DNA#
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_HELICAL_RISE#
Default helical rise.
#include <ViennaRNA/model.h>
-
VRNA_MODEL_BACKBONE_LENGTH_RNA#
#include <ViennaRNA/model.h>
-
VRNA_MODEL_BACKBONE_LENGTH_DNA#
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_BACKBONE_LENGTH#
Default backbone length.
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_CIRC_PENALTY#
#include <ViennaRNA/model.h>
-
VRNA_MODEL_DEFAULT_CIRC_ALPHA0#
#include <ViennaRNA/model.h>
-
MAXALPHA#
Maximal length of alphabet.
#include <ViennaRNA/model.h>
-
model_detailsT#
#include <ViennaRNA/model.h>
Typedefs
Functions
-
void vrna_md_set_default(vrna_md_t *md)#
Apply default model details to a provided vrna_md_t data structure.
#include <ViennaRNA/model.h>
Use this function to initialize a vrna_md_t data structure with its default values
- Parameters:
md – A pointer to the data structure that is about to be initialized
-
void vrna_md_update(vrna_md_t *md)#
Update the model details data structure.
#include <ViennaRNA/model.h>
This function should be called after changing the vrna_md_t.energy_set attribute since it re-initializes base pairing related arrays within the vrna_md_t data structure. In particular, vrna_md_t.pair, vrna_md_t.alias, and vrna_md_t.rtype are set to the values that correspond to the specified vrna_md_t.energy_set option
-
vrna_md_t *vrna_md_copy(vrna_md_t *md_to, const vrna_md_t *md_from)#
Copy/Clone a vrna_md_t model.
#include <ViennaRNA/model.h>
Use this function to clone a given model either inplace (target container
md_togiven) or create a copy by cloning the source model and returning it (md_to== NULL).- Parameters:
md_to – The model to be overwritten (if non-NULL and
md_to!=md_from)md_from – The model to copy (if non-NULL)
- Returns:
A pointer to the copy model (or NULL if
md_from== NULL)
-
char *vrna_md_option_string(vrna_md_t *md)#
Get a corresponding commandline parameter string of the options in a vrna_md_t.
#include <ViennaRNA/model.h>
Note
This function is not threadsafe!
-
void vrna_md_defaults_reset(vrna_md_t *md_p)#
Reset the global default model details to a specific set of parameters, or their initial values.
#include <ViennaRNA/model.h>
This function resets the global default model details to their initial values, i.e. as specified by the ViennaRNA Package release, upon passing NULL as argument. Alternatively it resets them according to a set of provided parameters.
See also
Note
The global default parameters affect all function calls of RNAlib where model details are not explicitly provided. Hence, any change of them is not considered threadsafe
Warning
This function first resets the global default settings to factory defaults, and only then applies user provided settings (if any). User settings that do not meet specifications are skipped.
- Parameters:
md_p – A set of model details to use as global default (if NULL is passed, factory defaults are restored)
-
void vrna_md_defaults_temperature(double T)#
Set default temperature for energy evaluation of loops.
#include <ViennaRNA/model.h>
- Parameters:
T – Temperature in centigrade
-
double vrna_md_defaults_temperature_get(void)#
Get default temperature for energy evaluation of loops.
#include <ViennaRNA/model.h>
See also
vrna_md_defaults_temperature(), vrna_md_defaults_reset(), vrna_md_set_default(), vrna_md_t, VRNA_MODEL_DEFAULT_TEMPERATURE
- Returns:
The global default settings for temperature in centigrade
-
void vrna_md_defaults_betaScale(double b)#
Set default scaling factor of thermodynamic temperature in Boltzmann factors.
#include <ViennaRNA/model.h>
Bolzmann factors are then computed as \( exp(-E / (b \cdot kT))\).
- Parameters:
b – The scaling factor, default is 1.0
-
double vrna_md_defaults_betaScale_get(void)#
Get default scaling factor of thermodynamic temperature in Boltzmann factors.
#include <ViennaRNA/model.h>
See also
vrna_md_defaults_betaScale(), vrna_md_defaults_reset(), vrna_md_set_default(), vrna_md_t, VRNA_MODEL_DEFAULT_BETA_SCALE
- Returns:
The global default thermodynamic temperature scaling factor
-
void vrna_md_defaults_pf_smooth(int s)#
#include <ViennaRNA/model.h>
-
int vrna_md_defaults_pf_smooth_get(void)#
#include <ViennaRNA/model.h>
-
void vrna_md_defaults_dangles(int d)#
Set default dangle model for structure prediction.
#include <ViennaRNA/model.h>
- Parameters:
d – The dangle model
-
int vrna_md_defaults_dangles_get(void)#
Get default dangle model for structure prediction.
#include <ViennaRNA/model.h>
See also
vrna_md_defaults_dangles(), vrna_md_defaults_reset(), vrna_md_set_default(), vrna_md_t, VRNA_MODEL_DEFAULT_DANGLES
- Returns:
The global default settings for the dangle model
-
void vrna_md_defaults_special_hp(int flag)#
Set default behavior for lookup of tabulated free energies for special hairpin loops, such as Tri-, Tetra-, or Hexa-loops.
#include <ViennaRNA/model.h>
- Parameters:
flag – On/Off switch (0 = OFF, else = ON)
-
int vrna_md_defaults_special_hp_get(void)#
Get default behavior for lookup of tabulated free energies for special hairpin loops, such as Tri-, Tetra-, or Hexa-loops.
#include <ViennaRNA/model.h>
See also
vrna_md_defaults_special_hp(), vrna_md_defaults_reset(), vrna_md_set_default(), vrna_md_t, VRNA_MODEL_DEFAULT_SPECIAL_HP
- Returns:
The global default settings for the treatment of special hairpin loops
-
void vrna_md_defaults_noLP(int flag)#
Set default behavior for prediction of canonical secondary structures.
#include <ViennaRNA/model.h>
- Parameters:
flag – On/Off switch (0 = OFF, else = ON)
-
int vrna_md_defaults_noLP_get(void)#
Get default behavior for prediction of canonical secondary structures.
#include <ViennaRNA/model.h>
See also
vrna_md_defaults_noLP(), vrna_md_defaults_reset(), vrna_md_set_default(), vrna_md_t, VRNA_MODEL_DEFAULT_NO_LP
- Returns:
The global default settings for predicting canonical secondary structures
-
void vrna_md_defaults_noGU(int flag)#
Set default behavior for treatment of G-U wobble pairs.
#include <ViennaRNA/model.h>
- Parameters:
flag – On/Off switch (0 = OFF, else = ON)
-
int vrna_md_defaults_noGU_get(void)#
Get default behavior for treatment of G-U wobble pairs.
#include <ViennaRNA/model.h>
See also
vrna_md_defaults_noGU(), vrna_md_defaults_reset(), vrna_md_set_default(), vrna_md_t, VRNA_MODEL_DEFAULT_NO_GU
- Returns:
The global default settings for treatment of G-U wobble pairs
-
void vrna_md_defaults_noGUclosure(int flag)#
Set default behavior for G-U pairs as closing pair for loops.
#include <ViennaRNA/model.h>
See also
vrna_md_defaults_reset(), vrna_md_set_default(), vrna_md_t, VRNA_MODEL_DEFAULT_NO_GU_CLOSURE
- Parameters:
flag – On/Off switch (0 = OFF, else = ON)
-
int vrna_md_defaults_noGUclosure_get(void)#
Get default behavior for G-U pairs as closing pair for loops.
#include <ViennaRNA/model.h>
See also
vrna_md_defaults_noGUclosure(), vrna_md_defaults_reset(), vrna_md_set_default(), vrna_md_t, VRNA_MODEL_DEFAULT_NO_GU_CLOSURE
- Returns:
The global default settings for treatment of G-U pairs closing a loop
-
void vrna_md_defaults_logML(int flag)#
Set default behavior recomputing free energies of multi-branch loops using a logarithmic model.
#include <ViennaRNA/model.h>
- Parameters:
flag – On/Off switch (0 = OFF, else = ON)
-
int vrna_md_defaults_logML_get(void)#
Get default behavior recomputing free energies of multi-branch loops using a logarithmic model.
#include <ViennaRNA/model.h>
See also
vrna_md_defaults_logML(), vrna_md_defaults_reset(), vrna_md_set_default(), vrna_md_t, VRNA_MODEL_DEFAULT_LOG_ML
- Returns:
The global default settings for logarithmic model in multi-branch loop free energy evaluation
-
void vrna_md_defaults_circ(int flag)#
Set default behavior whether input sequences are circularized.
#include <ViennaRNA/model.h>
- Parameters:
flag – On/Off switch (0 = OFF, else = ON)
-
int vrna_md_defaults_circ_get(void)#
Get default behavior whether input sequences are circularized.
#include <ViennaRNA/model.h>
See also
vrna_md_defaults_circ(), vrna_md_defaults_reset(), vrna_md_set_default(), vrna_md_t, VRNA_MODEL_DEFAULT_CIRC
- Returns:
The global default settings for treating input sequences as circular
-
void vrna_md_defaults_circ_penalty(int flag)#
Set default behavior for fully unpaired circular RNA penalty.
#include <ViennaRNA/model.h>
See also
vrna_E_exterior_loop(), vrna_md_defaults_reset(), vrna_md_set_default(), vrna_md_t, #VRNA_MODEL_DEFAULT_CIRC_PENALTY
- Parameters:
flag – On/Off switch (0 = OFF, else = ON)
-
int vrna_md_defaults_circ_penalty_get(void)#
Get default behavior for fully unpaired circular RNA penalty.
#include <ViennaRNA/model.h>
See also
vrna_md_defaults_circ_penalty(), vrna_md_defaults_reset(), vrna_md_set_default(), vrna_md_t, VRNA_MODEL_DEFAULT_CIRC
- Returns:
The global default settings for adding an entropic penalty for unpaired circular RNA ring
-
void vrna_md_defaults_gquad(int flag)#
Set default behavior for treatment of G-Quadruplexes.
#include <ViennaRNA/model.h>
- Parameters:
flag – On/Off switch (0 = OFF, else = ON)
-
int vrna_md_defaults_gquad_get(void)#
Get default behavior for treatment of G-Quadruplexes.
#include <ViennaRNA/model.h>
See also
vrna_md_defaults_gquad(), vrna_md_defaults_reset(), vrna_md_set_default(), vrna_md_t, VRNA_MODEL_DEFAULT_GQUAD
- Returns:
The global default settings for treatment of G-Quadruplexes
-
void vrna_md_defaults_uniq_ML(int flag)#
Set default behavior for creating additional matrix for unique multi-branch loop prediction.
#include <ViennaRNA/model.h>
Note
Activating this option usually results in higher memory consumption!
- Parameters:
flag – On/Off switch (0 = OFF, else = ON)
-
int vrna_md_defaults_uniq_ML_get(void)#
Get default behavior for creating additional matrix for unique multi-branch loop prediction.
#include <ViennaRNA/model.h>
See also
vrna_md_defaults_uniq_ML(), vrna_md_defaults_reset(), vrna_md_set_default(), vrna_md_t, VRNA_MODEL_DEFAULT_UNIQ_ML
- Returns:
The global default settings for creating additional matrices for unique multi-branch loop prediction
-
void vrna_md_defaults_energy_set(int e)#
Set default energy set.
#include <ViennaRNA/model.h>
- Parameters:
e – Energy set (0, 1, 2, 3)
-
int vrna_md_defaults_energy_set_get(void)#
Get default energy set.
#include <ViennaRNA/model.h>
See also
vrna_md_defaults_energy_set(), vrna_md_defaults_reset(), vrna_md_set_default(), vrna_md_t, VRNA_MODEL_DEFAULT_ENERGY_SET
- Returns:
The global default settings for the energy set
-
void vrna_md_defaults_backtrack(int flag)#
Set default behavior for whether to backtrack secondary structures.
#include <ViennaRNA/model.h>
- Parameters:
flag – On/Off switch (0 = OFF, else = ON)
-
int vrna_md_defaults_backtrack_get(void)#
Get default behavior for whether to backtrack secondary structures.
#include <ViennaRNA/model.h>
See also
vrna_md_defaults_backtrack(), vrna_md_defaults_reset(), vrna_md_set_default(), vrna_md_t, VRNA_MODEL_DEFAULT_BACKTRACK
- Returns:
The global default settings for backtracking structures
-
void vrna_md_defaults_backtrack_type(char t)#
Set default backtrack type, i.e. which DP matrix is used.
#include <ViennaRNA/model.h>
See also
vrna_md_defaults_reset(), vrna_md_set_default(), vrna_md_t, VRNA_MODEL_DEFAULT_BACKTRACK_TYPE
- Parameters:
t – The type (‘F’, ‘C’, or ‘M’)
-
char vrna_md_defaults_backtrack_type_get(void)#
Get default backtrack type, i.e. which DP matrix is used.
#include <ViennaRNA/model.h>
See also
vrna_md_defaults_backtrack_type(), vrna_md_defaults_reset(), vrna_md_set_default(), vrna_md_t, VRNA_MODEL_DEFAULT_BACKTRACK_TYPE
- Returns:
The global default settings that specify which DP matrix is used for backtracking
-
void vrna_md_defaults_compute_bpp(int flag)#
Set the default behavior for whether to compute base pair probabilities after partition function computation.
#include <ViennaRNA/model.h>
- Parameters:
flag – On/Off switch (0 = OFF, else = ON)
-
int vrna_md_defaults_compute_bpp_get(void)#
Get the default behavior for whether to compute base pair probabilities after partition function computation.
#include <ViennaRNA/model.h>
See also
vrna_md_defaults_compute_bpp(), vrna_md_defaults_reset(), vrna_md_set_default(), vrna_md_t, VRNA_MODEL_DEFAULT_COMPUTE_BPP
- Returns:
The global default settings that specify whether base pair probabilities are computed together with partition function
-
void vrna_md_defaults_max_bp_span(int span)#
Set default maximal base pair span.
#include <ViennaRNA/model.h>
- Parameters:
span – Maximal base pair span
-
int vrna_md_defaults_max_bp_span_get(void)#
Get default maximal base pair span.
#include <ViennaRNA/model.h>
See also
vrna_md_defaults_max_bp_span(), vrna_md_defaults_reset(), vrna_md_set_default(), vrna_md_t, VRNA_MODEL_DEFAULT_MAX_BP_SPAN
- Returns:
The global default settings for maximum base pair span
-
void vrna_md_defaults_min_loop_size(int size)#
Set default minimal loop size.
#include <ViennaRNA/model.h>
See also
vrna_md_defaults_reset(), vrna_md_set_default(), vrna_md_t, TURN
- Parameters:
size – Minimal size, i.e. number of unpaired nucleotides for a hairpin loop
-
int vrna_md_defaults_min_loop_size_get(void)#
Get default minimal loop size.
#include <ViennaRNA/model.h>
See also
vrna_md_defaults_min_loop_size(), vrna_md_defaults_reset(), vrna_md_set_default(), vrna_md_t, TURN
- Returns:
The global default settings for minimal size of hairpin loops
-
void vrna_md_defaults_window_size(int size)#
Set default window size for sliding window structure prediction approaches.
#include <ViennaRNA/model.h>
- Parameters:
size – The size of the sliding window
-
int vrna_md_defaults_window_size_get(void)#
Get default window size for sliding window structure prediction approaches.
#include <ViennaRNA/model.h>
See also
vrna_md_defaults_window_size(), vrna_md_defaults_reset(), vrna_md_set_default(), vrna_md_t, VRNA_MODEL_DEFAULT_WINDOW_SIZE
- Returns:
The global default settings for the size of the sliding window
-
void vrna_md_defaults_oldAliEn(int flag)#
Set default behavior for whether to use old energy model for comparative structure prediction.
#include <ViennaRNA/model.h>
Note
This option is outdated. Activating the old energy model usually results in worse consensus structure predictions.
- Parameters:
flag – On/Off switch (0 = OFF, else = ON)
-
int vrna_md_defaults_oldAliEn_get(void)#
Get default behavior for whether to use old energy model for comparative structure prediction.
#include <ViennaRNA/model.h>
See also
vrna_md_defaults_oldAliEn(), vrna_md_defaults_reset(), vrna_md_set_default(), vrna_md_t, VRNA_MODEL_DEFAULT_ALI_OLD_EN
- Returns:
The global default settings for using old energy model for comparative structure prediction
-
void vrna_md_defaults_ribo(int flag)#
Set default behavior for whether to use Ribosum Scoring in comparative structure prediction.
#include <ViennaRNA/model.h>
- Parameters:
flag – On/Off switch (0 = OFF, else = ON)
-
int vrna_md_defaults_ribo_get(void)#
Get default behavior for whether to use Ribosum Scoring in comparative structure prediction.
#include <ViennaRNA/model.h>
See also
vrna_md_defaults_ribo(), vrna_md_defaults_reset(), vrna_md_set_default(), vrna_md_t, VRNA_MODEL_DEFAULT_ALI_RIBO
- Returns:
The global default settings for using Ribosum scoring in comparative structure prediction
-
void vrna_md_defaults_cv_fact(double factor)#
Set the default co-variance scaling factor used in comparative structure prediction.
#include <ViennaRNA/model.h>
- Parameters:
factor – The co-variance factor
-
double vrna_md_defaults_cv_fact_get(void)#
Get the default co-variance scaling factor used in comparative structure prediction.
#include <ViennaRNA/model.h>
See also
vrna_md_defaults_cv_fact(), vrna_md_defaults_reset(), vrna_md_set_default(), vrna_md_t, VRNA_MODEL_DEFAULT_ALI_CV_FACT
- Returns:
The global default settings for the co-variance factor
-
void vrna_md_defaults_nc_fact(double factor)#
#include <ViennaRNA/model.h>
- Parameters:
factor
-
double vrna_md_defaults_nc_fact_get(void)#
#include <ViennaRNA/model.h>
See also
vrna_md_defaults_nc_fact(), vrna_md_defaults_reset(), vrna_md_set_default(), vrna_md_t, VRNA_MODEL_DEFAULT_ALI_NC_FACT
- Returns:
-
void vrna_md_defaults_sfact(double factor)#
Set the default scaling factor used to avoid under-/overflows in partition function computation.
#include <ViennaRNA/model.h>
- Parameters:
factor – The scaling factor (default: 1.07)
-
double vrna_md_defaults_sfact_get(void)#
Get the default scaling factor used to avoid under-/overflows in partition function computation.
#include <ViennaRNA/model.h>
- Returns:
The global default settings of the scaling factor
-
void vrna_md_defaults_salt(double salt)#
Set the default salt concentration.
#include <ViennaRNA/model.h>
- Parameters:
salt – The sodium concentration in M (default: 1.021)
-
double vrna_md_defaults_salt_get(void)#
Get the default salt concentration.
#include <ViennaRNA/model.h>
- Returns:
The default salt concentration
-
void vrna_md_defaults_saltMLLower(int lower)#
Set the default multiloop size lower bound for loop salt correciton linear fitting.
#include <ViennaRNA/model.h>
- Parameters:
lower – Size lower bound (number of backbone in loop)
-
int vrna_md_defaults_saltMLLower_get(void)#
Get the default multiloop size lower bound for loop salt correciton linear fitting.
#include <ViennaRNA/model.h>
- Returns:
The default lower bound
-
void vrna_md_defaults_saltMLUpper(int upper)#
Set the default multiloop size upper bound for loop salt correciton linear fitting.
#include <ViennaRNA/model.h>
- Parameters:
upper – Size Upper bound (number of backbone in loop)
-
int vrna_md_defaults_saltMLUpper_get(void)#
Get the default multiloop size upper bound for loop salt correciton linear fitting.
#include <ViennaRNA/model.h>
- Returns:
The default upper bound
-
void vrna_md_defaults_saltDPXInit(int value)#
Set user-provided salt correciton for duplex initialization If value is 99999 the default value from fitting is used.
#include <ViennaRNA/model.h>
- Parameters:
value – The value of salt correction for duplex initialization (in dcal/mol)
-
int vrna_md_defaults_saltDPXInit_get(void)#
Get user-provided salt correciton for duplex initialization If value is 99999 the default value from fitting is used.
#include <ViennaRNA/model.h>
- Returns:
The user-provided salt correction for duplex initialization
-
void vrna_md_defaults_saltDPXInitFact(float value)#
#include <ViennaRNA/model.h>
-
float vrna_md_defaults_saltDPXInitFact_get(void)#
#include <ViennaRNA/model.h>
-
void vrna_md_defaults_helical_rise(float value)#
#include <ViennaRNA/model.h>
-
float vrna_md_defaults_helical_rise_get(void)#
#include <ViennaRNA/model.h>
-
void vrna_md_defaults_backbone_length(float value)#
#include <ViennaRNA/model.h>
-
float vrna_md_defaults_backbone_length_get(void)#
#include <ViennaRNA/model.h>
-
void vrna_md_defaults_circ_alpha0(double a0)#
#include <ViennaRNA/model.h>
-
double vrna_md_defaults_circ_alpha0_get(void)#
#include <ViennaRNA/model.h>
-
void set_model_details(vrna_md_t *md)#
Set default model details.
#include <ViennaRNA/model.h>
Use this function if you wish to initialize a vrna_md_t data structure with its default values, i.e. the global model settings as provided by the deprecated global variables.
- Deprecated:
This function will vanish as soon as backward compatibility of RNAlib is dropped (expected in version 3). Use vrna_md_set_default() instead!
- Parameters:
md – A pointer to the data structure that is about to be initialized
-
char *option_string(void)#
#include <ViennaRNA/model.h>
Variables
-
double temperature#
Rescale energy parameters to a temperature in degC.
#include <ViennaRNA/model.h>
Default is 37C. You have to call the update_…_params() functions after changing this parameter.
- Deprecated:
Use vrna_md_defaults_temperature(), and vrna_md_defaults_temperature_get() to change, and read the global default temperature settings
-
double pf_scale#
A scaling factor used by pf_fold() to avoid overflows.
#include <ViennaRNA/model.h>
Should be set to approximately \(exp{((-F/kT)/length)}\), where \(F\) is an estimate for the ensemble free energy, for example the minimum free energy. You must call update_pf_params()
after changing this parameter.
If pf_scale is -1 (the default) , an estimate will be provided automatically when computing partition functions, e.g.
pf_fold() The automatic estimate is usually insufficient for sequences more than a few hundred bases long.
-
int dangles#
Switch the energy model for dangling end contributions (0, 1, 2, 3).
#include <ViennaRNA/model.h>
If set to 0 no stabilizing energies are assigned to bases adjacent to helices in free ends and multiloops (so called dangling ends). Normally (dangles = 1) dangling end energies are assigned only to unpaired bases and a base cannot participate simultaneously in two dangling ends. In the partition function algorithm pf_fold() these checks are neglected. If dangles
is set to 2, all folding routines will follow this convention. This treatment of dangling ends gives more favorable energies to helices directly adjacent to one another, which can be beneficial since such helices often do engage in stabilizing interactions through co-axial stacking.
If dangles = 3 co-axial stacking is explicitly included for adjacent helices in multiloops. The option affects only mfe folding and energy evaluation (
fold() and energy_of_structure()), as well as suboptimal folding (subopt()) via re-evaluation of energies. Co-axial stacking with one intervening mismatch is not considered so far.Default is 2 in most algorithms, partition function algorithms can only handle 0 and 2
-
int tetra_loop#
Include special stabilizing energies for some tri-, tetra- and hexa-loops;.
#include <ViennaRNA/model.h>
default is 1.
-
int noLonelyPairs#
Global switch to avoid/allow helices of length 1.
#include <ViennaRNA/model.h>
Disallow all pairs which can only occur as lonely pairs (i.e. as helix of length 1). This avoids lonely base pairs in the predicted structures in most cases.
-
int noGU#
Global switch to forbid/allow GU base pairs at all.
#include <ViennaRNA/model.h>
-
int no_closingGU#
GU allowed only inside stacks if set to 1.
#include <ViennaRNA/model.h>
-
int circ#
backward compatibility variable.. this does not effect anything
#include <ViennaRNA/model.h>
-
int gquad#
Allow G-quadruplex formation.
#include <ViennaRNA/model.h>
-
int uniq_ML#
do ML decomposition uniquely (for subopt)
#include <ViennaRNA/model.h>
-
int energy_set#
0 = BP; 1=any with GC; 2=any with AU-parameter
#include <ViennaRNA/model.h>
If set to 1 or 2: fold sequences from an artificial alphabet ABCD…, where A pairs B, C pairs D, etc. using either GC (1) or AU parameters (2); default is 0, you probably don’t want to change it.
-
int do_backtrack#
do backtracking, i.e. compute secondary structures or base pair probabilities
#include <ViennaRNA/model.h>
If 0, do not calculate pair probabilities in pf_fold(); this is about twice as fast. Default is 1.
-
char backtrack_type#
A backtrack array marker for inverse_fold().
#include <ViennaRNA/model.h>
If set to ‘C’: force (1,N) to be paired, ‘M’ fold as if the sequence were inside a multiloop. Otherwise (‘F’) the usual mfe structure is computed.
-
char *nonstandards#
contains allowed non standard base pairs
#include <ViennaRNA/model.h>
Lists additional base pairs that will be allowed to form in addition to GC, CG, AU, UA, GU and UG. Nonstandard base pairs are given a stacking energy of 0.
-
int max_bp_span#
Maximum allowed base pair span.
#include <ViennaRNA/model.h>
A value of -1 indicates no restriction for distant base pairs.
-
int oldAliEn#
use old alifold energies (with gaps)
#include <ViennaRNA/model.h>
-
int ribo#
use ribosum matrices
#include <ViennaRNA/model.h>
-
double cv_fact#
This variable controls the weight of the covariance term in the energy function of alignment folding algorithms.
#include <ViennaRNA/model.h>
- Deprecated:
See vrna_md_t.cv_fact, and vrna_mfe() to avoid using global variables
Default is 1.
-
double nc_fact#
This variable controls the magnitude of the penalty for non-compatible sequences in the covariance term of alignment folding algorithms.
#include <ViennaRNA/model.h>
- Deprecated:
See vrna_md_t.nc_fact, and vrna_mfe() to avoid using global variables
Default is 1.
-
int logML#
if nonzero use logarithmic ML energy in energy_of_struct
#include <ViennaRNA/model.h>
-
double salt#
salt concentration
#include <ViennaRNA/model.h>
-
int saltDPXInit#
Salt correction for duplex initialization.
#include <ViennaRNA/model.h>
-
float helical_rise#
#include <ViennaRNA/model.h>
-
float backbone_length#
#include <ViennaRNA/model.h>
-
struct vrna_md_s#
- #include <ViennaRNA/model.h>
The data structure that contains the complete model details used throughout the calculations.
For convenience reasons, we provide the type name vrna_md_t to address this data structure without the use of the struct keyword
- SWIG Wrapper Notes:
This data structure is wrapped as an object
mdwith multiple related functions attached as methods.A new set of default parameters can be obtained by calling the constructure of
md:md()– Initialize with default settings
The resulting object has a list of attached methods which directly correspond to functions that mainly operate on the corresponding C data structure:
reset()- vrna_md_set_default()set_from_globals()- set_model_details()option_string()- vrna_md_option_string()
Public Members
-
double temperature#
The temperature used to scale the thermodynamic parameters.
#include <ViennaRNA/model.h>
-
double betaScale#
A scaling factor for the thermodynamic temperature of the Boltzmann factors.
#include <ViennaRNA/model.h>
-
int pf_smooth#
A flat specifying whether energies in Boltzmann factors need to be smoothed.
#include <ViennaRNA/model.h>
-
int dangles#
Specifies the dangle model used in any energy evaluation (0,1,2 or 3).
#include <ViennaRNA/model.h>
If set to 0 no stabilizing energies are assigned to bases adjacent to helices in free ends and multiloops (so called dangling ends). Normally (dangles = 1) dangling end energies are assigned only to unpaired bases and a base cannot participate simultaneously in two dangling ends. In the partition function algorithm vrna_pf()
these checks are neglected. To provide comparability between free energy minimization and partition function algorithms, the default setting is 2. This treatment of dangling ends gives more favorable energies to helices directly adjacent to one another, which can be beneficial since such helices often do engage in stabilizing interactions through co-axial stacking.
If set to 3 co-axial stacking is explicitly included for adjacent helices in multiloops. The option affects only mfe folding and energy evaluation (
vrna_mfe() and vrna_eval_structure()), as well as suboptimal folding (vrna_subopt()) via re-evaluation of energies. Co-axial stacking with one intervening mismatch is not considered so far. Note, that some function do not implement all dangle model but only a subset of (0,1,2,3). In particular, partition function algorithms can only handle 0 and 2. Read the documentation of the particular recurrences or energy evaluation function for information about the provided dangle model.
-
int special_hp#
Include special hairpin contributions for tri, tetra and hexaloops.
#include <ViennaRNA/model.h>
-
int noLP#
Only consider canonical structures, i.e. no ‘lonely’ base pairs.
#include <ViennaRNA/model.h>
-
int noGU#
Do not allow GU pairs.
#include <ViennaRNA/model.h>
-
int noGUclosure#
Do not allow loops to be closed by GU pair.
#include <ViennaRNA/model.h>
-
int logML#
Use logarithmic scaling for multiloops.
#include <ViennaRNA/model.h>
-
int circ#
Assume RNA to be circular instead of linear.
#include <ViennaRNA/model.h>
-
int circ_penalty#
Add an entropic penalty to the unpaired circRNA chain.
#include <ViennaRNA/model.h>
-
int gquad#
Include G-quadruplexes in structure prediction.
#include <ViennaRNA/model.h>
-
int uniq_ML#
Flag to ensure unique multi-branch loop decomposition during folding.
#include <ViennaRNA/model.h>
-
int energy_set#
Specifies the energy set that defines set of compatible base pairs.
#include <ViennaRNA/model.h>
-
int backtrack#
Specifies whether or not secondary structures should be backtraced.
#include <ViennaRNA/model.h>
-
char backtrack_type#
Specifies in which matrix to backtrack.
#include <ViennaRNA/model.h>
-
int compute_bpp#
Specifies whether or not backward recursions for base pair probability (bpp) computation will be performed.
#include <ViennaRNA/model.h>
-
char nonstandards[64]#
contains allowed non standard bases
#include <ViennaRNA/model.h>
-
int max_bp_span#
maximum allowed base pair span
#include <ViennaRNA/model.h>
-
int min_loop_size#
Minimum size of hairpin loops.
#include <ViennaRNA/model.h>
The default value for this field is TURN, however, it may be 0 in cofolding context.
-
int window_size#
Size of the sliding window for locally optimal structure prediction.
#include <ViennaRNA/model.h>
-
int oldAliEn#
Use old alifold energy model.
#include <ViennaRNA/model.h>
-
int ribo#
Use ribosum scoring table in alifold energy model.
#include <ViennaRNA/model.h>
-
double cv_fact#
Co-variance scaling factor for consensus structure prediction.
#include <ViennaRNA/model.h>
-
double nc_fact#
Scaling factor to weight co-variance contributions of non-canonical pairs.
#include <ViennaRNA/model.h>
-
double sfact#
Scaling factor for partition function scaling.
#include <ViennaRNA/model.h>
-
int rtype[8]#
Reverse base pair type array.
#include <ViennaRNA/model.h>
-
short alias[20 + 1]#
alias of an integer nucleotide representation
#include <ViennaRNA/model.h>
-
int pair[20 + 1][20 + 1]#
Integer representation of a base pair.
#include <ViennaRNA/model.h>
-
float pair_dist[7][7]#
Base pair dissimilarity, a.k.a. distance matrix.
#include <ViennaRNA/model.h>
-
double salt#
Salt (monovalent) concentration (M) in buffer.
#include <ViennaRNA/model.h>
-
int saltMLLower#
Lower bound of multiloop size to use in loop salt correction linear fitting.
#include <ViennaRNA/model.h>
-
int saltMLUpper#
Upper bound of multiloop size to use in loop salt correction linear fitting.
#include <ViennaRNA/model.h>
-
int saltDPXInit#
User-provided salt correction for duplex initialization (in dcal/mol). If set to 99999 the default salt correction is used. If set to 0 there is no salt correction for duplex initialization.
#include <ViennaRNA/model.h>
-
float saltDPXInitFact#
#include <ViennaRNA/model.h>
-
float helical_rise#
#include <ViennaRNA/model.h>
-
float backbone_length#
#include <ViennaRNA/model.h>
-
double circ_alpha0#
#include <ViennaRNA/model.h>
-
NBASES#
Energy Evaluation for Individual Loops#
General#
Functions to evaluate the free energy of particular types of loops.
Functions
-
int vrna_eval_loop_pt(vrna_fold_compound_t *fc, int i, const short *pt)#
Calculate energy of a loop.
#include <ViennaRNA/eval/structures.h>
- SWIG Wrapper Notes:
This function is attached as method
eval_loop_pt()to objects of typefold_compound. See, e.g.RNA.fold_compound.eval_loop_pt()in the The RNA Python module .
- Parameters:
fc – A vrna_fold_compound_t containing the energy parameters and model details
i – position of covering base pair
pt – the pair table of the secondary structure
- Returns:
free energy of the loop in 10cal/mol
-
int vrna_eval_loop_pt_v(vrna_fold_compound_t *fc, int i, const short *pt, int verbosity_level)#
Calculate energy of a loop.
#include <ViennaRNA/eval/structures.h>
- Parameters:
fc – A vrna_fold_compound_t containing the energy parameters and model details
i – position of covering base pair
pt – the pair table of the secondary structure
verbosity_level – The level of verbosity of this function
- Returns:
free energy of the loop in 10cal/mol
-
int vrna_eval_loop_pt(vrna_fold_compound_t *fc, int i, const short *pt)#
Exterior Loops#
Functions to evaluate the free energy contributions for exterior (external) loops.
Boltzmann weight (partition function) interface
-
typedef struct vrna_mx_pf_aux_el_s *vrna_mx_pf_aux_el_t#
Auxiliary helper arrays for fast exterior loop computations.
#include <ViennaRNA/partfunc/exterior.h>
See also
vrna_exp_E_ext_fast_init(), vrna_exp_E_ext_fast_rotate(), vrna_exp_E_ext_fast_free(), vrna_exp_E_ext_fast()
-
vrna_mx_pf_aux_el_t vrna_exp_E_ext_fast_init(vrna_fold_compound_t *fc)#
#include <ViennaRNA/partfunc/exterior.h>
-
void vrna_exp_E_ext_fast_rotate(vrna_mx_pf_aux_el_t aux_mx)#
#include <ViennaRNA/partfunc/exterior.h>
-
void vrna_exp_E_ext_fast_free(vrna_mx_pf_aux_el_t aux_mx)#
#include <ViennaRNA/partfunc/exterior.h>
-
FLT_OR_DBL vrna_exp_E_ext_fast(vrna_fold_compound_t *fc, int i, int j, vrna_mx_pf_aux_el_t aux_mx)#
#include <ViennaRNA/partfunc/exterior.h>
-
void vrna_exp_E_ext_fast_update(vrna_fold_compound_t *fc, int j, vrna_mx_pf_aux_el_t aux_mx)#
#include <ViennaRNA/partfunc/exterior.h>
Basic free energy interface
-
int vrna_E_exterior_stem(unsigned int type, int n5d, int n3d, vrna_param_t *p)#
Evaluate a stem branching off the exterior loop.
#include <ViennaRNA/eval/exterior.h>
Given a base pair \((i,j)\) encoded by type, compute the energy contribution including dangling-end/terminal-mismatch contributions. Instead of returning the energy contribution per-se, this function returns the corresponding Boltzmann factor. If either of the adjacent nucleotides \((i - 1)\) and \((j+1)\) must not contribute stacking energy, the corresponding encoding must be \(-1\).
See also
Note
By default, terminal mismatch energies are applied that correspond to the neighboring nucleotides provided by their encodings
n5dandn3d. Whenever the encodings are negative, the implementation switches to usage of dangling end energies (for the non-negative base). If both encodings are negative, no terminal mismatch contributions are added.- Parameters:
type – The base pair encoding
n5d – The encoded nucleotide directly adjacent at the 5’ side of the base pair (may be -1)
n3d – The encoded nucleotide directly adjacent at the 3’ side of the base pair (may be -1)
p – The pre-computed energy parameters
- Returns:
The energy contribution of the introduced exterior-loop stem
-
int vrna_eval_exterior_stem(vrna_fold_compound_t *fc, unsigned int i, unsigned int j, unsigned int options)#
Evaluate the free energy of a base pair in the exterior loop.
#include <ViennaRNA/eval/exterior.h>
Evalue the free energy of a base pair connecting two nucleotides in the exterior loop and take hard constraints into account.
Typically, this is simply dangling end contributions of the adjacent nucleotides, potentially a terminal A-U mismatch penalty, and maybe some generic soft constraint contribution for that decomposition.
See also
vrna_E_exterior_stem(), VRNA_EVAL_LOOP_NO_HC, VRNA_EVAL_LOOP_NO_SC, VRNA_EVAL_LOOP_NO_CONSTRAINTS
Note
For dangles == 1 || 3 this function also evaluates the three additional pairs (i + 1, j), (i, j - 1), and (i + 1, j - 1) and returns the minimum for all four possibilities in total.
Note
By default, all user-supplied hard- and soft constraints will be taken into account! Use the VRNA_EVAL_LOOP_NO_HC and VRNA_EVAL_LOOP_NO_SC bit flags as input for
optionsto change the default behavior if necessary.- Parameters:
fc – Fold compound to work on (defines the model and parameters)
i – 5’ position of the base pair
j – 3’ position of the base pair
options – A bit-field that specifies which aspects (not) to consider during evaluation
- Returns:
Free energy for the terminal base pair of a stem branching off the exterior loop in deka-kal/mol or INF if the pair is forbidden
Boltzmann weight (partition function) interface
-
FLT_OR_DBL vrna_exp_E_exterior_stem(unsigned int type, int n5d, int n3d, vrna_exp_param_t *p)#
Evaluate a stem branching off the exterior loop (Boltzmann factor version).
#include <ViennaRNA/eval/exterior.h>
Given a base pair \((i,j)\) encoded by type, compute the energy contribution including dangling-end/terminal-mismatch contributions. Instead of returning the energy contribution per-se, this function returns the corresponding Boltzmann factor.
See also
vrna_E_exterior()
Note
By default, terminal mismatch energies are applied that correspond to the neighboring nucleotides provided by their encodings
n5dandn3d. Whenever the encodings are negative, the implementation switches to usage of dangling end energies (for the non-negative base). If both encodings are negative, no terminal mismatch contributions are added.- Parameters:
type – The base pair encoding
n5d – The encoded nucleotide directly adjacent at the 5’ side of the base pair (may be -1)
n3d – The encoded nucleotide directly adjacent at the 3’ side of the base pair (may be -1)
p – The pre-computed energy parameters (Boltzmann factor version)
- Returns:
The Boltzmann weighted energy contribution of the introduced exterior-loop stem
-
FLT_OR_DBL vrna_exp_E_exterior_loop(unsigned int n, vrna_md_t *md)#
#include <ViennaRNA/eval/exterior.h>
Minimum Free Energy API
-
int vrna_mfe_exterior_f5(vrna_fold_compound_t *fc)#
#include <ViennaRNA/mfe/exterior.h>
-
int vrna_mfe_exterior_f3(vrna_fold_compound_t *fc, unsigned int i)#
#include <ViennaRNA/mfe/exterior.h>
Functions
-
int vrna_E_ext_loop_5(vrna_fold_compound_t *fc)#
#include <ViennaRNA/mfe/exterior.h>
-
int vrna_E_ext_loop_3(vrna_fold_compound_t *fc)#
#include <ViennaRNA/mfe/exterior.h>
-
typedef struct vrna_mx_pf_aux_el_s *vrna_mx_pf_aux_el_t#
Hairpin Loops#
Functions to evaluate the free energy contributions for hairpin loops.
Basic free energy interface
-
int vrna_E_hairpin(unsigned int size, unsigned int type, int si1, int sj1, const char *sequence, vrna_param_t *P)#
Retrieve the energy of a hairpin-loop.
#include <ViennaRNA/eval/hairpin.h>
To evaluate the free energy of a hairpin-loop, several parameters have to be known. A general hairpin-loop has this structure:
a3 a4
a2 a5
a1 a6
X - Y
| |
5’ 3’
where X-Y marks the closing pair [e.g. a (G,C) pair]. The length of this loop is 6 as there are six unpaired nucleotides (a1-a6) enclosed by (X,Y). The 5’ mismatching nucleotide is a1 while the 3’ mismatch is a6. The nucleotide sequence of this loop is “a1.a2.a3.a4.a5.a6”See also
Note
Whenever one of the mismatch base encodings
si1orsj1is negative, terminal mismatch energies are not applied!Note
The parameter
sequenceis a 0-terminated string of sizesize+ 2 that contain the nucleic acid sequence of the loop in upper-case letters. This parameter is only required for loops ofsizebelow 7, since it is used for look-up of unusually stable tri-, tetra- and hexa-loops, such as GNRA tetra loops. Those may have additional sequence-dependent tabulated free energies available.Warning
This function only evaluates the free energy of a hairpin loop according to the current Turner energy parameter set! No additional hard- or soft constraints are applied. See vrna_eval_hp_loop() for a function that also takes into account any user-supplied constraints!
- Parameters:
size – The size of the loop (number of unpaired nucleotides)
type – The pair type of the base pair closing the hairpin
si1 – The 5’-mismatching nucleotide
sj1 – The 3’-mismatching nucleotide
sequence – The sequence of the loop (May be
NULL, otherwise mst be at least \(size + 2\) long)P – The datastructure containing scaled energy parameters
- Returns:
The Free energy of the Hairpin-loop in dcal/mol
-
int vrna_eval_hairpin(vrna_fold_compound_t *fc, unsigned int i, unsigned int j, unsigned int options)#
Evaluate free energy of a hairpin loop.
#include <ViennaRNA/eval/hairpin.h>
This function evaluates the free energy of a hairpin loop closed by a base pair (i,j). By default (
options= VRNA_EVAL_LOOP_DEFAULT), all user-supplied constraints will be taken into consideration. This means that any hard constraints that prohibit the formation of this loop will result in an energy contribution of INF. On the other hand, if, given the set of constraints, the loop is allowed then its free energy is evaluated according to the Nearest Neighbor energy parameter set. On top of that, any user-supplied soft-constraints will be added, if applicable.The
optionsargument allows for (de-)activating certain aspects of the evaluation, e.g. hard constraints, soft constraints, etc.See also
vrna_E_hairpin(), vrna_exp_eval_hairpin(), VRNA_EVAL_LOOP_NO_HC, VRNA_EVAL_LOOP_NO_SC, VRNA_EVAL_LOOP_NO_CONSTRAINTS
Note
If sequence position
iis larger thanj, the function assumes a hairpin loop formed by a circular RNA, where the unpaired loop sequence spans the n,1-junction.Note
By default, all user-supplied hard- and soft constraints will be taken into account! Use the VRNA_EVAL_LOOP_NO_HC and VRNA_EVAL_LOOP_NO_SC bit flags as input for
optionsto change the default behavior if necessary.Note
This function is polymorphic! The provided vrna_fold_compound_t may be of type VRNA_FC_TYPE_SINGLE or VRNA_FC_TYPE_COMPARATIVE
- Parameters:
fc – The vrna_fold_compound_t for the particular energy evaluation
i – 5’-position of the base pair
j – 3’-position of the base pair
options – A bit-field that specifies which aspects (not) to consider during evaluation
- Returns:
Free energy of the hairpin loop closed by \( (i,j) \) in deka-kal/mol or INF if the loop is forbidden
Boltzmann weight (partition function) interface
-
FLT_OR_DBL vrna_exp_E_hairpin(unsigned int size, unsigned int type, int si1, int sj1, const char *sequence, vrna_exp_param_t *P)#
Compute Boltzmann weight \(e^{-\Delta G/kT} \) of a hairpin loop.
#include <ViennaRNA/eval/hairpin.h>
This is the partition function variant of vrna_E_hp() that returns the Boltzmann weight \(e^{-\Delta E/kT} \) instead of the energy \( E \).
See also
vrna_exp_eval_hp_loop(), vrna_exp_param_t, vrna_E_hp()
Note
Whenever one of the mismatch base encodings
si1orsj1is negative, terminal mismatch energies are not applied!Note
Do not forget to scale this Bolztmann factor properly, e.g. by multiplying with scale[u+2]
- Parameters:
size – The size of the loop (number of unpaired nucleotides)
type – The pair type of the base pair closing the hairpin
si1 – The 5’-mismatching nucleotide
sj1 – The 3’-mismatching nucleotide
sequence – The sequence of the loop (May be
NULL, otherwise mst be at least \(size + 2\) long)P – The datastructure containing scaled Boltzmann weights of the energy parameters
- Returns:
The Boltzmann weight of the Hairpin-loop
-
FLT_OR_DBL vrna_exp_eval_hairpin(vrna_fold_compound_t *fc, unsigned int i, unsigned int j, unsigned int options)#
High-Level function for hairpin loop energy evaluation (partition function variant).
#include <ViennaRNA/eval/hairpin.h>
This is the partition function variant of vrna_eval_hp_loop() that returns the Boltzmann weight \(e^{-\Delta E/kT} \) instead of the energy \( E \). On top of all constraints application, this function already scales the Boltzmann factor, i.e. it multiplies the result with scale[u + 2]
The
optionsargument allows for (de-)activating certain aspects of the evaluation, e.g. hard constraints, soft constraints, etc.See also
vrna_eval_hairpin(), vrna_exp_E_hairpin(), VRNA_EVAL_LOOP_NO_HC, VRNA_EVAL_LOOP_NO_SC, VRNA_EVAL_LOOP_NO_CONSTRAINTS
Note
If sequence position
iis larger thanj, the function assumes a hairpin loop formed by a circular RNA, where the unpaired loop sequence spans the n,1-junction.Note
By default, all user-supplied hard- and soft constraints will be taken into account! Use the VRNA_EVAL_LOOP_NO_HC and VRNA_EVAL_LOOP_NO_SC bit flags to change the default behavior if necessary.
Note
This function is polymorphic! The provided vrna_fold_compound_t may be of type VRNA_FC_TYPE_SINGLE or VRNA_FC_TYPE_COMPARATIVE
- Parameters:
fc – The vrna_fold_compound_t for the particular energy evaluation
i – 5’-position of the base pair
j – 3’-position of the base pair
options – A bit-field that specifies which aspects (not) to consider during evaluation
- Returns:
Boltzmann factor of the free energy of the hairpin loop closed by \( (i,j) \) or 0. if the loop is forbidden
-
int vrna_E_hairpin(unsigned int size, unsigned int type, int si1, int sj1, const char *sequence, vrna_param_t *P)#
Internal Loops#
Functions to evaluate the free energy contributions for internal loops.
Basic free energy interface
-
int vrna_E_internal(unsigned int n1, unsigned int n2, unsigned int type, unsigned int type_2, int si1, int sj1, int sp1, int sq1, vrna_param_t *P)#
Compute the Energy of an internal loop.
#include <ViennaRNA/eval/internal.h>
This function computes the free energy \( E \) of an internal-loop with the following structure:
3’ 5’
| |
U - V
a_n b_1
. .
. .
. .
a_1 b_m
X - Y
| |
5’ 3’
This general structure depicts an internal-loop that is closed by the base pair (X,Y). The enclosed base pair is (V,U) which leaves the unpaired bases a_1-a_n and b_1-b_n that constitute the loop. In this example, the length of the internal-loop is \((n+m)\)where n or m may be 0 resulting in a bulge-loop or base pair stack. The mismatching nucleotides for the closing pair (X,Y) are:
5’-mismatch: a_1
3’-mismatch: b_m
and for the enclosed base pair (V,U):
5’-mismatch: b_1
3’-mismatch: a_n
See also
vrna_exp_E_internal()
Note
Base pairs are always denoted in 5’->3’ direction. Thus the enclosed base pair must be ‘turned arround’ when evaluating the free energy of the internal-loop
This function is threadsafe
- Parameters:
n1 – The size of the ‘left’-loop (number of unpaired nucleotides)
n2 – The size of the ‘right’-loop (number of unpaired nucleotides)
type – The pair type of the base pair closing the internal loop
type_2 – The pair type of the enclosed base pair
si1 – The 5’-mismatching nucleotide of the closing pair
sj1 – The 3’-mismatching nucleotide of the closing pair
sp1 – The 3’-mismatching nucleotide of the enclosed pair
sq1 – The 5’-mismatching nucleotide of the enclosed pair
P – The datastructure containing scaled energy parameters
- Returns:
The Free energy of the internal loop in dcal/mol
-
int vrna_en_internal(unsigned int n1, unsigned int n2, unsigned int type, unsigned int type_2, unsigned int si1, unsigned int sj1, unsigned int sp1, unsigned int sq1, vrna_param_t *P)#
Compute the Energy of an internal loop.
#include <ViennaRNA/eval/internal.h>
This function computes the free energy \( E \) of an internal-loop with the following structure:
3’ 5’
| |
U - V
a_n b_1
. .
. .
. .
a_1 b_m
X - Y
| |
5’ 3’
This general structure depicts an internal-loop that is closed by the base pair (X,Y). The enclosed base pair is (V,U) which leaves the unpaired bases a_1-a_n and b_1-b_n that constitute the loop. In this example, the length of the internal-loop is \((n+m)\)where n or m may be 0 resulting in a bulge-loop or base pair stack. The mismatching nucleotides for the closing pair (X,Y) are:
5’-mismatch: a_1
3’-mismatch: b_m
and for the enclosed base pair (V,U):
5’-mismatch: b_1
3’-mismatch: a_n
See also
vrna_exp_E_internal()
Note
Base pairs are always denoted in 5’->3’ direction. Thus the enclosed base pair must be ‘turned arround’ when evaluating the free energy of the internal-loop
This function is threadsafe
- Parameters:
n1 – The size of the ‘left’-loop (number of unpaired nucleotides)
n2 – The size of the ‘right’-loop (number of unpaired nucleotides)
type – The pair type of the base pair closing the internal loop
type_2 – The pair type of the enclosed base pair
si1 – The 5’-mismatching nucleotide of the closing pair
sj1 – The 3’-mismatching nucleotide of the closing pair
sp1 – The 3’-mismatching nucleotide of the enclosed pair
sq1 – The 5’-mismatching nucleotide of the enclosed pair
P – The datastructure containing scaled energy parameters
- Returns:
The Free energy of the internal loop in dcal/mol
-
int vrna_en_bulge(unsigned int n, unsigned int type, unsigned int type_2, vrna_param_t *P)#
#include <ViennaRNA/eval/internal.h>
-
int vrna_en_stack(unsigned int type, unsigned int type_2, vrna_param_t *P)#
#include <ViennaRNA/eval/internal.h>
-
int vrna_eval_internal(vrna_fold_compound_t *fc, unsigned int i, unsigned int j, unsigned int k, unsigned int l, unsigned int options)#
Evaluate the free energy contribution of an internal loop with delimiting base pairs \((i,j)\) and \((k,l)\).
#include <ViennaRNA/eval/internal.h>
Note
This function is polymorphic, i.e. it accepts vrna_fold_compound_t of type VRNA_FC_TYPE_SINGLE as well as VRNA_FC_TYPE_COMPARATIVE
-
int vrna_eval_stack(vrna_fold_compound_t *fc, unsigned int i, unsigned int j, unsigned int options)#
#include <ViennaRNA/eval/internal.h>
Boltzmann weight (partition function) interface
-
FLT_OR_DBL vrna_exp_E_internal(unsigned int n1, unsigned int n2, unsigned int type, unsigned int type_2, int si1, int sj1, int sp1, int sq1, vrna_exp_param_t *P)#
#include <ViennaRNA/eval/internal.h>
-
FLT_OR_DBL vrna_exp_eval_internal(vrna_fold_compound_t *fc, unsigned int i, unsigned int j, unsigned int k, unsigned int l, unsigned int options)#
#include <ViennaRNA/eval/internal.h>
-
FLT_OR_DBL vrna_exp_eval_stack(vrna_fold_compound_t *fc, unsigned int i, unsigned int j, unsigned int options)#
#include <ViennaRNA/eval/internal.h>
Minimum Free Energy API
-
int vrna_mfe_internal(vrna_fold_compound_t *fc, unsigned int i, unsigned int j)#
#include <ViennaRNA/mfe/internal.h>
-
int vrna_mfe_internal_ext(vrna_fold_compound_t *fc, unsigned int i, unsigned int j, unsigned int *ip, unsigned int *iq)#
#include <ViennaRNA/mfe/internal.h>
Boltzmann weight (partition function) interface
-
FLT_OR_DBL vrna_exp_E_int_loop(vrna_fold_compound_t *fc, int i, int j)#
#include <ViennaRNA/partfunc/internal.h>
Functions
-
int vrna_E_int_loop(vrna_fold_compound_t *fc, int i, int j)#
#include <ViennaRNA/mfe/internal.h>
-
int vrna_E_ext_int_loop(vrna_fold_compound_t *fc, int i, int j, int *ip, int *iq)#
#include <ViennaRNA/mfe/internal.h>
-
int vrna_E_internal(unsigned int n1, unsigned int n2, unsigned int type, unsigned int type_2, int si1, int sj1, int sp1, int sq1, vrna_param_t *P)#
Multibranch Loops#
Functions to evaluate the free energy contributions for mutlibranch loops.
Minimum Free Energy API
-
typedef struct vrna_mx_mfe_aux_ml_s *vrna_mx_mfe_aux_ml_t#
#include <ViennaRNA/mfe/multibranch.h>
-
vrna_mx_mfe_aux_ml_t vrna_mfe_multibranch_fast_init(unsigned int length)#
#include <ViennaRNA/mfe/multibranch.h>
-
void vrna_mfe_multibranch_fast_rotate(vrna_mx_mfe_aux_ml_t aux)#
#include <ViennaRNA/mfe/multibranch.h>
-
void vrna_mfe_multibranch_fast_free(vrna_mx_mfe_aux_ml_t aux)#
#include <ViennaRNA/mfe/multibranch.h>
-
int vrna_mfe_multibranch_loop_fast(vrna_fold_compound_t *fc, unsigned int i, unsigned int j, vrna_mx_mfe_aux_ml_t helpers)#
#include <ViennaRNA/mfe/multibranch.h>
-
int vrna_mfe_multibranch_stems_fast(vrna_fold_compound_t *fc, unsigned int i, unsigned int j, struct vrna_mx_mfe_aux_ml_s *helpers)#
#include <ViennaRNA/mfe/multibranch.h>
-
int vrna_mfe_multibranch_m2_fast(vrna_fold_compound_t *fc, unsigned int i, unsigned int j, struct vrna_mx_mfe_aux_ml_s *helpers)#
#include <ViennaRNA/mfe/multibranch.h>
-
int vrna_mfe_multibranch_loop_stack(vrna_fold_compound_t *fc, unsigned int i, unsigned int j)#
Evaluate energy of multi branch loop helices stacking onto closing pair (i,j).
#include <ViennaRNA/mfe/multibranch.h>
Computes total free energy for coaxial stacking of (i.j) with (i+1.k) or (k+1.j-1)
-
int vrna_mfe_multibranch_m1(vrna_fold_compound_t *fc, unsigned int i, unsigned int j)#
#include <ViennaRNA/mfe/multibranch.h>
Boltzmann weight (partition function) interface
-
typedef struct vrna_mx_pf_aux_ml_s *vrna_mx_pf_aux_ml_t#
Auxiliary helper arrays for fast exterior loop computations.
#include <ViennaRNA/partfunc/multibranch.h>
See also
vrna_exp_E_ml_fast_init(), vrna_exp_E_ml_fast_rotate(), vrna_exp_E_ml_fast_free(), vrna_exp_E_ml_fast()
-
FLT_OR_DBL vrna_exp_E_mb_loop_fast(vrna_fold_compound_t *fc, int i, int j, vrna_mx_pf_aux_ml_t aux_mx)#
#include <ViennaRNA/partfunc/multibranch.h>
-
vrna_mx_pf_aux_ml_t vrna_exp_E_ml_fast_init(vrna_fold_compound_t *fc)#
#include <ViennaRNA/partfunc/multibranch.h>
-
void vrna_exp_E_ml_fast_rotate(vrna_mx_pf_aux_ml_t aux_mx)#
#include <ViennaRNA/partfunc/multibranch.h>
-
void vrna_exp_E_ml_fast_free(vrna_mx_pf_aux_ml_t aux_mx)#
#include <ViennaRNA/partfunc/multibranch.h>
-
const FLT_OR_DBL *vrna_exp_E_ml_fast_qqm(vrna_mx_pf_aux_ml_t aux_mx)#
#include <ViennaRNA/partfunc/multibranch.h>
-
const FLT_OR_DBL *vrna_exp_E_ml_fast_qqm1(vrna_mx_pf_aux_ml_t aux_mx)#
#include <ViennaRNA/partfunc/multibranch.h>
-
FLT_OR_DBL vrna_exp_E_ml_fast(vrna_fold_compound_t *fc, int i, int j, vrna_mx_pf_aux_ml_t aux_mx)#
#include <ViennaRNA/partfunc/multibranch.h>
-
FLT_OR_DBL vrna_exp_E_m2_fast(vrna_fold_compound_t *fc, int i, int j, struct vrna_mx_pf_aux_ml_s *aux_mx)#
#include <ViennaRNA/partfunc/multibranch.h>
Basic free energy interface
-
int vrna_E_multibranch_stem(unsigned int type, int si1, int sj1, vrna_param_t *P)#
Evaluate the free energy contribution of a stem branching off a multibranch loop.
#include <ViennaRNA/eval/multibranch.h>
This function yields the free energy contribution for the terminal base pairs of a stem branching off a multibranch loop. In essence, this consists of (i) a terminal mismatch or dangling end contribution, (ii) the score for a stem according to the affine multibranch loop model, and (iii) a terminal AU/GU penalty, if applicable.
Note
By default, terminal mismatch energies are applied that correspond to the neighboring nucleotides provided by their encodings
n5dandn3d. Whenever the encodings are negative, the implementation switches to usage of dangling end energies (for the non-negative base). If both encodings are negative, no terminal mismatch contributions are added.- Parameters:
type – The base pair encoding
si1 – The encoded nucleotide directly adjacent at the 5’ side of the base pair (may be -1)
sj1 – The encoded nucleotide directly adjacent at the 3’ side of the base pair (may be -1)
P – The pre-computed energy parameters
- Returns:
The energy contribution of the introduced mutlibranch loop stem
Boltzmann weight (partition function) interface
-
FLT_OR_DBL vrna_exp_E_multibranch_stem(unsigned int type, int si1, int sj1, vrna_exp_param_t *P)#
Evaluate the free energy contribution of a stem branching off a multibranch loop (Boltzmann factor version).
#include <ViennaRNA/eval/multibranch.h>
This function yields the free energy contribution as Boltzmann factor \( exp(-E/kT) \) for the terminal base pairs of a stem branching off a multibranch loop. In essence, this consists of (i) a terminal mismatch or dangling end contribution, (ii) the score for a stem according to the affine multibranch loop model, and (iii) a terminal AU/GU penalty, if applicable.
Note
By default, terminal mismatch energies are applied that correspond to the neighboring nucleotides provided by their encodings
n5dandn3d. Whenever the encodings are negative, the implementation switches to usage of dangling end energies (for the non-negative base). If both encodings are negative, no terminal mismatch contributions are added.- Parameters:
type – The base pair encoding
si1 – The encoded nucleotide directly adjacent at the 5’ side of the base pair (may be -1)
sj1 – The encoded nucleotide directly adjacent at the 3’ side of the base pair (may be -1)
P – The pre-computed energy parameters (Boltzmann factor version)
- Returns:
The Boltzmann factor of the energy contribution for the introduced mutlibranch loop stem
-
typedef struct vrna_mx_mfe_aux_ml_s *vrna_mx_mfe_aux_ml_t#
Energy Evaluation for Atomic Moves#
Functions to evaluate the free energy change of a structure after application of (a set of) atomic moves
Functions
-
float vrna_eval_move(vrna_fold_compound_t *fc, const char *structure, int m1, int m2)#
Calculate energy of a move (closing or opening of a base pair).
#include <ViennaRNA/eval/structures.h>
If the parameters m1 and m2 are negative, it is deletion (opening) of a base pair, otherwise it is insertion (opening).
- SWIG Wrapper Notes:
This function is attached as method
eval_move()to objects of typefold_compound. See, e.g.RNA.fold_compound.eval_move()in the The RNA Python module .
See also
- Parameters:
fc – A vrna_fold_compound_t containing the energy parameters and model details
structure – secondary structure in dot-bracket notation
m1 – first coordinate of base pair
m2 – second coordinate of base pair
- Returns:
energy change of the move in kcal/mol (INF / 100. upon any error)
-
int vrna_eval_move_pt(vrna_fold_compound_t *fc, short *pt, int m1, int m2)#
Calculate energy of a move (closing or opening of a base pair).
#include <ViennaRNA/eval/structures.h>
If the parameters m1 and m2 are negative, it is deletion (opening) of a base pair, otherwise it is insertion (opening).
- SWIG Wrapper Notes:
This function is attached as method
eval_move_pt()to objects of typefold_compound. See, e.g.RNA.fold_compound.eval_move_pt()in the The RNA Python module .
See also
- Parameters:
fc – A vrna_fold_compound_t containing the energy parameters and model details
pt – the pair table of the secondary structure
m1 – first coordinate of base pair
m2 – second coordinate of base pair
- Returns:
energy change of the move in 10cal/mol
-
int vrna_eval_move_pt_simple(const char *string, short *pt, int m1, int m2)#
#include <ViennaRNA/eval/structures.h>
-
int vrna_eval_move_shift_pt(vrna_fold_compound_t *fc, vrna_move_t *m, short *structure)#
#include <ViennaRNA/eval/structures.h>
-
float vrna_eval_move(vrna_fold_compound_t *fc, const char *structure, int m1, int m2)#
Evaluation of Structures#
Functions to evaluate the free energy of secondary structures under a particular set of parameters.
Basic Energy Evaluation Interface with Dot-Bracket Structure String
-
float vrna_eval_structure(vrna_fold_compound_t *fc, const char *structure)#
Calculate the free energy of an already folded RNA.
#include <ViennaRNA/eval/structures.h>
This function allows for energy evaluation of a given pair of structure and sequence (alignment). Model details, energy parameters, and possibly soft constraints are used as provided via the parameter ‘fc’. The vrna_fold_compound_t does not need to contain any DP matrices, but requires all most basic init values as one would get from a call like this:
fc = vrna_fold_compound(sequence, NULL, VRNA_OPTION_EVAL_ONLY);
- SWIG Wrapper Notes:
This function is attached as method
eval_structure()to objects of typefold_compound. See, e.g.RNA.fold_compound.eval_structure()in the The RNA Python module .
See also
vrna_eval_structure_pt(), vrna_eval_structure_verbose(), vrna_eval_structure_pt_verbose(), vrna_fold_compound(), vrna_fold_compound_comparative(), vrna_eval_covar_structure()
Note
Accepts vrna_fold_compound_t of type VRNA_FC_TYPE_SINGLE and VRNA_FC_TYPE_COMPARATIVE
- Parameters:
fc – A vrna_fold_compound_t containing the energy parameters and model details
structure – Secondary structure in dot-bracket notation
- Returns:
The free energy of the input structure given the input sequence in kcal/mol
-
float vrna_eval_covar_structure(vrna_fold_compound_t *fc, const char *structure)#
Calculate the pseudo energy derived by the covariance scores of a set of aligned sequences.
#include <ViennaRNA/eval/structures.h>
Consensus structure prediction is driven by covariance scores of base pairs in rows of the provided alignment. This function allows one to retrieve the total amount of this covariance pseudo energy scores. The vrna_fold_compound_t does not need to contain any DP matrices, but requires all most basic init values as one would get from a call like this:
fc = vrna_fold_compound_comparative(alignment, NULL, VRNA_OPTION_EVAL_ONLY);
- SWIG Wrapper Notes:
This function is attached as method
eval_covar_structure()to objects of typefold_compound. See, e.g.RNA.fold_compound.eval_covar_structure()in the The RNA Python module .
Note
Accepts vrna_fold_compound_t of type VRNA_FC_TYPE_COMPARATIVE only!
- Parameters:
fc – A vrna_fold_compound_t containing the energy parameters and model details
structure – Secondary (consensus) structure in dot-bracket notation
- Returns:
The covariance pseudo energy score of the input structure given the input sequence alignment in kcal/mol
-
float vrna_eval_structure_verbose(vrna_fold_compound_t *fc, const char *structure, FILE *file)#
Calculate the free energy of an already folded RNA and print contributions on a per-loop base.
#include <ViennaRNA/eval/structures.h>
This function is a simplyfied version of vrna_eval_structure_v() that uses the default verbosity level.
- SWIG Wrapper Notes:
This function is attached as method
eval_structure_verbose()to objects of typefold_compound. See, e.g.RNA.fold_compound.eval_structure_verbose()in the The RNA Python module .
- Parameters:
fc – A vrna_fold_compound_t containing the energy parameters and model details
structure – Secondary structure in dot-bracket notation
file – A file handle where this function should print to (may be NULL).
- Returns:
The free energy of the input structure given the input sequence in kcal/mol
-
float vrna_eval_structure_v(vrna_fold_compound_t *fc, const char *structure, int verbosity_level, FILE *file)#
Calculate the free energy of an already folded RNA and print contributions on a per-loop base.
#include <ViennaRNA/eval/structures.h>
This function allows for detailed energy evaluation of a given sequence/structure pair. In contrast to vrna_eval_structure() this function prints detailed energy contributions based on individual loops to a file handle. If NULL is passed as file handle, this function defaults to print to stdout. Any positive
verbosity_levelactivates potential warning message of the energy evaluting functions, while values \( \ge 1 \) allow for detailed control of what data is printed. A negative parameterverbosity_levelturns off printing all together.Model details, energy parameters, and possibly soft constraints are used as provided via the parameter ‘fc’. The fold_compound does not need to contain any DP matrices, but all the most basic init values as one would get from a call like this:
fc = vrna_fold_compound(sequence, NULL, VRNA_OPTION_EVAL_ONLY);
- Parameters:
fc – A vrna_fold_compound_t containing the energy parameters and model details
structure – Secondary structure in dot-bracket notation
verbosity_level – The level of verbosity of this function
file – A file handle where this function should print to (may be NULL).
- Returns:
The free energy of the input structure given the input sequence in kcal/mol
-
float vrna_eval_structure_cstr(vrna_fold_compound_t *fc, const char *structure, int verbosity_level, vrna_cstr_t output_stream)#
#include <ViennaRNA/eval/structures.h>
Basic Energy Evaluation Interface with Structure Pair Table
-
int vrna_eval_structure_pt(vrna_fold_compound_t *fc, const short *pt)#
Calculate the free energy of an already folded RNA.
#include <ViennaRNA/eval/structures.h>
This function allows for energy evaluation of a given sequence/structure pair where the structure is provided in pair_table format as obtained from vrna_ptable(). Model details, energy parameters, and possibly soft constraints are used as provided via the parameter ‘fc’. The fold_compound does not need to contain any DP matrices, but all the most basic init values as one would get from a call like this:
fc = vrna_fold_compound(sequence, NULL, VRNA_OPTION_EVAL_ONLY);
- SWIG Wrapper Notes:
This function is attached as method
eval_structure_pt()to objects of typefold_compound. See, e.g.RNA.fold_compound.eval_structure_pt()in the The RNA Python module .
- Parameters:
fc – A vrna_fold_compound_t containing the energy parameters and model details
pt – Secondary structure as pair_table
- Returns:
The free energy of the input structure given the input sequence in 10cal/mol
-
int vrna_eval_structure_pt_verbose(vrna_fold_compound_t *fc, const short *pt, FILE *file)#
Calculate the free energy of an already folded RNA.
#include <ViennaRNA/eval/structures.h>
This function is a simplyfied version of vrna_eval_structure_simple_v() that uses the default verbosity level.
- SWIG Wrapper Notes:
This function is attached as method
eval_structure_pt_verbose()to objects of typefold_compound. See, e.g.RNA.fold_compound.eval_structure_pt_verbose()in the The RNA Python module .
See also
vrna_eval_structure_pt_v(), vrna_ptable(), vrna_eval_structure_pt(), vrna_eval_structure_verbose()
- Parameters:
fc – A vrna_fold_compound_t containing the energy parameters and model details
pt – Secondary structure as pair_table
file – A file handle where this function should print to (may be NULL).
- Returns:
The free energy of the input structure given the input sequence in 10cal/mol
-
int vrna_eval_structure_pt_v(vrna_fold_compound_t *fc, const short *pt, int verbosity_level, FILE *file)#
Calculate the free energy of an already folded RNA.
#include <ViennaRNA/eval/structures.h>
This function allows for energy evaluation of a given sequence/structure pair where the structure is provided in pair_table format as obtained from vrna_ptable(). Model details, energy parameters, and possibly soft constraints are used as provided via the parameter ‘fc’. The fold_compound does not need to contain any DP matrices, but all the most basic init values as one would get from a call like this:
In contrast to vrna_eval_structure_pt() this function prints detailed energy contributions based on individual loops to a file handle. If NULL is passed as file handle, this function defaults to print to stdout. Any positivefc = vrna_fold_compound(sequence, NULL, VRNA_OPTION_EVAL_ONLY);
verbosity_levelactivates potential warning message of the energy evaluting functions, while values \( \ge 1 \) allow for detailed control of what data is printed. A negative parameterverbosity_levelturns off printing all together.- Parameters:
fc – A vrna_fold_compound_t containing the energy parameters and model details
pt – Secondary structure as pair_table
verbosity_level – The level of verbosity of this function
file – A file handle where this function should print to (may be NULL).
- Returns:
The free energy of the input structure given the input sequence in 10cal/mol
Simplified Energy Evaluation with Sequence and Dot-Bracket Strings
-
float vrna_eval_structure_simple(const char *string, const char *structure)#
Calculate the free energy of an already folded RNA.
#include <ViennaRNA/eval/structures.h>
This function allows for energy evaluation of a given sequence/structure pair. In contrast to vrna_eval_structure() this function assumes default model details and default energy parameters in order to evaluate the free energy of the secondary structure. Therefore, it serves as a simple interface function for energy evaluation for situations where no changes on the energy model are required.
- SWIG Wrapper Notes:
In the target scripting language, this function serves as a wrapper for vrna_eval_structure_simple_v() and, thus, allows for two additional, optional arguments, the verbosity level and a file handle which default to VRNA_VERBOSITY_QUIET and
NULL, respectively.. See, e.g.RNA.eval_structure_simple()in the The RNA Python module .
See also
vrna_eval_structure(), vrna_eval_structure_pt(), vrna_eval_structure_verbose(), vrna_eval_structure_pt_verbose(),
- Parameters:
string – RNA sequence in uppercase letters
structure – Secondary structure in dot-bracket notation
- Returns:
The free energy of the input structure given the input sequence in kcal/mol
-
float vrna_eval_circ_structure(const char *string, const char *structure)#
Evaluate the free energy of a sequence/structure pair where the sequence is circular.
#include <ViennaRNA/eval/structures.h>
- SWIG Wrapper Notes:
In the target scripting language, this function serves as a wrapper for vrna_eval_circ_structure_v() and, thus, allows for two additional, optional arguments, the verbosity level and a file handle which default to VRNA_VERBOSITY_QUIET and
NULL, respectively.. See, e.g.RNA.eval_circ_structure()in the The RNA Python module .
See also
vrna_eval_structure_simple(), vrna_eval_gquad_structure(), vrna_eval_circ_consensus_structure(), vrna_eval_circ_structure_v(), vrna_eval_structure()
- Parameters:
string – RNA sequence in uppercase letters
structure – Secondary structure in dot-bracket notation
- Returns:
The free energy of the structure given the circular input sequence in kcal/mol
-
float vrna_eval_gquad_structure(const char *string, const char *structure)#
Evaluate the free energy of a sequence/structure pair where the structure may contain G-Quadruplexes.
#include <ViennaRNA/eval/structures.h>
G-Quadruplexes are annotated as plus signs (‘+’) for each G involved in the motif. Linker sequences must be denoted by dots (‘.’) as they are considered unpaired. Below is an example of a 2-layer G-quadruplex:
GGAAGGAAAGGAGG ++..++...++.++
- SWIG Wrapper Notes:
In the target scripting language, this function serves as a wrapper for vrna_eval_gquad_structure_v() and, thus, allows for two additional, optional arguments, the verbosity level and a file handle which default to VRNA_VERBOSITY_QUIET and
NULL, respectively.. See, e.g.RNA.eval_gquad_structure()in the The RNA Python module .
See also
vrna_eval_structure_simple(), vrna_eval_circ_structure(), vrna_eval_gquad_consensus_structure(), vrna_eval_gquad_structure_v(), vrna_eval_structure()
- Parameters:
string – RNA sequence in uppercase letters
structure – Secondary structure in dot-bracket notation
- Returns:
The free energy of the structure including contributions of G-quadruplexes in kcal/mol
-
float vrna_eval_circ_gquad_structure(const char *string, const char *structure)#
Evaluate the free energy of a sequence/structure pair where the sequence is circular and the structure may contain G-Quadruplexes.
#include <ViennaRNA/eval/structures.h>
G-Quadruplexes are annotated as plus signs (‘+’) for each G involved in the motif. Linker sequences must be denoted by dots (‘.’) as they are considered unpaired. Below is an example of a 2-layer G-quadruplex:
GGAAGGAAAGGAGG ++..++...++.++
- SWIG Wrapper Notes:
In the target scripting language, this function serves as a wrapper for vrna_eval_circ_gquad_structure_v() and, thus, allows for two additional, optional arguments, the verbosity level and a file handle which default to VRNA_VERBOSITY_QUIET and
NULL, respectively.. See, e.g.RNA.eval_circ_gquad_structure()in the The RNA Python module .
See also
vrna_eval_structure_simple(), vrna_eval_circ_gquad_consensus_structure(), vrna_eval_circ_gquad_structure_v(), vrna_eval_structure()
- Parameters:
string – RNA sequence in uppercase letters
structure – Secondary structure in dot-bracket notation
- Returns:
The free energy of the structure including contributions of G-quadruplexes in kcal/mol
-
float vrna_eval_structure_simple_verbose(const char *string, const char *structure, FILE *file)#
Calculate the free energy of an already folded RNA and print contributions per loop.
#include <ViennaRNA/eval/structures.h>
This function is a simplyfied version of vrna_eval_structure_simple_v() that uses the default verbosity level.
See also
vrna_eval_structure_simple_v(), vrna_eval_structure_verbose(), vrna_eval_structure_pt(), vrna_eval_structure_verbose(), vrna_eval_structure_pt_verbose()
- Parameters:
string – RNA sequence in uppercase letters
structure – Secondary structure in dot-bracket notation
file – A file handle where this function should print to (may be NULL).
- Returns:
The free energy of the input structure given the input sequence in kcal/mol
-
float vrna_eval_structure_simple_v(const char *string, const char *structure, int verbosity_level, FILE *file)#
Calculate the free energy of an already folded RNA and print contributions per loop.
#include <ViennaRNA/eval/structures.h>
This function allows for detailed energy evaluation of a given sequence/structure pair. In contrast to vrna_eval_structure() this function prints detailed energy contributions based on individual loops to a file handle. If NULL is passed as file handle, this function defaults to print to stdout. Any positive
verbosity_levelactivates potential warning message of the energy evaluting functions, while values \( \ge 1 \) allow for detailed control of what data is printed. A negative parameterverbosity_levelturns off printing all together.In contrast to vrna_eval_structure_verbose() this function assumes default model details and default energy parameters in order to evaluate the free energy of the secondary structure. Threefore, it serves as a simple interface function for energy evaluation for situations where no changes on the energy model are required.
- SWIG Wrapper Notes:
This function is available through an overloaded version of vrna_eval_structure_simple(). The last two arguments for this function are optional and default to VRNA_VERBOSITY_QUIET and
NULL, respectively. See, e.g.RNA.eval_structure_simple()in the The RNA Python module .
- Parameters:
string – RNA sequence in uppercase letters
structure – Secondary structure in dot-bracket notation
verbosity_level – The level of verbosity of this function
file – A file handle where this function should print to (may be NULL).
- Returns:
The free energy of the input structure given the input sequence in kcal/mol
-
float vrna_eval_circ_structure_v(const char *string, const char *structure, int verbosity_level, FILE *file)#
Evaluate free energy of a sequence/structure pair, assume sequence to be circular and print contributions per loop.
#include <ViennaRNA/eval/structures.h>
This function is the same as vrna_eval_structure_simple_v() but assumes the input sequence to be circularized.
- SWIG Wrapper Notes:
This function is available through an overloaded version of vrna_eval_circ_structure(). The last two arguments for this function are optional and default to VRNA_VERBOSITY_QUIET and
NULL, respectively. See, e.g.RNA.eval_circ_structure()in the The RNA Python module .
- Parameters:
string – RNA sequence in uppercase letters
structure – Secondary structure in dot-bracket notation
verbosity_level – The level of verbosity of this function
file – A file handle where this function should print to (may be NULL).
- Returns:
The free energy of the input structure given the input sequence in kcal/mol
-
float vrna_eval_gquad_structure_v(const char *string, const char *structure, int verbosity_level, FILE *file)#
Evaluate free energy of a sequence/structure pair, allow for G-Quadruplexes in the structure and print contributions per loop.
#include <ViennaRNA/eval/structures.h>
This function is the same as vrna_eval_structure_simple_v() but allows for annotated G-Quadruplexes in the dot-bracket structure input.
G-Quadruplexes are annotated as plus signs (‘+’) for each G involved in the motif. Linker sequences must be denoted by dots (‘.’) as they are considered unpaired. Below is an example of a 2-layer G-quadruplex:
GGAAGGAAAGGAGG ++..++...++.++
- SWIG Wrapper Notes:
This function is available through an overloaded version of vrna_eval_gquad_structure(). The last two arguments for this function are optional and default to VRNA_VERBOSITY_QUIET and
NULL, respectively. See, e.g.RNA.eval_gquad_structure()in the The RNA Python module .
- Parameters:
string – RNA sequence in uppercase letters
structure – Secondary structure in dot-bracket notation
verbosity_level – The level of verbosity of this function
file – A file handle where this function should print to (may be NULL).
- Returns:
The free energy of the input structure given the input sequence in kcal/mol
-
float vrna_eval_circ_gquad_structure_v(const char *string, const char *structure, int verbosity_level, FILE *file)#
Evaluate free energy of a sequence/structure pair, assume sequence to be circular, allow for G-Quadruplexes in the structure, and print contributions per loop.
#include <ViennaRNA/eval/structures.h>
This function is the same as vrna_eval_structure_simple_v() but assumes the input sequence to be circular and allows for annotated G-Quadruplexes in the dot-bracket structure input.
G-Quadruplexes are annotated as plus signs (‘+’) for each G involved in the motif. Linker sequences must be denoted by dots (‘.’) as they are considered unpaired. Below is an example of a 2-layer G-quadruplex:
GGAAGGAAAGGAGG ++..++...++.++
- SWIG Wrapper Notes:
This function is available through an overloaded version of vrna_eval_circ_gquad_structure(). The last two arguments for this function are optional and default to VRNA_VERBOSITY_QUIET and
NULL, respectively. See, e.g.RNA.eval_circ_gquad_structure()in the The RNA Python module .
- Parameters:
string – RNA sequence in uppercase letters
structure – Secondary structure in dot-bracket notation
verbosity_level – The level of verbosity of this function
file – A file handle where this function should print to (may be NULL).
- Returns:
The free energy of the input structure given the input sequence in kcal/mol
Simplified Energy Evaluation with Sequence Alignments and Consensus Structure Dot-Bracket String
-
float vrna_eval_consensus_structure_simple(const char **alignment, const char *structure)#
Calculate the free energy of an already folded RNA sequence alignment.
#include <ViennaRNA/eval/structures.h>
This function allows for energy evaluation for a given multiple sequence alignment and consensus structure pair. In contrast to vrna_eval_structure() this function assumes default model details and default energy parameters in order to evaluate the free energy of the secondary structure. Therefore, it serves as a simple interface function for energy evaluation for situations where no changes on the energy model are required.
- SWIG Wrapper Notes:
This function is available through an overloadeded version of vrna_eval_structure_simple(). Simply pass a sequence alignment as list of strings (including gaps) as first, and the consensus structure as second argument. See, e.g.
RNA.eval_structure_simple()in the The RNA Python module .
See also
vrna_eval_covar_structure(), vrna_eval_structure(), vrna_eval_structure_pt(), vrna_eval_structure_verbose(), vrna_eval_structure_pt_verbose()
Note
The free energy returned from this function already includes the covariation pseudo energies that is used fir comparative structure prediction within this library.
- Parameters:
alignment – RNA sequence alignment in uppercase letters and hyphen (‘-’) to denote gaps
structure – Consensus Secondary structure in dot-bracket notation
- Returns:
The free energy of the consensus structure given the input alignment in kcal/mol
-
float vrna_eval_circ_consensus_structure(const char **alignment, const char *structure)#
Evaluate the free energy of a multiple sequence alignment/consensus structure pair where the sequences are circular.
#include <ViennaRNA/eval/structures.h>
- SWIG Wrapper Notes:
This function is available through an overloadeded version of vrna_eval_circ_structure(). Simply pass a sequence alignment as list of strings (including gaps) as first, and the consensus structure as second argument. See, e.g.
RNA.eval_circ_structure()in the The RNA Python module .
See also
vrna_eval_covar_structure(), vrna_eval_consensus_structure_simple(), vrna_eval_gquad_consensus_structure(), vrna_eval_circ_structure(), vrna_eval_circ_consensus_structure_v(), vrna_eval_structure()
Note
The free energy returned from this function already includes the covariation pseudo energies that is used fir comparative structure prediction within this library.
- Parameters:
alignment – RNA sequence alignment in uppercase letters
structure – Consensus secondary structure in dot-bracket notation
- Returns:
The free energy of the consensus structure given the circular input sequence in kcal/mol
-
float vrna_eval_gquad_consensus_structure(const char **alignment, const char *structure)#
Evaluate the free energy of a multiple sequence alignment/consensus structure pair where the structure may contain G-Quadruplexes.
#include <ViennaRNA/eval/structures.h>
G-Quadruplexes are annotated as plus signs (‘+’) for each G involved in the motif. Linker sequences must be denoted by dots (‘.’) as they are considered unpaired. Below is an example of a 2-layer G-quadruplex:
GGAAGGAAAGGAGG ++..++...++.++
- SWIG Wrapper Notes:
This function is available through an overloadeded version of vrna_eval_gquad_structure(). Simply pass a sequence alignment as list of strings (including gaps) as first, and the consensus structure as second argument. See, e.g.
RNA.eval_gquad_structure()in the The RNA Python module .
See also
vrna_eval_covar_structure(), vrna_eval_consensus_structure_simple(), vrna_eval_circ_consensus_structure(), vrna_eval_gquad_structure(), vrna_eval_gquad_consensus_structure_v(), vrna_eval_structure()
Note
The free energy returned from this function already includes the covariation pseudo energies that is used fir comparative structure prediction within this library.
- Parameters:
alignment – RNA sequence alignment in uppercase letters
structure – Consensus secondary structure in dot-bracket notation
- Returns:
The free energy of the consensus structure including contributions of G-quadruplexes in kcal/mol
-
float vrna_eval_circ_gquad_consensus_structure(const char **alignment, const char *structure)#
Evaluate the free energy of a multiple sequence alignment/consensus structure pair where the sequence is circular and the structure may contain G-Quadruplexes.
#include <ViennaRNA/eval/structures.h>
G-Quadruplexes are annotated as plus signs (‘+’) for each G involved in the motif. Linker sequences must be denoted by dots (‘.’) as they are considered unpaired. Below is an example of a 2-layer G-quadruplex:
GGAAGGAAAGGAGG ++..++...++.++
- SWIG Wrapper Notes:
This function is available through an overloadeded version of vrna_eval_circ_gquad_structure(). Simply pass a sequence alignment as list of strings (including gaps) as first, and the consensus structure as second argument. See, e.g.
RNA.eval_circ_gquad_structure()in the The RNA Python module .
See also
vrna_eval_covar_structure(), vrna_eval_consensus_structure_simple(), vrna_eval_circ_consensus_structure(), vrna_eval_gquad_structure(), vrna_eval_circ_gquad_consensus_structure_v(), vrna_eval_structure()
Note
The free energy returned from this function already includes the covariation pseudo energies that is used fir comparative structure prediction within this library.
- Parameters:
alignment – RNA sequence alignment in uppercase letters
structure – Consensus secondary structure in dot-bracket notation
- Returns:
The free energy of the consensus structure including contributions of G-quadruplexes in kcal/mol
-
float vrna_eval_consensus_structure_simple_verbose(const char **alignment, const char *structure, FILE *file)#
Evaluate the free energy of a consensus structure for an RNA sequence alignment and print contributions per loop.
#include <ViennaRNA/eval/structures.h>
This function is a simplyfied version of vrna_eval_consensus_structure_simple_v() that uses the default verbosity level.
See also
vrna_eval_consensus_structure_simple_v(), vrna_eval_structure_verbose(), vrna_eval_structure_pt(), vrna_eval_structure_pt_verbose()
Note
The free energy returned from this function already includes the covariation pseudo energies that is used fir comparative structure prediction within this library.
- Parameters:
alignment – RNA sequence alignment in uppercase letters. Gaps are denoted by hyphens (‘-’)
structure – Consensus secondary structure in dot-bracket notation
file – A file handle where this function should print to (may be NULL).
- Returns:
The free energy of the conensus structure given the aligned input sequences in kcal/mol
-
float vrna_eval_consensus_structure_simple_v(const char **alignment, const char *structure, int verbosity_level, FILE *file)#
Evaluate the free energy of a consensus structure for an RNA sequence alignment and print contributions per loop.
#include <ViennaRNA/eval/structures.h>
This function allows for detailed energy evaluation of a given sequence alignment/consensus structure pair. In contrast to vrna_eval_consensus_structure_simple() this function prints detailed energy contributions based on individual loops to a file handle. If NULL is passed as file handle, this function defaults to print to stdout. Any positive
verbosity_levelactivates potential warning message of the energy evaluting functions, while values \( \ge 1 \) allow for detailed control of what data is printed. A negative parameterverbosity_levelturns off printing all together.- SWIG Wrapper Notes:
This function is available through an overloaded version of vrna_eval_structure_simple(). Simply pass a sequence alignment as list of strings (including gaps) as first, and the consensus structure as second argument. The last two arguments are optional and default to VRNA_VERBOSITY_QUIET and
NULL, respectively. See, e.g.RNA.eval_structure_simple()in the The RNA Python module .
See also
vrna_eval_consensus_structure(), vrna_eval_structure()
Note
The free energy returned from this function already includes the covariation pseudo energies that is used fir comparative structure prediction within this library.
- Parameters:
alignment – RNA sequence alignment in uppercase letters. Gaps are denoted by hyphens (‘-’)
structure – Consensus secondary structure in dot-bracket notation
verbosity_level – The level of verbosity of this function
file – A file handle where this function should print to (may be NULL).
- Returns:
The free energy of the consensus structure given the sequence alignment in kcal/mol
-
float vrna_eval_circ_consensus_structure_v(const char **alignment, const char *structure, int verbosity_level, FILE *file)#
Evaluate the free energy of a consensus structure for an alignment of circular RNA sequences and print contributions per loop.
#include <ViennaRNA/eval/structures.h>
This function is identical with vrna_eval_consensus_structure_simple_v() but assumed the aligned sequences to be circular.
- SWIG Wrapper Notes:
This function is available through an overloaded version of vrna_eval_circ_structure(). Simply pass a sequence alignment as list of strings (including gaps) as first, and the consensus structure as second argument. The last two arguments are optional and default to VRNA_VERBOSITY_QUIET and
NULL, respectively. See, e.g.RNA.eval_circ_structure()in the The RNA Python module .
See also
vrna_eval_consensus_structure_simple_v(), vrna_eval_circ_consensus_structure(), vrna_eval_structure()
Note
The free energy returned from this function already includes the covariation pseudo energies that is used fir comparative structure prediction within this library.
- Parameters:
alignment – RNA sequence alignment in uppercase letters. Gaps are denoted by hyphens (‘-’)
structure – Consensus secondary structure in dot-bracket notation
verbosity_level – The level of verbosity of this function
file – A file handle where this function should print to (may be NULL).
- Returns:
The free energy of the consensus structure given the sequence alignment in kcal/mol
-
float vrna_eval_gquad_consensus_structure_v(const char **alignment, const char *structure, int verbosity_level, FILE *file)#
Evaluate the free energy of a consensus structure for an RNA sequence alignment, allow for annotated G-Quadruplexes in the structure and print contributions per loop.
#include <ViennaRNA/eval/structures.h>
This function is identical with vrna_eval_consensus_structure_simple_v() but allows for annotated G-Quadruplexes in the consensus structure.
G-Quadruplexes are annotated as plus signs (‘+’) for each G involved in the motif. Linker sequences must be denoted by dots (‘.’) as they are considered unpaired. Below is an example of a 2-layer G-quadruplex:
GGAAGGAAAGGAGG ++..++...++.++
- SWIG Wrapper Notes:
This function is available through an overloaded version of vrna_eval_gquad_structure(). Simply pass a sequence alignment as list of strings (including gaps) as first, and the consensus structure as second argument. The last two arguments are optional and default to VRNA_VERBOSITY_QUIET and
NULL, respectively. See, e.g.RNA.eval_gquad_structure()in the The RNA Python module .
See also
vrna_eval_consensus_structure_simple_v(), vrna_eval_gquad_consensus_structure(), vrna_eval_structure()
Note
The free energy returned from this function already includes the covariation pseudo energies that is used fir comparative structure prediction within this library.
- Parameters:
alignment – RNA sequence alignment in uppercase letters. Gaps are denoted by hyphens (‘-’)
structure – Consensus secondary structure in dot-bracket notation
verbosity_level – The level of verbosity of this function
file – A file handle where this function should print to (may be NULL).
- Returns:
The free energy of the consensus structure given the sequence alignment in kcal/mol
-
float vrna_eval_circ_gquad_consensus_structure_v(const char **alignment, const char *structure, int verbosity_level, FILE *file)#
Evaluate the free energy of a consensus structure for an alignment of circular RNA sequences, allow for annotated G-Quadruplexes in the structure and print contributions per loop.
#include <ViennaRNA/eval/structures.h>
This function is identical with vrna_eval_consensus_structure_simple_v() but assumes the sequences in the alignment to be circular and allows for annotated G-Quadruplexes in the consensus structure.
G-Quadruplexes are annotated as plus signs (‘+’) for each G involved in the motif. Linker sequences must be denoted by dots (‘.’) as they are considered unpaired. Below is an example of a 2-layer G-quadruplex:
GGAAGGAAAGGAGG ++..++...++.++
- SWIG Wrapper Notes:
This function is available through an overloaded version of vrna_eval_circ_gquad_structure(). Simply pass a sequence alignment as list of strings (including gaps) as first, and the consensus structure as second argument. The last two arguments are optional and default to VRNA_VERBOSITY_QUIET and
NULL, respectively. See, e.g.RNA.eval_circ_gquad_structure()in the The RNA Python module .
See also
vrna_eval_consensus_structure_simple_v(), vrna_eval_circ_gquad_consensus_structure(), vrna_eval_structure()
Note
The free energy returned from this function already includes the covariation pseudo energies that is used fir comparative structure prediction within this library.
- Parameters:
alignment – RNA sequence alignment in uppercase letters. Gaps are denoted by hyphens (‘-’)
structure – Consensus secondary structure in dot-bracket notation
verbosity_level – The level of verbosity of this function
file – A file handle where this function should print to (may be NULL).
- Returns:
The free energy of the consensus structure given the sequence alignment in kcal/mol
Simplified Energy Evaluation with Sequence String and Structure Pair Table
-
int vrna_eval_structure_pt_simple(const char *string, const short *pt)#
Calculate the free energy of an already folded RNA.
#include <ViennaRNA/eval/structures.h>
In contrast to vrna_eval_structure_pt() this function assumes default model details and default energy parameters in order to evaluate the free energy of the secondary structure. Threefore, it serves as a simple interface function for energy evaluation for situations where no changes on the energy model are required.
- SWIG Wrapper Notes:
In the target scripting language, this function serves as a wrapper for vrna_eval_structure_pt_v() and, thus, allows for two additional, optional arguments, the verbosity level and a file handle which default to VRNA_VERBOSITY_QUIET and
NULL, respectively. See, e.g.RNA.eval_structure_pt_simple()in the The RNA Python module .
- Parameters:
string – RNA sequence in uppercase letters
pt – Secondary structure as pair_table
- Returns:
The free energy of the input structure given the input sequence in 10cal/mol
-
int vrna_eval_structure_pt_simple_verbose(const char *string, const short *pt, FILE *file)#
Calculate the free energy of an already folded RNA.
#include <ViennaRNA/eval/structures.h>
This function is a simplyfied version of vrna_eval_structure_pt_simple_v() that uses the default verbosity level.
See also
vrna_eval_structure_pt_simple_v(), vrna_ptable(), vrna_eval_structure_pt_verbose(), vrna_eval_structure_simple()
- Parameters:
string – RNA sequence in uppercase letters
pt – Secondary structure as pair_table
file – A file handle where this function should print to (may be NULL).
- Returns:
The free energy of the input structure given the input sequence in 10cal/mol
-
int vrna_eval_structure_pt_simple_v(const char *string, const short *pt, int verbosity_level, FILE *file)#
Calculate the free energy of an already folded RNA.
#include <ViennaRNA/eval/structures.h>
This function allows for energy evaluation of a given sequence/structure pair where the structure is provided in pair_table format as obtained from vrna_ptable(). Model details, energy parameters, and possibly soft constraints are used as provided via the parameter ‘fc’. The fold_compound does not need to contain any DP matrices, but all the most basic init values as one would get from a call like this:
In contrast to vrna_eval_structure_pt_verbose() this function assumes default model details and default energy parameters in order to evaluate the free energy of the secondary structure. Threefore, it serves as a simple interface function for energy evaluation for situations where no changes on the energy model are required.fc = vrna_fold_compound(sequence, NULL, VRNA_OPTION_EVAL_ONLY);
- Parameters:
string – RNA sequence in uppercase letters
pt – Secondary structure as pair_table
verbosity_level – The level of verbosity of this function
file – A file handle where this function should print to (may be NULL).
- Returns:
The free energy of the input structure given the input sequence in 10cal/mol
Simplified Energy Evaluation with Sequence Alignment and Consensus Structure Pair Table
-
int vrna_eval_consensus_structure_pt_simple(const char **alignment, const short *pt)#
Evaluate the Free Energy of a Consensus Secondary Structure given a Sequence Alignment.
#include <ViennaRNA/eval/structures.h>
- SWIG Wrapper Notes:
This function is available through an overloadeded version of vrna_eval_structure_pt_simple(). Simply pass a sequence alignment as list of strings (including gaps) as first, and the consensus structure as second argument. See, e.g.
RNA.eval_structure_pt_simple()in the The RNA Python module .
See also
vrna_eval_consensus_structure_simple(), vrna_eval_structure_pt(), vrna_eval_structure(), vrna_eval_covar_structure()
Note
The free energy returned from this function already includes the covariation pseudo energies that is used fir comparative structure prediction within this library.
- Parameters:
alignment – RNA sequence alignment in uppercase letters. Gaps are denoted by hyphens (‘-’)
pt – Secondary structure in pair table format
- Returns:
Free energy of the consensus structure in 10cal/mol
-
int vrna_eval_consensus_structure_pt_simple_verbose(const char **alignment, const short *pt, FILE *file)#
#include <ViennaRNA/eval/structures.h>
-
int vrna_eval_consensus_structure_pt_simple_v(const char **alignment, const short *pt, int verbosity_level, FILE *file)#
#include <ViennaRNA/eval/structures.h>
- SWIG Wrapper Notes:
This function is available through an overloaded version of vrna_eval_structure_pt_simple(). Simply pass a sequence alignment as list of strings (including gaps) as first, and the consensus structure as second argument. The last two arguments are optional and default to VRNA_VERBOSITY_QUIET and
NULL, respectively. See, e.g.RNA.eval_structure_pt_simple()in the The RNA Python module .
Defines
-
VRNA_VERBOSITY_QUIET#
Quiet level verbosity setting.
#include <ViennaRNA/eval/basic.h>
-
VRNA_VERBOSITY_DEFAULT#
Default level verbosity setting.
#include <ViennaRNA/eval/basic.h>
-
VRNA_EVAL_LOOP_DEFAULT#
Default options for loop evaluation.
#include <ViennaRNA/eval/basic.h>
-
VRNA_EVAL_LOOP_NO_HC#
Do not acknowledge hard constraints in loop evaluation.
#include <ViennaRNA/eval/basic.h>
-
VRNA_EVAL_LOOP_NO_SC#
Do not acknowledge soft constraints in loop evaluation.
#include <ViennaRNA/eval/basic.h>
-
VRNA_EVAL_LOOP_NO_CONSTRAINTS#
Do not acknowledge any constraints in loop evaluation.
#include <ViennaRNA/eval/basic.h>
-
float vrna_eval_structure(vrna_fold_compound_t *fc, const char *structure)#
Deprecated Interface for Free Energy Evaluation#
Warning
Using the functions below is discouraged as they have been marked deprecated and will be removed from the library in the (near) future!
Defines
-
ON_SAME_STRAND(I, J, C)#
#include <ViennaRNA/eval/internal.h>
Functions
-
float energy_of_alistruct(const char **sequences, const char *structure, int n_seq, float *energy)#
Calculate the free energy of a consensus structure given a set of aligned sequences.
#include <ViennaRNA/alifold.h>
- Deprecated:
Usage of this function is discouraged! Use vrna_eval_structure(), and vrna_eval_covar_structure() instead!
- Parameters:
sequences – The NULL terminated array of sequences
structure – The consensus structure
n_seq – The number of sequences in the alignment
energy – A pointer to an array of at least two floats that will hold the free energies (energy[0] will contain the free energy, energy[1] will be filled with the covariance energy term)
- Returns:
free energy in kcal/mol
-
int vrna_eval_ext_stem(vrna_fold_compound_t *fc, int i, int j)#
#include <ViennaRNA/eval/exterior.h>
-
int E_Stem(int type, int si1, int sj1, int extLoop, vrna_param_t *P)#
Compute the energy contribution of a stem branching off a loop-region.
#include <ViennaRNA/eval/exterior.h>
This function computes the energy contribution of a stem that branches off a loop region. This can be the case in multiloops, when a stem branching off increases the degree of the loop but also immediately interior base pairs of an exterior loop contribute free energy. To switch the behavior of the function according to the evaluation of a multiloop- or exterior-loop-stem, you pass the flag ‘extLoop’. The returned energy contribution consists of a TerminalAU penalty if the pair type is greater than 2, dangling end contributions of mismatching nucleotides adjacent to the stem if only one of the si1, sj1 parameters is greater than 0 and mismatch energies if both mismatching nucleotides are positive values. Thus, to avoid incorporating dangling end or mismatch energies just pass a negative number, e.g. -1 to the mismatch argument.
This is an illustration of how the energy contribution is assembled:
3’ 5’
| |
X - Y
5’-si1 sj1-3’
Here, (X,Y) is the base pair that closes the stem that branches off a loop region. The nucleotides si1 and sj1 are the 5’- and 3’- mismatches, respectively. If the base pair type of (X,Y) is greater than 2 (i.e. an A-U or G-U pair, the TerminalAU penalty will be included in the energy contribution returned. If si1 and sj1 are both nonnegative numbers, mismatch energies will also be included. If one of si1 or sj1 is a negative value, only 5’ or 3’ dangling end contributions are taken into account. To prohibit any of these mismatch contributions to be incorporated, just pass a negative number to both, si1 and sj1. In case the argument extLoop is 0, the returned energy contribution also includes the internal-loop-penalty of a multiloop stem with closing pair type.
- Deprecated:
Please use one of the functions vrna_E_exterior_stem() and vrna_E_multibranch_stem() instead! Use the former for cases where
extLoop!= 0 and the latter otherwise.
See also
vrna_E_multibranch_stem(), _ExtLoop()
Note
This function is threadsafe
- Parameters:
type – The pair type of the first base pair un the stem
si1 – The 5’-mismatching nucleotide
sj1 – The 3’-mismatching nucleotide
extLoop – A flag that indicates whether the contribution reflects the one of an exterior loop or not
P – The data structure containing scaled energy parameters
- Returns:
The Free energy of the branch off the loop in dcal/mol
-
int E_ExtLoop(int type, int si1, int sj1, vrna_param_t *P)#
#include <ViennaRNA/eval/exterior.h>
-
int vrna_E_ext_stem(unsigned int type, int n5d, int n3d, vrna_param_t *p)#
#include <ViennaRNA/eval/exterior.h>
-
FLT_OR_DBL vrna_exp_E_ext_stem(unsigned int type, int n5d, int n3d, vrna_exp_param_t *p)#
#include <ViennaRNA/eval/exterior.h>
-
FLT_OR_DBL exp_E_ExtLoop(int type, int si1, int sj1, vrna_exp_param_t *P)#
#include <ViennaRNA/eval/exterior.h>
This is the partition function variant of E_ExtLoop()
- Deprecated:
Use vrna_exp_E_ext_stem() instead!
See also
E_ExtLoop()
- Returns:
The Boltzmann weighted energy contribution of the introduced exterior-loop stem
-
FLT_OR_DBL exp_E_Stem(int type, int si1, int sj1, int extLoop, vrna_exp_param_t *P)#
#include <ViennaRNA/eval/exterior.h>
Compute the Boltzmann weighted energy contribution of a stem branching off a loop-region
This is the partition function variant of E_Stem()
See also
Note
This function is threadsafe
- Returns:
The Boltzmann weighted energy contribution of the branch off the loop
-
static int E_Hairpin(int size, int type, int si1, int sj1, const char *string, vrna_param_t *P)#
Compute the Energy of a hairpin-loop.
#include <ViennaRNA/eval/hairpin.h>
To evaluate the free energy of a hairpin-loop, several parameters have to be known. A general hairpin-loop has this structure:
a3 a4
a2 a5
a1 a6
X - Y
| |
5’ 3’
where X-Y marks the closing pair [e.g. a (G,C) pair]. The length of this loop is 6 as there are six unpaired nucleotides (a1-a6) enclosed by (X,Y). The 5’ mismatching nucleotide is a1 while the 3’ mismatch is a6. The nucleotide sequence of this loop is “a1.a2.a3.a4.a5.a6”See also
Note
The parameter sequence should contain the sequence of the loop in capital letters of the nucleic acid alphabet if the loop size is below 7. This is useful for unusually stable tri-, tetra- and hexa-loops which are treated differently (based on experimental data) if they are tabulated.
Warning
Not (really) thread safe! A threadsafe implementation will replace this function in a future release!
Energy evaluation may change due to updates in global variable “tetra_loop”
- Parameters:
size – The size of the loop (number of unpaired nucleotides)
type – The pair type of the base pair closing the hairpin
si1 – The 5’-mismatching nucleotide
sj1 – The 3’-mismatching nucleotide
string – The sequence of the loop (May be
NULL, otherwise mst be at least \(size + 2\) long)P – The datastructure containing scaled energy parameters
- Returns:
The Free energy of the Hairpin-loop in dcal/mol
-
int vrna_E_hp_loop(vrna_fold_compound_t *fc, int i, int j)#
#include <ViennaRNA/eval/hairpin.h>
-
int vrna_E_ext_hp_loop(vrna_fold_compound_t *fc, int i, int j)#
#include <ViennaRNA/eval/hairpin.h>
-
int vrna_eval_hp_loop(vrna_fold_compound_t *fc, int i, int j)#
#include <ViennaRNA/eval/hairpin.h>
- SWIG Wrapper Notes:
This function is attached as method
eval_hp_loop()to objects of typefold_compound. See, e.g.RNA.fold_compound.eval_hp_loop()in the The RNA Python module .
-
int vrna_eval_ext_hp_loop(vrna_fold_compound_t *fc, int i, int j)#
#include <ViennaRNA/eval/hairpin.h>
-
static FLT_OR_DBL exp_E_Hairpin(int u, int type, short si1, short sj1, const char *string, vrna_exp_param_t *P)#
Compute Boltzmann weight \(e^{-\Delta G/kT} \) of a hairpin loop.
#include <ViennaRNA/eval/hairpin.h>
See also
get_scaled_pf_parameters(), vrna_exp_param_t, E_Hairpin()
Note
multiply by scale[u+2]
Warning
Not (really) thread safe! A threadsafe implementation will replace this function in a future release!
Energy evaluation may change due to updates in global variable “tetra_loop”
- Parameters:
u – The size of the loop (number of unpaired nucleotides)
type – The pair type of the base pair closing the hairpin
si1 – The 5’-mismatching nucleotide
sj1 – The 3’-mismatching nucleotide
string – The sequence of the loop (May be
NULL, otherwise mst be at least \(size + 2\) long)P – The datastructure containing scaled Boltzmann weights of the energy parameters
- Returns:
The Boltzmann weight of the Hairpin-loop
-
FLT_OR_DBL vrna_exp_E_hp_loop(vrna_fold_compound_t *fc, int i, int j)#
#include <ViennaRNA/eval/hairpin.h>
-
static int E_IntLoop(int n1, int n2, int type, int type_2, int si1, int sj1, int sp1, int sq1, vrna_param_t *P)#
#include <ViennaRNA/eval/internal.h>
Compute the Energy of an internal-loop
This function computes the free energy \(\Delta G\) of an internal-loop with the following structure:
3’ 5’
| |
U - V
a_n b_1
. .
. .
. .
a_1 b_m
X - Y
| |
5’ 3’
This general structure depicts an internal-loop that is closed by the base pair (X,Y). The enclosed base pair is (V,U) which leaves the unpaired bases a_1-a_n and b_1-b_n that constitute the loop. In this example, the length of the internal-loop is \((n+m)\)where n or m may be 0 resulting in a bulge-loop or base pair stack. The mismatching nucleotides for the closing pair (X,Y) are:
5’-mismatch: a_1
3’-mismatch: b_m
and for the enclosed base pair (V,U):
5’-mismatch: b_1
3’-mismatch: a_n
See also
Note
Base pairs are always denoted in 5’->3’ direction. Thus the enclosed base pair must be ‘turned arround’ when evaluating the free energy of the internal-loop
This function is threadsafe
- Parameters:
n1 – The size of the ‘left’-loop (number of unpaired nucleotides)
n2 – The size of the ‘right’-loop (number of unpaired nucleotides)
type – The pair type of the base pair closing the internal loop
type_2 – The pair type of the enclosed base pair
si1 – The 5’-mismatching nucleotide of the closing pair
sj1 – The 3’-mismatching nucleotide of the closing pair
sp1 – The 3’-mismatching nucleotide of the enclosed pair
sq1 – The 5’-mismatching nucleotide of the enclosed pair
P – The datastructure containing scaled energy parameters
- Returns:
The Free energy of the Interior-loop in dcal/mol
-
static FLT_OR_DBL exp_E_IntLoop(int u1, int u2, int type, int type2, short si1, short sj1, short sp1, short sq1, vrna_exp_param_t *P)#
#include <ViennaRNA/eval/internal.h>
Compute Boltzmann weight \(e^{-\Delta G/kT} \) of internal loop
multiply by scale[u1+u2+2] for scaling
See also
get_scaled_pf_parameters(), vrna_exp_param_t, E_IntLoop()
Note
This function is threadsafe
- Parameters:
u1 – The size of the ‘left’-loop (number of unpaired nucleotides)
u2 – The size of the ‘right’-loop (number of unpaired nucleotides)
type – The pair type of the base pair closing the internal loop
type2 – The pair type of the enclosed base pair
si1 – The 5’-mismatching nucleotide of the closing pair
sj1 – The 3’-mismatching nucleotide of the closing pair
sp1 – The 3’-mismatching nucleotide of the enclosed pair
sq1 – The 5’-mismatching nucleotide of the enclosed pair
P – The datastructure containing scaled Boltzmann weights of the energy parameters
- Returns:
The Boltzmann weight of the Interior-loop
-
static int E_IntLoop_Co(int type, int type_2, int i, int j, int p, int q, int cutpoint, short si1, short sj1, short sp1, short sq1, int dangles, vrna_param_t *P)#
#include <ViennaRNA/eval/internal.h>
-
static int __E_IntLoop_Co(int type, int type_2, int i, int j, int p, int q, int cutpoint, short si1, short sj1, short sp1, short sq1, int dangles, vrna_param_t *P)#
#include <ViennaRNA/eval/internal.h>
-
static int ubf_eval_int_loop(int i, int j, int p, int q, int i1, int j1, int p1, int q1, short si, short sj, short sp, short sq, unsigned char type, unsigned char type_2, int *rtype, int ij, int cp, vrna_param_t *P, vrna_sc_t *sc)#
#include <ViennaRNA/eval/internal.h>
-
static int ubf_eval_int_loop2(int i, int j, int p, int q, int i1, int j1, int p1, int q1, short si, short sj, short sp, short sq, unsigned char type, unsigned char type_2, int *rtype, int ij, unsigned int *sn, unsigned int *ss, vrna_param_t *P, vrna_sc_t *sc)#
#include <ViennaRNA/eval/internal.h>
-
static int ubf_eval_ext_int_loop(int i, int j, int p, int q, int i1, int j1, int p1, int q1, short si, short sj, short sp, short sq, unsigned char type, unsigned char type_2, int length, vrna_param_t *P, vrna_sc_t *sc)#
#include <ViennaRNA/eval/internal.h>
-
int vrna_eval_int_loop(vrna_fold_compound_t *fc, int i, int j, int k, int l)#
#include <ViennaRNA/eval/internal.h>
- SWIG Wrapper Notes:
This function is attached as method
eval_int_loop()to objects of typefold_compound. See, e.g.RNA.fold_compound.eval_int_loop()in the The RNA Python module .
-
int vrna_E_stack(vrna_fold_compound_t *fc, int i, int j)#
#include <ViennaRNA/eval/internal.h>
-
FLT_OR_DBL vrna_exp_E_interior_loop(vrna_fold_compound_t *fc, int i, int j, int k, int l)#
#include <ViennaRNA/eval/internal.h>
-
static int E_MLstem(int type, int si1, int sj1, vrna_param_t *P)#
#include <ViennaRNA/eval/multibranch.h>
-
static FLT_OR_DBL exp_E_MLstem(int type, int si1, int sj1, vrna_exp_param_t *P)#
#include <ViennaRNA/eval/multibranch.h>
-
float energy_of_structure(const char *string, const char *structure, int verbosity_level)#
Calculate the free energy of an already folded RNA using global model detail settings.
#include <ViennaRNA/eval/structures.h>
If verbosity level is set to a value >0, energies of structure elements are printed to stdout
- Deprecated:
Use vrna_eval_structure() or vrna_eval_structure_verbose() instead!
See also
Note
OpenMP: This function relies on several global model settings variables and thus is not to be considered threadsafe. See energy_of_struct_par() for a completely threadsafe implementation.
- Parameters:
string – RNA sequence
structure – secondary structure in dot-bracket notation
verbosity_level – a flag to turn verbose output on/off
- Returns:
the free energy of the input structure given the input sequence in kcal/mol
-
float energy_of_struct_par(const char *string, const char *structure, vrna_param_t *parameters, int verbosity_level)#
Calculate the free energy of an already folded RNA.
#include <ViennaRNA/eval/structures.h>
If verbosity level is set to a value >0, energies of structure elements are printed to stdout
- Deprecated:
Use vrna_eval_structure() or vrna_eval_structure_verbose() instead!
See also
- Parameters:
string – RNA sequence in uppercase letters
structure – Secondary structure in dot-bracket notation
parameters – A data structure containing the prescaled energy contributions and the model details.
verbosity_level – A flag to turn verbose output on/off
- Returns:
The free energy of the input structure given the input sequence in kcal/mol
-
float energy_of_circ_structure(const char *string, const char *structure, int verbosity_level)#
Calculate the free energy of an already folded circular RNA.
#include <ViennaRNA/eval/structures.h>
If verbosity level is set to a value >0, energies of structure elements are printed to stdout
- Deprecated:
Use vrna_eval_structure() or vrna_eval_structure_verbose() instead!
See also
Note
OpenMP: This function relies on several global model settings variables and thus is not to be considered threadsafe. See energy_of_circ_struct_par() for a completely threadsafe implementation.
- Parameters:
string – RNA sequence
structure – Secondary structure in dot-bracket notation
verbosity_level – A flag to turn verbose output on/off
- Returns:
The free energy of the input structure given the input sequence in kcal/mol
-
float energy_of_circ_struct_par(const char *string, const char *structure, vrna_param_t *parameters, int verbosity_level)#
Calculate the free energy of an already folded circular RNA.
#include <ViennaRNA/eval/structures.h>
If verbosity level is set to a value >0, energies of structure elements are printed to stdout
- Deprecated:
Use vrna_eval_structure() or vrna_eval_structure_verbose() instead!
See also
- Parameters:
string – RNA sequence
structure – Secondary structure in dot-bracket notation
parameters – A data structure containing the prescaled energy contributions and the model details.
verbosity_level – A flag to turn verbose output on/off
- Returns:
The free energy of the input structure given the input sequence in kcal/mol
-
float energy_of_gquad_structure(const char *string, const char *structure, int verbosity_level)#
#include <ViennaRNA/eval/structures.h>
-
float energy_of_gquad_struct_par(const char *string, const char *structure, vrna_param_t *parameters, int verbosity_level)#
#include <ViennaRNA/eval/structures.h>
-
int energy_of_structure_pt(const char *string, short *ptable, short *s, short *s1, int verbosity_level)#
Calculate the free energy of an already folded RNA.
#include <ViennaRNA/eval/structures.h>
If verbosity level is set to a value >0, energies of structure elements are printed to stdout
- Deprecated:
Use vrna_eval_structure_pt() or vrna_eval_structure_pt_verbose() instead!
See also
Note
OpenMP: This function relies on several global model settings variables and thus is not to be considered threadsafe. See energy_of_struct_pt_par() for a completely threadsafe implementation.
- Parameters:
string – RNA sequence
ptable – the pair table of the secondary structure
s – encoded RNA sequence
s1 – encoded RNA sequence
verbosity_level – a flag to turn verbose output on/off
- Returns:
the free energy of the input structure given the input sequence in 10kcal/mol
-
int energy_of_struct_pt_par(const char *string, short *ptable, short *s, short *s1, vrna_param_t *parameters, int verbosity_level)#
Calculate the free energy of an already folded RNA.
#include <ViennaRNA/eval/structures.h>
If verbosity level is set to a value >0, energies of structure elements are printed to stdout
- Deprecated:
Use vrna_eval_structure_pt() or vrna_eval_structure_pt_verbose() instead!
See also
- Parameters:
string – RNA sequence in uppercase letters
ptable – The pair table of the secondary structure
s – Encoded RNA sequence
s1 – Encoded RNA sequence
parameters – A data structure containing the prescaled energy contributions and the model details.
verbosity_level – A flag to turn verbose output on/off
- Returns:
The free energy of the input structure given the input sequence in 10kcal/mol
-
float energy_of_move(const char *string, const char *structure, int m1, int m2)#
Calculate energy of a move (closing or opening of a base pair).
#include <ViennaRNA/eval/structures.h>
If the parameters m1 and m2 are negative, it is deletion (opening) of a base pair, otherwise it is insertion (opening).
- Deprecated:
Use vrna_eval_move() instead!
See also
- Parameters:
string – RNA sequence
structure – secondary structure in dot-bracket notation
m1 – first coordinate of base pair
m2 – second coordinate of base pair
- Returns:
energy change of the move in kcal/mol
-
int energy_of_move_pt(short *pt, short *s, short *s1, int m1, int m2)#
Calculate energy of a move (closing or opening of a base pair).
#include <ViennaRNA/eval/structures.h>
If the parameters m1 and m2 are negative, it is deletion (opening) of a base pair, otherwise it is insertion (opening).
- Deprecated:
Use vrna_eval_move_pt() instead!
See also
- Parameters:
pt – the pair table of the secondary structure
s – encoded RNA sequence
s1 – encoded RNA sequence
m1 – first coordinate of base pair
m2 – second coordinate of base pair
- Returns:
energy change of the move in 10cal/mol
-
int loop_energy(short *ptable, short *s, short *s1, int i)#
Calculate energy of a loop.
#include <ViennaRNA/eval/structures.h>
- Deprecated:
Use vrna_eval_loop_pt() instead!
See also
- Parameters:
ptable – the pair table of the secondary structure
s – encoded RNA sequence
s1 – encoded RNA sequence
i – position of covering base pair
- Returns:
free energy of the loop in 10cal/mol
-
float energy_of_struct(const char *string, const char *structure)#
#include <ViennaRNA/eval/structures.h>
Calculate the free energy of an already folded RNA
- Deprecated:
This function is deprecated and should not be used in future programs! Use energy_of_structure() instead!
Note
This function is not entirely threadsafe! Depending on the state of the global variable eos_debug it prints energy information to stdout or not…
- Parameters:
string – RNA sequence
structure – secondary structure in dot-bracket notation
- Returns:
the free energy of the input structure given the input sequence in kcal/mol
-
int energy_of_struct_pt(const char *string, short *ptable, short *s, short *s1)#
#include <ViennaRNA/eval/structures.h>
Calculate the free energy of an already folded RNA
- Deprecated:
This function is deprecated and should not be used in future programs! Use energy_of_structure_pt() instead!
See also
make_pair_table(), energy_of_structure()
Note
This function is not entirely threadsafe! Depending on the state of the global variable eos_debug it prints energy information to stdout or not…
- Parameters:
string – RNA sequence
ptable – the pair table of the secondary structure
s – encoded RNA sequence
s1 – encoded RNA sequence
- Returns:
the free energy of the input structure given the input sequence in 10kcal/mol
-
float energy_of_circ_struct(const char *string, const char *structure)#
#include <ViennaRNA/eval/structures.h>
Calculate the free energy of an already folded circular RNA
- Deprecated:
This function is deprecated and should not be used in future programs Use energy_of_circ_structure() instead!
Note
This function is not entirely threadsafe! Depending on the state of the global variable eos_debug it prints energy information to stdout or not…
- Parameters:
string – RNA sequence
structure – secondary structure in dot-bracket notation
- Returns:
the free energy of the input structure given the input sequence in kcal/mol
-
ON_SAME_STRAND(I, J, C)#