Kraken 2 and MetaPhlAn both estimate which organisms are present in a metagenome, but they use different evidence. Kraken 2 classifies reads by exact k-mer matches against a reference database; MetaPhlAn uses a set of marker genes to estimate relative abundance. The choice changes both the output and the kind of community you can detect.
What each approach is
Kraken 2
Kraken 2 builds a compact hash-based index of k-mers from reference genomes and assigns each read to the lowest common ancestor of its matches. It reports per-read labels and can be combined with a abundance estimator to produce taxon counts. Its results depend heavily on the reference database and on how unknown reads are handled.
MetaPhlAn
MetaPhlAn uses clade-specific marker genes and a reference database of marker sequences to estimate the relative abundance of taxa. Because it targets markers rather than all genomic k-mers, it can profile known taxa from a smaller database, but it does not describe functions or organisms absent from its marker set.
How they differ
| Aspect | Kraken 2 | MetaPhlAn |
|---|---|---|
| What it is | A k-mer based read classifier with a lowest-common-ancestor assignment. | A marker-gene based taxonomic profiler. |
| Typical use | Community profiling, contamination checks and read-level taxonomic assignment. | Relative abundance profiles of known bacteria, archaea and eukaryotes. |
| Database | A reference genome database that must be built and maintained. | A curated marker-gene database distributed with the tool. |
| Output | Per-read labels and taxon counts, with optional reports. | Relative abundances at species and higher levels. |
| Limits | Unknown organisms are forced into the nearest reference or left unclassified. | Only taxa represented in the marker set can be detected. |
| When to choose | You need read-level assignments or want to inspect unclassified reads. | You need a compact relative-abundance profile of known taxa. |
In practice
Kraken 2 classifies individual reads using exact k-mer matches against a reference database, then reports counts or estimated abundances. It can be very fast, but the result depends heavily on the database and on the confidence threshold. A read can be assigned to a taxon because of a shared k-mer. Low-complexity or host reads can inflate false assignments. MetaPhlAn uses marker genes to profile taxa and estimate relative abundance. It is less dependent on whole-genome coverage in the database, but it can only report taxa for which markers exist.
The two methods answer slightly different questions. If the study needs to detect any readable organism, including viruses or poorly represented groups, a k-mer classifier with a carefully chosen database may be appropriate. If the goal is a comparable taxonomic profile across human microbiome samples, a marker-gene method is often easier to interpret. Either way, remove host reads, check negative controls and report the database version and parameters. Relative abundance is not an absolute count, and a missing taxon is not proof of absence.
Abundance estimates are not directly comparable across methods. A k-mer classifier may report a read count, while a marker-gene method reports a relative abundance derived from marker coverage. Convert both to a common unit only if the assumptions are stated. Check unclassified reads, host contamination and negative controls. If a taxon is central to the conclusion, confirm it with a targeted assay or an independent marker rather than relying on one profiler.
How to decide
1. Do you need to describe unknown organisms?
A marker-based method cannot report a taxon that is not in its reference set. A k-mer classifier can at least show that reads are unclassified, which is useful when the community is poorly characterised.
2. Do you need functions as well as taxa?
Neither tool directly measures gene function. If function matters, plan a separate functional annotation step and remember that taxonomic composition and functional potential are not the same.
3. How will you handle unclassified reads?
The unclassified fraction is a result, not a nuisance. Report it and inspect it. A large fraction can indicate a novel community, contamination, host reads or a database that does not match the sample.
4. What database and version will you use?
Taxonomic profiles change when the database changes. Record the database name, release and any custom additions, and avoid comparing profiles generated with different databases as if they were the same measurement.
What this comparison does not settle
Relative abundances from both tools depend on the reference database and on the DNA extraction and sequencing method. Neither method proves that an organism is alive or active, and neither gives absolute cell counts without an independent measurement.
What to record
Record the database and release, the classifier settings, the read preprocessing, the unclassified fraction and the abundance estimation method. Keep the per-read output if you may need to reanalyse the community.
Sources
Related pages
Related reading
Last reviewed: . This is an editorial summary, not a benchmark. If a tool or method has changed, tell us and we will update the page.