Skip to main content

bracken

Tags: metagenomics classification taxonomy abundance kraken2 bracken krona sample-scope

Taxonomic classification and abundance estimation.

Uses Kraken2 to classify reads against a taxonomic database, followed by Bracken (Bayesian Reestimation of Abundance with KrakEN) to estimate relative abundances at a specific taxonomic level. It also generates an interactive Krona plot for visualization.

Uses explicit positional record fields for reads:

  • Input: record(meta, r1, r2, se, lr) where each read slot is Path?
Database Required

Requires a compatible Kraken2/Bracken database (tarball).

Inputs

record (
meta: Record,
r1: Path?,
r2: Path?,
se: Path?,
lr: Path?
)
FieldTypeDescription
metaRecordGroovy Record containing sample information
r1Path?Illumina R1 reads (paired-end)
r2Path?Illumina R2 reads (paired-end)
sePath?Single-end Illumina reads
lrPath?Long reads (ONT/PacBio) - not typically used
db: Path
NameTypeDescription
dbPathA compressed tarball containing the Kraken2/Bracken database

Outputs

record (
meta: Record,
tsv: Path,
special_meta: Record,
classified: Set<Path?>,
unclassified: Set<Path?>,
kraken2_report: Path,
kraken2_output: Path?,
bracken_report: Path,
krona: Set<Path?>,
abundances: Path,
classification: Path,
adjusted_abundances: Path,
results: Set<Path>,
logs: Set<Path?>,
nf_logs: Set<Path>,
versions: Set<Path>
)
FieldTypeDescription
metaRecordSample information record
tsvPathTab-delimited summary of Bracken primary and secondary species abundances
special_metaRecordA simplified metadata record for internal use
classifiedSet<Path?>Reads classified to belong to any of the taxa on the Kraken2 database
unclassifiedSet<Path?>Reads not classified to belong to any of the taxa on the Kraken2 database
kraken2_reportPathKraken2 report containing stats about classified and not classified reads
kraken2_outputPath?Kraken2 output file containing the taxonomic classification of each read
bracken_reportPathBracken report containing stats about classified and not classified reads
kronaSet<Path?>Interactive Krona HTML visualization
abundancesPathBracken abundance estimates for each taxon
classificationPathBracken per-read classification details
adjusted_abundancesPathBracken abundance estimates adjusted for unclassified reads
resultsSet<Path>All output files to be published
logsSet<Path?>Optional program specific log files
nf_logsSet<Path>Nextflow-specific log files (e.g. .command.{begin
versionsSet<Path>A YAML formatted file with program versions

Parameters

Kraken2 and Bracken Parameters

ParameterTypeDefaultDescription
--kraken2_dbstringThe a single tarball or path to a Kraken2 formatted database
--kraken2_confidencenumber0.0Confidence score threshold between 0 and 1
--kraken2_use_mpa_stylebooleanfalseFormat report output like Kraken 1's kraken-mpa-report
--kraken2_report_zero_countsbooleanfalseReport counts for ALL taxa, even if counts are zero

Used By

Subworkflows

  • bracken - Estimate species abundance from metagenomic reads.

Workflows

  • bracken - Estimate taxonomic abundance of metagenomic samples.

Citations

If you use this in your analysis, please cite the following.

Source

View source on GitHub

Version

BRACKEN:
- bactopia-teton: 1.1.3