Ok-k-mer: Selecting k-mer length ensembles for calculating genomic distance
Abstract
Current methods for computing sequence similarity across large groups of genome sequences tend to do so at the level of k-mers since this is far more efficient than base-by-base alignment. While these methods use default k-mer lengths, recent work shows that the particular choice of k-mer length greatly affects accuracy, and that using multiple values of k can boost accuracy relative to the best single choice of k, particularly when the goal is to estimate genomic distances that reflect true phylogenetic relationships. Here, we introduce Ok-k-mer, a tool to systematically select weighted k-mer length ensembles for pairwise genomic distance estimation, thereby increasing the accuracy of those estimates. Given a phylogenetic tree, Ok-k-mer ranks genome pairs by Jaccard distance across a range of k and uses a progressive search to maximize the Spearman correlation, {rho}, between weighted-average k-mer ranks and branch distances. Across eight Genome Taxonomy Database datasets, Ok-k-mer ensembles improved correlation over standard default k-mer lengths. In the Chlamydiales taxonomy, a three-length ensemble k=(9,17,22) achieved a 23.9% relative improvement over the best single length (k=20) and a 36.7% improvement over a commonly used default of 31-mers. We demonstrate that Ok-k-mer k-mer length ensembles remain stable (i.e. lengths and weights change only moderately) under genome subsampling within a taxonomy but vary across datasets. Ok-k-mer can annotate all subtrees of a phylogeny, which reveals distinct patterns of ensembles reflecting potential differences in genome evolution. Ok-k-mer provides a framework for moving beyond a "one-k-fits-all" k-mer analysis, improving genomic distance estimation in the era of massive-scale genomics.
02 /Specification & Classification
Click any tag to browse matching papers- Assay
- Research Focus
- Approach
Reproducibility ledger
Nobody has reported trying to reproduce this paper yet. Did you replicate an experiment or run the code? Your report saves the next lab a week.
Sign in to file a reproducibility report.
Related papers
- Kmer-db: instant evolutionary distance estimation
Sebastian Deorowicz, Adam Gudyś, … Agnieszka Danek·BioinformaticsPeer-reviewed·Jul 7, 2018
- OptiK: An Entropy-Driven Framework for Optimal k-mer Size Selection for Bacterial Genomics
AJ Gutierrez-Escobar·bioRxiv·May 21, 2025
- A k-mer-based maximum likelihood method for estimating distances of reads to genomes enables genome-wide phylogenetic placement.
Ali Osman Berk Şapcı, Siavash Mirarab·Genome biologyPeer-reviewed·Feb 21, 2026
- The number of k-mer matches between two DNA sequences as a function of k and applications to estimate phylogenetic distances
Sophie Röhling, Burkhard Morgenstern·bioRxiv·Nov 18, 2019
- KmerAperture: Retaining k-mer synteny for alignment-free extraction of core and accessory differences between bacterial genomes
Matthew Moore, Mirjam Laager, … Xavier Didelot·PLoS GeneticsPeer-reviewed·Apr 29, 2024
- SeqDistK: a Novel Tool for Alignment-free Phylogenetic Analysis
Xuemei Liu, Wen Li, … Li Charlie Xia·bioRxiv·Aug 16, 2021