running an application chromosome by chromosome
Dear all,
Please could you advise where could I find some TEMPLATE CODE that will allow running MUTECT (or any other program) on each BAM file associated with each chromosome (or chromosome fragment), instead of running it on a BAM file for all chromosomes ;)?
Thanks,
bogdan
• 2,059 views
•
link
1 answer
If I understand correctly you're essentially trying to split 1 BAM file into several BAM files by chromosome? This can be pretty easily done by using the bamtools -split function as referenced in this topic: How To Split A Bam File By Chromosome
This code will generate individual BAM files for all the chromosomes.
bamtools split -in file.bam -reference
These BAM files can then be fed into your program of choice.
• 0 views
•
link
Log in to answer this question.