20.5 KB
/srv/reproducible-results/rbuild-debian/r-b-build.Zc2w7mO8/b1/r-bioc-genomicfeatures_1.50.4+dfsg-1_i386.changes vs.
/srv/reproducible-results/rbuild-debian/r-b-build.Zc2w7mO8/b2/r-bioc-genomicfeatures_1.50.4+dfsg-1_i386.changes
234 B
Files
    
Offset 1, 2 lines modifiedOffset 1, 2 lines modified
  
1 ·5730d6946189eebed1097943f7f5dd32·1644316·gnu-r·optional·r-bioc-genomicfeatures_1.50.4+dfsg-1_all.deb1 ·fdd8f442496acbfb78e7c3c4b88d091c·1643892·gnu-r·optional·r-bioc-genomicfeatures_1.50.4+dfsg-1_all.deb
20.1 KB
r-bioc-genomicfeatures_1.50.4+dfsg-1_all.deb
367 B
file list
    
Offset 1, 3 lines modifiedOffset 1, 3 lines modified
1 -rw-r--r--···0········0········0········4·2023-01-30·12:34:26.000000·debian-binary1 -rw-r--r--···0········0········0········4·2023-01-30·12:34:26.000000·debian-binary
2 -rw-r--r--···0········0········0·····2996·2023-01-30·12:34:26.000000·control.tar.xz2 -rw-r--r--···0········0········0·····2996·2023-01-30·12:34:26.000000·control.tar.xz
3 -rw-r--r--···0········0········0··1641128·2023-01-30·12:34:26.000000·data.tar.xz3 -rw-r--r--···0········0········0··1640704·2023-01-30·12:34:26.000000·data.tar.xz
98.0 B
control.tar.xz
70.0 B
control.tar
48.0 B
./md5sums
30.0 B
./md5sums
Files differ
19.5 KB
data.tar.xz
19.5 KB
data.tar
2.66 KB
file list
    
Offset 20, 16 lines modifiedOffset 20, 16 lines modified
20 drwxr-xr-x···0·root·········(0)·root·········(0)········0·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/R/20 drwxr-xr-x···0·root·········(0)·root·········(0)········0·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/R/
21 -rw-r--r--···0·root·········(0)·root·········(0)·····1058·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/R/GenomicFeatures21 -rw-r--r--···0·root·········(0)·root·········(0)·····1058·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/R/GenomicFeatures
22 -rw-r--r--···0·root·········(0)·root·········(0)··1156133·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/R/GenomicFeatures.rdb22 -rw-r--r--···0·root·········(0)·root·········(0)··1156133·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/R/GenomicFeatures.rdb
23 -rw-r--r--···0·root·········(0)·root·········(0)····10022·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/R/GenomicFeatures.rdx23 -rw-r--r--···0·root·········(0)·root·········(0)····10022·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/R/GenomicFeatures.rdx
24 drwxr-xr-x···0·root·········(0)·root·········(0)········0·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/doc/24 drwxr-xr-x···0·root·········(0)·root·········(0)········0·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/doc/
25 -rw-r--r--···0·root·········(0)·root·········(0)·····4269·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/doc/GenomicFeatures.R25 -rw-r--r--···0·root·········(0)·root·········(0)·····4269·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/doc/GenomicFeatures.R
26 -rw-r--r--···0·root·········(0)·root·········(0)····16695·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/doc/GenomicFeatures.Rmd26 -rw-r--r--···0·root·········(0)·root·········(0)····16695·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/doc/GenomicFeatures.Rmd
27 -rw-r--r--···0·root·········(0)·root·········(0)····29184·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/doc/GenomicFeatures.html27 -rw-r--r--···0·root·········(0)·root·········(0)····29183·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/doc/GenomicFeatures.html
28 -rw-r--r--···0·root·········(0)·root·········(0)····21489·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/doc/GenomicFeatures.md28 -rw-r--r--···0·root·········(0)·root·········(0)····21488·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/doc/GenomicFeatures.md
29 -rw-r--r--···0·root·········(0)·root·········(0)·····1783·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/doc/index.html29 -rw-r--r--···0·root·········(0)·root·········(0)·····1783·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/doc/index.html
30 drwxr-xr-x···0·root·········(0)·root·········(0)········0·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/extdata/30 drwxr-xr-x···0·root·········(0)·root·········(0)········0·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/extdata/
31 -rw-r--r--···0·root·········(0)·root·········(0)····45056·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/extdata/Biomart_Ensembl_sample.sqlite31 -rw-r--r--···0·root·········(0)·root·········(0)····45056·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/extdata/Biomart_Ensembl_sample.sqlite
32 -rw-r--r--···0·root·········(0)·root·········(0)····34816·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/extdata/FeatureDb.sqlite32 -rw-r--r--···0·root·········(0)·root·········(0)····34816·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/extdata/FeatureDb.sqlite
33 drwxr-xr-x···0·root·········(0)·root·········(0)········0·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/extdata/GFF3_files/33 drwxr-xr-x···0·root·········(0)·root·········(0)········0·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/extdata/GFF3_files/
34 -rw-r--r--···0·root·········(0)·root·········(0)···263054·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/extdata/GFF3_files/NC_011025.gff34 -rw-r--r--···0·root·········(0)·root·········(0)···263054·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/extdata/GFF3_files/NC_011025.gff
35 -rw-r--r--···0·root·········(0)·root·········(0)·····1760·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/extdata/GFF3_files/TheCanonicalGene_v1.gff335 -rw-r--r--···0·root·········(0)·root·········(0)·····1760·2023-01-30·12:34:26.000000·./usr/lib/R/site-library/GenomicFeatures/extdata/GFF3_files/TheCanonicalGene_v1.gff3
16.3 KB
./usr/lib/R/site-library/GenomicFeatures/doc/GenomicFeatures.html
    
Offset 92, 15 lines modifiedOffset 92, 15 lines modified
92 <div·class="include-before">92 <div·class="include-before">
  
93 </div>93 </div>
  
94 <div·class="frontmatter">94 <div·class="frontmatter">
95 <div·class="title"><h1>Making·and·Utilizing·TxDb·Objects</h1></div>95 <div·class="title"><h1>Making·and·Utilizing·TxDb·Objects</h1></div>
96 <div·class="author"><h2>Marc·Carlson,·Patrick·Aboyoun,·Hervé·Pagès,·Seth·Falcon,·Martin·Morgan</h2></div>96 <div·class="author"><h2>Marc·Carlson,·Patrick·Aboyoun,·Hervé·Pagès,·Seth·Falcon,·Martin·Morgan</h2></div>
97 <div·class="date"><h3>Friday,·February·21,·2025</h3></div>97 <div·class="date"><h3>Sunday,·January·21,·2024</h3></div>
98 </div>98 </div>
  
99 <div·class="body">99 <div·class="body">
100 <h2>Introduction</h2>100 <h2>Introduction</h2>
101 <p>The·<code>GenomicFeatures</code>·package·retrieves·and·manages101 <p>The·<code>GenomicFeatures</code>·package·retrieves·and·manages
102 transcript-related·features·from·the·UCSC·Genome102 transcript-related·features·from·the·UCSC·Genome
103 Bioinformatics\footnote{(<a·href="http://genome.ucsc.edu/)%7D">http://genome.ucsc.edu/)}</a>·and103 Bioinformatics\footnote{(<a·href="http://genome.ucsc.edu/)%7D">http://genome.ucsc.edu/)}</a>·and
Offset 188, 24 lines modifiedOffset 188, 24 lines modified
188 to·the·seqlevels·stored·in·the·db),·then·set·the·seqlevels·to188 to·the·seqlevels·stored·in·the·db),·then·set·the·seqlevels·to
189 <code>seqlevels0(txdb)</code>.</p>189 <code>seqlevels0(txdb)</code>.</p>
190 <pre><code·class="language-r">seqlevels(txdb)·&lt;-·seqlevels0(txdb)190 <pre><code·class="language-r">seqlevels(txdb)·&lt;-·seqlevels0(txdb)
191 </code></pre>191 </code></pre>
192 <pre><code>##·Error·in·seqlevels0(txdb):·could·not·find·function·&quot;seqlevels0&quot;192 <pre><code>##·Error·in·seqlevels0(txdb):·could·not·find·function·&quot;seqlevels0&quot;
193 </code></pre>193 </code></pre>
194 <p>\begin{Exercise}·Use·</code>seqlevels<code>·to·set·only·chromsome·15·to·be·active.··BTW,·the·rest·of·this·vignette·will·assume·you·have·succeeded·at·this.·\end{Exercise}194 <p>\begin{Exercise}·Use·</code>seqlevels<code>·to·set·only·chromsome·15·to·be·active.··BTW,·the·rest·of·this·vignette·will·assume·you·have·succeeded·at·this.·\end{Exercise}
195 `Fk\begin{Solution}</p>195 `Dw\begin{Solution}</p>
196 <pre><code·class="language-r">seqlevels(txdb)·&lt;-·&quot;chr15&quot;196 <pre><code·class="language-r">seqlevels(txdb)·&lt;-·&quot;chr15&quot;
197 </code></pre>197 </code></pre>
198 <pre><code>##·Error·in·seqlevels(txdb)·&lt;-·&quot;chr15&quot;:·object·'txdb'·not·found198 <pre><code>##·Error·in·seqlevels(txdb)·&lt;-·&quot;chr15&quot;:·object·'txdb'·not·found
199 </code></pre>199 </code></pre>
200 <pre><code·class="language-r">seqlevels(txdb)200 <pre><code·class="language-r">seqlevels(txdb)
201 </code></pre>201 </code></pre>
202 <pre><code>##·Error·in·seqlevels(txdb):·could·not·find·function·&quot;seqlevels&quot;202 <pre><code>##·Error·in·seqlevels(txdb):·could·not·find·function·&quot;seqlevels&quot;
203 </code></pre>203 </code></pre>
204 <p>\end{Solution}Fk`</p>204 <p>\end{Solution}Dw`</p>
205 <h3>Retrieving·data·using·the·select·method</h3>205 <h3>Retrieving·data·using·the·select·method</h3>
206 <p>The·<code>TxDb</code>·objects·inherit·from·<code>AnnotationDb</code>206 <p>The·<code>TxDb</code>·objects·inherit·from·<code>AnnotationDb</code>
207 objects·(just·as·the·<code>ChipDb</code>·and·<code>OrgDb</code>·objects·do).207 objects·(just·as·the·<code>ChipDb</code>·and·<code>OrgDb</code>·objects·do).
208 One·of·the·implications·of·this·relationship·is·that·these·object208 One·of·the·implications·of·this·relationship·is·that·these·object
209 ought·to·be·used·in·similar·ways·to·each·other.··Therefore·we·have209 ought·to·be·used·in·similar·ways·to·each·other.··Therefore·we·have
210 written·supporting·<code>columns</code>,·<code>keytypes</code>,·<code>keys</code>210 written·supporting·<code>columns</code>,·<code>keytypes</code>,·<code>keys</code>
211 and·<code>select</code>·methods·for·<code>TxDb</code>·objects.</p>211 and·<code>select</code>·methods·for·<code>TxDb</code>·objects.</p>
Offset 224, 25 lines modifiedOffset 224, 25 lines modified
224 <pre><code>##·Error·in·keytypes(txdb):·could·not·find·function·&quot;keytypes&quot;224 <pre><code>##·Error·in·keytypes(txdb):·could·not·find·function·&quot;keytypes&quot;
225 </code></pre>225 </code></pre>
226 <pre><code·class="language-r">select(txdb,·keys·=·keys,·columns=&quot;TXNAME&quot;,·keytype=&quot;GENEID&quot;)226 <pre><code·class="language-r">select(txdb,·keys·=·keys,·columns=&quot;TXNAME&quot;,·keytype=&quot;GENEID&quot;)
227 </code></pre>227 </code></pre>
228 <pre><code>##·Error·in·select(txdb,·keys·=·keys,·columns·=·&quot;TXNAME&quot;,·keytype·=·&quot;GENEID&quot;):·could·not·find·function·&quot;select&quot;228 <pre><code>##·Error·in·select(txdb,·keys·=·keys,·columns·=·&quot;TXNAME&quot;,·keytype·=·&quot;GENEID&quot;):·could·not·find·function·&quot;select&quot;
229 </code></pre>229 </code></pre>
230 <p>\begin{Exercise}·For·the·genes·in·the·example·above,·find·the·chromosome·and·strand·information·that·will·go·with·each·of·the·transcript·names.·\end{Exercise}230 <p>\begin{Exercise}·For·the·genes·in·the·example·above,·find·the·chromosome·and·strand·information·that·will·go·with·each·of·the·transcript·names.·\end{Exercise}
231 `Fk\begin{Solution}</p>231 `Dw\begin{Solution}</p>
232 <pre><code·class="language-r">columns(txdb)232 <pre><code·class="language-r">columns(txdb)
233 </code></pre>233 </code></pre>
234 <pre><code>##·Error·in·columns(txdb):·could·not·find·function·&quot;columns&quot;234 <pre><code>##·Error·in·columns(txdb):·could·not·find·function·&quot;columns&quot;
235 </code></pre>235 </code></pre>
236 <pre><code·class="language-r">cols·&lt;-·c(&quot;TXNAME&quot;,·&quot;TXSTRAND&quot;,·&quot;TXCHROM&quot;)236 <pre><code·class="language-r">cols·&lt;-·c(&quot;TXNAME&quot;,·&quot;TXSTRAND&quot;,·&quot;TXCHROM&quot;)
237 select(txdb,·keys=keys,·columns=cols,·keytype=&quot;GENEID&quot;)237 select(txdb,·keys=keys,·columns=cols,·keytype=&quot;GENEID&quot;)
238 </code></pre>238 </code></pre>
239 <pre><code>##·Error·in·select(txdb,·keys·=·keys,·columns·=·cols,·keytype·=·&quot;GENEID&quot;):·could·not·find·function·&quot;select&quot;239 <pre><code>##·Error·in·select(txdb,·keys·=·keys,·columns·=·cols,·keytype·=·&quot;GENEID&quot;):·could·not·find·function·&quot;select&quot;
240 </code></pre>240 </code></pre>
241 <p>\end{Solution}Fk`</p>241 <p>\end{Solution}Dw`</p>
242 <h3>Methods·for·returning·<code>GRanges</code>·objects</h3>242 <h3>Methods·for·returning·<code>GRanges</code>·objects</h3>
243 <p>Retrieving·data·with·select·is·useful,·but·sometimes·it·is·more243 <p>Retrieving·data·with·select·is·useful,·but·sometimes·it·is·more
244 convenient·to·extract·the·result·as·<code>GRanges</code>·objects.··This·is244 convenient·to·extract·the·result·as·<code>GRanges</code>·objects.··This·is
245 often·the·case·when·you·are·doing·counting·or·specialized·overlap245 often·the·case·when·you·are·doing·counting·or·specialized·overlap
246 operations·downstream.··For·these·use·cases·there·is·another·family·of246 operations·downstream.··For·these·use·cases·there·is·another·family·of
247 methods·available.</p>247 methods·available.</p>
248 <p>Perhaps·the·most·common·operations·for·a·<code>TxDb</code>·object248 <p>Perhaps·the·most·common·operations·for·a·<code>TxDb</code>·object
Offset 317, 15 lines modifiedOffset 317, 15 lines modified
317 </code></pre>317 </code></pre>
318 <pre><code>##·Error·in·eval(expr,·envir,·enclos):·object·'PR'·not·found318 <pre><code>##·Error·in·eval(expr,·envir,·enclos):·object·'PR'·not·found
319 </code></pre>319 </code></pre>
320 <p>The·<code>exons</code>·and·<code>cds</code>·functions·can·also·be·used320 <p>The·<code>exons</code>·and·<code>cds</code>·functions·can·also·be·used
321 in·a·similar·fashion·to·retrive·genomic·coordinates·for·exons·and321 in·a·similar·fashion·to·retrive·genomic·coordinates·for·exons·and
322 coding·sequences.</p>322 coding·sequences.</p>
323 <p>\begin{Exercise}·Use·</code>exons<code>to·retrieve·all·the·exons·from·chromosome·15.·How·does·the·length·of·this·compare·to·the·value·returned·by</code>transcripts<code>?·\end{Exercise}323 <p>\begin{Exercise}·Use·</code>exons<code>to·retrieve·all·the·exons·from·chromosome·15.·How·does·the·length·of·this·compare·to·the·value·returned·by</code>transcripts<code>?·\end{Exercise}
324 `Fk\begin{Solution}</p>324 `Dw\begin{Solution}</p>
325 <pre><code·class="language-r">EX·&lt;-·exons(txdb)325 <pre><code·class="language-r">EX·&lt;-·exons(txdb)
326 </code></pre>326 </code></pre>
327 <pre><code>##·Error·in·exons(txdb):·could·not·find·function·&quot;exons&quot;327 <pre><code>##·Error·in·exons(txdb):·could·not·find·function·&quot;exons&quot;
328 </code></pre>328 </code></pre>
329 <pre><code·class="language-r">EX[1:4]329 <pre><code·class="language-r">EX[1:4]
330 </code></pre>330 </code></pre>
331 <pre><code>##·Error·in·eval(expr,·envir,·enclos):·object·'EX'·not·found331 <pre><code>##·Error·in·eval(expr,·envir,·enclos):·object·'EX'·not·found
Offset 334, 15 lines modifiedOffset 334, 15 lines modified
334 </code></pre>334 </code></pre>
335 <pre><code>##·Error·in·eval(expr,·envir,·enclos):·object·'EX'·not·found335 <pre><code>##·Error·in·eval(expr,·envir,·enclos):·object·'EX'·not·found
336 </code></pre>336 </code></pre>
337 <pre><code·class="language-r">length(GR)337 <pre><code·class="language-r">length(GR)
338 </code></pre>338 </code></pre>
339 <pre><code>##·Error·in·eval(expr,·envir,·enclos):·object·'GR'·not·found339 <pre><code>##·Error·in·eval(expr,·envir,·enclos):·object·'GR'·not·found
340 </code></pre>340 </code></pre>
341 <p>\end{Solution}Fk`</p>341 <p>\end{Solution}Dw`</p>
342 <h3>Working·with·Grouped·Features</h3>342 <h3>Working·with·Grouped·Features</h3>
343 <p>Often·one·is·interested·in·how·particular·genomic·features·relate·to343 <p>Often·one·is·interested·in·how·particular·genomic·features·relate·to
344 each·other,·and·not·just·their·location.··For·example,·it·might·be·of344 each·other,·and·not·just·their·location.··For·example,·it·might·be·of
345 interest·to·group·transcripts·by·gene·or·to·group·exons·by·transcript.345 interest·to·group·transcripts·by·gene·or·to·group·exons·by·transcript.
346 Such·groupings·are·supported·by·the·<code>transcriptsBy</code>,346 Such·groupings·are·supported·by·the·<code>transcriptsBy</code>,
347 <code>exonsBy</code>,·and·<code>cdsBy</code>·functions.</p>347 <code>exonsBy</code>,·and·<code>cdsBy</code>·functions.</p>
348 <p>The·following·call·can·be·used·to·group·transcripts·by·genes:</p>348 <p>The·following·call·can·be·used·to·group·transcripts·by·genes:</p>
Offset 405, 28 lines modifiedOffset 405, 28 lines modified
405 unique·identifier·for·all·features.··In·this·situation,·the·group405 unique·identifier·for·all·features.··In·this·situation,·the·group
406 label·will·be·a·synthetic·ID·created·by·<code>GenomicFeatures</code>·to406 label·will·be·a·synthetic·ID·created·by·<code>GenomicFeatures</code>·to
407 keep·the·relations·between·features·consistent·in·the·database·this407 keep·the·relations·between·features·consistent·in·the·database·this
408 was·the·case·in·the·2nd·example.··Even·though·the·results·will408 was·the·case·in·the·2nd·example.··Even·though·the·results·will
409 sometimes·have·to·come·back·to·you·as·synthetic·IDs,·you·can·still409 sometimes·have·to·come·back·to·you·as·synthetic·IDs,·you·can·still
410 always·retrieve·the·original·IDs.</p>410 always·retrieve·the·original·IDs.</p>
411 <p>\begin{Exercise}·Starting·with·the·tx_ids·that·are·the·names·of·the·GRList·object·we·just·made,·use·</code>select<code>to·retrieve·that·matching·transcript·names.··Remember·that·the·list·used·a</code>by<code>·argument·=·&quot;tx&quot;,·so·the·list·is·grouped·by·transcript·IDs.·\end{Exercise}411 <p>\begin{Exercise}·Starting·with·the·tx_ids·that·are·the·names·of·the·GRList·object·we·just·made,·use·</code>select<code>to·retrieve·that·matching·transcript·names.··Remember·that·the·list·used·a</code>by<code>·argument·=·&quot;tx&quot;,·so·the·list·is·grouped·by·transcript·IDs.·\end{Exercise}
412 `Fk\begin{Solution}</p>412 `Dw\begin{Solution}</p>
413 <pre><code·class="language-r">GRList·&lt;-·exonsBy(txdb,·by·=·&quot;tx&quot;)413 <pre><code·class="language-r">GRList·&lt;-·exonsBy(txdb,·by·=·&quot;tx&quot;)
414 </code></pre>414 </code></pre>
415 <pre><code>##·Error·in·exonsBy(txdb,·by·=·&quot;tx&quot;):·could·not·find·function·&quot;exonsBy&quot;415 <pre><code>##·Error·in·exonsBy(txdb,·by·=·&quot;tx&quot;):·could·not·find·function·&quot;exonsBy&quot;
416 </code></pre>416 </code></pre>
417 <pre><code·class="language-r">tx_ids·&lt;-·names(GRList)417 <pre><code·class="language-r">tx_ids·&lt;-·names(GRList)
418 </code></pre>418 </code></pre>
419 <pre><code>##·Error·in·eval(expr,·envir,·enclos):·object·'GRList'·not·found419 <pre><code>##·Error·in·eval(expr,·envir,·enclos):·object·'GRList'·not·found
420 </code></pre>420 </code></pre>
421 <pre><code·class="language-r">head(select(txdb,·keys=tx_ids,·columns=&quot;TXNAME&quot;,·keytype=&quot;TXID&quot;))421 <pre><code·class="language-r">head(select(txdb,·keys=tx_ids,·columns=&quot;TXNAME&quot;,·keytype=&quot;TXID&quot;))
422 </code></pre>422 </code></pre>
423 <pre><code>##·Error·in·select(txdb,·keys·=·tx_ids,·columns·=·&quot;TXNAME&quot;,·keytype·=·&quot;TXID&quot;):·could·not·find·function·&quot;select&quot;423 <pre><code>##·Error·in·select(txdb,·keys·=·tx_ids,·columns·=·&quot;TXNAME&quot;,·keytype·=·&quot;TXID&quot;):·could·not·find·function·&quot;select&quot;
424 </code></pre>424 </code></pre>
425 <p>\end{Solution}Fk`</p>425 <p>\end{Solution}Dw`</p>
426 <p>Finally,·the·order·of·the·results·in·a·<code>GRangesList</code>·object·can426 <p>Finally,·the·order·of·the·results·in·a·<code>GRangesList</code>·object·can
427 vary·with·the·way·in·which·things·were·grouped.·In·most·cases·the427 vary·with·the·way·in·which·things·were·grouped.·In·most·cases·the
428 grouped·elements·of·the·<code>GRangesList</code>·object·will·be·listed·in428 grouped·elements·of·the·<code>GRangesList</code>·object·will·be·listed·in
429 the·order·that·they·occurred·along·the·chromosome.··However,·when429 the·order·that·they·occurred·along·the·chromosome.··However,·when
430 exons·or·CDS·are·grouped·by·transcript,·they·will·instead·be·grouped430 exons·or·CDS·are·grouped·by·transcript,·they·will·instead·be·grouped
431 according·to·their·position·along·the·transcript·itself.··This·is431 according·to·their·position·along·the·transcript·itself.··This·is
432 important·because·alternative·splicing·can·mean·that·the·order·along432 important·because·alternative·splicing·can·mean·that·the·order·along
Max diff block lines reached; 1790/9082 bytes (19.71%) of diff not shown.
7.32 KB
html2text {}
    
Offset 1, 13 lines modifiedOffset 1, 13 lines modified
  
  
1 ******·Making·and·Utilizing·TxDb·Objects·******1 ******·Making·and·Utilizing·TxDb·Objects·******
2 *****·Marc·Carlson,·Patrick·Aboyoun,·Hervé·Pagès,·Seth·Falcon,·Martin·Morgan2 *****·Marc·Carlson,·Patrick·Aboyoun,·Hervé·Pagès,·Seth·Falcon,·Martin·Morgan
3 *****3 *****
4 ****·Friday,·February·21,·2025·****4 ****·Sunday,·January·21,·2024·****
5 *****·Introduction·*****5 *****·Introduction·*****
6 The·GenomicFeatures·package·retrieves·and·manages·transcript-related·features6 The·GenomicFeatures·package·retrieves·and·manages·transcript-related·features
7 from·the·UCSC·Genome·Bioinformatics\footnote{(http://genome.ucsc.edu/)}·and7 from·the·UCSC·Genome·Bioinformatics\footnote{(http://genome.ucsc.edu/)}·and
8 BioMart\footnote{(http://www.biomart.org/)}·data·resources.·The·package·is8 BioMart\footnote{(http://www.biomart.org/)}·data·resources.·The·package·is
9 useful·for·ChIP-chip,·ChIP-seq,·and·RNA-seq·analyses.9 useful·for·ChIP-chip,·ChIP-seq,·and·RNA-seq·analyses.
10 suppressPackageStartupMessages(library('GenomicFeatures'))10 suppressPackageStartupMessages(library('GenomicFeatures'))
11 ##·Error·in·library("GenomicFeatures"):·there·is·no·package·called11 ##·Error·in·library("GenomicFeatures"):·there·is·no·package·called
Offset 69, 20 lines modifiedOffset 69, 20 lines modified
69 would·be·consulted·when·you·call·the·various·retrieval·methods…·If·you·need69 would·be·consulted·when·you·call·the·various·retrieval·methods…·If·you·need
70 to·reset·back·to·the·original·seqlevels·(i.e.·to·the·seqlevels·stored·in·the70 to·reset·back·to·the·original·seqlevels·(i.e.·to·the·seqlevels·stored·in·the
71 db),·then·set·the·seqlevels·to·seqlevels0(txdb).71 db),·then·set·the·seqlevels·to·seqlevels0(txdb).
72 seqlevels(txdb)·<-·seqlevels0(txdb)72 seqlevels(txdb)·<-·seqlevels0(txdb)
73 ##·Error·in·seqlevels0(txdb):·could·not·find·function·"seqlevels0"73 ##·Error·in·seqlevels0(txdb):·could·not·find·function·"seqlevels0"
74 \begin{Exercise}·Use74 \begin{Exercise}·Use
75 seqlevelsto·set·only·chromsome·15·to·be·active.·BTW,·the·rest·of·this·vignette75 seqlevelsto·set·only·chromsome·15·to·be·active.·BTW,·the·rest·of·this·vignette
76 will·assume·you·have·succeeded·at·this.·\end{Exercise}·`Fk\begin{Solution}76 will·assume·you·have·succeeded·at·this.·\end{Exercise}·`Dw\begin{Solution}
77 seqlevels(txdb)·<-·"chr15"77 seqlevels(txdb)·<-·"chr15"
78 ##·Error·in·seqlevels(txdb)·<-·"chr15":·object·'txdb'·not·found78 ##·Error·in·seqlevels(txdb)·<-·"chr15":·object·'txdb'·not·found
79 seqlevels(txdb)79 seqlevels(txdb)
80 ##·Error·in·seqlevels(txdb):·could·not·find·function·"seqlevels"80 ##·Error·in·seqlevels(txdb):·could·not·find·function·"seqlevels"
81 \end{Solution}Fk`81 \end{Solution}Dw`
82 ****·Retrieving·data·using·the·select·method·****82 ****·Retrieving·data·using·the·select·method·****
83 The·TxDb·objects·inherit·from·AnnotationDb·objects·(just·as·the·ChipDb·and83 The·TxDb·objects·inherit·from·AnnotationDb·objects·(just·as·the·ChipDb·and
84 OrgDb·objects·do).·One·of·the·implications·of·this·relationship·is·that·these84 OrgDb·objects·do).·One·of·the·implications·of·this·relationship·is·that·these
85 object·ought·to·be·used·in·similar·ways·to·each·other.·Therefore·we·have85 object·ought·to·be·used·in·similar·ways·to·each·other.·Therefore·we·have
86 written·supporting·columns,·keytypes,·keys·and·select·methods·for·TxDb·objects.86 written·supporting·columns,·keytypes,·keys·and·select·methods·for·TxDb·objects.
87 These·methods·can·be·a·useful·way·of·extracting·data·from·a·TxDb·object.·And87 These·methods·can·be·a·useful·way·of·extracting·data·from·a·TxDb·object.·And
88 they·are·used·in·the·same·way·that·they·would·be·used·to·extract·information88 they·are·used·in·the·same·way·that·they·would·be·used·to·extract·information
Offset 94, 22 lines modifiedOffset 94, 22 lines modified
94 keytypes(txdb)94 keytypes(txdb)
95 ##·Error·in·keytypes(txdb):·could·not·find·function·"keytypes"95 ##·Error·in·keytypes(txdb):·could·not·find·function·"keytypes"
96 select(txdb,·keys·=·keys,·columns="TXNAME",·keytype="GENEID")96 select(txdb,·keys·=·keys,·columns="TXNAME",·keytype="GENEID")
97 ##·Error·in·select(txdb,·keys·=·keys,·columns·=·"TXNAME",·keytype·=·"GENEID"):97 ##·Error·in·select(txdb,·keys·=·keys,·columns·=·"TXNAME",·keytype·=·"GENEID"):
98 could·not·find·function·"select"98 could·not·find·function·"select"
99 \begin{Exercise}·For·the·genes·in·the·example·above,·find·the·chromosome·and99 \begin{Exercise}·For·the·genes·in·the·example·above,·find·the·chromosome·and
100 strand·information·that·will·go·with·each·of·the·transcript·names.·\end100 strand·information·that·will·go·with·each·of·the·transcript·names.·\end
101 {Exercise}·`Fk\begin{Solution}101 {Exercise}·`Dw\begin{Solution}
102 columns(txdb)102 columns(txdb)
103 ##·Error·in·columns(txdb):·could·not·find·function·"columns"103 ##·Error·in·columns(txdb):·could·not·find·function·"columns"
104 cols·<-·c("TXNAME",·"TXSTRAND",·"TXCHROM")104 cols·<-·c("TXNAME",·"TXSTRAND",·"TXCHROM")
105 select(txdb,·keys=keys,·columns=cols,·keytype="GENEID")105 select(txdb,·keys=keys,·columns=cols,·keytype="GENEID")
106 ##·Error·in·select(txdb,·keys·=·keys,·columns·=·cols,·keytype·=·"GENEID"):106 ##·Error·in·select(txdb,·keys·=·keys,·columns·=·cols,·keytype·=·"GENEID"):
107 could·not·find·function·"select"107 could·not·find·function·"select"
108 \end{Solution}Fk`108 \end{Solution}Dw`
109 ****·Methods·for·returning·GRanges·objects·****109 ****·Methods·for·returning·GRanges·objects·****
110 Retrieving·data·with·select·is·useful,·but·sometimes·it·is·more·convenient·to110 Retrieving·data·with·select·is·useful,·but·sometimes·it·is·more·convenient·to
111 extract·the·result·as·GRanges·objects.·This·is·often·the·case·when·you·are111 extract·the·result·as·GRanges·objects.·This·is·often·the·case·when·you·are
112 doing·counting·or·specialized·overlap·operations·downstream.·For·these·use112 doing·counting·or·specialized·overlap·operations·downstream.·For·these·use
113 cases·there·is·another·family·of·methods·available.113 cases·there·is·another·family·of·methods·available.
114 Perhaps·the·most·common·operations·for·a·TxDb·object·is·to·retrieve·the·genomic114 Perhaps·the·most·common·operations·for·a·TxDb·object·is·to·retrieve·the·genomic
115 coordinates·or·ranges·for·exons,·transcripts·or·coding·sequences.·The·functions115 coordinates·or·ranges·for·exons,·transcripts·or·coding·sequences.·The·functions
Offset 156, 24 lines modifiedOffset 156, 24 lines modified
156 function·"promoters"156 function·"promoters"
157 PR157 PR
158 ##·Error·in·eval(expr,·envir,·enclos):·object·'PR'·not·found158 ##·Error·in·eval(expr,·envir,·enclos):·object·'PR'·not·found
159 The·exons·and·cds·functions·can·also·be·used·in·a·similar·fashion·to·retrive159 The·exons·and·cds·functions·can·also·be·used·in·a·similar·fashion·to·retrive
160 genomic·coordinates·for·exons·and·coding·sequences.160 genomic·coordinates·for·exons·and·coding·sequences.
161 \begin{Exercise}·Use161 \begin{Exercise}·Use
162 exonsto·retrieve·all·the·exons·from·chromosome·15.·How·does·the·length·of·this162 exonsto·retrieve·all·the·exons·from·chromosome·15.·How·does·the·length·of·this
163 compare·to·the·value·returned·bytranscripts?·\end{Exercise}·`Fk\begin{Solution}163 compare·to·the·value·returned·bytranscripts?·\end{Exercise}·`Dw\begin{Solution}
164 EX·<-·exons(txdb)164 EX·<-·exons(txdb)
165 ##·Error·in·exons(txdb):·could·not·find·function·"exons"165 ##·Error·in·exons(txdb):·could·not·find·function·"exons"
166 EX[1:4]166 EX[1:4]
167 ##·Error·in·eval(expr,·envir,·enclos):·object·'EX'·not·found167 ##·Error·in·eval(expr,·envir,·enclos):·object·'EX'·not·found
168 length(EX)168 length(EX)
169 ##·Error·in·eval(expr,·envir,·enclos):·object·'EX'·not·found169 ##·Error·in·eval(expr,·envir,·enclos):·object·'EX'·not·found
170 length(GR)170 length(GR)
171 ##·Error·in·eval(expr,·envir,·enclos):·object·'GR'·not·found171 ##·Error·in·eval(expr,·envir,·enclos):·object·'GR'·not·found
172 \end{Solution}Fk`172 \end{Solution}Dw`
173 ****·Working·with·Grouped·Features·****173 ****·Working·with·Grouped·Features·****
174 Often·one·is·interested·in·how·particular·genomic·features·relate·to·each174 Often·one·is·interested·in·how·particular·genomic·features·relate·to·each
175 other,·and·not·just·their·location.·For·example,·it·might·be·of·interest·to175 other,·and·not·just·their·location.·For·example,·it·might·be·of·interest·to
176 group·transcripts·by·gene·or·to·group·exons·by·transcript.·Such·groupings·are176 group·transcripts·by·gene·or·to·group·exons·by·transcript.·Such·groupings·are
177 supported·by·the·transcriptsBy,·exonsBy,·and·cdsBy·functions.177 supported·by·the·transcriptsBy,·exonsBy,·and·cdsBy·functions.
178 The·following·call·can·be·used·to·group·transcripts·by·genes:178 The·following·call·can·be·used·to·group·transcripts·by·genes:
179 GRList·<-·transcriptsBy(txdb,·by·=·"gene")179 GRList·<-·transcriptsBy(txdb,·by·=·"gene")
Offset 217, 23 lines modifiedOffset 217, 23 lines modified
217 relations·between·features·consistent·in·the·database·this·was·the·case·in·the217 relations·between·features·consistent·in·the·database·this·was·the·case·in·the
218 2nd·example.·Even·though·the·results·will·sometimes·have·to·come·back·to·you·as218 2nd·example.·Even·though·the·results·will·sometimes·have·to·come·back·to·you·as
219 synthetic·IDs,·you·can·still·always·retrieve·the·original·IDs.219 synthetic·IDs,·you·can·still·always·retrieve·the·original·IDs.
220 \begin{Exercise}·Starting·with·the·tx_ids·that·are·the·names·of·the·GRList220 \begin{Exercise}·Starting·with·the·tx_ids·that·are·the·names·of·the·GRList
221 object·we·just·made,·use221 object·we·just·made,·use
222 selectto·retrieve·that·matching·transcript·names.·Remember·that·the·list·used222 selectto·retrieve·that·matching·transcript·names.·Remember·that·the·list·used
223 abyargument·=·"tx",·so·the·list·is·grouped·by·transcript·IDs.·\end{Exercise}223 abyargument·=·"tx",·so·the·list·is·grouped·by·transcript·IDs.·\end{Exercise}
224 `Fk\begin{Solution}224 `Dw\begin{Solution}
225 GRList·<-·exonsBy(txdb,·by·=·"tx")225 GRList·<-·exonsBy(txdb,·by·=·"tx")
226 ##·Error·in·exonsBy(txdb,·by·=·"tx"):·could·not·find·function·"exonsBy"226 ##·Error·in·exonsBy(txdb,·by·=·"tx"):·could·not·find·function·"exonsBy"
227 tx_ids·<-·names(GRList)227 tx_ids·<-·names(GRList)
228 ##·Error·in·eval(expr,·envir,·enclos):·object·'GRList'·not·found228 ##·Error·in·eval(expr,·envir,·enclos):·object·'GRList'·not·found
229 head(select(txdb,·keys=tx_ids,·columns="TXNAME",·keytype="TXID"))229 head(select(txdb,·keys=tx_ids,·columns="TXNAME",·keytype="TXID"))
230 ##·Error·in·select(txdb,·keys·=·tx_ids,·columns·=·"TXNAME",·keytype·=·"TXID"):230 ##·Error·in·select(txdb,·keys·=·tx_ids,·columns·=·"TXNAME",·keytype·=·"TXID"):
231 could·not·find·function·"select"231 could·not·find·function·"select"
232 \end{Solution}Fk`232 \end{Solution}Dw`
233 Finally,·the·order·of·the·results·in·a·GRangesList·object·can·vary·with·the·way233 Finally,·the·order·of·the·results·in·a·GRangesList·object·can·vary·with·the·way
234 in·which·things·were·grouped.·In·most·cases·the·grouped·elements·of·the234 in·which·things·were·grouped.·In·most·cases·the·grouped·elements·of·the
235 GRangesList·object·will·be·listed·in·the·order·that·they·occurred·along·the235 GRangesList·object·will·be·listed·in·the·order·that·they·occurred·along·the
236 chromosome.·However,·when·exons·or·CDS·are·grouped·by·transcript,·they·will236 chromosome.·However,·when·exons·or·CDS·are·grouped·by·transcript,·they·will
237 instead·be·grouped·according·to·their·position·along·the·transcript·itself.237 instead·be·grouped·according·to·their·position·along·the·transcript·itself.
238 This·is·important·because·alternative·splicing·can·mean·that·the·order·along238 This·is·important·because·alternative·splicing·can·mean·that·the·order·along
239 the·transcript·can·be·different·from·that·along·the·chromosome.239 the·transcript·can·be·different·from·that·along·the·chromosome.
Offset 268, 22 lines modifiedOffset 268, 22 lines modified
268 suppressWarnings(translate(tx_seqs1))268 suppressWarnings(translate(tx_seqs1))
269 ##·Error·in·translate(tx_seqs1):·could·not·find·function·"translate"269 ##·Error·in·translate(tx_seqs1):·could·not·find·function·"translate"
270 \begin{Exercise}·But·of·course·this·is·not·a·meaningful·translation,·because270 \begin{Exercise}·But·of·course·this·is·not·a·meaningful·translation,·because
271 the·call·to271 the·call·to
272 extractTranscriptSeqswill·have·extracted·all·the·transcribed·regions·of·the272 extractTranscriptSeqswill·have·extracted·all·the·transcribed·regions·of·the
273 genome·regardless·of·whether·or·not·they·are·translated.·Look·at·the·manual273 genome·regardless·of·whether·or·not·they·are·translated.·Look·at·the·manual
274 page·forextractTranscriptSeqsand·see·how·you·can·use·cdsBy·to·only·translate274 page·forextractTranscriptSeqsand·see·how·you·can·use·cdsBy·to·only·translate
275 only·the·coding·regions.·\end{Exercise}·`Fk\begin{Solution}275 only·the·coding·regions.·\end{Exercise}·`Dw\begin{Solution}
276 cds_seqs·<-·extractTranscriptSeqs(Hsapiens,276 cds_seqs·<-·extractTranscriptSeqs(Hsapiens,
277 ··································cdsBy(txdb,·by="tx",·use.names=TRUE))277 ··································cdsBy(txdb,·by="tx",·use.names=TRUE))
278 ##·Error·in·extractTranscriptSeqs(Hsapiens,·cdsBy(txdb,·by·=·"tx",·use.names·=278 ##·Error·in·extractTranscriptSeqs(Hsapiens,·cdsBy(txdb,·by·=·"tx",·use.names·=
279 TRUE)):·could·not·find·function·"extractTranscriptSeqs"279 TRUE)):·could·not·find·function·"extractTranscriptSeqs"
280 translate(cds_seqs)280 translate(cds_seqs)
281 ##·Error·in·translate(cds_seqs):·could·not·find·function·"translate"281 ##·Error·in·translate(cds_seqs):·could·not·find·function·"translate"
282 \end{Solution}Fk`282 \end{Solution}Dw`
283 *****·Creating·New·TxDb·Objects·or·Packages·*****283 *****·Creating·New·TxDb·Objects·or·Packages·*****
284 The·GenomicFeatures·package·provides·functions·to·create·TxDb·objects·based·on284 The·GenomicFeatures·package·provides·functions·to·create·TxDb·objects·based·on
285 data·downloaded·from·UCSC·Genome·Bioinformatics·or·BioMart.·The·following285 data·downloaded·from·UCSC·Genome·Bioinformatics·or·BioMart.·The·following
286 subsections·demonstrate·the·use·of·these·functions.·There·is·also·support·for286 subsections·demonstrate·the·use·of·these·functions.·There·is·also·support·for
287 creating·TxDb·objects·from·custom·data·sources·using·makeTxDb;·see·the·help287 creating·TxDb·objects·from·custom·data·sources·using·makeTxDb;·see·the·help
Max diff block lines reached; 34/7471 bytes (0.46%) of diff not shown.
522 B
./usr/lib/R/site-library/GenomicFeatures/doc/GenomicFeatures.md
    
Offset 1, 11 lines modifiedOffset 1, 11 lines modified
1 ---1 ---
2 title:·"Making·and·Utilizing·TxDb·Objects"2 title:·"Making·and·Utilizing·TxDb·Objects"
3 author:·"Marc·Carlson,·Patrick·Aboyoun,·Hervé·Pagès,·Seth·Falcon,·Martin·Morgan"3 author:·"Marc·Carlson,·Patrick·Aboyoun,·Hervé·Pagès,·Seth·Falcon,·Martin·Morgan"
4 date:·"Friday,·February·21,·2025"4 date:·"Sunday,·January·21,·2024"
5 package:·GenomicFeatures5 package:·GenomicFeatures
6 output:6 output:
7 ··BiocStyle::html_document:7 ··BiocStyle::html_document:
8 ····df_print:·paged8 ····df_print:·paged
9 ····toc_float:·true9 ····toc_float:·true
10 vignette:·>10 vignette:·>
11 ··%\VignetteIndexEntry{Making·and·Utilizing·TxDb·Objects}11 ··%\VignetteIndexEntry{Making·and·Utilizing·TxDb·Objects}