Skip to main content

kmertools is a k-mer based feature extraction tool designed to support metagenomics and other bioinformatics analytics.

Project description

kmertools: DNA Vectorisation Tool

License: GPL v3 Cargo tests Clippy check install with bioconda Conda - Version Conda Downloads PyPI Downloads codecov PyPI - Version

$$\   $$\                                   $$$$$$$$\                     $$\           
$$ | $$  |                                  \__$$  __|                    $$ |          
$$ |$$  / $$$$$$\$$$$\   $$$$$$\   $$$$$$\     $$ |    $$$$$$\   $$$$$$\  $$ | $$$$$$$\ 
$$$$$  /  $$  _$$  _$$\ $$  __$$\ $$  __$$\    $$ |   $$  __$$\ $$  __$$\ $$ |$$  _____|
$$  $$<   $$ / $$ / $$ |$$$$$$$$ |$$ |  \__|   $$ |   $$ /  $$ |$$ /  $$ |$$ |\$$$$$$\  
$$ |\$$\  $$ | $$ | $$ |$$   ____|$$ |         $$ |   $$ |  $$ |$$ |  $$ |$$ | \____$$\ 
$$ | \$$\ $$ | $$ | $$ |\$$$$$$$\ $$ |         $$ |   \$$$$$$  |\$$$$$$  |$$ |$$$$$$$  |
\__|  \__|\__| \__| \__| \_______|\__|         \__|    \______/  \______/ \__|\_______/ 

Overview

kmertools is a k-mer based feature extraction tool designed to support metagenomics and other bioinformatics analytics. This tool leverages k-mer analysis to vectorize DNA sequences, facilitating the use of these vectors in various AI/ML applications.

Features

  • Oligonucleotide Frequency Vectors: Generate frequency vectors for oligonucleotides.
  • Minimiser Binning: Efficiently bin sequences using minimisers to reduce data complexity.
  • Chaos Game Representation (CGR): Compute CGR vectors for DNA sequences based on k-mers or whole sequence transformation.
  • Coverage Histograms: Create coverage histograms to analyze the depth of sequencing reads.
  • Python Binding: You can import kmertools functionality using import pykmertools as kt

Installation

Option 1: from bioconda (recommended)

You can install kmertools from Bioconda at https://anaconda.org/bioconda/kmertools. Make sure you have conda installed.

# create conda environment and install kmertools
conda create -n kmertools -c bioconda kmertools

# activate environment
conda activate kmertools

Option 2: from PyPI

You can install kmertools from PyPI at https://pypi.org/project/pykmertools/.

pip install pykmertools

Option 3: from sources

You can install kmertools directly from the source by cloning the repository and using Rust's package manager cargo.

git clone https://github.com/your-repository/kmertools.git
cd kmertools
cargo build --release

Now add the binary to path (you may modify ~/.bashrc or ~/.zshrc)

# to add to current terminal
export PATH=$PATH:$(pwd)/target/release/

# to save to ~/.bashrc
echo "export PATH=\$PATH:$(pwd)/target/release/" >> ~/.bashrc
source ~/.bashrc

# to save to ~/.zshrc for Mac
echo "export PATH=\$PATH:$(pwd)/target/release/" >> ~/.zshrc
source ~/.zshrc

To install the python bindings run the following commands. You can use either pip or conda directories for this.

# pip
cd pip
maturin build --release
# conda
cd conda
maturin build --release

Now move to parent directory using cd .. and run the following command.

pip install target/wheels/pykmertools-<VERSION>-cp39-abi3-manylinux_2_34_x86_64.whl

Test the installation

After setting up, run the following command to print out the kmertools help message.

kmertools --help

Help

Please read our comprehensive Wiki.

Authors

Citation

If you use kmertools please cite as follows.

@software{Wickramarachchi_kmertools_DNA_Vectorisation,
  author = {Wickramarachchi, Anuradha and Mallawaarachchi, Vijini},
  title = {{kmertools: DNA Vectorisation Tool}},
  url = {https://github.com/anuradhawick/kmertools},
  version = {0.1.4}
}

Please refer to the Wiki for citations of relevant algorithms.

Support and contributions

Please get in touch via author websites or GitHub issues. Thanks!

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

pykmertools-0.2.2-cp310-abi3-win_amd64.whl (832.3 kB view details)

Uploaded CPython 3.10+Windows x86-64

pykmertools-0.2.2-cp310-abi3-musllinux_1_2_x86_64.whl (1.3 MB view details)

Uploaded CPython 3.10+musllinux: musl 1.2+ x86-64

pykmertools-0.2.2-cp310-abi3-musllinux_1_2_aarch64.whl (1.2 MB view details)

Uploaded CPython 3.10+musllinux: musl 1.2+ ARM64

pykmertools-0.2.2-cp310-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.1 MB view details)

Uploaded CPython 3.10+manylinux: glibc 2.17+ x86-64

pykmertools-0.2.2-cp310-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (1.1 MB view details)

Uploaded CPython 3.10+manylinux: glibc 2.17+ ARM64

pykmertools-0.2.2-cp310-abi3-macosx_11_0_arm64.whl (978.2 kB view details)

Uploaded CPython 3.10+macOS 11.0+ ARM64

pykmertools-0.2.2-cp310-abi3-macosx_10_12_x86_64.whl (992.4 kB view details)

Uploaded CPython 3.10+macOS 10.12+ x86-64

File details

Details for the file pykmertools-0.2.2-cp310-abi3-win_amd64.whl.

File metadata

File hashes

Hashes for pykmertools-0.2.2-cp310-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 f6989e7d4d20b61d9b915eb87eb2eb7de462c42e399911efd6391674776eb9ac
MD5 503e5f1d771686219928250df53cd644
BLAKE2b-256 d602864c147920086e3fbd46bb78766cb20570ad4a2211ad8e9a863a857b2ed9

See more details on using hashes here.

File details

Details for the file pykmertools-0.2.2-cp310-abi3-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for pykmertools-0.2.2-cp310-abi3-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 a59a7b622cda9261334f562f789be2e716d4a9f8f02755ab691fd08794975886
MD5 8d459bef6b9763bc097fcf6712fd5d91
BLAKE2b-256 d6875e9044336f6a84faf57ed2509e98646ad6ad853361871a1975e51c43b084

See more details on using hashes here.

File details

Details for the file pykmertools-0.2.2-cp310-abi3-musllinux_1_2_aarch64.whl.

File metadata

File hashes

Hashes for pykmertools-0.2.2-cp310-abi3-musllinux_1_2_aarch64.whl
Algorithm Hash digest
SHA256 a60646ed2ccbe11bdb1e621ae7587af8ac092c057de23148fb634d370bbff55c
MD5 26db03467ea2ce7be6e5ae4eab75edc7
BLAKE2b-256 6f920b95f532068594cb9f5a42969d6e1b3eb4d9d3dbc268862fb218e73fb11c

See more details on using hashes here.

File details

Details for the file pykmertools-0.2.2-cp310-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for pykmertools-0.2.2-cp310-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 25627f7d2629a038c94724525e4568befbdf08deb7cad9ecc646d0ff328447cf
MD5 15ff7e78f0b2f2b0e8643ca9a4232151
BLAKE2b-256 7b18a0aaa327bc6d0e312362eb8a8e7a2c7a4bbe6c40b5755b2f341f41822b9a

See more details on using hashes here.

File details

Details for the file pykmertools-0.2.2-cp310-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for pykmertools-0.2.2-cp310-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 a05f1eb3670899016f4350513a30b8b33315c0c65c3169b9635d5eb62d63ff62
MD5 53cebf6efcbfe4b2b58f48e6a382a676
BLAKE2b-256 34244a1ed80fd73a7c3ded81d11389cd7d3acf4d173d4c5856896b9ab6074767

See more details on using hashes here.

File details

Details for the file pykmertools-0.2.2-cp310-abi3-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for pykmertools-0.2.2-cp310-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 831d8d4365f94f17cf72911e392505e0863b79bc64304ac064856beb69ab2833
MD5 af62f8450e20f369309e325afad6a8ae
BLAKE2b-256 835ced344befe221663f5c4d5de24c39550b7a975c042ee6e8dfe49dab365a28

See more details on using hashes here.

File details

Details for the file pykmertools-0.2.2-cp310-abi3-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for pykmertools-0.2.2-cp310-abi3-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 b8a700349337f27f10a85cbb4e36c1f0e82713b9432ec52a4c09c00acc7c09ab
MD5 dde300897fa23be725d4ba5496e60796
BLAKE2b-256 94a45b0630e8bec57199818cdac84543d324d41820bb1029a2fb67e96adbb6b0

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page