From Genome Analysis Wiki
Jump to navigationJump to search
266 bytes added
, 16:12, 5 April 2012
Line 3: |
Line 3: |
| == Generating GLF Files == | | == Generating GLF Files == |
| | | |
− | GLF files can be generated using [http://samtools.sourceforge.net samtools]. To generate a GLF file, use the <code>samtools pileup -g</code> command, which requires a sorted [[SAM]] file and a [[FASTA]] file with the human genome reference sequence. | + | GLF files can be generated using [https://github.com/statgen/samtools-0.1.7a-hybrid samtools-hybrid]. To generate a GLF file, use the <code>samtools-hybrid pileup -g</code> command, which requires a sorted [[SAM]] file and a [[FASTA]] file with the human genome reference sequence. |
| | | |
− | samtools pileup -g -f human_b36_male.fa.gz NA19240.SLX.maq.bam > NA19240.SLX.maq.glf | + | samtools-hybrid pileup -g -f human_b36_male.fa.gz NA19240.SLX.maq.bam > NA19240.SLX.maq.glf |
| + | |
| + | NOTE: Newer versions of samtools do not have the pileup command and do not generate glf files. samtools-hybrid is a version that still supports those operations but also has the updated BAQ logic. |
| | | |
| === Generating GLF Files for a Specific Region === | | === Generating GLF Files for a Specific Region === |
| | | |
− | Sometimes, you want to generate a GLF file for a specific chromosome region. This can be accomplished by first using <code>samtools view</code> to extract reads for a specific region from a [[SAM]] or [[BAM]] file and then using <code>samtools pileup -g</code> to generate the GLF file using the selected reads as input. Here is an example: | + | Sometimes, you want to generate a GLF file for a specific chromosome region. This can be accomplished by first using <code>samtools-hybrid view</code> to extract reads for a specific region from a [[SAM]] or [[BAM]] file and then using <code>samtools-hybrid pileup -g</code> to generate the GLF file using the selected reads as input. Here is an example: |
| | | |
− | samtools view -u NA19240.SLX.maq.bam chr20:10000000-20000000 | samtools pileup -g -f human_b36_male.fa.gz - > NA19240.SLX.chr20_region.glf | + | samtools-hybrid view -u NA19240.SLX.maq.bam chr20:10000000-20000000 | samtools-hybrid pileup -g -f human_b36_male.fa.gz - > NA19240.SLX.chr20_region.glf |
| | | |
| == File Format == | | == File Format == |