Question: BWA error [bns_restore_core] Parse error reading ref.fa.amb- After and despite removing spaces from my reference hg19
0
gravatar for ngs_star
20 months ago by
ngs_star0
USA
ngs_star0 wrote:

I have read various threads here that suggested that the "Parse error reading exome.fasta.amb" is due to the whitespaces in my reference file hg19.fa

Basically, I run and get $ bwa mem ref.fa read1.fq read2.fq > aln-pe.sam

BWA error [bns_restore_core] Parse error reading ref.fa.amb

I think I have removed whitespaces using:

tr -d ' ' < in.fa >out.fa ## remove all spaces

also tried without success: sed 's/ *$//g' in.fasta > out.fasta

I am trying to align/map exome.fastq to indexed hg19(ref.fa). I have read that bwa mem have issues with whitespaces but I am stuck here. Did anyone have the same issue and got it solved? Is there a workaround? Thanks.

alignment • 1.0k views
ADD COMMENTlink modified 20 months ago • written 20 months ago by ngs_star0

You should download your hg19.fa and re-index it. I never had to remove space in hg19.fa ...

ADD REPLYlink written 20 months ago by Titus900

I had downloaded the hg19 tar file from ucsc, untarred it, concatenated every fasta files into one file (ref_hg19.fa). Do you think concatenating every files would cause the problem? Should I concatenate only chr1-22, X, Y, M?

How about should I download indexed hg19 file from iGenome?

Where did you obtain your hg19 and index it?

Thanks.

ADD REPLYlink written 20 months ago by ngs_star0

Should I concatenate only chr1-22, X, Y, M?

What did concatenated plus that ? Sure you have to concatenated only that ! How did syou concatenated it by the way ?

I get my hg19 on ucsc like downloading ref chromosome by chromosome and concatenated them

ADD REPLYlink modified 20 months ago • written 20 months ago by Titus900
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: 2555 users visited in the last hour