Hello!
Budding bioinformaticion here so please bear with me here..
I am trying to run mpileup on a bed file (chrX start stop) that contains SNPs located only in exons. I can run mpileup on a particular region of interest with this command:
samtools mpileup -f hg38.fa -r chrX:1120516-1120517 -s [path to RNAseq bam file]
My question is, what is the best way to go about going through the entire list of SNPs in the bed file? There are roughly 700 SNPs found so it would take too long to do manually. Would I need to make a python script to loop through the file? If so what would that potentially look like and what libraries would I need?
I have some experience with both bash and python so any help or guidance is appreciated!
Welcome to Biostars and thank you for the contribution! Please use the formatting bar (especially the
code
option) to present your post better. You can use backticks for inline code (`text` becomestext
), or select a chunk of text and use the highlighted button to format it as a code block. I've done it for you this time.Okay, thank you! Will do for the future.