DAMAGE-PATTERNS(1)

NAME
damage-patterns -- plot or calculate substitution patterns

SYNPOSIS
damage-patterns [option...] file ...

DESCRIPTION
damage-patterns reads BAM or SAM files containing alignments, accumulates statistics about substitution patterns and prints them in table form or creates a colorful plot. Six plots are created: the base composition around the 5' and the 3' end, all possible substitutions near the 5' and the 3' end, and all possible substitutions at CpG motivs near the 5' and the 3'end. The base composition is that of the reference. Substitutions use the position in the read as coordinate (in case indels make a difference). The values are plotted as lines and 95% confidence intervals as shaded regions. Sometimes plots are skipped because of a lack of that particular kind of data.

OPTIONS

  Common Options

-V, --version
    Output the version number and exit.

-h, --help
    Display usage information and exit.

  General Options

-o, --output PATH
    Sets the prefix of output files to PATH. The default is './', i.e. output goes to the current directory and no prefix is prepended.

--leeHom
    To compensate for the fact that the primary author of leeHom is a moron, this option causes damage-patterns to pretend that every unpaired read is the result of adapter trimming. If you mutilated your data by misguidedly running leeHom, you likely want to set this option.

-C, --context NUM
    Displays the base composition for an additional NUM bases of context around either end of the aligned query. Note that context requires that a genome file is given.

-G, --genome FILE
    Declares that the reference genome is available in FILE in 2bit format. If a genome is given, context becomes available and the input does not need to have a valid MD field.

-x, --xrange NUM
    Sets the range of the x axis to [0..NUM]. Plots get the appropriate scale, tables contain the appropriate lines. The default is 80.

-f, --fractions
    Causes numbers in tables to be shown as common fractions (instead of decimal fractions) where applicable. Common fractions allow an estimate of confidence intervals, decimal fractions don't.

  Graphical Only Options
The following options are only applicable if damage-patterns was compiled with support for plotting. A version without plotting capability will not accept these and supports only the 'txt' output format.

-y, --yrange NUM
    Sets the range of the y axis of substitution plots to [0..NUM]. Note that NUM is a floating point number, not a percentage. The default is to adjust automatically.

-Y, --yrange1 NUM
    Sets the range of the y axis for base composition plots to [0.25-NUM..0.25+NUM], that is, symmetrical around one quarter. The default is to adjust automatically.

-t, --title TEXT
    Sets the title of this data set to TEXT. Plots will mention the data set title in their heading.

-F, --format FORMAT
    Sets the output format of plots to FORMAT. Legal values are svg, ps, pdf, png and txt. The txt format will not actually produce a plot, but a table with the values that would have been plotted. The default is svg.

-W, --width NUM
    Sets the width of plots to NUM pixels.

-H, --height NUM
    Sets the height of plots to NUM pixels.

FILES

BAM is the most standard format for aligned reads, chiefly from high throughput sequencing platforms. If possible, use Bam as input. See http://samtools.github.io for more information. damage-patterns will read the reference sequence from the 2bit file if given. Else it will reconstruct the reference from the MD field. Bam files with strangely miscoded MD fields have been spotted in the wild. If you get errors about inconsistent MD fields, either fix them by running samtools calmd or simply supply a 2bit file.

SAM is effectively the text form of BAM, and is pretty much equivalent to it, but bloated. Use BAM if you can, but SAM is fine if and only if it saves a needless conversion step.

2bit
    is a compact format for genomes used by BLAT and other software by UCSC. See https://genome.ucsc.edu/goldenpath/help/blatSpec.html for details. (The alternative to 2bit used by samtools would be indexed FastA. Clearly, 2bit is superior in every conceivable way.)

AUTHOR
Written by Udo Stenzel <udo_stenzel@eva.mpg.de>.