Galaxy | Tool Preview

bamCompare (version 3.5.4+galaxy0)
The genome will be divided into bins of the specified size. For each bin, the overlapping number of fragments (or reads) will be reported. If only half a fragment overlaps then this fraction will be reported.
The default is to output the log2ratio between the two samples. The reciprocal ratio returns the negative of the inverse of the ratio if the ratio is less than 0. The resulting values are interpreted as negative fold changes. To output the scaled values from the first or second BAM file, select 'first' or 'second'.
Small number to avoid dividing by zero. You can specify separate values for the pseudocount added to the numerator and denominator by providing two values separated by a space.
Compute an exact scaling factor rather than one based on sampled reads. This is only useful in cases where you are filtering some alignments out AND this are both rare and tend to clump together in the genome. In such cases the region-based sampling employed by deepTools would produce inaccurate scaling factors. Note that this option results in the process taking significantly more time to complete.
This is useful when testing parameters to reduce the time required. The format is chr:start:end, for example "chr10" or "chr10:456700:891000".

What it does

This tool can be used to generate a bigWig or bedGraph file based on two BAM or CRAM files that are compared to each other while being simultaneously normalized for sequencing depth.

To compare the BAM files to each other, the genome is partitioned into bins of equal size, then the number of reads found in each BAM file is counted per bin, and finally a summary value reported.

The tool works in two steps: 1. Scaling : To properly compare samples with different sequencing depth, each bam file can be scaled either using the SES method (proposed in Diaz et al. (2012). "Normalization, bias correction, and peak calling for ChIP-seq". Statistical applications in genetics and molecular biology, 11(3).) or total read count. additionally scaling can be turned off and a per-sample normalization can be used (--normalizeUsing RPKM/CPM/BPM)

  1. Comparison : Two bam files are compared using one of the chosen methods (e.g. add, subtract, mean, log2 ratio etc.)

By default, if reads are from a paired-end sequencing run and reads are properly paired, the fragment length reported in the BAM file is used.

Note: For paired-end sequencing samples, each read mate is treated independently to avoid a bias when a mixture of concordant and discordant pairs are present. This means that _each end_ will be extended to match the fragment length.

/repository/static/images/4fa66b89b58c4662/norm_IGVsnapshot_indFiles.png

Output files

bamCompare produces the same kind of output as bamCoverage. The difference is that you now obtain 1 coverage file that is based on 2 BAM files: a bedGraph or a bigwig file containing the bin location and the resulting comparison values.

Like BAM files, bigWig files are compressed, binary files. If you would like to see the coverage values, choose the bedGraph output. For more information on typical NGS file formats, see our Glossary

/repository/static/images/4fa66b89b58c4662/bamCompare_output.png

For more information on the tools, please visit our help site.

For support or questions please post to Biostars. For bug reports and feature requests please open an issue on github.

This tool is developed by the Bioinformatics and Deep-Sequencing Unit at the Max Planck Institute for Immunobiology and Epigenetics.