A comprehensive library for computational molecular biology
Project description
Biotite project
Biotite is your Swiss army knife for bioinformatics. Whether you want to identify homologous sequence regions in a protein family or you would like to find disulfide bonds in a protein structure: Biotite has the right tool for you. This package bundles popular tasks in computational molecular biology into a uniform Python library. It can handle a major part of the typical workflow for sequence and biomolecular structure data:
Searching and fetching data from biological databases
Reading and writing popular sequence/structure file formats
Analyzing and editing sequence/structure data
Visualizing sequence/structure data
Interfacing external applications for further analysis
Biotite internally stores most of the data as NumPy ndarray objects, enabling
fast C-accelerated analysis,
intuitive usability through NumPy-like indexing syntax,
extensibility through direct access of the internal NumPy arrays.
As a result the user can skip writing code for basic functionality (like file parsers) and can focus on what their code makes unique - from small analysis scripts to entire bioinformatics software packages.
If you use Biotite in a scientific publication, please cite:
Installation
Biotite requires the following packages:
numpy
requests
msgpack
networkx
Some functions require some extra packages:
mdtraj - Required for trajetory file I/O operations.
matplotlib - Required for plotting purposes.
Biotite can be installed via Conda…
$ conda install -c conda-forge biotite
… or pip
$ pip install biotite
Usage
Here is a small example that downloads two protein sequences from the NCBI Entrez database and aligns them:
import biotite.sequence.align as align
import biotite.sequence.io.fasta as fasta
import biotite.database.entrez as entrez
# Download FASTA file for the sequences of avidin and streptavidin
file_name = entrez.fetch_single_file(
uids=["CAC34569", "ACL82594"], file_name="sequences.fasta",
db_name="protein", ret_type="fasta"
)
# Parse the downloaded FASTA file
# and create 'ProteinSequence' objects from it
fasta_file = fasta.FastaFile.read(file_name)
avidin_seq, streptavidin_seq = fasta.get_sequences(fasta_file).values()
# Align sequences using the BLOSUM62 matrix with affine gap penalty
matrix = align.SubstitutionMatrix.std_protein_matrix()
alignments = align.align_optimal(
avidin_seq, streptavidin_seq, matrix,
gap_penalty=(-10, -1), terminal_penalty=False
)
print(alignments[0])
MVHATSPLLLLLLLSLALVAPGLSAR------KCSLTGKWDNDLGSNMTIGAVNSKGEFTGTYTTAV-TA
-------------------DPSKESKAQAAVAEAGITGTWYNQLGSTFIVTA-NPDGSLTGTYESAVGNA
TSNEIKESPLHGTQNTINKRTQPTFGFTVNWKFS----ESTTVFTGQCFIDRNGKEV-LKTMWLLRSSVN
ESRYVLTGRYDSTPATDGSGT--ALGWTVAWKNNYRNAHSATTWSGQYV---GGAEARINTQWLLTSGTT
DIGDDWKATRVGINIFTRLRTQKE---------------------
-AANAWKSTLVGHDTFTKVKPSAASIDAAKKAGVNNGNPLDAVQQ
More documentation, including a tutorial, an example gallery and the API reference is available at https://www.biotite-python.org/.
Contribution
Interested in improving Biotite? Have a look at the contribution guidelines. Feel free to join or community chat on Discord.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distributions
Hashes for biotite-0.36.0-cp311-cp311-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | bcad76b8d58bbd7d5fd502c8d6e07b7d7ff5b71f020b616aa6a923e1867a2813 |
|
MD5 | e43c153b1e6269e1d3e1da181803c880 |
|
BLAKE2b-256 | 10bebfe5e9493a5a4716ec5603fcb39035750d6deb1a839676477c24b87291b6 |
Hashes for biotite-0.36.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 57c1789b4a929b82dc00b288a7564cfbeab0fcc806f83ad2a8eee85e7b674b77 |
|
MD5 | c1eb3c372bb04494c2a54da85506ddf7 |
|
BLAKE2b-256 | d36f654c5ce0a5e33cbdfad197e6c110b65e2c8cdfdf99d30a4ae1a2c71d2732 |
Hashes for biotite-0.36.0-cp311-cp311-macosx_11_0_arm64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 84247f85b2981b46624fec2aba882431f5727b61f2f7b23a0ff2e2305d900ef3 |
|
MD5 | eb70ff47fe14b188582390958beb133a |
|
BLAKE2b-256 | 993ba3c3e522150102e93282f4e0f8a221440cbadcc784459547f1b4b61bcc71 |
Hashes for biotite-0.36.0-cp311-cp311-macosx_10_9_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c3e089760c8386f6f6cf195c613e4b9afd1e37fbdaba61d6631eb5471d2aac97 |
|
MD5 | 8bae922d8ce28f315fd9580ec1c4b27f |
|
BLAKE2b-256 | 0f4f96c205927683178e22fc19d9d9de289956b17529a52f54f16a2302d7952b |
Hashes for biotite-0.36.0-cp310-cp310-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 838f0685002dd3d4a1cc54cbe80f06f2009328641687fd3f7b4bc4bd7b632dad |
|
MD5 | e4a8cb8b3df88a6adf4fc31b353d4663 |
|
BLAKE2b-256 | 4f55af54c16ad561e05d30a89ea55c57db3d5c6949d9659a0fb27acd79c17240 |
Hashes for biotite-0.36.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 66db95c807da307fa9efb914441bc151c384bfc664cc3a63f4a570cecc5f5b2e |
|
MD5 | 8731df9af47f69081fc1080e35498eb0 |
|
BLAKE2b-256 | f190f67794518c185a586d4ef9d396dfe45ab2672678c79d4b6ddb0b83ddf3c4 |
Hashes for biotite-0.36.0-cp310-cp310-macosx_11_0_arm64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 583c3d15d0b3340e4751e47de179e460023d60b9cf13c69c82a1adf9eee7ec8d |
|
MD5 | 34758062222f5a70da520ce9367fac36 |
|
BLAKE2b-256 | d1f3289f89918a28be644c5b4d70bc9913240e401eecab0328668f7b09c9638b |
Hashes for biotite-0.36.0-cp310-cp310-macosx_10_9_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9e25f039a4f03b7eed3ca3ebbb1cc1cb4cd5e3a89d4dfc3d23cde2013ea52e0d |
|
MD5 | 309e605ea8927c254277a37eeae22c60 |
|
BLAKE2b-256 | 8591e91b2756c4578af79d81c02a50b7abaa4950a75f466daa31a91e99f7e502 |
Hashes for biotite-0.36.0-cp39-cp39-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 49d6a55b0615e32e3caafc9908a01ad7d82df55c3c47ee98fea7d6abd426f34b |
|
MD5 | 78bc8071665e980a5e30d017a2558766 |
|
BLAKE2b-256 | 9e247392e9332afce97c195ac7d1db320414c2f69864cd459364643980679d90 |
Hashes for biotite-0.36.0-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | b80ff13c4842c5edc4fbb8733f252d18aad7de270152bbd8271cab5de96ac2e1 |
|
MD5 | f9c9279e28e069c577ea81068c8773eb |
|
BLAKE2b-256 | c1f18cc9fd6ba0137d96f43ef08fe81cc0c20d662312387709f61cb15fbe190d |
Hashes for biotite-0.36.0-cp39-cp39-macosx_11_0_arm64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 360943a46929d39361dc32d0c91746404c20ae5412c7b48ff46cd94713928fc1 |
|
MD5 | 98f35846efc1a2a585782c17721c14e2 |
|
BLAKE2b-256 | 3f0d69565c78aecdd8a6cdff12f138f75760d5c416022f04e9c94f2212b3f11d |
Hashes for biotite-0.36.0-cp39-cp39-macosx_10_9_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7500161bf6d324a92b5ab32a63452ffa81a7ebeed0f314abf7560c7f1568fa3b |
|
MD5 | 4f7a35bdb2087ac40bd0f54cf7076c0c |
|
BLAKE2b-256 | 2515a6534666dfbe291babdd1b883fe2c028747fb9da5adfaceb14ba9e541239 |