Debian Codegraph @

doc/artificialFastqGenerator/QualityScoreAndErrorGenerator.html

raw
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
2 <!-- NewPage -->
3 <html lang="en">
4 <head>
5 <!-- Generated by javadoc (version 1.7.0_51) on Wed Oct 01 16:41:56 BST 2014 -->
6 <title>QualityScoreAndErrorGenerator</title>
7 <meta name="date" content="2014-10-01">
8 <link rel="stylesheet" type="text/css" href="../stylesheet.css" title="Style">
9 </head>
10 <body>
11 <script type="text/javascript"><!--
12 if (location.href.indexOf('is-external=true') == -1) {
13 parent.document.title="QualityScoreAndErrorGenerator";
14 }
15 //-->
16 </script>
17 <noscript>
18 <div>JavaScript is disabled on your browser.</div>
19 </noscript>
20 <!-- ========= START OF TOP NAVBAR ======= -->
21 <div class="topNav"><a name="navbar_top">
22 <!-- -->
23 </a><a href="#skip-navbar_top" title="Skip navigation links"></a><a name="navbar_top_firstrow">
24 <!-- -->
25 </a>
26 <ul class="navList" title="Navigation">
27 <li><a href="../artificialFastqGenerator/package-summary.html">Package</a></li>
28 <li class="navBarCell1Rev">Class</li>
29 <li><a href="class-use/QualityScoreAndErrorGenerator.html">Use</a></li>
30 <li><a href="package-tree.html">Tree</a></li>
31 <li><a href="../deprecated-list.html">Deprecated</a></li>
32 <li><a href="../index-files/index-1.html">Index</a></li>
33 <li><a href="../help-doc.html">Help</a></li>
34 </ul>
35 </div>
36 <div class="subNav">
37 <ul class="navList">
38 <li><a href="../artificialFastqGenerator/NucleobaseAndReadFactory.html" title="class in artificialFastqGenerator"><span class="strong">Prev Class</span></a></li>
39 <li><a href="../artificialFastqGenerator/Read.html" title="class in artificialFastqGenerator"><span class="strong">Next Class</span></a></li>
40 </ul>
41 <ul class="navList">
42 <li><a href="../index.html?artificialFastqGenerator/QualityScoreAndErrorGenerator.html" target="_top">Frames</a></li>
43 <li><a href="QualityScoreAndErrorGenerator.html" target="_top">No Frames</a></li>
44 </ul>
45 <ul class="navList" id="allclasses_navbar_top">
46 <li><a href="../allclasses-noframe.html">All Classes</a></li>
47 </ul>
48 <div>
49 <script type="text/javascript"><!--
50 allClassesLink = document.getElementById("allclasses_navbar_top");
51 if(window==top) {
52 allClassesLink.style.display = "block";
53 }
54 else {
55 allClassesLink.style.display = "none";
56 }
57 //-->
58 </script>
59 </div>
60 <div>
61 <ul class="subNavList">
62 <li>Summary:&nbsp;</li>
63 <li>Nested&nbsp;|&nbsp;</li>
64 <li><a href="#field_summary">Field</a>&nbsp;|&nbsp;</li>
65 <li><a href="#constructor_summary">Constr</a>&nbsp;|&nbsp;</li>
66 <li><a href="#method_summary">Method</a></li>
67 </ul>
68 <ul class="subNavList">
69 <li>Detail:&nbsp;</li>
70 <li><a href="#field_detail">Field</a>&nbsp;|&nbsp;</li>
71 <li><a href="#constructor_detail">Constr</a>&nbsp;|&nbsp;</li>
72 <li><a href="#method_detail">Method</a></li>
73 </ul>
74 </div>
75 <a name="skip-navbar_top">
76 <!-- -->
77 </a></div>
78 <!-- ========= END OF TOP NAVBAR ========= -->
79 <!-- ======== START OF CLASS DATA ======== -->
80 <div class="header">
81 <div class="subTitle">artificialFastqGenerator</div>
82 <h2 title="Class QualityScoreAndErrorGenerator" class="title">Class QualityScoreAndErrorGenerator</h2>
83 </div>
84 <div class="contentContainer">
85 <ul class="inheritance">
86 <li>java.lang.Object</li>
87 <li>
88 <ul class="inheritance">
89 <li>artificialFastqGenerator.QualityScoreAndErrorGenerator</li>
90 </ul>
91 </li>
92 </ul>
93 <div class="description">
94 <ul class="blockList">
95 <li class="blockList">
96 <hr>
97 <br>
98 <pre>public class <span class="strong">QualityScoreAndErrorGenerator</span>
99 extends java.lang.Object</pre>
100 <div class="block">An instance of this class can be used to generate (1) ASCII encodings of Phred quality scores for bases in reads; (2)
101 base-call errors. (1) is done by taking quality scores from a pre-existing FASTQ file, and (2) by generating an error with
102 a probability that depends on the base's phred score.
103
104 Copyright (C) 2012 The Institute of Cancer Research (ICR).
105
106 This file is part of ArtificialFastqGenerator v1.0.0.
107
108 ArtificialFastqGenerator is free software: you can redistribute it and/or modify it under the terms of the GNU General
109 Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any
110 later version.
111
112 This program is distributed in the hope that it will be useful but WITHOUT ANY WARRANTY; without even the implied warranty
113 of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
114
115 You should have received a copy of the GNU Public License along with this program. If not, see
116 <http://www.gnu.org/licenses/>
117
118 Authour's contact email: [email protected]</div>
119 </li>
120 </ul>
121 </div>
122 <div class="summary">
123 <ul class="blockList">
124 <li class="blockList">
125 <!-- =========== FIELD SUMMARY =========== -->
126 <ul class="blockList">
127 <li class="blockList"><a name="field_summary">
128 <!-- -->
129 </a>
130 <h3>Field Summary</h3>
131 <table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Field Summary table, listing fields, and an explanation">
132 <caption><span>Fields</span><span class="tabEnd">&nbsp;</span></caption>
133 <tr>
134 <th class="colFirst" scope="col">Modifier and Type</th>
135 <th class="colLast" scope="col">Field and Description</th>
136 </tr>
137 <tr class="altColor">
138 <td class="colFirst"><code>static char[]</code></td>
139 <td class="colLast"><code><strong><a href="../artificialFastqGenerator/QualityScoreAndErrorGenerator.html#encodedSangerQualityScores">encodedSangerQualityScores</a></strong></code>&nbsp;</td>
140 </tr>
141 </table>
142 </li>
143 </ul>
144 <!-- ======== CONSTRUCTOR SUMMARY ======== -->
145 <ul class="blockList">
146 <li class="blockList"><a name="constructor_summary">
147 <!-- -->
148 </a>
149 <h3>Constructor Summary</h3>
150 <table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Constructor Summary table, listing constructors, and an explanation">
151 <caption><span>Constructors</span><span class="tabEnd">&nbsp;</span></caption>
152 <tr>
153 <th class="colOne" scope="col">Constructor and Description</th>
154 </tr>
155 <tr class="altColor">
156 <td class="colOne"><code><strong><a href="../artificialFastqGenerator/QualityScoreAndErrorGenerator.html#QualityScoreAndErrorGenerator(int, boolean, boolean, java.lang.String, java.lang.String)">QualityScoreAndErrorGenerator</a></strong>(int&nbsp;readLength,
157 boolean&nbsp;useRealQualityScores,
158 boolean&nbsp;simulateErrorInRead,
159 java.lang.String&nbsp;fastq1ForQualityScoresPath,
160 java.lang.String&nbsp;fastq2ForQualityScoresPath)</code>
161 <div class="block">Initialise a new QualityScoreAndErrorGenerator object.</div>
162 </td>
163 </tr>
164 </table>
165 </li>
166 </ul>
167 <!-- ========== METHOD SUMMARY =========== -->
168 <ul class="blockList">
169 <li class="blockList"><a name="method_summary">
170 <!-- -->
171 </a>
172 <h3>Method Summary</h3>
173 <table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation">
174 <caption><span>Methods</span><span class="tabEnd">&nbsp;</span></caption>
175 <tr>
176 <th class="colFirst" scope="col">Modifier and Type</th>
177 <th class="colLast" scope="col">Method and Description</th>
178 </tr>
179 <tr class="altColor">
180 <td class="colFirst"><code>long</code></td>
181 <td class="colLast"><code><strong><a href="../artificialFastqGenerator/QualityScoreAndErrorGenerator.html#getNumACGTBasesCalled()">getNumACGTBasesCalled</a></strong>()</code>
182 <div class="block">Get the number of ACGT bases.</div>
183 </td>
184 </tr>
185 <tr class="rowColor">
186 <td class="colFirst"><code>long</code></td>
187 <td class="colLast"><code><strong><a href="../artificialFastqGenerator/QualityScoreAndErrorGenerator.html#getNumBaseCallErrors()">getNumBaseCallErrors</a></strong>()</code>
188 <div class="block">Get the number of base call errors that have been simulated.</div>
189 </td>
190 </tr>
191 <tr class="altColor">
192 <td class="colFirst"><code>java.util.ArrayList&lt;char[]&gt;</code></td>
193 <td class="colLast"><code><strong><a href="../artificialFastqGenerator/QualityScoreAndErrorGenerator.html#getQualityScoresAndGenotypesRead(boolean, java.util.ArrayList)">getQualityScoresAndGenotypesRead</a></strong>(boolean&nbsp;isLeft,
194 java.util.ArrayList&lt;<a href="../artificialFastqGenerator/Nucleobase.html" title="class in artificialFastqGenerator">Nucleobase</a>&gt;&nbsp;nucleobases)</code>
195 <div class="block">Get the encoded phred quality scores and the genotypes read.</div>
196 </td>
197 </tr>
198 <tr class="rowColor">
199 <td class="colFirst"><code>void</code></td>
200 <td class="colLast"><code><strong><a href="../artificialFastqGenerator/QualityScoreAndErrorGenerator.html#resetNumBaseCallErrors()">resetNumBaseCallErrors</a></strong>()</code>
201 <div class="block">Reset the number of simulated base call errors to 0.</div>
202 </td>
203 </tr>
204 </table>
205 <ul class="blockList">
206 <li class="blockList"><a name="methods_inherited_from_class_java.lang.Object">
207 <!-- -->
208 </a>
209 <h3>Methods inherited from class&nbsp;java.lang.Object</h3>
210 <code>equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</code></li>
211 </ul>
212 </li>
213 </ul>
214 </li>
215 </ul>
216 </div>
217 <div class="details">
218 <ul class="blockList">
219 <li class="blockList">
220 <!-- ============ FIELD DETAIL =========== -->
221 <ul class="blockList">
222 <li class="blockList"><a name="field_detail">
223 <!-- -->
224 </a>
225 <h3>Field Detail</h3>
226 <a name="encodedSangerQualityScores">
227 <!-- -->
228 </a>
229 <ul class="blockListLast">
230 <li class="blockList">
231 <h4>encodedSangerQualityScores</h4>
232 <pre>public static final&nbsp;char[] encodedSangerQualityScores</pre>
233 </li>
234 </ul>
235 </li>
236 </ul>
237 <!-- ========= CONSTRUCTOR DETAIL ======== -->
238 <ul class="blockList">
239 <li class="blockList"><a name="constructor_detail">
240 <!-- -->
241 </a>
242 <h3>Constructor Detail</h3>
243 <a name="QualityScoreAndErrorGenerator(int, boolean, boolean, java.lang.String, java.lang.String)">
244 <!-- -->
245 </a>
246 <ul class="blockListLast">
247 <li class="blockList">
248 <h4>QualityScoreAndErrorGenerator</h4>
249 <pre>public&nbsp;QualityScoreAndErrorGenerator(int&nbsp;readLength,
250 boolean&nbsp;useRealQualityScores,
251 boolean&nbsp;simulateErrorInRead,
252 java.lang.String&nbsp;fastq1ForQualityScoresPath,
253 java.lang.String&nbsp;fastq2ForQualityScoresPath)</pre>
254 <div class="block">Initialise a new QualityScoreAndErrorGenerator object.</div>
255 <dl><dt><span class="strong">Parameters:</span></dt><dd><code>readLength</code> - - the length of each read.</dd><dd><code>useRealQualityScores</code> - - true if using quality scores from an existing fastq file, else false.</dd><dd><code>simulateErrorInRead</code> - - true if simulating error in reads, else false.</dd><dd><code>fastq1ForQualityScoresPath</code> - - the 1st fastq file whose quality scores are used.</dd><dd><code>fastq2ForQualityScoresPath</code> - - the 2nd fastq file whose quality scores are used.</dd></dl>
256 </li>
257 </ul>
258 </li>
259 </ul>
260 <!-- ============ METHOD DETAIL ========== -->
261 <ul class="blockList">
262 <li class="blockList"><a name="method_detail">
263 <!-- -->
264 </a>
265 <h3>Method Detail</h3>
266 <a name="getQualityScoresAndGenotypesRead(boolean, java.util.ArrayList)">
267 <!-- -->
268 </a>
269 <ul class="blockList">
270 <li class="blockList">
271 <h4>getQualityScoresAndGenotypesRead</h4>
272 <pre>public&nbsp;java.util.ArrayList&lt;char[]&gt;&nbsp;getQualityScoresAndGenotypesRead(boolean&nbsp;isLeft,
273 java.util.ArrayList&lt;<a href="../artificialFastqGenerator/Nucleobase.html" title="class in artificialFastqGenerator">Nucleobase</a>&gt;&nbsp;nucleobases)</pre>
274 <div class="block">Get the encoded phred quality scores and the genotypes read. If the read is right-end, then it should align to the
275 -ive strand, so reverse nucleobases, and read their complements.</div>
276 <dl><dt><span class="strong">Parameters:</span></dt><dd><code>isLeft</code> - - true if the read is a left read, else false.</dd><dd><code>nucleobases</code> - - human reference sequence nucleobases which the read is a read of.</dd>
277 <dt><span class="strong">Returns:</span></dt><dd>finalQualityScoresAndGenotypesRead - an ArrayList of char arrays containing the final quality scores and the
278 genotypes that get read.</dd></dl>
279 </li>
280 </ul>
281 <a name="getNumBaseCallErrors()">
282 <!-- -->
283 </a>
284 <ul class="blockList">
285 <li class="blockList">
286 <h4>getNumBaseCallErrors</h4>
287 <pre>public&nbsp;long&nbsp;getNumBaseCallErrors()</pre>
288 <div class="block">Get the number of base call errors that have been simulated.</div>
289 <dl><dt><span class="strong">Returns:</span></dt><dd>numBaseCallErrors - the number of bases for which base calls have been simulated.</dd></dl>
290 </li>
291 </ul>
292 <a name="resetNumBaseCallErrors()">
293 <!-- -->
294 </a>
295 <ul class="blockList">
296 <li class="blockList">
297 <h4>resetNumBaseCallErrors</h4>
298 <pre>public&nbsp;void&nbsp;resetNumBaseCallErrors()</pre>
299 <div class="block">Reset the number of simulated base call errors to 0.</div>
300 </li>
301 </ul>
302 <a name="getNumACGTBasesCalled()">
303 <!-- -->
304 </a>
305 <ul class="blockListLast">
306 <li class="blockList">
307 <h4>getNumACGTBasesCalled</h4>
308 <pre>public&nbsp;long&nbsp;getNumACGTBasesCalled()</pre>
309 <div class="block">Get the number of ACGT bases.</div>
310 <dl><dt><span class="strong">Returns:</span></dt><dd>numACGTBaseCalls - the number of ACGT bases that have been called.</dd></dl>
311 </li>
312 </ul>
313 </li>
314 </ul>
315 </li>
316 </ul>
317 </div>
318 </div>
319 <!-- ========= END OF CLASS DATA ========= -->
320 <!-- ======= START OF BOTTOM NAVBAR ====== -->
321 <div class="bottomNav"><a name="navbar_bottom">
322 <!-- -->
323 </a><a href="#skip-navbar_bottom" title="Skip navigation links"></a><a name="navbar_bottom_firstrow">
324 <!-- -->
325 </a>
326 <ul class="navList" title="Navigation">
327 <li><a href="../artificialFastqGenerator/package-summary.html">Package</a></li>
328 <li class="navBarCell1Rev">Class</li>
329 <li><a href="class-use/QualityScoreAndErrorGenerator.html">Use</a></li>
330 <li><a href="package-tree.html">Tree</a></li>
331 <li><a href="../deprecated-list.html">Deprecated</a></li>
332 <li><a href="../index-files/index-1.html">Index</a></li>
333 <li><a href="../help-doc.html">Help</a></li>
334 </ul>
335 </div>
336 <div class="subNav">
337 <ul class="navList">
338 <li><a href="../artificialFastqGenerator/NucleobaseAndReadFactory.html" title="class in artificialFastqGenerator"><span class="strong">Prev Class</span></a></li>
339 <li><a href="../artificialFastqGenerator/Read.html" title="class in artificialFastqGenerator"><span class="strong">Next Class</span></a></li>
340 </ul>
341 <ul class="navList">
342 <li><a href="../index.html?artificialFastqGenerator/QualityScoreAndErrorGenerator.html" target="_top">Frames</a></li>
343 <li><a href="QualityScoreAndErrorGenerator.html" target="_top">No Frames</a></li>
344 </ul>
345 <ul class="navList" id="allclasses_navbar_bottom">
346 <li><a href="../allclasses-noframe.html">All Classes</a></li>
347 </ul>
348 <div>
349 <script type="text/javascript"><!--
350 allClassesLink = document.getElementById("allclasses_navbar_bottom");
351 if(window==top) {
352 allClassesLink.style.display = "block";
353 }
354 else {
355 allClassesLink.style.display = "none";
356 }
357 //-->
358 </script>
359 </div>
360 <div>
361 <ul class="subNavList">
362 <li>Summary:&nbsp;</li>
363 <li>Nested&nbsp;|&nbsp;</li>
364 <li><a href="#field_summary">Field</a>&nbsp;|&nbsp;</li>
365 <li><a href="#constructor_summary">Constr</a>&nbsp;|&nbsp;</li>
366 <li><a href="#method_summary">Method</a></li>
367 </ul>
368 <ul class="subNavList">
369 <li>Detail:&nbsp;</li>
370 <li><a href="#field_detail">Field</a>&nbsp;|&nbsp;</li>
371 <li><a href="#constructor_detail">Constr</a>&nbsp;|&nbsp;</li>
372 <li><a href="#method_detail">Method</a></li>
373 </ul>
374 </div>
375 <a name="skip-navbar_bottom">
376 <!-- -->
377 </a></div>
378 <!-- ======== END OF BOTTOM NAVBAR ======= -->
379 </body>
380 </html>