K-mer counting and clustering for biological sequence analysis

kmer is an R package for rapidly computing distance matrices and clustering large sequence datasets using fast alignment-free k-mer counting and recursive k-means partitioning.


To download kmer from CRAN and load the package, run


To download the development version from GitHub, first ensure a C/C++ compliler is available and the devtools R package is installed. Linux users will generally have a compiler installed by default; however Windows users may need to download Rtools and Mac OSX users will need Xcode (note that these are not R packages). To download and install devtools, run


The kmer package can then be installed and loaded by running



An overview of the package and its functions can be found by running


To view the tutorial, you can either run


or access it directly from CRAN.

If you experience a problem using this package please feel free to raise it as an issue on GitHub. Any feedback is appreciated.


This software was developed at Victoria University of Wellington with funding from a Rutherford Foundation Postdoctoral Research Fellowship award from the Royal Society of New Zealand.

Try the kmer package in your browser

Any scripts or data that you put into this service are public.

kmer documentation built on May 20, 2019, 9:02 a.m.