Changes

From Genome Analysis Wiki
Jump to navigationJump to search
2,045 bytes added ,  14:06, 6 January 2014
no edit summary
Line 1: Line 1: −
== Polish BAM ==
+
= Overview of the <code>polishBam</code> function of <code>bamUtil</code> =
The <code>polishBam</code> program is released as part of the StatGen Library & Tools download.
+
The <code>polishBam</code> option on the [[bamUtil]] executable adds/updates header lines & adds the RG tag to each record.
   −
<code>polishBam</code> trims the end of reads in a SAM/BAM file, changing read ends to ‘N’ and quality to ‘!’.
+
= Usage =
 +
./bam polishBam (options) --in <inBamFile> --out <outBamFile>
   −
 
+
= Parameters =
=== Parameters ===
   
<pre>
 
<pre>
 
   Required parameters:  
 
   Required parameters:  
Line 22: Line 22:  
         --checkSQ : check the consistency of SQ tags (SN and LN) with existing header lines. Must be used with --fasta option
 
         --checkSQ : check the consistency of SQ tags (SN and LN) with existing header lines. Must be used with --fasta option
 
</pre>
 
</pre>
 +
{{PhoneHomeParamDesc}}
 +
 +
== Required Parameters ==
 +
{{InBAMInputFile}}
 +
{{OutBAMOutputFile}}
 +
 +
== Optional Parameters ==
 +
=== Verbose (<code>--verbose</code>) ===
 +
Use <code>--verbose</code> to turn on verbose mode.
 +
 +
=== Specify Log Filename (<code>--log</code>) ===
 +
Use <code>--log</code> followed by the log filename to specify the log filename.  Default is the output file basename with a <code>.log</code> extension
 +
 +
=== Add the HD Header (<code>--HD</code>) ===
 +
Use <code>--HD</code> followed by the HD header line to add a HD header.  Be sure to include "@HD" in the line you specify.
 +
 +
=== Add the RG Header (<code>--RG</code>) ===
 +
Use <code>--RG</code> followed by the RG header line to add a RG header.  Be sure to include "@RG" in the line you specify.
 +
 +
=== Add the PG Header (<code>--PG</code>) ===
 +
Use <code>--PG</code> followed by the PG header line to add a PG header.  Be sure to include "@PG" in the line you specify.
 +
 +
=== Add MD5 and UR tags to SQ Headers (<code>--fasta</code>) ===
 +
Use <code>--fasta</code> followed by the fasta reference file name to compute MD5sums and update SQ tags with the M5 & UR values.  Use the [[#Add the UR tag to SQ Headers (--UR)|<code>--UR</code>]] option to specify a different UR value.
 +
 +
=== Add the AS tag to SQ Headers (<code>--AS</code>) ===
 +
Use <code>--AS</code> followed by the genome assembly identify to add the AS tag to the SQ Headers.
 +
 +
=== Add the UR tag to SQ Headers (<code>--UR</code>) ===
 +
Use <code>--UR</code> followed by the URI of the sequence to add the UR tag to the SQ Headers.
   −
=== Usage ===
+
The UR header will be automatically added with the [[#Add MD5 and UR tags to SQ Headers (--fasta)|<code>--fasta</code>]] option, so if [[#Add MD5 and UR tags to SQ Headers (--fasta)|<code>--fasta</code>]] is used, <code>--UR</code> only needs to be specified if it is different from [[#Add MD5 and UR tags to SQ Headers (--fasta)|<code>--fasta</code>]].
polishBAM (options) --in <inBamFile> --out <outBamFile>
      +
=== Add the SP tag to SQ Headers (<code>--SP</code>) ===
 +
Use <code>--SP</code> followed by the species to add the SP tag to the SQ Headers.
   −
=== Return Value ===
+
{{PhoneHomeParameters}}
Returns 0.
     −
=== Example ===
+
= Return Value =
 +
Returns 0 on success, non-0 on failure.
 +
 
 +
= Example =
 
Command:
 
Command:
 
<pre>
 
<pre>
../../bin/polishBam  --in testFiles/sortedSam.sam --out results/updatedSam.sam --log results/updated.log --checkSQ --fasta testFiles/testFasta.fa --AS my37 --UR testFasta.fa --RG "@RG ID:UM0037:1 SM:Sample2 LB:lb2 PU:mypu CN:UMCORE DT:2010-11-01 PL:ILLUMINA" --PG "@PG ID:polish VN:0.0.1" --SP new --HD "@HD VN:1.0 SO:coordinate GO:none"
+
./bam polishBam  --in testFiles/sortedSam.sam --out results/updatedSam.sam --log results/updated.log --checkSQ --fasta testFiles/testFasta.fa --AS my37 --UR testFasta.fa --RG "@RG ID:UM0037:1 SM:Sample2 LB:lb2 PU:mypu CN:UMCORE DT:2010-11-01 PL:ILLUMINA" --PG "@PG ID:polish VN:0.0.1" --SP new --HD "@HD VN:1.0 SO:coordinate GO:none"
 
</pre>
 
</pre>
   Line 118: Line 151:  
</pre>
 
</pre>
    +
 +
[[Category:BamUtil|polishBam]]
 +
[[Category:BAM Software]]
 
[[Category:Software]]
 
[[Category:Software]]
[[Category:StatGen Download]]
  −
[[Category:BAM Software]]
 

Navigation menu