Skip to main content

SNP utils

Project description

License BSD-3 PyPI Python Version tests

snputils

Installation

We recommend creating a fresh Python >= 3.8 conda environment. This package can be easily installed using pip after cloning the repository:

(base) $ conda create -n snputils python=3.10
(base) $ conda activate snputils
(snputils) $ git clone https://github.com/AI-sandbox/snputils.git && cd snputils
(snputils) $ pip install -e '.[testing,jupyter]'

Alternatively, you can install the package directly from the repository without cloning it:

(base) $ pip install git+https://github.com/AI-sandbox/snputils.git

Use snputils tools

PCA

To directly run Principal Component Analysis (PCA) on SNP data, plotting the results, and saving the principal components on a .npy file, simply call snputils pca with the required arguments, see snputils pca --help for more information.

An example of running PCA on a .vcf file, saving the plot in fig.png and the principal components in pc.npy:

> snputils pca --vcf_file /dataset/path/hapmap3.vcf --fig_path fig.png --npy_path pc.npy --backend sklearn

Project details


Download files

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

Source Distribution

snputils-0.1.0.tar.gz (808.5 kB view details)

Uploaded Source

Built Distribution

snputils-0.1.0-py3-none-any.whl (63.8 kB view details)

Uploaded Python 3

File details

Details for the file snputils-0.1.0.tar.gz.

File metadata

  • Download URL: snputils-0.1.0.tar.gz
  • Upload date:
  • Size: 808.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.11.9

File hashes

Hashes for snputils-0.1.0.tar.gz
Algorithm Hash digest
SHA256 7bfabeff8a8b6b4f91bf683642fa66cb835d1da28ea2d8a5c0e08505be9e6f92
MD5 0b32f477b7594723e908db30ebf90e34
BLAKE2b-256 123a0e935affdc78ddd7133aa1cbe116f503c2d8d5dd7304579dd8712960f732

See more details on using hashes here.

File details

Details for the file snputils-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: snputils-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 63.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.11.9

File hashes

Hashes for snputils-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 ae9cac6682f142af0cb778339381ce6f9d69e3b926f0427a413b2df1662b5212
MD5 b7de7ef486a4dfc9e42c0e4b48f62709
BLAKE2b-256 1c63e62cd0eb9110692c3a2d8f6ca35f62d15b1126e6a403725daf240f168a9f

See more details on using hashes here.

Supported by

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