New to this, and I'm trying to work through our pipeline. I am having difficulty extracting my regions of interest from my merged VCF file. The code is correct, however, I get an error that I can only extract one chr at a time. Wondering if there is something I can do to this to make it extract multiple at once, or if I can use something else.
Note: do not have an available bed file, I have a .txt file with these regions in it. Also, I ran this script with just one chr, and it worked. (Which is how I know it's correct).
Code (imagine this with multiple chr regions to extract):
for FILE in XXX do vcftools --gzvcf $FILE --chr chr8 --from-bp 89933325 --to-bp 90003238 --out output --recode --recode-INFO-all done