Learn R Programming

kmeRtone (version 1.0)

initKmerTable: Initialise k-mer table with all possible k-mers

Description

Initialise k-mer table with the following columns: kmer, pos_strand, and neg_strand

Usage

initKmerTable(k, central.pattern = NULL, split.kmer = FALSE)

Value

data.table with 3 columns: kmer, pos_strand, neg_strand

Arguments

k

K-mer size. Limit to 15 because vector size is limited to .Machine$integer.max. For 9- to 15-mer, the kmer sequence is separated to two columns (kmer_part1 and kmer_part2) to reduce memory significantly.

central.pattern

Central pattern(s) of the k-mer. Default is NULL.

split.kmer

Whether to split the k-mer sequence into two parts for large k values. Default is FALSE.