Question: ERROR MESSAGE: Fasta index file
0
gravatar for granecious
13 months ago by
granecious0
granecious0 wrote:

Good day

Can someone please assist me with the following. I am new to GATK(3.8), and I want to run the RealignerTargetCreator command according to what is specified on the GATK website.

This is my specific command:

>singularity exec /tools/containers/gatk/gatk-3.8--py36_4.simg java -jar GenomeAnalysisTK.jar \
-T RealignerTargetCreator \
-R ~/Analysis_data/GATK/refs/ref.fa \
-known ~/Analysis_data/GATK/Mills_and_1000G_gold_standard.indels.hg38.vcf \
-known ~/Analysis_data/GATK/Homo_sapiens_assembly38.known_indels.vcf \
-I marked_dup.bam \
-o forIndelRealigner.intervals

but I get the following error message:

> ERROR MESSAGE: Fasta index file /usr/people/sfernol/Analysis_data/GATK/refs/ref.fasta.fai.fai for reference /usr/people/sfernol/Analysis_data/GATK/refs/ref.fasta.fai does not exist.

I read up on similar problems and I tried putting the different reference files in the same location, but i still get the same error.

I used Picard for creating the .dict file and samtools for indexing my reference genome file, so i have those two files and the original fasta file in the same folder.

I am not sure what I am doing wrong, please help?

genome • 840 views
ADD COMMENTlink modified 13 months ago by finswimmer13k • written 13 months ago by granecious0
0
gravatar for Pierre Lindenbaum
13 months ago by
France/Nantes/Institut du Thorax - INSERM UMR1087
Pierre Lindenbaum129k wrote:
samtools faidx  ~/Analysis_data/GATK/refs/ref.fa

https://gatkforums.broadinstitute.org/gatk/discussion/1601/how-can-i-prepare-a-fasta-file-to-use-as-reference

We use the faidx command in samtools to prepare the fasta index file. This file describes byte offsets in the fasta file for each contig, allowing us to compute exactly where a particular reference base at contig:pos is in the fasta file.

ADD COMMENTlink written 13 months ago by Pierre Lindenbaum129k

Hi

I managed to solve my problem. I had to rename my sam indexed file to correspond to my ref.fa, since my file formats were different GATK could not pick up my index file.

I renamed my index file from ref.fasta.fai to ref.fa.fai and it worked.

ADD REPLYlink written 13 months ago by granecious0
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.3.0
Traffic: 1232 users visited in the last hour