1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
2 <html xmlns="http://www.w3.org/1999/xhtml">
4 <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
5 <title>RNAlib-2.1.2: Partition functions for locally stable secondary structures</title>
6 <link href="tabs.css" rel="stylesheet" type="text/css"/>
7 <link href="doxygen.css" rel="stylesheet" type="text/css"/>
10 <!-- Generated by Doxygen 1.6.1 -->
11 <script type="text/javascript">
13 function changeDisplayState (e){
14 var num=this.id.replace(/[^[0-9]/g,'');
15 var button=this.firstChild;
16 var sectionDiv=document.getElementById('dynsection'+num);
17 if (sectionDiv.style.display=='none'||sectionDiv.style.display==''){
18 sectionDiv.style.display='block';
19 button.src='open.gif';
21 sectionDiv.style.display='none';
22 button.src='closed.gif';
25 function initDynSections(){
26 var divs=document.getElementsByTagName('div');
28 for(var i=0;i<divs.length-1;i++){
29 if(divs[i].className=='dynheader'&&divs[i+1].className=='dynsection'){
31 var section=divs[i+1];
32 var button=header.firstChild;
34 divs[i].insertBefore(document.createTextNode(' '),divs[i].firstChild);
35 button=document.createElement('img');
36 divs[i].insertBefore(button,divs[i].firstChild);
38 header.style.cursor='pointer';
39 header.onclick=changeDisplayState;
40 header.id='dynheader'+sectionCounter;
41 button.src='closed.gif';
42 section.id='dynsection'+sectionCounter;
43 section.style.display='none';
44 section.style.marginLeft='14px';
49 window.onload = initDynSections;
52 <div class="navigation" id="top">
55 <li><a href="main.html"><span>Main Page</span></a></li>
56 <li><a href="pages.html"><span>Related Pages</span></a></li>
57 <li><a href="modules.html"><span>Modules</span></a></li>
58 <li><a href="annotated.html"><span>Data Structures</span></a></li>
59 <li><a href="files.html"><span>Files</span></a></li>
63 <div class="contents">
64 <h1>Partition functions for locally stable secondary structures<br/>
66 [<a class="el" href="group__local__fold.html">Predicting Locally stable structures of large sequences</a>, <a class="el" href="group__pf__fold.html">Calculating Partition Functions and Pair Probabilities</a>]</small>
68 <p><div class="dynheader">
69 Collaboration diagram for Partition functions for locally stable secondary structures:</div>
70 <div class="dynsection">
71 <center><table><tr><td><img src="group__local__pf__fold.png" border="0" alt="" usemap="#group____local____pf____fold_map"/>
72 <map name="group____local____pf____fold_map" id="group____local____pf____fold">
73 <area shape="rect" id="node1" href="group__pf__fold.html" title="This section provides information about all functions and variables related to the..." alt="" coords="16,5,347,35"/><area shape="rect" id="node2" href="group__local__fold.html" title="Predicting Locally stable structures of large sequences" alt="" coords="7,58,356,89"/></map></td></tr></table></center>
76 <table border="0" cellpadding="0" cellspacing="0">
77 <tr><td colspan="2"><h2>Functions</h2></td></tr>
78 <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="group__local__pf__fold.html#ga5a019014d37fe6105131dfc2fc447880">update_pf_paramsLP</a> (int length)</td></tr>
79 <tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="structplist.html">plist</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="group__local__pf__fold.html#gaa1ecd401617ebc748a0220026543c777">pfl_fold</a> (char *sequence, int winSize, int pairSize, float cutoffb, double **pU, struct <a class="el" href="structplist.html">plist</a> **dpp2, FILE *pUfp, FILE *spup)</td></tr>
80 <tr><td class="mdescLeft"> </td><td class="mdescRight">Compute partition functions for locally stable secondary structures. <a href="#gaa1ecd401617ebc748a0220026543c777"></a><br/></td></tr>
81 <tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="gab354507e8028f3e1c52ef96bb1eb9df8"></a><!-- doxytag: member="local_pf_fold::pfl_fold_par" ref="gab354507e8028f3e1c52ef96bb1eb9df8" args="(char *sequence, int winSize, int pairSize, float cutoffb, double **pU, struct plist **dpp2, FILE *pUfp, FILE *spup, pf_paramT *parameters)" -->
82 <a class="el" href="structplist.html">plist</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="group__local__pf__fold.html#gab354507e8028f3e1c52ef96bb1eb9df8">pfl_fold_par</a> (char *sequence, int winSize, int pairSize, float cutoffb, double **pU, struct <a class="el" href="structplist.html">plist</a> **dpp2, FILE *pUfp, FILE *spup, <a class="el" href="structpf__paramT.html">pf_paramT</a> *parameters)</td></tr>
83 <tr><td class="mdescLeft"> </td><td class="mdescRight">Compute partition functions for locally stable secondary structures. <br/></td></tr>
84 <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="group__local__pf__fold.html#ga0bcb751860bbf34e3dfee8c2fbdb3ef3">putoutpU_prob</a> (double **pU, int length, int ulength, FILE *fp, int energies)</td></tr>
85 <tr><td class="mdescLeft"> </td><td class="mdescRight">Writes the unpaired probabilities (pU) or opening energies into a file. <a href="#ga0bcb751860bbf34e3dfee8c2fbdb3ef3"></a><br/></td></tr>
86 <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="group__local__pf__fold.html#ga9acb00ee10e96b1ca4ea394cd8bcec75">putoutpU_prob_bin</a> (double **pU, int length, int ulength, FILE *fp, int energies)</td></tr>
87 <tr><td class="mdescLeft"> </td><td class="mdescRight">Writes the unpaired probabilities (pU) or opening energies into a binary file. <a href="#ga9acb00ee10e96b1ca4ea394cd8bcec75"></a><br/></td></tr>
89 <hr/><h2>Function Documentation</h2>
90 <a class="anchor" id="ga5a019014d37fe6105131dfc2fc447880"></a><!-- doxytag: member="LPfold.h::update_pf_paramsLP" ref="ga5a019014d37fe6105131dfc2fc447880" args="(int length)" -->
92 <div class="memproto">
93 <table class="memname">
95 <td class="memname">void update_pf_paramsLP </td>
97 <td class="paramtype">int </td>
98 <td class="paramname"> <em>length</em></td>
99 <td> ) </td>
105 <dl><dt><b>Parameters:</b></dt><dd>
106 <table border="0" cellspacing="2" cellpadding="0">
107 <tr><td valign="top"></td><td valign="top"><em>length</em> </td><td></td></tr>
114 <a class="anchor" id="gaa1ecd401617ebc748a0220026543c777"></a><!-- doxytag: member="LPfold.h::pfl_fold" ref="gaa1ecd401617ebc748a0220026543c777" args="(char *sequence, int winSize, int pairSize, float cutoffb, double **pU, struct plist **dpp2, FILE *pUfp, FILE *spup)" -->
115 <div class="memitem">
116 <div class="memproto">
117 <table class="memname">
119 <td class="memname"><a class="el" href="structplist.html">plist</a>* pfl_fold </td>
121 <td class="paramtype">char * </td>
122 <td class="paramname"> <em>sequence</em>, </td>
125 <td class="paramkey"></td>
127 <td class="paramtype">int </td>
128 <td class="paramname"> <em>winSize</em>, </td>
131 <td class="paramkey"></td>
133 <td class="paramtype">int </td>
134 <td class="paramname"> <em>pairSize</em>, </td>
137 <td class="paramkey"></td>
139 <td class="paramtype">float </td>
140 <td class="paramname"> <em>cutoffb</em>, </td>
143 <td class="paramkey"></td>
145 <td class="paramtype">double ** </td>
146 <td class="paramname"> <em>pU</em>, </td>
149 <td class="paramkey"></td>
151 <td class="paramtype">struct <a class="el" href="structplist.html">plist</a> ** </td>
152 <td class="paramname"> <em>dpp2</em>, </td>
155 <td class="paramkey"></td>
157 <td class="paramtype">FILE * </td>
158 <td class="paramname"> <em>pUfp</em>, </td>
161 <td class="paramkey"></td>
163 <td class="paramtype">FILE * </td>
164 <td class="paramname"> <em>spup</em></td><td> </td>
169 <td></td><td></td><td></td>
175 <p>Compute partition functions for locally stable secondary structures. </p>
176 <p>pfl_fold computes partition functions for every window of size 'winSize' possible in a RNA molecule, allowing only pairs with a span smaller than 'pairSize'. It returns the mean pair probabilities averaged over all windows containing the pair in 'pl'. 'winSize' should always be >= 'pairSize'. Note that in contrast to <a class="el" href="group__local__mfe__fold.html#ga16e5a70e60835bb969eaecbe6482f1be" title="The local analog to fold().">Lfold()</a>, bases outside of the window do not influence the structure at all. Only probabilities higher than 'cutoffb' are kept.</p>
177 <p>If 'pU' is supplied (i.e is not the NULL pointer), <a class="el" href="group__local__pf__fold.html#gaa1ecd401617ebc748a0220026543c777" title="Compute partition functions for locally stable secondary structures.">pfl_fold()</a> will also compute the mean probability that regions of length 'u' and smaller are unpaired. The parameter 'u' is supplied in 'pup[0][0]'. On return the 'pup' array will contain these probabilities, with the entry on 'pup[x][y]' containing the mean probability that x and the y-1 preceding bases are unpaired. The 'pU' array needs to be large enough to hold n+1 float* entries, where n is the sequence length.</p>
178 <p>If an array dpp2 is supplied, the probability of base pair (i,j) given that there already exists a base pair (i+1,j-1) is also computed and saved in this array. If pUfp is given (i.e. not NULL), pU is not saved but put out imediately. If spup is given (i.e. is not NULL), the pair probabilities in pl are not saved but put out imediately.</p>
179 <dl><dt><b>Parameters:</b></dt><dd>
180 <table border="0" cellspacing="2" cellpadding="0">
181 <tr><td valign="top"></td><td valign="top"><em>sequence</em> </td><td>RNA sequence </td></tr>
182 <tr><td valign="top"></td><td valign="top"><em>winSize</em> </td><td>size of the window </td></tr>
183 <tr><td valign="top"></td><td valign="top"><em>pairSize</em> </td><td>maximum size of base pair </td></tr>
184 <tr><td valign="top"></td><td valign="top"><em>cutoffb</em> </td><td>cutoffb for base pairs </td></tr>
185 <tr><td valign="top"></td><td valign="top"><em>pU</em> </td><td>array holding all unpaired probabilities </td></tr>
186 <tr><td valign="top"></td><td valign="top"><em>dpp2</em> </td><td>array of dependent pair probabilities </td></tr>
187 <tr><td valign="top"></td><td valign="top"><em>pUfp</em> </td><td>file pointer for pU </td></tr>
188 <tr><td valign="top"></td><td valign="top"><em>spup</em> </td><td>file pointer for pair probabilities </td></tr>
192 <dl class="return"><dt><b>Returns:</b></dt><dd>list of pair probabilities </dd></dl>
196 <a class="anchor" id="ga0bcb751860bbf34e3dfee8c2fbdb3ef3"></a><!-- doxytag: member="LPfold.h::putoutpU_prob" ref="ga0bcb751860bbf34e3dfee8c2fbdb3ef3" args="(double **pU, int length, int ulength, FILE *fp, int energies)" -->
197 <div class="memitem">
198 <div class="memproto">
199 <table class="memname">
201 <td class="memname">void putoutpU_prob </td>
203 <td class="paramtype">double ** </td>
204 <td class="paramname"> <em>pU</em>, </td>
207 <td class="paramkey"></td>
209 <td class="paramtype">int </td>
210 <td class="paramname"> <em>length</em>, </td>
213 <td class="paramkey"></td>
215 <td class="paramtype">int </td>
216 <td class="paramname"> <em>ulength</em>, </td>
219 <td class="paramkey"></td>
221 <td class="paramtype">FILE * </td>
222 <td class="paramname"> <em>fp</em>, </td>
225 <td class="paramkey"></td>
227 <td class="paramtype">int </td>
228 <td class="paramname"> <em>energies</em></td><td> </td>
233 <td></td><td></td><td></td>
239 <p>Writes the unpaired probabilities (pU) or opening energies into a file. </p>
240 <p>Can write either the unpaired probabilities (accessibilities) pU or the opening energies -log(pU)kT into a file</p>
241 <dl><dt><b>Parameters:</b></dt><dd>
242 <table border="0" cellspacing="2" cellpadding="0">
243 <tr><td valign="top"></td><td valign="top"><em>pU</em> </td><td>pair probabilities </td></tr>
244 <tr><td valign="top"></td><td valign="top"><em>length</em> </td><td>length of RNA sequence </td></tr>
245 <tr><td valign="top"></td><td valign="top"><em>ulength</em> </td><td>maximum length of unpaired stretch </td></tr>
246 <tr><td valign="top"></td><td valign="top"><em>fp</em> </td><td>file pointer of destination file </td></tr>
247 <tr><td valign="top"></td><td valign="top"><em>energies</em> </td><td>switch to put out as opening energies </td></tr>
254 <a class="anchor" id="ga9acb00ee10e96b1ca4ea394cd8bcec75"></a><!-- doxytag: member="LPfold.h::putoutpU_prob_bin" ref="ga9acb00ee10e96b1ca4ea394cd8bcec75" args="(double **pU, int length, int ulength, FILE *fp, int energies)" -->
255 <div class="memitem">
256 <div class="memproto">
257 <table class="memname">
259 <td class="memname">void putoutpU_prob_bin </td>
261 <td class="paramtype">double ** </td>
262 <td class="paramname"> <em>pU</em>, </td>
265 <td class="paramkey"></td>
267 <td class="paramtype">int </td>
268 <td class="paramname"> <em>length</em>, </td>
271 <td class="paramkey"></td>
273 <td class="paramtype">int </td>
274 <td class="paramname"> <em>ulength</em>, </td>
277 <td class="paramkey"></td>
279 <td class="paramtype">FILE * </td>
280 <td class="paramname"> <em>fp</em>, </td>
283 <td class="paramkey"></td>
285 <td class="paramtype">int </td>
286 <td class="paramname"> <em>energies</em></td><td> </td>
291 <td></td><td></td><td></td>
297 <p>Writes the unpaired probabilities (pU) or opening energies into a binary file. </p>
298 <p>Can write either the unpaired probabilities (accessibilities) pU or the opening energies -log(pU)kT into a file</p>
299 <dl><dt><b>Parameters:</b></dt><dd>
300 <table border="0" cellspacing="2" cellpadding="0">
301 <tr><td valign="top"></td><td valign="top"><em>pU</em> </td><td>pair probabilities </td></tr>
302 <tr><td valign="top"></td><td valign="top"><em>length</em> </td><td>length of RNA sequence </td></tr>
303 <tr><td valign="top"></td><td valign="top"><em>ulength</em> </td><td>maximum length of unpaired stretch </td></tr>
304 <tr><td valign="top"></td><td valign="top"><em>fp</em> </td><td>file pointer of destination file </td></tr>
305 <tr><td valign="top"></td><td valign="top"><em>energies</em> </td><td>switch to put out as opening energies </td></tr>
313 <hr size="1"/><address style="text-align: right;"><small>Generated on 11 Apr 2017 for RNAlib-2.1.2 by
314 <a href="http://www.doxygen.org/index.html">
315 <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.6.1 </small></address>