https://github.com/althonos/scoring-matrices

Dependency free, Cython-compatible scoring matrices to use with biological sequences.

https://github.com/althonos/scoring-matrices

Science Score: 36.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
  • Academic publication links
  • Committers with academic emails
    1 of 2 committers (50.0%) from academic institutions
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (10.4%) to scientific vocabulary
Last synced: 10 months ago · JSON representation

Repository

Dependency free, Cython-compatible scoring matrices to use with biological sequences.

Basic Info
  • Host: GitHub
  • Owner: althonos
  • License: mit
  • Language: Cython
  • Default Branch: main
  • Size: 200 KB
Statistics
  • Stars: 9
  • Watchers: 1
  • Forks: 2
  • Open Issues: 1
  • Releases: 9
Created about 2 years ago · Last pushed 11 months ago
Metadata Files
Readme Changelog Contributing License

README.md

🧬🔠 scoring-matrices Stars

Dependency free, Cython-compatible scoring matrices to use with biological sequences.

Actions Coverage License PyPI Bioconda AUR Wheel Python Versions Python Implementations Source Issues Docs Changelog Downloads

🗺️ Overview

Scoring Matrices are matrices used to score the matches and mismatches between two characters are the same position in a sequence alignment. Some of these matrices are derived from substitution matrices, which uses evolutionary modeling.

The scoring-matrices package is a dependency-free, batteries included library to handle and distribute common substitution matrices:

  • no external dependencies: The matrices are distributed as-is: you don't need the whole Biopython ecosystem, or even NumPy.
  • Cython compatibility: The ScoringMatrix is a Cython class that can be inherited, and the matrix data can be accessed as either a raw pointer, or a typed memoryview.
  • most common matrices: The package distributes most common matrices, such as those used by the NCBI BLAST+ suite, including:
    • PAM matrices by Dayhoff et al. (1978).
    • BLOSUM matrices by Henikoff & Henikoff (1992).
    • VTML matrices by Muller et al. (2002).
    • BENNER matrices by Benner et al. (1994).

🔧 Installing

scoring-matrices can be installed directly from PyPI, which hosts some pre-built wheels for the x86-64 architecture (Linux/OSX/Windows) and the Aarch64 architecture (Linux/OSX), as well as the code required to compile from source with Cython: console $ pip install scoring-matrices

Otherwise, scoring-matrices is also available as a Bioconda package: console $ conda install bioconda::scoring-matrices

💡 Usage

Python

  • Import the ScoringMatrix class from the installed module: python from scoring_matrices import ScoringMatrix
  • Load one of the built-in matrices: python blosum62 = ScoringMatrix.from_name("BLOSUM62")
  • Get individual matrix weights either by index or by alphabet letter: python x = blosum62[0, 0] y = blosum62['A', 'A']
  • Get a row of the matrix either by index or by alphabet letter: python row_x = blosum62[0] row_y = blosum62['A']

Cython

  • Access the matrix weights as raw pointers to constant data: ```cython from scoring_matrices cimport ScoringMatrix

cdef ScoringMatrix blosum = ScoringMatrix.fromname("BLOSUM62") cdef const float* data = blosum.dataptr() # dense array cdef const float** matrix = blosum.matrixptr() # array of pointers - Access the `ScoringMatrix` weights as a [typed memoryview](https://cython.readthedocs.io/en/latest/src/userguide/memoryviews.html) using the *buffer protocol* in more recents versions of Python: cython from scoringmatrices cimport ScoringMatrix

cdef ScoringMatrix blosum = ScoringMatrix.from_name("BLOSUM62") cdef const float[:, :] weights = blosum ```

💭 Feedback

⚠️ Issue Tracker

Found a bug ? Have an enhancement request ? Head over to the GitHub issue tracker if you need to report or ask something. If you are filing in on a bug, please include as much information as you can about the issue, and try to recreate the same bug in a simple, easily reproducible situation.

🏗️ Contributing

Contributions are more than welcome! See CONTRIBUTING.md for more details.

📋 Changelog

This project adheres to Semantic Versioning and provides a changelog in the Keep a Changelog format.

⚖️ License

This library is provided under the MIT License. Matrices were collected from the MMseqs2, Biopython and NCBI BLAST+ sources and are believed to be in the public domain.

This project was developed by Martin Larralde during his PhD project at the Leiden University Medical Center in the Zeller team.

Owner

  • Name: Martin Larralde
  • Login: althonos
  • Kind: user
  • Location: Heidelberg, Germany
  • Company: EMBL / LUMC, @zellerlab

PhD candidate in Bioinformatics, passionate about programming, SIMD-enthusiast, Pythonista, Rustacean. I write poems, and sometimes they are executable.

GitHub Events

Total
  • Create event: 5
  • Release event: 1
  • Issues event: 3
  • Watch event: 3
  • Delete event: 1
  • Issue comment event: 6
  • Push event: 26
  • Pull request event: 1
  • Fork event: 1
Last Year
  • Create event: 5
  • Release event: 1
  • Issues event: 3
  • Watch event: 3
  • Delete event: 1
  • Issue comment event: 6
  • Push event: 26
  • Pull request event: 1
  • Fork event: 1

Committers

Last synced: about 2 years ago

All Time
  • Total Commits: 53
  • Total Committers: 2
  • Avg Commits per committer: 26.5
  • Development Distribution Score (DDS): 0.019
Past Year
  • Commits: 53
  • Committers: 2
  • Avg Commits per committer: 26.5
  • Development Distribution Score (DDS): 0.019
Top Committers
Name Email Commits
Martin Larralde m****e@e****e 52
RayHackett 9****t 1
Committer Domains (Top 20 + Academic)
embl.de: 1

Issues and Pull Requests

Last synced: 11 months ago

All Time
  • Total issues: 2
  • Total pull requests: 2
  • Average time to close issues: 2 days
  • Average time to close pull requests: about 4 hours
  • Total issue authors: 2
  • Total pull request authors: 2
  • Average comments per issue: 1.0
  • Average comments per pull request: 1.0
  • Merged pull requests: 2
  • Bot issues: 0
  • Bot pull requests: 0
Past Year
  • Issues: 2
  • Pull requests: 1
  • Average time to close issues: 2 days
  • Average time to close pull requests: about 8 hours
  • Issue authors: 2
  • Pull request authors: 1
  • Average comments per issue: 1.0
  • Average comments per pull request: 2.0
  • Merged pull requests: 1
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
  • valentynbez (2)
  • apcamargo (1)
Pull Request Authors
  • apcamargo (2)
  • RayHackett (2)
Top Labels
Issue Labels
enhancement (1)
Pull Request Labels

Packages

  • Total packages: 1
  • Total downloads:
    • pypi 4,044 last-month
  • Total dependent packages: 3
  • Total dependent repositories: 0
  • Total versions: 10
  • Total maintainers: 1
pypi.org: scoring-matrices

Dependency free, Cython-compatible scoring matrices to use with biological sequences.

  • Documentation: https://scoring-matrices.readthedocs.io/en/stable/
  • License: MIT License Copyright (c) 2024 Martin Larralde <martin.larralde@embl.de> Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
  • Latest release: 0.3.3
    published 11 months ago
  • Versions: 10
  • Dependent Packages: 3
  • Dependent Repositories: 0
  • Downloads: 4,044 Last month
Rankings
Dependent packages count: 9.5%
Average: 35.9%
Dependent repos count: 62.4%
Maintainers (1)
Last synced: 11 months ago

Dependencies

.github/workflows/package.yml actions
  • actions-rs/toolchain v1 composite
  • actions/checkout v3 composite
  • actions/download-artifact v2 composite
  • actions/setup-python v2 composite
  • actions/upload-artifact v3 composite
  • actions/upload-artifact v2 composite
  • docker/setup-qemu-action v2 composite
  • pypa/cibuildwheel v2.16.5 composite
  • pypa/gh-action-pypi-publish release/v1 composite
  • rasmus-saks/release-a-changelog-action v1.0.1 composite
.github/workflows/test.yml actions
  • actions/checkout v2 composite
  • actions/setup-python v5 composite
  • codecov/codecov-action v3 composite
.github/workflows/requirements.txt pypi
  • auditwheel *
  • coverage *
  • cython *
  • importlib-resources *
  • setuptools >=46.4.0
  • wheel *
pyproject.toml pypi
docs/requirements.txt pypi
  • cython *
  • ipython *
  • nbsphinx *
  • pygments *
  • pygments-style-monokailight *
  • recommonmark *
  • semantic_version *
  • setuptools >=46.4
  • sphinx >=5.0
  • sphinxcontrib-jquery *