Source-linked AI summary
Fast and accurate alignment of long bisulfite-seq reads
Brent S. Pedersen, Kenneth Eyring, Subhajyoti De, Ivana V. Yang, David A. Schwartz
TL;DR
Existing bisulfite-sequencing aligners were optimized for shorter reads, motivating a longer-read comparison and a new mapper. The study benchmarks current tools on targeted and simulated data and finds bwa-meth accurate without trimming, fast, and downstream-compatible. Its evidence is bounded by an inbred mouse strain with few polymorphisms and indel-free simulated reads.
Problem
Existing BS-Seq mapper comparisons were limited by shorter reads and by incomplete ground truth or simulation assumptions.
Method
The study compares current BS-Seq aligners using targeted real reads and simulated reads, with and without quality trimming, including a BWA mem-based mapper.
Results
bwa-meth is very accurate without quality trimming, outperforms all aligners on simulated data, and produces fast, downstream-usable sorted BAM output.
Takeaways & Limitations
bwa-meth offers accurate BS-Seq alignment without trimming while reducing intermediate-read storage and producing output usable by downstream tools.
Takeaways & Limitations
The comparisons use an inbred mouse strain with few polymorphisms, and the simulated reads contain no insertions or deletions.
Abstract
from arXiv · showhide
Summary: Longer sequencing reads, with at least 200 bases per template are now common. While traditional aligners have adopted new strategies to improve the mapping of longer reads, aligners specific to bisulfite-sequencing were optimized when much shorter reads were the norm. We sought to perform the first comparison using longer reads to determine which aligners were most accurate and efficient and to evaluate a novel software tool, bwa-meth, built on a traditional mapper that supports insertions, deletions and clipped alignments. We gauge accuracy by comparing the number of on and off-target reads from a targeted sequencing project and by simulations. Availability and Implementation: The benchmarking scripts and the bwa-meth software are available at https://github/com/brentp/bwa-meth/ under the MIT License.
Summary:
The paper compares existing bisulfite-sequencing mappers for longer paired-end reads and introduces bwa-meth to address limitations in accuracy evaluation and workflow usability. Its evaluation combines targeted real reads with simulated reads.
- Existing BS-Seq comparisons used real or simulated reads but were limited by incomplete ground truth or simulation assumptions.
- The study compares four-base and three-base BS-Seq aligners, including Last, GSNAP, BSMAP, BSmooth, Bison, Bismark, and bwa-meth.
- The comparison uses 100-base paired-end reads, longer than in previous comparisons, to test whether read length changes aligner performance.
- bwa-meth addresses temporary files, quality trimming, memory, runtime, and downstream compatibility by supporting indels and local alignment while streaming reads and alignments.
- Accuracy is evaluated with targeted mouse capture reads using on-target versus off-target counts and with simulated indel-free reads mapped to mm10.
3 METHODS
The benchmark evaluates real and simulated mouse reads with and without quality trimming, using on-target and off-target reads to compare accuracy and resource demands. bwa-meth remains accurate without trimming, while aligner behavior differs across trimming and mapping strategies.
- 3 METHODS: Real and simulated reads were aligned both as-is and quality-trimmed, using software versions and selected parameters reported as reasonable representations.
- 4.1 Accuracy: Figure 1 plots untrimmed paired-end 100-base reads on target against off target, with mapping-quality cutoffs shown for aligners that report them.
- 3 METHODS: Reads were considered on-target when within 1001 bases of a target region.
- 3 METHODS: bwa-meth outputs sorted, indexed BAM files usable by coordinate-sorted and read-group-dependent downstream tools, and can additionally restrict alignments to a targeted strand.
- 4.1 Accuracy: bwa-meth and Last align the most real reads on target with low off-target percentages, while Last provides better off-target control; trimming leaves Last, GSNAP, and bwa-meth relatively unaffected.
- 4.1 Accuracy: Bowtie-backed aligners, including Bismark, perform better with trimmed reads, whereas bwa-meth achieves nearly identical accuracy without read trimming.
- 4.1 Accuracy: bwa-meth outperforms all tested aligners on simulated data, while Last requires about 10GB of shared memory per process.
5 CONCLUSION
Using simulated and targeted capture reads, the paper finds bwa-meth highly accurate without quality trimming, fast, and immediately compatible with downstream tools. The conclusion emphasizes reduced intermediate storage and practical usability.
- The evaluation combines simulated reads with reads from a CpG-rich targeted capture method.
- bwa-meth is very accurate without quality trimming, while global-alignment methods benefit more from trimming and may require another converted-read copy.
- bwa-meth is fast and outputs sorted BAM alignments immediately usable by downstream tools.
Supplemental Information
The reported advantages of bwa-meth span workflow simplicity, speed, storage, output compatibility, strand-specific alignment, and accuracy. The tool uses BWA capabilities to retain accuracy without trimming while supporting targeted-strand analysis.
- A single script indexes the reference, aligns reads, and tabulates methylation, with default parameters reported to work well.
- bwa-meth can use all available CPUs on one machine through BWA's parallelization.
- Reads are streamed directly to the aligner without being written to disk, avoiding the 3X raw-sequence storage requirement associated with trimming and conversion.
- The resulting BAM contains sorted and indexed alignments, mapping qualities, flags, read-groups, and headers accepted by Picard and GATK.
- For reverse-strand capture methods, bwa-meth supports considering only the original bottom strand, reducing off-target reads.
- bwa-meth consistently performs as the best or among the best for specificity and sensitivity, according to the authors.
- Local alignment contributes to bwa-meth's accuracy without trimming, avoiding the additional storage and processing time trimming can require.
3 Comparison On Real Data
Real paired-end data compare seven aligners using on-target versus off-target read percentages, with additional trimmed-read and resource analyses.
- Real-data comparison: Seven aligners were compared on real data, with results summarized for untrimmed and trimmed 100-base paired-end reads.The resource table reports CPU time and memory for the real dataset.
- Untrimmed reads: Figure 1 measures the percentage of primary mapped reads on target against the percentage off target.Aligners reporting mapping quality span each quality cutoff.
- Trimmed reads: Trimming was evaluated separately, with aligned-read percentages reported relative to the original untrimmed read count.The analysis focuses on overall mapping rate after trimming.
- Resources: On real data, bwa used 490.37 CPU minutes and 17.70 GB memory without trimming, versus 413.69 minutes and 17.65 GB with trimming.These are the corresponding bwa rows in the real-data resource table.
4 Comparison On Simulated Data
Simulated 100-base paired-end reads were benchmarked with errors and after quality trimming, using known mouse and E. coli origins to distinguish on- and off-target alignments.
- Simulation design: Paired-end 100-base reads were simulated with 95% from mm10 and 5% from E. coli, then aligned using parameters listed in Supplemental Table 1.E. coli reads aligning to mm10 were classified as off target.
- Simulation design: The simulations used 98% unmethylated E. coli reads, a 1% per-base error rate, and no insertions or deletions.These assumptions define the error-containing simulation setting.
- Results: Bwa-meth outperformed all aligners on simulated data.The comparison included simulations with errors and without errors, with trimmed and untrimmed analyses shown separately.
- Trimmed simulations: Trimmed simulations remove read pairs when either read has low quality, while mapping percentages remain relative to the original untrimmed mm10 count.This preserves an overall mapping-rate denominator.
- Resources: For simulated data with a 1% error rate, untrimmed bwa required 145.56 CPU minutes and 19.40 GB memory.The table also reports separate resource values for trimmed runs and other aligners.
5 Comparison On Error-Free Simulated Data
Error-free paired-end simulations isolate alignment behavior without contamination or sequencing errors, with trimmed and untrimmed mapping analyses compared.
- Simulation design: Error-free 100-base paired-end reads were simulated without contamination or errors.The simulation otherwise followed the preceding setup.
- Untrimmed reads: Figure 5 compares the percentages of error-free simulated reads on target and off target for each aligner.Mapping-quality aligners appear as connected dots across quality cutoffs.
- Trimmed reads: Trimmed error-free simulations exclude read pairs containing a low-quality read and retain the original untrimmed mm10 count as denominator.This reports overall mapping rate rather than only retained pairs.
- Resources: For error-free simulations, untrimmed bwa used 170.66 CPU minutes and 21.11 GB memory.The resource table lists separate values for each aligner and trimming condition.
6 Improved Accuracy for Stranded Capture Experiments
The stranded-capture analysis reduces off-target reads by restricting bwa-meth alignments to the strand targeted by the capture protocol.
- Strand restriction: Considering only reads mapping to the capture-targeted strand reduces the percentage of off-target reads.The analysis is specific to a capture protocol targeting one strand.
- Implementation: Bwa-meth supports strand-specific filtering, which the authors state was not currently supported by the other aligners considered.The implementation marks reads mapping to a selected strand as failed using the set-as-failed flag.
- Trimming: Quality trimming improves accuracy for most aligners, but the difference is very small for bwa-meth.This comparison concerns the mapping-accuracy evaluation rather than strand restriction alone.
8 bwa-meth Installation And Requirements
bwa-meth requires samtools and the Python library toolshed, while Bis-SNP and cn.mops support downstream methylation tabulation and CNV detection.
- bwa-meth depends on samtools and the Python library toolshed.Samtools is commonly available as a C library, while toolshed can be installed from the project directory.
- Bis-SNP is required for tabulating methylation by CpG.
- The R package cn.mops is required for CNV detection from BS-Seq data.
9 Additional Features
bwa-meth produces validation-compatible BAM files and provides tools for methylation-bias assessment and simplified downstream tabulation through Bis-SNP.
- Bwa-meth and GSNAP are the only compared programs producing BAM files that pass Picard ValidateSam without errors.Bwa-meth outputs customizable read-groups by default, whereas other aligners generally omit them or report incomplete pairing information.
- bwa-meth can calculate methylation-estimate bias by read location and generate a bias plot.The plot identifies read bases that should be excluded from methylation calls.
- Bwa-meth defers methylation-score tabulation to Bis-SNP through a simplified interface.The interface passes arguments to Bis-SNP, including trimming the first and last three bases to avoid bias.
- A full real-data usage example is available in the project repository.