RNAlib-2.6.0b
 
Loading...
Searching...
No Matches
model.h
Go to the documentation of this file.
1#ifndef VIENNA_RNA_PACKAGE_MODEL_H
2#define VIENNA_RNA_PACKAGE_MODEL_H
3
17#ifndef NBASES
18#define NBASES 8
19#endif
20
22typedef struct vrna_md_s vrna_md_t;
23
30#define VRNA_MODEL_DEFAULT_TEMPERATURE 37.0
31
36#define VRNA_MODEL_DEFAULT_PF_SCALE -1
37
42#define VRNA_MODEL_DEFAULT_BETA_SCALE 1.
43
47#define VRNA_MODEL_DEFAULT_DANGLES 2
48
53#define VRNA_MODEL_DEFAULT_SPECIAL_HP 1
54
59#define VRNA_MODEL_DEFAULT_NO_LP 0
60
65#define VRNA_MODEL_DEFAULT_NO_GU 0
66
71#define VRNA_MODEL_DEFAULT_NO_GU_CLOSURE 0
72
77#define VRNA_MODEL_DEFAULT_CIRC 0
78
83#define VRNA_MODEL_DEFAULT_GQUAD 0
84
89#define VRNA_MODEL_DEFAULT_UNIQ_ML 0
90
95#define VRNA_MODEL_DEFAULT_ENERGY_SET 0
96
101#define VRNA_MODEL_DEFAULT_BACKTRACK 1
102
107#define VRNA_MODEL_DEFAULT_BACKTRACK_TYPE 'F'
108
113#define VRNA_MODEL_DEFAULT_COMPUTE_BPP 1
114
119#define VRNA_MODEL_DEFAULT_MAX_BP_SPAN -1
120
125#define VRNA_MODEL_DEFAULT_WINDOW_SIZE -1
126
131#define VRNA_MODEL_DEFAULT_LOG_ML 0
132
137#define VRNA_MODEL_DEFAULT_ALI_OLD_EN 0
138
143#define VRNA_MODEL_DEFAULT_ALI_RIBO 0
144
149#define VRNA_MODEL_DEFAULT_ALI_CV_FACT 1.
150
154#define VRNA_MODEL_DEFAULT_ALI_NC_FACT 1.
155
156
157#define VRNA_MODEL_DEFAULT_PF_SMOOTH 1
158
162#define VRNA_MODEL_DEFAULT_SALT 1.021
163
164
168#define VRNA_MODEL_DEFAULT_SALTMLLOWER 6
169
170
174#define VRNA_MODEL_DEFAULT_SALTMLUPPER 24
175
176
180#define VRNA_MODEL_DEFAULT_SALTDPXINIT 99999
181
182
183#ifndef VRNA_DISABLE_BACKWARD_COMPATIBILITY
184
185#ifndef MAXALPHA
189#define MAXALPHA 20
190#endif
191
192#endif
193
203struct vrna_md_s {
204 double temperature;
205 double betaScale;
232 int noLP;
233 int noGU;
235 int logML;
236 int circ;
237 int gquad;
243 char nonstandards[64];
252 int ribo;
253 double cv_fact;
254 double nc_fact;
255 double sfact;
256 int rtype[8];
257 short alias[MAXALPHA + 1];
258 int pair[MAXALPHA + 1][MAXALPHA + 1];
259 float pair_dist[7][7];
260 double salt;
267};
268
269
278void
280
281
294void
296
297
308vrna_md_t *
310 const vrna_md_t *md_from);
311
312
318char *
320
321
322void
323vrna_md_set_nonstandards(vrna_md_t *md,
324 const char *ns_bases);
325
326
344void
346
347
353void
355
356
362double
364
365
373void
375
376
383double
385
386
387void
388vrna_md_defaults_pf_smooth(int s);
389
390
391int
392vrna_md_defaults_pf_smooth_get(void);
393
394
400void
402
403
409int
411
412
418void
420
421
427int
429
430
436void
438
439
445int
447
448
454void
456
457
463int
465
466
472void
474
475
481int
483
484
490void
492
493
499int
501
502
508void
510
511
517int
519
520
526void
528
529
535int
537
538
545void
547
548
554int
556
557
563void
565
566
572int
574
575
581void
583
584
590int
592
593
599void
601
602
608char
610
611
617void
619
620
626int
628
629
635void
637
638
644int
646
647
653void
655
656
662int
664
665
671void
673
674
680int
682
683
691void
693
694
700int
702
703
709void
711
712
718int
720
721
727void
729
730
736double
738
739
745void
747
748
754double
756
757
763void
765
766
772double
774
775
781void
783
784
789double
791
792
798void
800
801
806int
808
809
815void
817
818
823int
825
826
833void
835
836
843int
845
846#ifndef VRNA_DISABLE_BACKWARD_COMPATIBILITY
847
848#define model_detailsT vrna_md_t /* restore compatibility of struct rename */
849
850/* BEGIN deprecated global variables: */
851
861extern double temperature;
862
874extern double pf_scale;
875
897extern int dangles;
898
904extern int tetra_loop;
905
913extern int noLonelyPairs;
914
918extern int noGU;
919
923extern int no_closingGU;
924
928extern int circ;
929
933extern int gquad;
934
938extern int uniq_ML;
939
947extern int energy_set;
948
955extern int do_backtrack;
956
964extern char backtrack_type;
965
973extern char *nonstandards;
974
980extern int max_bp_span;
981
985extern int oldAliEn;
986
990extern int ribo;
991
992extern double cv_fact;
993
994extern double nc_fact;
995
997extern int logML;
998
1000extern double salt;
1001
1003extern int saltDPXInit;
1004
1005
1006/* END deprecated global variables: */
1007
1021void
1023
1024
1025char *
1026option_string(void);
1027
1028
1029#endif
1034#endif
double nc_fact
This variable controls the magnitude of the penalty for non-compatible sequences in the covariance te...
double cv_fact
This variable controls the weight of the covariance term in the energy function of alignment folding ...
double betaScale
A scaling factor for the thermodynamic temperature of the Boltzmann factors.
Definition: model.h:205
int backtrack
Specifies whether or not secondary structures should be backtraced.
Definition: model.h:240
int ribo
Use ribosum scoring table in alifold energy model.
Definition: model.h:252
char nonstandards[64]
contains allowed non standard bases
Definition: model.h:243
int saltDPXInit
User-provided salt correction for duplex initialization (in dcal/mol). If set to 99999 the default sa...
Definition: model.h:263
int energy_set
Specifies the energy set that defines set of compatible base pairs.
Definition: model.h:239
double temperature
The temperature used to scale the thermodynamic parameters.
Definition: model.h:204
double cv_fact
Co-variance scaling factor for consensus structure prediction.
Definition: model.h:253
int max_bp_span
maximum allowed base pair span
Definition: model.h:244
short alias[MAXALPHA+1]
alias of an integer nucleotide representation
Definition: model.h:257
double salt
Salt (monovalent) concentration (M) in buffer.
Definition: model.h:260
int noLP
Only consider canonical structures, i.e. no 'lonely' base pairs.
Definition: model.h:232
int saltMLUpper
Upper bound of multiloop size to use in loop salt correction linear fitting.
Definition: model.h:262
int noGUclosure
Do not allow loops to be closed by GU pair.
Definition: model.h:234
int circ
Assume RNA to be circular instead of linear.
Definition: model.h:236
float pair_dist[7][7]
Base pair dissimilarity, a.k.a. distance matrix.
Definition: model.h:259
int pf_smooth
A flat specifying whether energies in Boltzmann factors need to be smoothed.
Definition: model.h:206
int min_loop_size
Minimum size of hairpin loops.
Definition: model.h:246
int compute_bpp
Specifies whether or not backward recursions for base pair probability (bpp) computation will be perf...
Definition: model.h:242
int pair[MAXALPHA+1][MAXALPHA+1]
Integer representation of a base pair.
Definition: model.h:258
int oldAliEn
Use old alifold energy model.
Definition: model.h:251
double sfact
Scaling factor for partition function scaling.
Definition: model.h:255
char backtrack_type
Specifies in which matrix to backtrack.
Definition: model.h:241
double nc_fact
Scaling factor to weight co-variance contributions of non-canonical pairs.
Definition: model.h:254
int window_size
Size of the sliding window for locally optimal structure prediction.
Definition: model.h:250
int saltMLLower
Lower bound of multiloop size to use in loop salt correction linear fitting.
Definition: model.h:261
int rtype[8]
Reverse base pair type array.
Definition: model.h:256
int noGU
Do not allow GU pairs.
Definition: model.h:233
int dangles
Specifies the dangle model used in any energy evaluation (0,1,2 or 3)
Definition: model.h:207
int special_hp
Include special hairpin contributions for tri, tetra and hexaloops.
Definition: model.h:231
int uniq_ML
Flag to ensure unique multi-branch loop decomposition during folding.
Definition: model.h:238
int logML
Use logarithmic scaling for multiloops.
Definition: model.h:235
int gquad
Include G-quadruplexes in structure prediction.
Definition: model.h:237
int vrna_md_defaults_energy_set_get(void)
Get default energy set.
int vrna_md_defaults_saltDPXInit_get(void)
Get user-provided salt correciton for duplex initialization If value is 99999 the default value from ...
#define MAXALPHA
Maximal length of alphabet.
Definition: model.h:189
int ribo
use ribosum matrices
void vrna_md_defaults_gquad(int flag)
Set default behavior for treatment of G-Quadruplexes.
int vrna_md_defaults_saltMLLower_get(void)
Get the default multiloop size lower bound for loop salt correciton linear fitting.
int noLonelyPairs
Global switch to avoid/allow helices of length 1.
char vrna_md_defaults_backtrack_type_get(void)
Get default backtrack type, i.e. which DP matrix is used.
int vrna_md_defaults_ribo_get(void)
Get default behavior for whether to use Ribosum Scoring in comparative structure prediction.
int max_bp_span
Maximum allowed base pair span.
int vrna_md_defaults_special_hp_get(void)
Get default behavior for lookup of tabulated free energies for special hairpin loops,...
char * vrna_md_option_string(vrna_md_t *md)
Get a corresponding commandline parameter string of the options in a vrna_md_t.
int vrna_md_defaults_oldAliEn_get(void)
Get default behavior for whether to use old energy model for comparative structure prediction.
int gquad
Allow G-quadruplex formation.
char * nonstandards
contains allowed non standard base pairs
int vrna_md_defaults_saltMLUpper_get(void)
Get the default multiloop size upper bound for loop salt correciton linear fitting.
double vrna_md_defaults_salt_get(void)
Get the default salt concentration.
void vrna_md_defaults_noLP(int flag)
Set default behavior for prediction of canonical secondary structures.
void vrna_md_update(vrna_md_t *md)
Update the model details data structure.
void vrna_md_defaults_logML(int flag)
Set default behavior recomputing free energies of multi-branch loops using a logarithmic model.
void vrna_md_defaults_sfact(double factor)
Set the default scaling factor used to avoid under-/overflows in partition function computation.
void vrna_md_defaults_oldAliEn(int flag)
Set default behavior for whether to use old energy model for comparative structure prediction.
void vrna_md_defaults_max_bp_span(int span)
Set default maximal base pair span.
void vrna_md_defaults_circ(int flag)
Set default behavior whether input sequences are circularized.
int tetra_loop
Include special stabilizing energies for some tri-, tetra- and hexa-loops;.
int vrna_md_defaults_noGUclosure_get(void)
Get default behavior for G-U pairs as closing pair for loops.
void vrna_md_defaults_uniq_ML(int flag)
Set default behavior for creating additional matrix for unique multi-branch loop prediction.
double salt
salt concentration
int vrna_md_defaults_min_loop_size_get(void)
Get default minimal loop size.
int vrna_md_defaults_noGU_get(void)
Get default behavior for treatment of G-U wobble pairs.
int vrna_md_defaults_window_size_get(void)
Get default window size for sliding window structure prediction approaches.
int vrna_md_defaults_dangles_get(void)
Get default dangle model for structure prediction.
void vrna_md_defaults_backtrack_type(char t)
Set default backtrack type, i.e. which DP matrix is used.
int uniq_ML
do ML decomposition uniquely (for subopt)
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.
int dangles
Switch the energy model for dangling end contributions (0, 1, 2, 3)
double vrna_md_defaults_nc_fact_get(void)
void vrna_md_defaults_window_size(int size)
Set default window size for sliding window structure prediction approaches.
void vrna_md_defaults_saltMLLower(int lower)
Set the default multiloop size lower bound for loop salt correciton linear fitting.
int logML
if nonzero use logarithmic ML energy in energy_of_struct
char backtrack_type
A backtrack array marker for inverse_fold()
void vrna_md_set_default(vrna_md_t *md)
Apply default model details to a provided vrna_md_t data structure.
void vrna_md_defaults_energy_set(int e)
Set default energy set.
int vrna_md_defaults_backtrack_get(void)
Get default behavior for whether to backtrack secondary structures.
int vrna_md_defaults_noLP_get(void)
Get default behavior for prediction of canonical secondary structures.
void vrna_md_defaults_ribo(int flag)
Set default behavior for whether to use Ribosum Scoring in comparative structure prediction.
int vrna_md_defaults_logML_get(void)
Get default behavior recomputing free energies of multi-branch loops using a logarithmic model.
double vrna_md_defaults_temperature_get(void)
Get default temperature for energy evaluation of loops.
void vrna_md_defaults_backtrack(int flag)
Set default behavior for whether to backtrack secondary structures.
void vrna_md_defaults_noGU(int flag)
Set default behavior for treatment of G-U wobble pairs.
int vrna_md_defaults_compute_bpp_get(void)
Get the default behavior for whether to compute base pair probabilities after partition function comp...
int vrna_md_defaults_max_bp_span_get(void)
Get default maximal base pair span.
vrna_md_t * vrna_md_copy(vrna_md_t *md_to, const vrna_md_t *md_from)
Copy/Clone a vrna_md_t model.
int no_closingGU
GU allowed only inside stacks if set to 1.
void vrna_md_defaults_saltDPXInit(int value)
Set user-provided salt correciton for duplex initialization If value is 99999 the default value from ...
double vrna_md_defaults_sfact_get(void)
Get the default scaling factor used to avoid under-/overflows in partition function computation.
int vrna_md_defaults_uniq_ML_get(void)
Get default behavior for creating additional matrix for unique multi-branch loop prediction.
double temperature
Rescale energy parameters to a temperature in degC.
void set_model_details(vrna_md_t *md)
Set default model details.
double vrna_md_defaults_betaScale_get(void)
Get default scaling factor of thermodynamic temperature in Boltzmann factors.
int noGU
Global switch to forbid/allow GU base pairs at all.
void vrna_md_defaults_salt(double salt)
Set the default salt concentration.
void vrna_md_defaults_min_loop_size(int size)
Set default minimal loop size.
void vrna_md_defaults_nc_fact(double factor)
int oldAliEn
use old alifold energies (with gaps)
void vrna_md_defaults_dangles(int d)
Set default dangle model for structure prediction.
void vrna_md_defaults_cv_fact(double factor)
Set the default co-variance scaling factor used in comparative structure prediction.
int vrna_md_defaults_circ_get(void)
Get default behavior whether input sequences are circularized.
double pf_scale
A scaling factor used by pf_fold() to avoid overflows.
int do_backtrack
do backtracking, i.e. compute secondary structures or base pair probabilities
void vrna_md_defaults_noGUclosure(int flag)
Set default behavior for G-U pairs as closing pair for loops.
double vrna_md_defaults_cv_fact_get(void)
Get the default co-variance scaling factor used in comparative structure prediction.
int vrna_md_defaults_gquad_get(void)
Get default behavior for treatment of G-Quadruplexes.
void vrna_md_defaults_betaScale(double b)
Set default scaling factor of thermodynamic temperature in Boltzmann factors.
void vrna_md_defaults_compute_bpp(int flag)
Set the default behavior for whether to compute base pair probabilities after partition function comp...
void vrna_md_defaults_saltMLUpper(int upper)
Set the default multiloop size upper bound for loop salt correciton linear fitting.
int circ
backward compatibility variable.. this does not effect anything
void vrna_md_defaults_temperature(double T)
Set default temperature for energy evaluation of loops.
int energy_set
0 = BP; 1=any with GC; 2=any with AU-parameter
int saltDPXInit
Salt correction for duplex initialization.
void vrna_md_defaults_special_hp(int flag)
Set default behavior for lookup of tabulated free energies for special hairpin loops,...
The data structure that contains the complete model details used throughout the calculations.
Definition: model.h:203