Skip to main content

ISV package

Python package for easy prediction of pathogenicity Copy Number Variants (CNVs)


If you mention or use the ISV tool, please cite our article

https://www.nature.com/articles/s41598-021-04505-z


Install

Install with pip install isv

This will also automatically install all required additional packages. Thus it is recommended to install the package in a separate environment (e.g. uv, virtualenv, conda, ...)

Package url: https://pypi.org/project/isv/

Module reference available at https://tsladecek.github.io/isv_package/


Modules

The package contains a wrapper function:

isv.isv(cnvs, proba, shap)

which automatically annotates and predicts cnvs provided in a list, np.array or pandas DataFrame format represented in 4 columns: chromosome, start (grch38), end (grch38) and cnv_type

  • The proba parameter controls whether probabilities should be calculated
  • The shap parameter controls whether shap values should be calculated

and a Wrapper class (which is recommended):

isv.ISV(cnvs)

with methods:

  • ISV.predict(proba)
  • ISV.shap(data=None)
    • where the data argument is optional
  • ISV.waterfall(cnv_index)
    • for creating an interactive waterfall plot for a CNV at index cnv_index

The main subfunctions of the package are:

1. isv.annotate(cnvs)

  • annotates cnvs provided in a list, np.array or pandas DataFrame format represented in 4 columns: chromosome, start (grch38), end (grch38) and cnv_type
  • Returns an annotated dataframe which can be used as an input to following two functions

2. isv.predict(annotated_cnvs, proba)

  • returns an array of isv predictions. annotated_cnvs represents annotated cnvs returned by the annotate function

3. isv.shap_values(annotated_cnvs)

  • calculates shap values for given CNVs. annotated_cnvs represents annotated cnvs returned by the annotate function

For example

  1. using the simple wrapper
from isv import isv


cnvs = [
    ["chr8", 100000, 500000, "DEL"],
    ["chrX", 52000000, 55000000, "DUP"]
] 

results = isv(cnvs, proba=True, shap=True)
  1. using the ISV class
from isv import ISV


cnvs = [
    ["chr8", 100000, 500000, "DEL"],
    ["chrX", 52000000, 55000000, "DUP"]
] 

cnv_isv = ISV(cnvs)
predictions = cnv_isv.predict(proba=True)
shap_vals = cnv_isv.shap()
cnv_isv.waterfall(cnv_index=1)

Can be also used as a command line tool

isv -i <input_cnvs>.bed -o <outputpath> [-p] [-sv]

where the input should be a list of CNVs in a bed format, with columns: chromosome, start (grch38), end (grch38) and cnv_type

[!NOTE] The first row must contain column names

Results will be saved in a tab separated file at path specified by user

Optionally, use following flags:

  • -p: whether probabilities should be returned
  • -sv: whether shap values should be calculated

For example

isv -i examples/loss_gain_cnvs.bed -o examples/loss_gain_cnvs_out.bed -p -sv

Download files

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

Source Distribution

isv-0.3.17.tar.gz (6.0 MB view details)

Uploaded Source

Built Distribution

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

isv-0.3.17-py3-none-any.whl (6.0 MB view details)

Uploaded Python 3

File details

Details for the file isv-0.3.17.tar.gz.

File metadata

  • Download URL: isv-0.3.17.tar.gz
  • Upload date:
  • Size: 6.0 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.5 {"installer":{"name":"uv","version":"0.11.5","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for isv-0.3.17.tar.gz
Algorithm Hash digest
SHA256 b422f9e46df434c9b9af7656e9238068f7cbc9b5a4734806659fc9fa3555ccca
MD5 9dcc3ac1723c391dbdc4e34593bf8d5c
BLAKE2b-256 8c32e7ab8c0775f32862ec1b1422bd0b3097850e0cc865f6f6cb87cf963169d4

See more details on using hashes here.

File details

Details for the file isv-0.3.17-py3-none-any.whl.

File metadata

  • Download URL: isv-0.3.17-py3-none-any.whl
  • Upload date:
  • Size: 6.0 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.11.5 {"installer":{"name":"uv","version":"0.11.5","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for isv-0.3.17-py3-none-any.whl
Algorithm Hash digest
SHA256 e1a72d59b29db5b52863d770be0c52c7bbbf90c226f4e2581019772c13b8ab59
MD5 0e7e0d7c60831a80da84c4277e98b47a
BLAKE2b-256 68deefd657d61cfde98e283742ac3077384c696668480204f9aa35bd77676189

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.3.17 This release

2 files

0.3.16

2 files

0.3.15

2 files

0.3.14

2 files

0.3.13

2 files

0.3.12

2 files

0.3.11

2 files

0.3.10

2 files

0.3.9

2 files

0.3.8

2 files

0.3.7

2 files

0.3.6

2 files

0.3.5

2 files

0.3.4

2 files

0.3.3

2 files

0.3.2

2 files

0.3.1

2 files

0.3.0

2 files

0.2.9

2 files

0.2.8

2 files

0.2.7

2 files

0.2.6

2 files

0.2.5

2 files

0.2.4

2 files

0.2.2

2 files

0.2.1

2 files

0.2.0

2 files

0.1.8

2 files

0.1.7

2 files

0.1.6

2 files

0.1.5

2 files

0.1.4

2 files

0.1.3

2 files

0.1.0

2 files

Supported by

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