bio-samtools 0.6.2 → 2.0.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (160) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile +3 -2
  3. data/README.md +4 -7
  4. data/VERSION +1 -1
  5. data/bio-samtools.gemspec +47 -105
  6. data/doc/Bio.html +68 -131
  7. data/doc/Bio/DB.html +51 -111
  8. data/doc/Bio/DB/Alignment.html +135 -363
  9. data/doc/Bio/DB/Pileup.html +183 -170
  10. data/doc/Bio/DB/SAM.html +1396 -820
  11. data/doc/Bio/DB/SAM/Library.html +73 -123
  12. data/doc/Bio/DB/SAM/Tools.html +51 -273
  13. data/doc/Bio/DB/Tag.html +78 -124
  14. data/doc/Bio/DB/Vcf.html +111 -147
  15. data/doc/LICENSE_txt.html +113 -148
  16. data/doc/created.rid +9 -10
  17. data/doc/fonts.css +167 -0
  18. data/doc/fonts/Lato-Light.ttf +0 -0
  19. data/doc/fonts/Lato-LightItalic.ttf +0 -0
  20. data/doc/fonts/Lato-Regular.ttf +0 -0
  21. data/doc/fonts/Lato-RegularItalic.ttf +0 -0
  22. data/doc/fonts/SourceCodePro-Bold.ttf +0 -0
  23. data/doc/fonts/SourceCodePro-Regular.ttf +0 -0
  24. data/doc/images/add.png +0 -0
  25. data/doc/images/arrow_up.png +0 -0
  26. data/doc/images/delete.png +0 -0
  27. data/doc/images/tag_blue.png +0 -0
  28. data/doc/index.html +48 -54
  29. data/doc/js/darkfish.js +9 -22
  30. data/doc/js/search.js +20 -5
  31. data/doc/js/search_index.js +1 -1
  32. data/doc/rdoc.css +255 -218
  33. data/doc/table_of_contents.html +256 -137
  34. data/ext/Rakefile +57 -0
  35. data/lib/bio-samtools.rb +7 -2
  36. data/lib/bio/BIOExtensions.rb +89 -0
  37. data/lib/bio/db/alignment.rb +59 -0
  38. data/lib/bio/db/fastadb.rb +255 -0
  39. data/lib/bio/db/pileup.rb +221 -172
  40. data/lib/bio/db/sam.rb +639 -589
  41. data/lib/bio/db/sam/{faidx.rb → faidx_old.rb} +0 -0
  42. data/lib/bio/db/vcf.rb +69 -68
  43. data/test/.gitignore +1 -0
  44. data/test/{test_basic.rb → old_test_basic.rb} +33 -1
  45. data/test/samples/small/dupes.bam +0 -0
  46. data/test/samples/small/dupes.sam +274 -0
  47. data/test/samples/small/map_for_reheader.sam +8 -0
  48. data/test/samples/small/map_to_merge1.bam +0 -0
  49. data/test/samples/small/map_to_merge1.bam.bai +0 -0
  50. data/test/samples/small/map_to_merge1.sam +8 -0
  51. data/test/samples/small/map_to_merge2.bam +0 -0
  52. data/test/samples/small/map_to_merge2.bam.bai +0 -0
  53. data/test/samples/small/map_to_merge2.sam +8 -0
  54. data/test/samples/small/no_md.sam +8 -0
  55. data/test/samples/small/test_chr.fasta.1.bt2 +0 -0
  56. data/test/samples/small/test_chr.fasta.2.bt2 +0 -0
  57. data/test/samples/small/test_chr.fasta.3.bt2 +0 -0
  58. data/test/samples/small/test_chr.fasta.4.bt2 +0 -0
  59. data/test/samples/small/test_chr.fasta.rev.1.bt2 +0 -0
  60. data/test/samples/small/test_chr.fasta.rev.2.bt2 +0 -0
  61. data/test/samples/small/test_cov.svg +273 -0
  62. data/test/samples/small/testu.bam.bai +0 -0
  63. data/test/svg +133 -0
  64. data/test/test_pileup.rb +84 -0
  65. data/test/test_sam.rb +331 -0
  66. data/test/test_vcf.rb +11 -0
  67. data/{doc → tutorial}/tutorial.html +0 -0
  68. data/{doc → tutorial}/tutorial.pdf +0 -0
  69. metadata +56 -114
  70. data/doc/Bio/DB/SAM/Tools/Bam1CoreT.html +0 -159
  71. data/doc/Bio/DB/SAM/Tools/Bam1T.html +0 -220
  72. data/doc/Bio/DB/SAM/Tools/BamHeaderT.html +0 -249
  73. data/doc/Bio/DB/SAM/Tools/BamPileup1T.html +0 -159
  74. data/doc/Bio/DB/SAM/Tools/SamfileT.html +0 -171
  75. data/doc/Bio/DB/SAM/Tools/SamfileTX.html +0 -159
  76. data/doc/Bio/DB/SAMException.html +0 -205
  77. data/doc/LibC.html +0 -155
  78. data/doc/Pileup.html +0 -571
  79. data/doc/Vcf.html +0 -473
  80. data/doc/basic_styles.css +0 -31
  81. data/doc/classes/Bio.html +0 -139
  82. data/doc/classes/Bio/DB.html +0 -137
  83. data/doc/classes/Bio/DB/Alignment.html +0 -441
  84. data/doc/classes/Bio/DB/Alignment.src/M000012.html +0 -19
  85. data/doc/classes/Bio/DB/Alignment.src/M000013.html +0 -27
  86. data/doc/classes/Bio/DB/Alignment.src/M000014.html +0 -45
  87. data/doc/classes/Bio/DB/Alignment.src/M000015.html +0 -40
  88. data/doc/classes/Bio/DB/SAM.html +0 -510
  89. data/doc/classes/Bio/DB/SAM/Library.html +0 -135
  90. data/doc/classes/Bio/DB/SAM/Library.src/M000006.html +0 -28
  91. data/doc/classes/Bio/DB/SAM/Tools.html +0 -278
  92. data/doc/classes/Bio/DB/SAM/Tools.src/M000007.html +0 -20
  93. data/doc/classes/Bio/DB/SAM/Tools/Bam1CoreT.html +0 -111
  94. data/doc/classes/Bio/DB/SAM/Tools/Bam1T.html +0 -150
  95. data/doc/classes/Bio/DB/SAM/Tools/Bam1T.src/M000010.html +0 -20
  96. data/doc/classes/Bio/DB/SAM/Tools/BamHeaderT.html +0 -169
  97. data/doc/classes/Bio/DB/SAM/Tools/BamHeaderT.src/M000008.html +0 -19
  98. data/doc/classes/Bio/DB/SAM/Tools/BamHeaderT.src/M000009.html +0 -18
  99. data/doc/classes/Bio/DB/SAM/Tools/BamPileup1T.html +0 -111
  100. data/doc/classes/Bio/DB/SAM/Tools/SamfileT.html +0 -129
  101. data/doc/classes/Bio/DB/SAM/Tools/SamfileTX.html +0 -111
  102. data/doc/classes/Bio/DB/SAMException.html +0 -140
  103. data/doc/classes/Bio/DB/SAMException.src/M000016.html +0 -18
  104. data/doc/classes/Bio/DB/Sam.src/M000017.html +0 -43
  105. data/doc/classes/Bio/DB/Sam.src/M000018.html +0 -42
  106. data/doc/classes/Bio/DB/Sam.src/M000019.html +0 -18
  107. data/doc/classes/Bio/DB/Sam.src/M000020.html +0 -22
  108. data/doc/classes/Bio/DB/Sam.src/M000021.html +0 -19
  109. data/doc/classes/Bio/DB/Sam.src/M000022.html +0 -25
  110. data/doc/classes/Bio/DB/Sam.src/M000023.html +0 -28
  111. data/doc/classes/Bio/DB/Sam.src/M000024.html +0 -28
  112. data/doc/classes/Bio/DB/Sam.src/M000025.html +0 -46
  113. data/doc/classes/Bio/DB/Sam.src/M000026.html +0 -24
  114. data/doc/classes/Bio/DB/Sam.src/M000027.html +0 -19
  115. data/doc/classes/Bio/DB/Sam.src/M000028.html +0 -24
  116. data/doc/classes/Bio/DB/Sam.src/M000029.html +0 -41
  117. data/doc/classes/Bio/DB/Sam.src/M000030.html +0 -31
  118. data/doc/classes/Bio/DB/Sam.src/M000031.html +0 -86
  119. data/doc/classes/Bio/DB/Sam.src/M000032.html +0 -34
  120. data/doc/classes/Bio/DB/Tag.html +0 -160
  121. data/doc/classes/Bio/DB/Tag.src/M000011.html +0 -21
  122. data/doc/classes/LibC.html +0 -105
  123. data/doc/classes/Pileup.html +0 -374
  124. data/doc/classes/Pileup.src/M000001.html +0 -34
  125. data/doc/classes/Pileup.src/M000002.html +0 -21
  126. data/doc/classes/Pileup.src/M000003.html +0 -21
  127. data/doc/classes/Pileup.src/M000004.html +0 -21
  128. data/doc/classes/Pileup.src/M000005.html +0 -31
  129. data/doc/files/lib/bio-samtools_rb.html +0 -109
  130. data/doc/files/lib/bio/db/sam/bam_rb.html +0 -108
  131. data/doc/files/lib/bio/db/sam/faidx_rb.html +0 -108
  132. data/doc/files/lib/bio/db/sam/library_rb.html +0 -101
  133. data/doc/files/lib/bio/db/sam/pileup_rb.html +0 -178
  134. data/doc/files/lib/bio/db/sam/sam_rb.html +0 -113
  135. data/doc/files/lib/bio/db/sam_rb.html +0 -111
  136. data/doc/fr_class_index.html +0 -43
  137. data/doc/fr_file_index.html +0 -33
  138. data/doc/fr_method_index.html +0 -58
  139. data/doc/lib/bio-samtools_rb.html +0 -115
  140. data/doc/lib/bio/db/pileup_rb.html +0 -171
  141. data/doc/lib/bio/db/sam/bam_rb.html +0 -121
  142. data/doc/lib/bio/db/sam/faidx_rb.html +0 -117
  143. data/doc/lib/bio/db/sam/library_rb.html +0 -115
  144. data/doc/lib/bio/db/sam/pileup_rb.html +0 -171
  145. data/doc/lib/bio/db/sam/sam_rb.html +0 -121
  146. data/doc/lib/bio/db/sam/vcf_rb.html +0 -124
  147. data/doc/lib/bio/db/sam_rb.html +0 -115
  148. data/doc/lib/bio/db/vcf_rb.html +0 -124
  149. data/doc/rdoc-style.css +0 -208
  150. data/lib/bio/db/sam/bam.rb +0 -210
  151. data/lib/bio/db/sam/sam.rb +0 -86
  152. data/test/samples/pipe_char/test.bam +0 -0
  153. data/test/samples/pipe_char/test.bam.bai +0 -0
  154. data/test/samples/pipe_char/test.tam +0 -10
  155. data/test/samples/pipe_char/test_chr.fasta +0 -1000
  156. data/test/samples/pipe_char/test_chr.fasta.fai +0 -1
  157. data/test/samples/small/test +0 -0
  158. data/test/samples/small/test.bam +0 -0
  159. data/test/samples/small/test.fa +0 -20
  160. data/test/samples/small/test.fai +0 -0
@@ -2,141 +2,83 @@
2
2
 
3
3
  <html>
4
4
  <head>
5
- <meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
5
+ <meta charset="UTF-8">
6
6
 
7
7
  <title>class Bio::DB - Pileup</title>
8
8
 
9
- <link type="text/css" media="screen" href="../rdoc.css" rel="stylesheet">
9
+ <link href="../fonts.css" rel="stylesheet">
10
+ <link href="../rdoc.css" rel="stylesheet">
10
11
 
11
12
  <script type="text/javascript">
12
13
  var rdoc_rel_prefix = "../";
13
14
  </script>
14
15
 
15
- <script type="text/javascript" charset="utf-8" src="../js/jquery.js"></script>
16
- <script type="text/javascript" charset="utf-8" src="../js/navigation.js"></script>
17
- <script type="text/javascript" charset="utf-8" src="../js/search_index.js"></script>
18
- <script type="text/javascript" charset="utf-8" src="../js/search.js"></script>
19
- <script type="text/javascript" charset="utf-8" src="../js/searcher.js"></script>
20
- <script type="text/javascript" charset="utf-8" src="../js/darkfish.js"></script>
16
+ <script src="../js/jquery.js"></script>
17
+ <script src="../js/navigation.js"></script>
18
+ <script src="../js/search_index.js"></script>
19
+ <script src="../js/search.js"></script>
20
+ <script src="../js/searcher.js"></script>
21
+ <script src="../js/darkfish.js"></script>
21
22
 
22
23
 
23
- <body id="top" class="class">
24
- <nav id="metadata">
25
- <nav id="home-section" class="section">
26
- <h3 class="section-header">
27
- <a href="../index.html">Home</a>
24
+ <body id="top" role="document" class="class">
25
+ <nav role="navigation">
26
+ <div id="project-navigation">
27
+ <div id="home-section" role="region" title="Quick navigation" class="nav-section">
28
+ <h2>
29
+ <a href="../index.html" rel="home">Home</a>
30
+ </h2>
31
+
32
+ <div id="table-of-contents-navigation">
33
+ <a href="../table_of_contents.html#pages">Pages</a>
28
34
  <a href="../table_of_contents.html#classes">Classes</a>
29
35
  <a href="../table_of_contents.html#methods">Methods</a>
30
- </h3>
31
- </nav>
32
-
36
+ </div>
37
+ </div>
33
38
 
34
- <nav id="search-section" class="section project-section" class="initially-hidden">
39
+ <div id="search-section" role="search" class="project-section initially-hidden">
35
40
  <form action="#" method="get" accept-charset="utf-8">
36
- <h3 class="section-header">
37
- <input type="text" name="search" placeholder="Search" id="search-field"
41
+ <div id="search-field-wrapper">
42
+ <input id="search-field" role="combobox" aria-label="Search"
43
+ aria-autocomplete="list" aria-controls="search-results"
44
+ type="text" name="search" placeholder="Search" spellcheck="false"
38
45
  title="Type to search, Up and Down to navigate, Enter to load">
39
- </h3>
40
- </form>
41
-
42
- <ul id="search-results" class="initially-hidden"></ul>
43
- </nav>
44
-
46
+ </div>
45
47
 
46
- <div id="file-metadata">
47
- <nav id="file-list-section" class="section">
48
- <h3 class="section-header">Defined In</h3>
49
- <ul>
50
- <li>lib/bio/db/pileup.rb
51
- <li>lib/bio/db/sam/bam.rb
52
- <li>lib/bio/db/sam/faidx.rb
53
- <li>lib/bio/db/sam/library.rb
54
- <li>lib/bio/db/sam/sam.rb
55
- <li>lib/bio/db/sam.rb
56
- <li>lib/bio/db/vcf.rb
57
- </ul>
58
- </nav>
48
+ <ul id="search-results" aria-label="Search Results"
49
+ aria-busy="false" aria-expanded="false"
50
+ aria-atomic="false" class="initially-hidden"></ul>
51
+ </form>
52
+ </div>
59
53
 
60
-
61
54
  </div>
62
55
 
56
+
57
+
63
58
  <div id="class-metadata">
64
59
 
65
- <nav id="parent-class-section" class="section">
66
- <h3 class="section-header">Parent</h3>
60
+ <div id="parent-class-section" class="nav-section">
61
+ <h3>Parent</h3>
62
+
67
63
 
68
64
  <p class="link">Object
69
65
 
70
- </nav>
66
+ </div>
71
67
 
72
68
 
73
69
 
74
- </div>
75
-
76
- <div id="project-metadata">
77
- <nav id="fileindex-section" class="section project-section">
78
- <h3 class="section-header">Pages</h3>
79
-
80
- <ul>
81
-
82
- <li class="file"><a href="../LICENSE_txt.html">LICENSE</a>
83
-
84
- </ul>
85
- </nav>
86
-
87
- <nav id="classindex-section" class="section project-section">
88
- <h3 class="section-header">Class and Module Index</h3>
89
-
90
- <ul class="link-list">
91
-
92
- <li><a href="../Bio.html">Bio</a>
93
-
94
- <li><a href="../Bio/DB.html">Bio::DB</a>
95
-
96
- <li><a href="../Bio/DB/Alignment.html">Bio::DB::Alignment</a>
97
-
98
- <li><a href="../Bio/DB/Pileup.html">Bio::DB::Pileup</a>
99
-
100
- <li><a href="../Bio/DB/SAM.html">Bio::DB::SAM</a>
101
-
102
- <li><a href="../Bio/DB/SAM/Library.html">Bio::DB::SAM::Library</a>
103
-
104
- <li><a href="../Bio/DB/SAM/Tools.html">Bio::DB::SAM::Tools</a>
105
-
106
- <li><a href="../Bio/DB/SAM/Tools/Bam1CoreT.html">Bio::DB::SAM::Tools::Bam1CoreT</a>
107
-
108
- <li><a href="../Bio/DB/SAM/Tools/Bam1T.html">Bio::DB::SAM::Tools::Bam1T</a>
109
-
110
- <li><a href="../Bio/DB/SAM/Tools/BamHeaderT.html">Bio::DB::SAM::Tools::BamHeaderT</a>
111
-
112
- <li><a href="../Bio/DB/SAM/Tools/BamPileup1T.html">Bio::DB::SAM::Tools::BamPileup1T</a>
113
-
114
- <li><a href="../Bio/DB/SAM/Tools/SamfileT.html">Bio::DB::SAM::Tools::SamfileT</a>
115
-
116
- <li><a href="../Bio/DB/SAM/Tools/SamfileTX.html">Bio::DB::SAM::Tools::SamfileTX</a>
117
-
118
- <li><a href="../Bio/DB/SAMException.html">Bio::DB::SAMException</a>
119
-
120
- <li><a href="../Bio/DB/Sam.html">Bio::DB::Sam</a>
121
-
122
- <li><a href="../Bio/DB/Tag.html">Bio::DB::Tag</a>
123
-
124
- <li><a href="../Bio/DB/Vcf.html">Bio::DB::Vcf</a>
125
-
126
- <li><a href="../LibC.html">LibC</a>
127
-
128
- </ul>
129
- </nav>
130
-
70
+
131
71
  </div>
132
72
  </nav>
133
73
 
134
- <div id="documentation">
135
- <h1 class="class">class Bio::DB</h1>
74
+ <main role="main" aria-labelledby="class-Bio::DB">
75
+ <h1 id="class-Bio::DB" class="class">
76
+ class Bio::DB
77
+ </h1>
136
78
 
137
- <div id="description" class="description">
79
+ <section class="description">
138
80
 
139
- </div><!-- description -->
81
+ </section>
140
82
 
141
83
 
142
84
 
@@ -150,16 +92,14 @@
150
92
 
151
93
 
152
94
 
153
- <!-- Methods -->
154
95
 
155
- </section><!-- 5Buntitled-5D -->
156
-
157
- </div><!-- documentation -->
96
+ </section>
97
+ </main>
158
98
 
159
99
 
160
- <footer id="validator-badges">
161
- <p><a href="http://validator.w3.org/check/referer">[Validate]</a>
162
- <p>Generated by <a href="https://github.com/rdoc/rdoc">RDoc</a> 3.12.
163
- <p>Generated with the <a href="http://deveiate.org/projects/Darkfish-Rdoc/">Darkfish Rdoc Generator</a> 3.
100
+ <footer id="validator-badges" role="contentinfo">
101
+ <p><a href="http://validator.w3.org/check/referer">Validate</a>
102
+ <p>Generated by <a href="http://rdoc.rubyforge.org">RDoc</a> 4.1.1.
103
+ <p>Based on <a href="http://deveiate.org/projects/Darkfish-Rdoc/">Darkfish</a> by <a href="http://deveiate.org">Michael Granger</a>.
164
104
  </footer>
165
105
 
@@ -2,151 +2,100 @@
2
2
 
3
3
  <html>
4
4
  <head>
5
- <meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
5
+ <meta charset="UTF-8">
6
6
 
7
7
  <title>class Bio::DB::Alignment - Pileup</title>
8
8
 
9
- <link type="text/css" media="screen" href="../../rdoc.css" rel="stylesheet">
9
+ <link href="../../fonts.css" rel="stylesheet">
10
+ <link href="../../rdoc.css" rel="stylesheet">
10
11
 
11
12
  <script type="text/javascript">
12
13
  var rdoc_rel_prefix = "../../";
13
14
  </script>
14
15
 
15
- <script type="text/javascript" charset="utf-8" src="../../js/jquery.js"></script>
16
- <script type="text/javascript" charset="utf-8" src="../../js/navigation.js"></script>
17
- <script type="text/javascript" charset="utf-8" src="../../js/search_index.js"></script>
18
- <script type="text/javascript" charset="utf-8" src="../../js/search.js"></script>
19
- <script type="text/javascript" charset="utf-8" src="../../js/searcher.js"></script>
20
- <script type="text/javascript" charset="utf-8" src="../../js/darkfish.js"></script>
16
+ <script src="../../js/jquery.js"></script>
17
+ <script src="../../js/navigation.js"></script>
18
+ <script src="../../js/search_index.js"></script>
19
+ <script src="../../js/search.js"></script>
20
+ <script src="../../js/searcher.js"></script>
21
+ <script src="../../js/darkfish.js"></script>
21
22
 
22
23
 
23
- <body id="top" class="class">
24
- <nav id="metadata">
25
- <nav id="home-section" class="section">
26
- <h3 class="section-header">
27
- <a href="../../index.html">Home</a>
24
+ <body id="top" role="document" class="class">
25
+ <nav role="navigation">
26
+ <div id="project-navigation">
27
+ <div id="home-section" role="region" title="Quick navigation" class="nav-section">
28
+ <h2>
29
+ <a href="../../index.html" rel="home">Home</a>
30
+ </h2>
31
+
32
+ <div id="table-of-contents-navigation">
33
+ <a href="../../table_of_contents.html#pages">Pages</a>
28
34
  <a href="../../table_of_contents.html#classes">Classes</a>
29
35
  <a href="../../table_of_contents.html#methods">Methods</a>
30
- </h3>
31
- </nav>
32
-
36
+ </div>
37
+ </div>
33
38
 
34
- <nav id="search-section" class="section project-section" class="initially-hidden">
39
+ <div id="search-section" role="search" class="project-section initially-hidden">
35
40
  <form action="#" method="get" accept-charset="utf-8">
36
- <h3 class="section-header">
37
- <input type="text" name="search" placeholder="Search" id="search-field"
41
+ <div id="search-field-wrapper">
42
+ <input id="search-field" role="combobox" aria-label="Search"
43
+ aria-autocomplete="list" aria-controls="search-results"
44
+ type="text" name="search" placeholder="Search" spellcheck="false"
38
45
  title="Type to search, Up and Down to navigate, Enter to load">
39
- </h3>
40
- </form>
41
-
42
- <ul id="search-results" class="initially-hidden"></ul>
43
- </nav>
46
+ </div>
44
47
 
48
+ <ul id="search-results" aria-label="Search Results"
49
+ aria-busy="false" aria-expanded="false"
50
+ aria-atomic="false" class="initially-hidden"></ul>
51
+ </form>
52
+ </div>
45
53
 
46
- <div id="file-metadata">
47
- <nav id="file-list-section" class="section">
48
- <h3 class="section-header">Defined In</h3>
49
- <ul>
50
- <li>lib/bio/db/sam.rb
51
- </ul>
52
- </nav>
53
-
54
-
55
54
  </div>
56
55
 
56
+
57
+
57
58
  <div id="class-metadata">
58
59
 
59
- <nav id="parent-class-section" class="section">
60
- <h3 class="section-header">Parent</h3>
60
+ <div id="parent-class-section" class="nav-section">
61
+ <h3>Parent</h3>
62
+
61
63
 
62
64
  <p class="link">Object
63
65
 
64
- </nav>
66
+ </div>
65
67
 
66
68
 
69
+
67
70
  <!-- Method Quickref -->
68
- <nav id="method-list-section" class="section">
69
- <h3 class="section-header">Methods</h3>
71
+ <div id="method-list-section" class="nav-section">
72
+ <h3>Methods</h3>
70
73
 
71
- <ul class="link-list">
72
-
73
- <li><a href="#method-c-finalize">::finalize</a>
74
+ <ul class="link-list" role="directory">
74
75
 
75
- <li><a href="#method-c-new">::new</a>
76
+ <li ><a href="#method-c-new">::new</a>
76
77
 
77
- <li><a href="#method-i-sam-3D">#sam=</a>
78
-
79
- <li><a href="#method-i-set">#set</a>
80
-
81
- </ul>
82
- </nav>
83
-
84
- </div>
85
-
86
- <div id="project-metadata">
87
- <nav id="fileindex-section" class="section project-section">
88
- <h3 class="section-header">Pages</h3>
89
-
90
- <ul>
91
-
92
- <li class="file"><a href="../../LICENSE_txt.html">LICENSE</a>
93
-
94
78
  </ul>
95
- </nav>
96
-
97
- <nav id="classindex-section" class="section project-section">
98
- <h3 class="section-header">Class and Module Index</h3>
99
-
100
- <ul class="link-list">
101
-
102
- <li><a href="../../Bio.html">Bio</a>
103
-
104
- <li><a href="../../Bio/DB.html">Bio::DB</a>
105
-
106
- <li><a href="../../Bio/DB/Alignment.html">Bio::DB::Alignment</a>
107
-
108
- <li><a href="../../Bio/DB/Pileup.html">Bio::DB::Pileup</a>
109
-
110
- <li><a href="../../Bio/DB/SAM.html">Bio::DB::SAM</a>
111
-
112
- <li><a href="../../Bio/DB/SAM/Library.html">Bio::DB::SAM::Library</a>
113
-
114
- <li><a href="../../Bio/DB/SAM/Tools.html">Bio::DB::SAM::Tools</a>
115
-
116
- <li><a href="../../Bio/DB/SAM/Tools/Bam1CoreT.html">Bio::DB::SAM::Tools::Bam1CoreT</a>
117
-
118
- <li><a href="../../Bio/DB/SAM/Tools/Bam1T.html">Bio::DB::SAM::Tools::Bam1T</a>
119
-
120
- <li><a href="../../Bio/DB/SAM/Tools/BamHeaderT.html">Bio::DB::SAM::Tools::BamHeaderT</a>
121
-
122
- <li><a href="../../Bio/DB/SAM/Tools/BamPileup1T.html">Bio::DB::SAM::Tools::BamPileup1T</a>
123
-
124
- <li><a href="../../Bio/DB/SAM/Tools/SamfileT.html">Bio::DB::SAM::Tools::SamfileT</a>
125
-
126
- <li><a href="../../Bio/DB/SAM/Tools/SamfileTX.html">Bio::DB::SAM::Tools::SamfileTX</a>
127
-
128
- <li><a href="../../Bio/DB/SAMException.html">Bio::DB::SAMException</a>
129
-
130
- <li><a href="../../Bio/DB/Sam.html">Bio::DB::Sam</a>
131
-
132
- <li><a href="../../Bio/DB/Tag.html">Bio::DB::Tag</a>
133
-
134
- <li><a href="../../Bio/DB/Vcf.html">Bio::DB::Vcf</a>
135
-
136
- <li><a href="../../LibC.html">LibC</a>
137
-
138
- </ul>
139
- </nav>
79
+ </div>
140
80
 
141
81
  </div>
142
82
  </nav>
143
83
 
144
- <div id="documentation">
145
- <h1 class="class">class Bio::DB::Alignment</h1>
84
+ <main role="main" aria-labelledby="class-Bio::DB::Alignment">
85
+ <h1 id="class-Bio::DB::Alignment" class="class">
86
+ class Bio::DB::Alignment
87
+ </h1>
146
88
 
147
- <div id="description" class="description">
89
+ <section class="description">
148
90
 
149
- </div><!-- description -->
91
+ <p>Attrobites frp, the flag field (see chapter 2.2.2 of the sam file
92
+ documentation) <a
93
+ href="Alignment.html#attribute-i-query_strand">#query_strand</a> and <a
94
+ href="Alignment.html#attribute-i-mate_strand">#mate_strand</a> are true if
95
+ they are forward. It is the opposite to the definition in the BAM format
96
+ for clarity. primary is the negation of is_negative from the BAM format</p>
97
+
98
+ </section>
150
99
 
151
100
 
152
101
 
@@ -159,9 +108,10 @@
159
108
 
160
109
 
161
110
 
162
- <!-- Attributes -->
163
- <section id="attribute-method-details" class="method-section section">
164
- <h3 class="section-header">Attributes</h3>
111
+ <section class="attribute-method-details" class="method-section">
112
+ <header>
113
+ <h3>Attributes</h3>
114
+ </header>
165
115
 
166
116
 
167
117
  <div id="attribute-i-al" class="method-detail">
@@ -172,7 +122,7 @@
172
122
 
173
123
  <div class="method-description">
174
124
 
175
- <p>Attributes from the format</p>
125
+
176
126
 
177
127
  </div>
178
128
  </div>
@@ -185,7 +135,7 @@
185
135
 
186
136
  <div class="method-description">
187
137
 
188
- <p>Attributes pulled with the C library</p>
138
+
189
139
 
190
140
  </div>
191
141
  </div>
@@ -198,7 +148,7 @@
198
148
 
199
149
  <div class="method-description">
200
150
 
201
- <p>Attributes from the format</p>
151
+
202
152
 
203
153
  </div>
204
154
  </div>
@@ -211,12 +161,7 @@
211
161
 
212
162
  <div class="method-description">
213
163
 
214
- <p>Attrobites frp, the flag field (see chapter 2.2.2 of the sam file
215
- documentation) <a
216
- href="Alignment.html#attribute-i-query_strand">#query_strand</a> and <a
217
- href="Alignment.html#attribute-i-mate_strand">#mate_strand</a> are true if
218
- they are forward. It is the opposite to the definition in the BAM format
219
- for clarity. primary is the negation of is_negative from the BAM format</p>
164
+
220
165
 
221
166
  </div>
222
167
  </div>
@@ -229,12 +174,7 @@ for clarity. primary is the negation of is_negative from the BAM format</p>
229
174
 
230
175
  <div class="method-description">
231
176
 
232
- <p>Attrobites frp, the flag field (see chapter 2.2.2 of the sam file
233
- documentation) <a
234
- href="Alignment.html#attribute-i-query_strand">#query_strand</a> and <a
235
- href="Alignment.html#attribute-i-mate_strand">#mate_strand</a> are true if
236
- they are forward. It is the opposite to the definition in the BAM format
237
- for clarity. primary is the negation of is_negative from the BAM format</p>
177
+
238
178
 
239
179
  </div>
240
180
  </div>
@@ -247,7 +187,7 @@ for clarity. primary is the negation of is_negative from the BAM format</p>
247
187
 
248
188
  <div class="method-description">
249
189
 
250
- <p>Attributes from the format</p>
190
+
251
191
 
252
192
  </div>
253
193
  </div>
@@ -260,12 +200,7 @@ for clarity. primary is the negation of is_negative from the BAM format</p>
260
200
 
261
201
  <div class="method-description">
262
202
 
263
- <p>Attrobites frp, the flag field (see chapter 2.2.2 of the sam file
264
- documentation) <a
265
- href="Alignment.html#attribute-i-query_strand">#query_strand</a> and <a
266
- href="Alignment.html#attribute-i-mate_strand">#mate_strand</a> are true if
267
- they are forward. It is the opposite to the definition in the BAM format
268
- for clarity. primary is the negation of is_negative from the BAM format</p>
203
+
269
204
 
270
205
  </div>
271
206
  </div>
@@ -278,12 +213,7 @@ for clarity. primary is the negation of is_negative from the BAM format</p>
278
213
 
279
214
  <div class="method-description">
280
215
 
281
- <p>Attrobites frp, the flag field (see chapter 2.2.2 of the sam file
282
- documentation) <a
283
- href="Alignment.html#attribute-i-query_strand">#query_strand</a> and <a
284
- href="Alignment.html#attribute-i-mate_strand">#mate_strand</a> are true if
285
- they are forward. It is the opposite to the definition in the BAM format
286
- for clarity. primary is the negation of is_negative from the BAM format</p>
216
+
287
217
 
288
218
  </div>
289
219
  </div>
@@ -296,12 +226,7 @@ for clarity. primary is the negation of is_negative from the BAM format</p>
296
226
 
297
227
  <div class="method-description">
298
228
 
299
- <p>Attrobites frp, the flag field (see chapter 2.2.2 of the sam file
300
- documentation) <a
301
- href="Alignment.html#attribute-i-query_strand">#query_strand</a> and <a
302
- href="Alignment.html#attribute-i-mate_strand">#mate_strand</a> are true if
303
- they are forward. It is the opposite to the definition in the BAM format
304
- for clarity. primary is the negation of is_negative from the BAM format</p>
229
+
305
230
 
306
231
  </div>
307
232
  </div>
@@ -314,7 +239,7 @@ for clarity. primary is the negation of is_negative from the BAM format</p>
314
239
 
315
240
  <div class="method-description">
316
241
 
317
- <p>Attributes from the format</p>
242
+
318
243
 
319
244
  </div>
320
245
  </div>
@@ -327,7 +252,7 @@ for clarity. primary is the negation of is_negative from the BAM format</p>
327
252
 
328
253
  <div class="method-description">
329
254
 
330
- <p>Attributes from the format</p>
255
+
331
256
 
332
257
  </div>
333
258
  </div>
@@ -340,12 +265,7 @@ for clarity. primary is the negation of is_negative from the BAM format</p>
340
265
 
341
266
  <div class="method-description">
342
267
 
343
- <p>Attrobites frp, the flag field (see chapter 2.2.2 of the sam file
344
- documentation) <a
345
- href="Alignment.html#attribute-i-query_strand">#query_strand</a> and <a
346
- href="Alignment.html#attribute-i-mate_strand">#mate_strand</a> are true if
347
- they are forward. It is the opposite to the definition in the BAM format
348
- for clarity. primary is the negation of is_negative from the BAM format</p>
268
+
349
269
 
350
270
  </div>
351
271
  </div>
@@ -358,12 +278,7 @@ for clarity. primary is the negation of is_negative from the BAM format</p>
358
278
 
359
279
  <div class="method-description">
360
280
 
361
- <p>Attrobites frp, the flag field (see chapter 2.2.2 of the sam file
362
- documentation) <a
363
- href="Alignment.html#attribute-i-query_strand">#query_strand</a> and <a
364
- href="Alignment.html#attribute-i-mate_strand">#mate_strand</a> are true if
365
- they are forward. It is the opposite to the definition in the BAM format
366
- for clarity. primary is the negation of is_negative from the BAM format</p>
281
+
367
282
 
368
283
  </div>
369
284
  </div>
@@ -376,7 +291,7 @@ for clarity. primary is the negation of is_negative from the BAM format</p>
376
291
 
377
292
  <div class="method-description">
378
293
 
379
- <p>Attributes from the format</p>
294
+
380
295
 
381
296
  </div>
382
297
  </div>
@@ -389,7 +304,7 @@ for clarity. primary is the negation of is_negative from the BAM format</p>
389
304
 
390
305
  <div class="method-description">
391
306
 
392
- <p>Attributes from the format</p>
307
+
393
308
 
394
309
  </div>
395
310
  </div>
@@ -402,7 +317,7 @@ for clarity. primary is the negation of is_negative from the BAM format</p>
402
317
 
403
318
  <div class="method-description">
404
319
 
405
- <p>Attributes from the format</p>
320
+
406
321
 
407
322
  </div>
408
323
  </div>
@@ -415,12 +330,7 @@ for clarity. primary is the negation of is_negative from the BAM format</p>
415
330
 
416
331
  <div class="method-description">
417
332
 
418
- <p>Attrobites frp, the flag field (see chapter 2.2.2 of the sam file
419
- documentation) <a
420
- href="Alignment.html#attribute-i-query_strand">#query_strand</a> and <a
421
- href="Alignment.html#attribute-i-mate_strand">#mate_strand</a> are true if
422
- they are forward. It is the opposite to the definition in the BAM format
423
- for clarity. primary is the negation of is_negative from the BAM format</p>
333
+
424
334
 
425
335
  </div>
426
336
  </div>
@@ -433,7 +343,7 @@ for clarity. primary is the negation of is_negative from the BAM format</p>
433
343
 
434
344
  <div class="method-description">
435
345
 
436
- <p>Attributes pulled with the C library</p>
346
+
437
347
 
438
348
  </div>
439
349
  </div>
@@ -446,7 +356,7 @@ for clarity. primary is the negation of is_negative from the BAM format</p>
446
356
 
447
357
  <div class="method-description">
448
358
 
449
- <p>Attributes from the format</p>
359
+
450
360
 
451
361
  </div>
452
362
  </div>
@@ -459,7 +369,7 @@ for clarity. primary is the negation of is_negative from the BAM format</p>
459
369
 
460
370
  <div class="method-description">
461
371
 
462
- <p>Attributes from the format</p>
372
+
463
373
 
464
374
  </div>
465
375
  </div>
@@ -472,12 +382,7 @@ for clarity. primary is the negation of is_negative from the BAM format</p>
472
382
 
473
383
  <div class="method-description">
474
384
 
475
- <p>Attrobites frp, the flag field (see chapter 2.2.2 of the sam file
476
- documentation) <a
477
- href="Alignment.html#attribute-i-query_strand">#query_strand</a> and <a
478
- href="Alignment.html#attribute-i-mate_strand">#mate_strand</a> are true if
479
- they are forward. It is the opposite to the definition in the BAM format
480
- for clarity. primary is the negation of is_negative from the BAM format</p>
385
+
481
386
 
482
387
  </div>
483
388
  </div>
@@ -490,12 +395,7 @@ for clarity. primary is the negation of is_negative from the BAM format</p>
490
395
 
491
396
  <div class="method-description">
492
397
 
493
- <p>Attrobites frp, the flag field (see chapter 2.2.2 of the sam file
494
- documentation) <a
495
- href="Alignment.html#attribute-i-query_strand">#query_strand</a> and <a
496
- href="Alignment.html#attribute-i-mate_strand">#mate_strand</a> are true if
497
- they are forward. It is the opposite to the definition in the BAM format
498
- for clarity. primary is the negation of is_negative from the BAM format</p>
398
+
499
399
 
500
400
  </div>
501
401
  </div>
@@ -508,7 +408,7 @@ for clarity. primary is the negation of is_negative from the BAM format</p>
508
408
 
509
409
  <div class="method-description">
510
410
 
511
- <p>Attributes from the format</p>
411
+
512
412
 
513
413
  </div>
514
414
  </div>
@@ -521,7 +421,7 @@ for clarity. primary is the negation of is_negative from the BAM format</p>
521
421
 
522
422
  <div class="method-description">
523
423
 
524
- <p>Attributes from the format</p>
424
+
525
425
 
526
426
  </div>
527
427
  </div>
@@ -534,12 +434,7 @@ for clarity. primary is the negation of is_negative from the BAM format</p>
534
434
 
535
435
  <div class="method-description">
536
436
 
537
- <p>Attrobites frp, the flag field (see chapter 2.2.2 of the sam file
538
- documentation) <a
539
- href="Alignment.html#attribute-i-query_strand">#query_strand</a> and <a
540
- href="Alignment.html#attribute-i-mate_strand">#mate_strand</a> are true if
541
- they are forward. It is the opposite to the definition in the BAM format
542
- for clarity. primary is the negation of is_negative from the BAM format</p>
437
+
543
438
 
544
439
  </div>
545
440
  </div>
@@ -552,7 +447,7 @@ for clarity. primary is the negation of is_negative from the BAM format</p>
552
447
 
553
448
  <div class="method-description">
554
449
 
555
- <p>Attributes from the format</p>
450
+
556
451
 
557
452
  </div>
558
453
  </div>
@@ -565,216 +460,93 @@ for clarity. primary is the negation of is_negative from the BAM format</p>
565
460
 
566
461
  <div class="method-description">
567
462
 
568
- <p>Attributes from the format</p>
463
+
569
464
 
570
465
  </div>
571
466
  </div>
572
467
 
573
- </section><!-- attribute-method-details -->
468
+ </section>
574
469
 
575
470
 
576
- <!-- Methods -->
577
471
 
578
- <section id="public-class-5Buntitled-5D-method-details" class="method-section section">
579
- <h3 class="section-header">Public Class Methods</h3>
580
-
581
-
582
- <div id="method-c-finalize" class="method-detail ">
583
-
584
- <div class="method-heading">
585
- <span class="method-name">finalize</span><span
586
- class="method-args">(object_id)</span>
587
- <span class="method-click-advice">click to toggle source</span>
588
- </div>
589
-
590
-
591
- <div class="method-description">
592
-
593
-
594
-
595
-
596
-
597
- <div class="method-source-code" id="finalize-source">
598
- <pre><span class="ruby-comment"># File lib/bio/db/sam.rb, line 560</span>
599
- <span class="ruby-keyword">def</span> <span class="ruby-constant">Alignment</span>.<span class="ruby-identifier">finalize</span>(<span class="ruby-identifier">object_id</span>)
600
-
601
- <span class="ruby-comment"># puts &quot;Object #{object_id} dying at #{Time.new}&quot;</span>
602
- <span class="ruby-comment"># p &quot;?&quot; . object_id.al</span>
603
- <span class="ruby-comment"># p object_id.al</span>
604
- <span class="ruby-constant">LibC</span>.<span class="ruby-identifier">free</span> <span class="ruby-identifier">object_id</span>.<span class="ruby-identifier">al</span>
605
- <span class="ruby-constant">LibC</span>.<span class="ruby-identifier">free</span> <span class="ruby-identifier">object_id</span>.<span class="ruby-identifier">sam</span>
606
- <span class="ruby-constant">LibC</span>.<span class="ruby-identifier">free</span> <span class="ruby-identifier">object_id</span>.<span class="ruby-identifier">calend</span>
607
- <span class="ruby-constant">LibC</span>.<span class="ruby-identifier">free</span> <span class="ruby-identifier">object_id</span>.<span class="ruby-identifier">qlen</span>
608
-
609
- <span class="ruby-constant">LibC</span>.<span class="ruby-identifier">free</span> <span class="ruby-identifier">object_id</span>.<span class="ruby-identifier">samstr</span>
610
- <span class="ruby-keyword">end</span></pre>
611
- </div><!-- finalize-source -->
612
-
613
- </div>
614
-
615
-
616
-
617
-
618
- </div><!-- finalize-method -->
472
+ <section id="public-class-5Buntitled-5D-method-details" class="method-section">
473
+ <header>
474
+ <h3>Public Class Methods</h3>
475
+ </header>
619
476
 
620
477
 
621
478
  <div id="method-c-new" class="method-detail ">
622
479
 
623
480
  <div class="method-heading">
624
481
  <span class="method-name">new</span><span
625
- class="method-args">()</span>
626
- <span class="method-click-advice">click to toggle source</span>
627
- </div>
628
-
629
-
630
- <div class="method-description">
631
-
482
+ class="method-args">(sam_string)</span>
632
483
 
633
-
634
-
635
-
636
- <div class="method-source-code" id="new-source">
637
- <pre><span class="ruby-comment"># File lib/bio/db/sam.rb, line 556</span>
638
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">initialize</span>
639
- <span class="ruby-constant">ObjectSpace</span>.<span class="ruby-identifier">define_finalizer</span>(<span class="ruby-keyword">self</span>,
640
- <span class="ruby-keyword">self</span>.<span class="ruby-identifier">class</span>.<span class="ruby-identifier">method</span>(<span class="ruby-value">:finalize</span>).<span class="ruby-identifier">to_proc</span>)
641
- <span class="ruby-keyword">end</span></pre>
642
- </div><!-- new-source -->
643
-
644
- </div>
645
-
646
-
647
-
648
-
649
- </div><!-- new-method -->
650
-
651
-
652
- </section><!-- public-class-method-details -->
653
-
654
- <section id="public-instance-5Buntitled-5D-method-details" class="method-section section">
655
- <h3 class="section-header">Public Instance Methods</h3>
656
-
657
-
658
- <div id="method-i-sam-3D" class="method-detail ">
659
-
660
- <div class="method-heading">
661
- <span class="method-name">sam=</span><span
662
- class="method-args">(sam)</span>
663
484
  <span class="method-click-advice">click to toggle source</span>
485
+
664
486
  </div>
665
487
 
666
488
 
667
489
  <div class="method-description">
668
490
 
491
+ <p>parses the SAM string into its constituents and set its attributes</p>
669
492
 
670
493
 
671
494
 
672
495
 
673
- <div class="method-source-code" id="sam-3D-source">
674
- <pre><span class="ruby-comment"># File lib/bio/db/sam.rb, line 614</span>
675
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">sam=</span>(<span class="ruby-identifier">sam</span>)
676
- <span class="ruby-comment">#p sam</span>
677
- <span class="ruby-identifier">s</span> = <span class="ruby-identifier">sam</span>.<span class="ruby-identifier">split</span>(<span class="ruby-string">&quot;\t&quot;</span>)
678
- <span class="ruby-keyword">self</span>.<span class="ruby-identifier">qname</span> = <span class="ruby-identifier">s</span>[<span class="ruby-value">0</span>]
679
- <span class="ruby-keyword">self</span>.<span class="ruby-identifier">flag</span> = <span class="ruby-identifier">s</span>[<span class="ruby-value">1</span>].<span class="ruby-identifier">to_i</span>
680
- <span class="ruby-keyword">self</span>.<span class="ruby-identifier">rname</span> = <span class="ruby-identifier">s</span>[<span class="ruby-value">2</span>]
681
- <span class="ruby-keyword">self</span>.<span class="ruby-identifier">pos</span> = <span class="ruby-identifier">s</span>[<span class="ruby-value">3</span>].<span class="ruby-identifier">to_i</span>
682
- <span class="ruby-keyword">self</span>.<span class="ruby-identifier">mapq</span> = <span class="ruby-identifier">s</span>[<span class="ruby-value">4</span>].<span class="ruby-identifier">to_i</span>
683
- <span class="ruby-keyword">self</span>.<span class="ruby-identifier">cigar</span> = <span class="ruby-identifier">s</span>[<span class="ruby-value">5</span>]
684
- <span class="ruby-keyword">self</span>.<span class="ruby-identifier">mrnm</span> = <span class="ruby-identifier">s</span>[<span class="ruby-value">6</span>]
685
- <span class="ruby-keyword">self</span>.<span class="ruby-identifier">mpos</span> = <span class="ruby-identifier">s</span>[<span class="ruby-value">7</span>].<span class="ruby-identifier">to_i</span>
686
- <span class="ruby-keyword">self</span>.<span class="ruby-identifier">isize</span> = <span class="ruby-identifier">s</span>[<span class="ruby-value">8</span>].<span class="ruby-identifier">to_i</span>
687
- <span class="ruby-keyword">self</span>.<span class="ruby-identifier">seq</span> = <span class="ruby-identifier">s</span>[<span class="ruby-value">9</span>]
688
- <span class="ruby-keyword">self</span>.<span class="ruby-identifier">qual</span> = <span class="ruby-identifier">s</span>[<span class="ruby-value">10</span>]
689
- <span class="ruby-keyword">self</span>.<span class="ruby-identifier">tags</span> = {}
496
+ <div class="method-source-code" id="new-source">
497
+ <pre><span class="ruby-comment"># File lib/bio/db/alignment.rb, line 24</span>
498
+ <span class="ruby-keyword">def</span> <span class="ruby-identifier">initialize</span>(<span class="ruby-identifier">sam_string</span>)
499
+ <span class="ruby-identifier">s</span> = <span class="ruby-identifier">sam_string</span>.<span class="ruby-identifier">chomp</span>.<span class="ruby-identifier">split</span>(<span class="ruby-string">&quot;\t&quot;</span>)
500
+ <span class="ruby-ivar">@qname</span> = <span class="ruby-identifier">s</span>[<span class="ruby-value">0</span>]
501
+ <span class="ruby-ivar">@flag</span> = <span class="ruby-identifier">s</span>[<span class="ruby-value">1</span>].<span class="ruby-identifier">to_i</span>
502
+ <span class="ruby-ivar">@rname</span> = <span class="ruby-identifier">s</span>[<span class="ruby-value">2</span>]
503
+ <span class="ruby-ivar">@pos</span> = <span class="ruby-identifier">s</span>[<span class="ruby-value">3</span>].<span class="ruby-identifier">to_i</span>
504
+ <span class="ruby-ivar">@mapq</span> = <span class="ruby-identifier">s</span>[<span class="ruby-value">4</span>].<span class="ruby-identifier">to_i</span>
505
+ <span class="ruby-ivar">@cigar</span> = <span class="ruby-identifier">s</span>[<span class="ruby-value">5</span>]
506
+ <span class="ruby-ivar">@mrnm</span> = <span class="ruby-identifier">s</span>[<span class="ruby-value">6</span>]
507
+ <span class="ruby-ivar">@mpos</span> = <span class="ruby-identifier">s</span>[<span class="ruby-value">7</span>].<span class="ruby-identifier">to_i</span>
508
+ <span class="ruby-ivar">@isize</span> = <span class="ruby-identifier">s</span>[<span class="ruby-value">8</span>].<span class="ruby-identifier">to_i</span>
509
+ <span class="ruby-ivar">@seq</span> = <span class="ruby-identifier">s</span>[<span class="ruby-value">9</span>]
510
+ <span class="ruby-ivar">@qual</span> = <span class="ruby-identifier">s</span>[<span class="ruby-value">10</span>]
511
+ <span class="ruby-ivar">@tags</span> = {}
690
512
  <span class="ruby-value">11</span>.<span class="ruby-identifier">upto</span>(<span class="ruby-identifier">s</span>.<span class="ruby-identifier">size</span><span class="ruby-operator">-</span><span class="ruby-value">1</span>) {<span class="ruby-operator">|</span><span class="ruby-identifier">n</span><span class="ruby-operator">|</span>
691
- <span class="ruby-identifier">t</span> = <span class="ruby-constant">Tag</span>.<span class="ruby-identifier">new</span>
513
+ <span class="ruby-identifier">t</span> = <span class="ruby-constant">Bio</span><span class="ruby-operator">::</span><span class="ruby-constant">DB</span><span class="ruby-operator">::</span><span class="ruby-constant">Tag</span>.<span class="ruby-identifier">new</span>
692
514
  <span class="ruby-identifier">t</span>.<span class="ruby-identifier">set</span>(<span class="ruby-identifier">s</span>[<span class="ruby-identifier">n</span>])
693
515
  <span class="ruby-identifier">tags</span>[<span class="ruby-identifier">t</span>.<span class="ruby-identifier">tag</span>] = <span class="ruby-identifier">t</span>
694
- }
695
-
696
-
697
- <span class="ruby-comment">#&lt;QNAME&gt; &lt;FLAG&gt; &lt;RNAME&gt; &lt;POS&gt; &lt;MAPQ&gt; &lt;CIGAR&gt; &lt;MRNM&gt; &lt;MPOS&gt; &lt;ISIZE&gt; &lt;SEQ&gt; &lt;QUAL&gt; \</span>
698
- <span class="ruby-comment">#[&lt;TAG&gt;:&lt;VTYPE&gt;:&lt;VALUE&gt; [...]] </span>
699
-
700
- <span class="ruby-keyword">end</span></pre>
701
- </div><!-- sam-3D-source -->
702
-
703
- </div>
704
-
705
-
706
-
707
-
708
- </div><!-- sam-3D-method -->
709
-
710
-
711
- <div id="method-i-set" class="method-detail ">
712
-
713
- <div class="method-heading">
714
- <span class="method-name">set</span><span
715
- class="method-args">(bam_alignment, header)</span>
716
- <span class="method-click-advice">click to toggle source</span>
717
- </div>
718
-
719
-
720
- <div class="method-description">
721
-
722
-
723
-
724
-
725
-
726
- <div class="method-source-code" id="set-source">
727
- <pre><span class="ruby-comment"># File lib/bio/db/sam.rb, line 582</span>
728
- <span class="ruby-keyword">def</span> <span class="ruby-identifier">set</span>(<span class="ruby-identifier">bam_alignment</span>, <span class="ruby-identifier">header</span>)
729
- <span class="ruby-comment">#Create the FFI object</span>
730
- <span class="ruby-ivar">@al</span> = <span class="ruby-constant">Bio</span><span class="ruby-operator">::</span><span class="ruby-constant">DB</span><span class="ruby-operator">::</span><span class="ruby-constant">SAM</span><span class="ruby-operator">::</span><span class="ruby-constant">Tools</span><span class="ruby-operator">::</span><span class="ruby-constant">Bam1T</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">bam_alignment</span>)
731
-
732
- <span class="ruby-comment">#set the raw data</span>
733
- <span class="ruby-identifier">tmp_str</span> = <span class="ruby-constant">Bio</span><span class="ruby-operator">::</span><span class="ruby-constant">DB</span><span class="ruby-operator">::</span><span class="ruby-constant">SAM</span><span class="ruby-operator">::</span><span class="ruby-constant">Tools</span>.<span class="ruby-identifier">bam_format1</span>(<span class="ruby-identifier">header</span>,<span class="ruby-identifier">al</span>)
734
- <span class="ruby-comment">#self.sam = tmp_str</span>
735
- <span class="ruby-comment">#ObjectSpace.define_finalizer(self, proc {|id| puts &quot;Finalizer one on #{id}&quot; })</span>
736
- <span class="ruby-keyword">self</span>.<span class="ruby-identifier">sam</span> = <span class="ruby-constant">String</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">tmp_str</span>)
737
- <span class="ruby-comment">#LibC.free tmp_str</span>
738
- <span class="ruby-comment">#Set values calculated by libbam</span>
739
- <span class="ruby-identifier">core</span> = <span class="ruby-identifier">al</span>[<span class="ruby-value">:core</span>]
740
- <span class="ruby-identifier">cigar</span> = <span class="ruby-identifier">al</span>[<span class="ruby-value">:data</span>][<span class="ruby-identifier">core</span>[<span class="ruby-value">:l_qname</span>]]<span class="ruby-comment">#define bam1_cigar(b) ((uint32_t*)((b)-&gt;data + (b)-&gt;core.l_qname)) </span>
741
- <span class="ruby-ivar">@calend</span> = <span class="ruby-constant">Bio</span><span class="ruby-operator">::</span><span class="ruby-constant">DB</span><span class="ruby-operator">::</span><span class="ruby-constant">SAM</span><span class="ruby-operator">::</span><span class="ruby-constant">Tools</span>.<span class="ruby-identifier">bam_calend</span>(<span class="ruby-identifier">core</span>,<span class="ruby-identifier">cigar</span>)
742
- <span class="ruby-ivar">@qlen</span> = <span class="ruby-constant">Bio</span><span class="ruby-operator">::</span><span class="ruby-constant">DB</span><span class="ruby-operator">::</span><span class="ruby-constant">SAM</span><span class="ruby-operator">::</span><span class="ruby-constant">Tools</span>.<span class="ruby-identifier">bam_cigar2qlen</span>(<span class="ruby-identifier">core</span>,<span class="ruby-identifier">cigar</span>)
743
-
744
- <span class="ruby-comment">#process the flags</span>
745
- <span class="ruby-ivar">@is_paired</span> = <span class="ruby-ivar">@flag</span> &amp; <span class="ruby-value">0x0001</span> <span class="ruby-operator">&gt;</span> <span class="ruby-value">0</span>
746
- <span class="ruby-ivar">@is_mapped</span> = <span class="ruby-ivar">@flag</span> &amp; <span class="ruby-value">0x0002</span> <span class="ruby-operator">&gt;</span> <span class="ruby-value">0</span>
747
- <span class="ruby-ivar">@query_unmapped</span> = <span class="ruby-ivar">@flag</span> &amp; <span class="ruby-value">0x0004</span> <span class="ruby-operator">&gt;</span> <span class="ruby-value">0</span>
748
- <span class="ruby-ivar">@mate_unmapped</span> = <span class="ruby-ivar">@flag</span> &amp; <span class="ruby-value">0x0008</span> <span class="ruby-operator">&gt;</span> <span class="ruby-value">0</span>
749
- <span class="ruby-ivar">@query_strand</span> = <span class="ruby-operator">!</span>(<span class="ruby-ivar">@flag</span> &amp; <span class="ruby-value">0x0010</span> <span class="ruby-operator">&gt;</span> <span class="ruby-value">0</span>)
750
- <span class="ruby-ivar">@mate_strand</span> = <span class="ruby-operator">!</span>(<span class="ruby-ivar">@flag</span> &amp; <span class="ruby-value">0x0020</span> <span class="ruby-operator">&gt;</span> <span class="ruby-value">0</span>)
751
- <span class="ruby-ivar">@first_in_pair</span> = <span class="ruby-ivar">@flag</span> &amp; <span class="ruby-value">0x0040</span> <span class="ruby-operator">&gt;</span> <span class="ruby-value">0</span>
752
- <span class="ruby-ivar">@second_in_pair</span> = <span class="ruby-ivar">@flag</span> &amp; <span class="ruby-value">0x0080</span> <span class="ruby-operator">&gt;</span> <span class="ruby-value">0</span>
753
- <span class="ruby-ivar">@primary</span> = <span class="ruby-operator">!</span>(<span class="ruby-ivar">@flag</span> &amp; <span class="ruby-value">0x0100</span> <span class="ruby-operator">&gt;</span> <span class="ruby-value">0</span>)
754
- <span class="ruby-ivar">@failed_quality</span> = <span class="ruby-ivar">@flag</span> &amp; <span class="ruby-value">0x0200</span> <span class="ruby-operator">&gt;</span> <span class="ruby-value">0</span>
755
- <span class="ruby-ivar">@is_duplicate</span> = <span class="ruby-ivar">@flag</span> &amp; <span class="ruby-value">0x0400</span> <span class="ruby-operator">&gt;</span> <span class="ruby-value">0</span>
516
+ }
517
+
518
+ <span class="ruby-ivar">@is_paired</span> = (<span class="ruby-ivar">@flag</span> <span class="ruby-operator">&amp;</span> <span class="ruby-value">0x0001</span>) <span class="ruby-operator">&gt;</span> <span class="ruby-value">0</span>
519
+ <span class="ruby-ivar">@is_mapped</span> = <span class="ruby-ivar">@flag</span> <span class="ruby-operator">&amp;</span> <span class="ruby-value">0x0002</span> <span class="ruby-operator">&gt;</span> <span class="ruby-value">0</span>
520
+ <span class="ruby-ivar">@query_unmapped</span> = <span class="ruby-ivar">@flag</span> <span class="ruby-operator">&amp;</span> <span class="ruby-value">0x0004</span> <span class="ruby-operator">&gt;</span> <span class="ruby-value">0</span>
521
+ <span class="ruby-ivar">@mate_unmapped</span> = <span class="ruby-ivar">@flag</span> <span class="ruby-operator">&amp;</span> <span class="ruby-value">0x0008</span> <span class="ruby-operator">&gt;</span> <span class="ruby-value">0</span>
522
+ <span class="ruby-ivar">@query_strand</span> = <span class="ruby-operator">!</span>(<span class="ruby-ivar">@flag</span> <span class="ruby-operator">&amp;</span> <span class="ruby-value">0x0010</span> <span class="ruby-operator">&gt;</span> <span class="ruby-value">0</span>)
523
+ <span class="ruby-ivar">@mate_strand</span> = <span class="ruby-operator">!</span>(<span class="ruby-ivar">@flag</span> <span class="ruby-operator">&amp;</span> <span class="ruby-value">0x0020</span> <span class="ruby-operator">&gt;</span> <span class="ruby-value">0</span>)
524
+ <span class="ruby-ivar">@first_in_pair</span> = <span class="ruby-ivar">@flag</span> <span class="ruby-operator">&amp;</span> <span class="ruby-value">0x0040</span> <span class="ruby-operator">&gt;</span> <span class="ruby-value">0</span>
525
+ <span class="ruby-ivar">@second_in_pair</span> = <span class="ruby-ivar">@flag</span> <span class="ruby-operator">&amp;</span> <span class="ruby-value">0x0080</span> <span class="ruby-operator">&gt;</span> <span class="ruby-value">0</span>
526
+ <span class="ruby-ivar">@primary</span> = <span class="ruby-operator">!</span>(<span class="ruby-ivar">@flag</span> <span class="ruby-operator">&amp;</span> <span class="ruby-value">0x0100</span> <span class="ruby-operator">&gt;</span> <span class="ruby-value">0</span>)
527
+ <span class="ruby-ivar">@failed_quality</span> = <span class="ruby-ivar">@flag</span> <span class="ruby-operator">&amp;</span> <span class="ruby-value">0x0200</span> <span class="ruby-operator">&gt;</span> <span class="ruby-value">0</span>
528
+ <span class="ruby-ivar">@is_duplicate</span> = <span class="ruby-ivar">@flag</span> <span class="ruby-operator">&amp;</span> <span class="ruby-value">0x0400</span> <span class="ruby-operator">&gt;</span> <span class="ruby-value">0</span>
756
529
 
757
530
  <span class="ruby-keyword">end</span></pre>
758
- </div><!-- set-source -->
531
+ </div>
759
532
 
760
533
  </div>
761
534
 
762
535
 
763
536
 
764
537
 
765
- </div><!-- set-method -->
538
+ </div>
766
539
 
767
540
 
768
- </section><!-- public-instance-method-details -->
541
+ </section>
769
542
 
770
- </section><!-- 5Buntitled-5D -->
771
-
772
- </div><!-- documentation -->
543
+ </section>
544
+ </main>
773
545
 
774
546
 
775
- <footer id="validator-badges">
776
- <p><a href="http://validator.w3.org/check/referer">[Validate]</a>
777
- <p>Generated by <a href="https://github.com/rdoc/rdoc">RDoc</a> 3.12.
778
- <p>Generated with the <a href="http://deveiate.org/projects/Darkfish-Rdoc/">Darkfish Rdoc Generator</a> 3.
547
+ <footer id="validator-badges" role="contentinfo">
548
+ <p><a href="http://validator.w3.org/check/referer">Validate</a>
549
+ <p>Generated by <a href="http://rdoc.rubyforge.org">RDoc</a> 4.1.1.
550
+ <p>Based on <a href="http://deveiate.org/projects/Darkfish-Rdoc/">Darkfish</a> by <a href="http://deveiate.org">Michael Granger</a>.
779
551
  </footer>
780
552