Learn R Programming

BALCONY (version 0.2.10)

D_matrix: Calculate substitution rate matrix between two amino acids

Description

This function is used to calculate Landgraf conservation metric. D_matrix contains substitution rates between two amino acids in the alignment, according to the following formula: $$D(a,b)= (d(a,a)-d(a,b))/d(a,a)$$ where: \(d(a,a)\) is a probability of AA substitution by itself \(d(a,b)\) is a probability of substitution of amino acid a with other amino acid.

Usage

D_matrix(substitution_matrix)

Arguments

substitution_matrix

A matrix with probablity of substitutions, e.g. Gonnet substitution matrix

Value

distance

A matrix of substitution probablities for all amino acids

Examples

Run this code
# NOT RUN {
data("gonnet")
distance=D_matrix(gonnet)
# }

Run the code above in your browser using DataLab