Generate K-mers in Seqqio: Choose k, Step Size, Coordinates, and Ambiguity Rules

Extract every eligible fixed-length window from DNA, RNA, or protein, preserve repeated occurrences and coordinates, and understand how step and ambiguity change output.

A k-mer is a substring of length k. If a normalized record has length n, Seqqio examines starts 0, step, 2 times step, and so on while a complete k-symbol window still fits. The candidate count is floor((n - k) / step) + 1 when n is at least k, otherwise zero. This explicit occurrence model is recorded as Seqqio-KmerGenerator-v1.

Set molecule, k, step, and ambiguity policy

Open K-mer Generator. Choose DNA, RNA, or protein rather than asking the app to guess an overlapping alphabet. Set k from 1 to 4,096 and step from 1 to 10,000,000. Choose Skip windows with ambiguity for concrete emitted strings, or retain literal ambiguity codes when they are meaningful to the downstream task. Paste one sequence or load an ordered FASTA batch, then select Generate k-mers.

How k and step alter candidate windows
SettingEffectExample use
k = 3, step = 1Every complete overlapping 3-merInspect local composition with maximum positional coverage
k = 3, step = 3Non-overlapping complete windows from the first basePartition a chosen frame-like offset without translation
Step less than kOverlapping windowsDense feature extraction
Step greater than kGaps between sampled windowsReduce occurrence count for a sampling workflow
n less than kZero candidates, not an errorKeep short valid records visible in batch output

Reproduce coordinates across an ambiguous base

Enter ACGNACGT as DNA, set k to 3, step to 1, and choose to skip ambiguity. Eight bases permit six candidate starts. The current Seqqio 0.1.0 Rust engine emitted three windows and skipped three because they contained N.

Executed K-mer Generator result
Emitted ordinalCoordinatesSequence
11-3ACG
25-7ACG
36-8CGT

The repeated ACG is retained twice because it occurred at two coordinate intervals. Candidate starts 2, 3, and 4 were skipped, but the later coordinates did not shift. If literal ambiguity were retained, all six windows would be emitted: ACG, CGN, GNA, NAC, ACG, and CGT. A gap or protein stop is always a barrier and is never deleted to create a window across it.

Separate extraction from counting and canonicalization

Many downstream tools use the same word “k-mer” for a different data product. The GATK PathSeqBuildKmers documentation, for example, describes scanning a reference and storing k-mers in a set, with configurable spacing. Seqqio instead returns occurrence-level rows: two identical strings at different positions remain two rows.

The original Jellyfish paper defines k-mers as length-k substrings and addresses efficient occurrence counting for applications such as assembly and error correction. That paper establishes why k-mer processing is useful; it does not mean this Seqqio extractor is a Jellyfish replacement. Use a dedicated counter when you need unique-frequency tables at sequencing scale.

Preserve record identity in batches and exports

Every FASTA record is processed independently. A window never crosses a header boundary, and duplicate record titles do not merge results. The report TSV includes successful, failed, and valid zero-output records. The K-mers TSV contains one row per emitted occurrence, while FASTA creates one record per occurrence with a unique record-and-k-mer identifier. This makes repeated strings traceable rather than deduplicating them silently.

Overlapping windows can make output much larger than input. Seqqio enforces simultaneous input, occurrence, emitted-symbol, and working-output limits; the first reached limit governs the run. Raising k makes each emitted row longer and does not necessarily reduce output bytes. Increase step, reduce the input, or divide a scientifically separable batch when the projected result is too large.

When K-mer Generator is a good fit

Use this tool to teach window geometry, inspect exact occurrences, create coordinate-aware exports, or prepare a bounded feature set for a downstream method. It does not choose an optimal k, calculate enrichment, infer taxonomy, estimate abundance, build a de Bruijn graph, or establish biological significance. The receiving analysis determines whether strand canonicalization, counting, normalization, or a different ambiguity rule is required.

K-mer Generator belongs to Seqqio's 39-application Windows 64-bit workspace. The Seqqio workspace overview explains the shared local batch, history, and export model. The complete toolkit is offered as a US$99 one-time purchase with no activation key.

References

  1. Broad Institute. PathSeqBuildKmers Official GATK documentation Documents reference scanning, fixed-length subsequences, and configurable k-mer spacing in a set-building workflow.
  2. Marcais G, Kingsford C. A fast, lock-free approach for efficient parallel counting of occurrences of k-mers Bioinformatics (2011) DOI: 10.1093/bioinformatics/btr011 Primary paper defining occurrence-counting use cases and the Jellyfish k-mer counter.