countKmers: Count k-mers from string(s) using a simple hash table.

View source: R/RcppExports.R

countKmersR Documentation

Count k-mers from string(s) using a simple hash table.

Description

Count only observed k-mers. Biostrings::oligonucleotideFrequency reports all possible k-mers. For k > 12, the memory for creating empty k-mer counts spiked and crashed the R session.

Usage

countKmers(sequences, k)

Arguments

sequences

Sequence strings.

k

Size of k-mer.

Value

A vector of k-mer counts. The counts of multiple sequences are combined, similar to Biostrings::oligonucleotideFrequency simplify.as "collapsed".


kmeRtone documentation built on Sept. 11, 2024, 9:12 p.m.