aa_similarity

Crates.ioaa_similarity
lib.rsaa_similarity
version0.1.0
sourcesrc
created_at2020-11-03 20:35:56.024026
updated_at2020-11-03 20:35:56.024026
descriptionSubstitution matrices for use in protein sequence analysis and alignment.
homepagehttps://github.com/jeanmanguy/amino-acids
repositoryhttps://github.com/jeanmanguy/amino-acids
max_upload_size
id308417
size185,634
Jean Manguy (jeanmanguy)

documentation

README

aa-similarity

stability-experimental Rust Documentation Crates.io version

Usage

Add the following to your Cargo.toml

[dependencies]
aa-similarity = "0.1.0"

Examples

use aa_similarity::{Blosum65, Similarity, AminoAcid};

assert_eq!(
    Blosum65::similarity(
        AminoAcid::GlutamicAcid,
        AminoAcid::AsparticAcid
    ),
    2
);

aa-similarity re-exports AminoAcid from aa-name. Amino acids from an alignment can be converted from chars or string like so:

use aa_similarity::{Blosum62, Similarity, AminoAcid};

let ala = AminoAcid::try_from('A')?;
let tyr = AminoAcid::try_from('Y')?;

assert_eq!(Blosum62::similarity(ala, tyr), -2);

See: aa-name.

Supported matrices

Source: ftp://ftp.ncbi.nih.gov/blast/matrices/

  • Blosum30

  • Blosum35

  • Blosum40

  • Blosum45

  • Blosum50

  • Blosum55

  • Blosum60

  • Blosum62

  • Blosum65

  • Blosum70

  • Blosum75

  • Blosum80

  • Blosum85

  • Blosum90

  • Blosum100

  • Blosumn

  • Dayhoff

  • Identity

  • Pam10

  • Pam20

  • Pam30

  • Pam40

  • Pam50

  • Pam60

  • Pam70

  • Pam80

  • Pam90

  • Pam100

  • Pam110

  • Pam120

  • Pam130

  • Pam140

  • Pam150

  • Pam160

  • Pam170

  • Pam180

  • Pam190

  • Pam200

  • Pam210

  • Pam220

  • Pam230

  • Pam240

  • Pam250

  • Pam260

  • Pam270

  • Pam280

  • Pam290

  • Pam300

  • Pam310

  • Pam320

  • Pam330

  • Pam340

  • Pam350

  • Pam360

  • Pam370

  • Pam380

  • Pam390

  • Pam400

  • Pam410

  • Pam420

  • Pam430

  • Pam440

  • Pam450

  • Pam460

  • Pam470

  • Pam480

  • Pam490

  • Pam500

Contributing

The project is maintained by Jean Manguy. Please submit a bug report or a feature request on the Github issues page.

License

aa-similarity is distributed under the terms of both the MIT license and the Apache License (Version 2.0).

See LICENSE-APACHE and LICENSE-MIT for details.

Commit count: 79

cargo fmt