Hello,
I installed bwa-0.6.1 and index human genome like
bwa index -a bwtsw hg19.fa
it generate five files (.amb, .ann, .bwt, .pac, .sa files) but with bwa-0.5.9 there are nine index files (.fai, .rpac, .amb, .ann, .pac, .bwt, .rbwt, .rsa, .sa nine files)
did I miss something in options of bwa index? What should I do to make it right?
Thanks a lot
2 answers
Yes, the index files are different between 0.5.x and 0.6.x. You can read more about the details in this post to the bio-bwa-help mailing list.
The main difference is that the 0.6.x index is 64-bit so that longer genomes can be indexed (>4GB). Also, the forward and reverse stranded indices are in one index. That's why you don't have the reverse files .rpac, .rbwt, and .rsa from 0.6.x. You probably don't have the .fai file because it used one you already generated (this is a guess).
I should add that you can't align reads against indices generated by incompatible versions of bwa (e.g. 0.6.x with 0.5.x indices). In my experience it will crash without a useful error message. A better practice is to run the 0.6.x bwa index with the -6 option that will append .64 to the filename. That way, different versions of the index can coexist without causing trouble, since bwa 0.6.x will look for the .64 indices first.
Edit: You need bwa 0.6.2 for the -6 command. Not sure why you'd want to use the older 0.6.1 version.
In general different versions of a software may create different number of types of files. Don't worry about that, check whether the program works properly.
Most likely there is nothing to worry about.
Log in to answer this question.