# Tag Info

## Hot answers tagged bwa

14 votes
Accepted

### Meaning of BWA-MEM MAPQ scores

First of all, if you want to understand mapping quality (mapQ), ignore RNA-seq mappers. They often produce misleading mapQ because mapQ is not important to RNA-seq anyway. Strictly speaking, you have ...
• 5,645
13 votes
Accepted

### Obtaining uniquely mapped reads from BWA mem alignment

To exclude all possible multi-mapped reads from a BWA-mapped BAM file, it looks like you need to use grep on the uncompressed SAM fields: ...
• 11.5k
12 votes

### Difference between BWA-backtrack and BWA-MEM

TL;DR: BWA-backtrack is based on backtracking. This approach is appropriate only when the dissimilarity between the reads and the reference is low, or when you want to find all best hits or enumerate ...
• 1,859
11 votes
Accepted

### Library for computing BWT-based alignments

First, let us remark that there exist several hundred read mappers, most of which have been even published (see, e.g., pages 25-29 of this thesis). Developing a new mapper probably makes sense only as ...
• 1,859
9 votes

### Library for computing BWT-based alignments

BWA-MEM can be used as a library. File bwa/example.c shows the basic functionality for single-end mapping. It should give identical mapping to the bwa-mem command line. Header bwa/bwamem.h contains ...
• 5,645
9 votes

### Difference between BWA-backtrack and BWA-MEM

To quote the Introduction to BWA on sourceforge: BWA is a software package for mapping low-divergent sequences against a large reference genome, such as the ...
• 573
8 votes
Accepted

### Why most aligners do not output the "X" CIGAR operation?

The SAM format originally had only M, I, D, N, S, H, and P CIGAR operators. See the original SAM specification (if you can view Apple Pages documents) and Table 1 in The Sequence Alignment/Map format ...
7 votes
Accepted

• 151
4 votes

### Library for computing BWT-based alignments

SeqAn supports BWT tables for use with their parametrisable alignment algorithms. To use it, follow the general outline for building a SeqAn short-read aligner, and use the ...
• 4,735
4 votes
Accepted

### What is the correct way to map Hi-C data with bwa mem?

See here, in particular slide #10 from the tutorial: bwa mem -5SPM ref.fa read1.fq read2.fq > out.sam Here, -SP disables ...
• 5,645
4 votes

### Determining Read Groups

Usually it doesn't actually matter, but if you want it to be very correct: ...
• 19.3k
3 votes

### How does the BWA-MEM algorithm assign its mapping qualities?

Yes, there bwa-mem was published as a preprint BWA-MEM’s seed extension differs from the standard seed extension in two aspects. Firstly, suppose at a certain extension step we come to reference ...
• 5,287
3 votes
Accepted

### How to read .bwt file .sa file?

In the bwa source code, file bwt.{c,h} implement basic operations on .bwt and .sa files. They depend on utils.{c,h}, but you can create a fake utils.h to cut this dependency as is shown below. Then ...
• 5,645
3 votes
Accepted

### Interpreting 0x200 flag in bwa-mem alignments

bwa mem is using exactly the same meaning of the 0x200 flag as every other program, including picard. Don't blindly assume that that entry in the header file ...
• 19.3k
3 votes

### How to map reads shorter than 32bp with minimap2?

Minimap2 doesn't work well with 32bp reads by design. Older mappers like bowtie1 and bwa-aln will be better.
• 5,645
3 votes

### samtools view: writing to standard output failed: Broken pipe

[W::sam_read1] Parse error at line 1 samtools sort: truncated file. Aborting SAMtools sort has been unable to parse its input, which it thought was SAM (mostly ...
3 votes
Accepted

### Error with BWA Mem input having multiple fastq files using cat and process substitution

You are correct that the concatenation of input read files will confuse BWA. BWA depends on the input reads being in the same order in R1 and R2 files for paired-end alignment. From bwa docs: ...
• 2,547

Only top scored, non community-wiki answers of a minimum length are eligible