BWA interpretation and Resources
1
0
Entering edit mode
9.1 years ago
zggayk ▴ 10

Hello I am trying to use the Burrows-Wheeler Aligner to align our de novo assembled contigs to a reference genome. I am trying to use the BWA-sw algorithm for this. I have some suspicion because of the output file (in the form of a .sam file) that the alignment did not work properly. Below is a small portion of the file:

@SQ     SN:scaffold356  LN:823
@SQ     SN:scaffold476  LN:7212
@SQ     SN:scaffold211  LN:3330
@SQ     SN:scaffold336  LN:2422
@SQ     SN:scaffold406  LN:17574
@SQ     SN:Scaffold596  LN:5070
@SQ     SN:scaffold151  LN:9921
@SQ     SN:scaffold516  LN:15906
@SQ     SN:scaffold316  LN:9962
@SQ     SN:scaffold321  LN:27663
@SQ     SN:scaffold431  LN:16280
@SQ     SN:scaffold311  LN:47646
@SQ     SN:scaffold601  LN:17621
@SQ     SN:scaffold701  LN:13490
@SQ     SN:scaffold216  LN:82533
@SQ     SN:scaffold726  LN:38736
@SQ     SN:scaffold101  LN:35666
@SQ     SN:scaffold71   LN:42933
@SQ     SN:scaffold186  LN:47996
@SQ     SN:scaffold731  LN:37331
@SQ     SN:Scaffold921  LN:7475
@SQ     SN:scaffold111  LN:31478
@SQ     SN:scaffold846  LN:25557

I used the following to get to this point:

bwa index -p RTLOindx -a bwtsw Gavia_stellata.fa
bwa bwasw RTLOindx test-scaffolds.fa > test-scaffolds.sam

Other than this forum, are there any detailed example scripts for BWA available anywhere? I have looked at several documentation pages for BWA and they were less than revealing to this novice. Supposing I get our reference alignment to work eventually, are there any good tools for visualization of BWA produced .sam or .bam files? I have looked at one called tablet, but was not able to get this to work with a different .bam file. Thank you very much for your help.

Sincerely,
Zach Gayk

alignment • 1.9k views
ADD COMMENT
0
Entering edit mode
9.1 years ago

The first few lines that you posted look like a perfectly valid SAM file, so unless there is another problem, you can proceed to convert to BAM. IGV is a good viewer for BAM files.

ADD COMMENT
0
Entering edit mode

Thank you very much. I got our alignment to display in the IGV. I was skeptical if the .sam file was accurate, because I was having trouble using the samtools flagstat command, but apparently the bwa alignment did work.

I am now going to try to merge our alignments of contigs and raw reads when I figure out how to do so.

Thanks for your help,

Zach

ADD REPLY
1
Entering edit mode

samtools flagstat works on bam file.

ADD REPLY

Login before adding your answer.

Traffic: 1614 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6