Thank you, I index it using bcftools index, but still used the vcf.gz for the script and it worked.
Still learning what these types of files mean, and how the script uses these various types of files.
Appreciate your help!
Hello,
I am attempting to use the af-dist bcftools plugin to detect potential strand issues using the instructions found here: https://samtools.github.io/bcftools/howtos/plugin.af-dist.html
My script:
bcftools annotate -c INFO/AF -a af.vcf.gz DAC14_chr1_hg38_nonduplicates_fix.vcf.gz | bcftools +af-dist | grep ^PROB > DAC14_chr1_hg38_nonduplicates_fix.dist.txt
Error received:
Failed to open DAC14_chr1_hg38_nonduplicates_fix.vcf.gz: could not load index
I checked to confirm that my data is there and it is the correct vcf.gz filetype needed:
fileformat=VCFv4.2
FILTER=<ID=PASS,Description="All filters passed">
fileDate=20210211
What's going wrong here? Tried to search, but no luck... Thank you.
You need to index the file mentioned below:
Failed to open DAC14_chr1_hg38_nonduplicates_fix.vcf.gz: could not load index
If that does not work:
Can you try this additional option?
-t, --tbi
generate TBI-format index for VCF files
Thank you, I index it using bcftools index, but still used the vcf.gz for the script and it worked.
Still learning what these types of files mean, and how the script uses these various types of files.
Appreciate your help!
After indexing your main file, you should still keep your CSI or TBI index files in the same folder. Then you will continue to use vcf.gz files in your next steps. Good luck!
Log in to answer this question.
You should index your VCF file (
bcftools indexLINK) .Index to make it a tbi file? Then should I use the tbi files for this af-dist script? Thanks
Instruction link you posted in original question shows
bcftools index af.vcf.gzin first step. Indexing allows rapid access.I actually did index the af.vcf.gz file upon downloading it from the site.... I also tried to index it again and it said that I already have done so. I don't think this indexing instruction applies to my data file...?