Learn R Programming

BALCONY (version 0.2.10)

get_seq_weights: Get sequences weights

Description

This function returns weights of the sequneces in the alignment object

Usage

get_seq_weights(alignment)

Arguments

alignment

alignment loaded with read.alignment

Value

A vector with weights of length equal to the number of sequences in the alignment

Details

The weights are calculated as shown in: Valdar and Thronton (2001)

According to the following formulas:

$$W_{j} = \frac{\sum_{k\neq j}^{N}Dist(s_{j},s_{k}))}{N-1}$$ where: \(W_{j}\) is the weight of sequence \(s_{j}\), and is defined as the average evolutionary distance between \(s_{j}\) and all other sequences in the alignment \(N\) is the number of sequences in the alignment.

$$Dist(s_{j},s_{k})) = 1 = \frac{\sum_{i\epsilon Aligned_{jk}}Mut(s_{j},s_{k}))}{n(Aligned_{jk}))}$$ where: \(Dist(s_{j},s_{k})\), the evolutionary distance between sequences \(s_{j}\) and \(s_{k}\) \(Aligned_{jk}\) is the set of all non-gap positions in \(s_{j}\) or \(s_{k}\), \(n(Aligned_{jk})\) is the number of such positions.

$$Mut(a,b) = \frac{m(a,b) - min(m)}{max(m) - min(m)}$$ where: \(Mut(a,b)\) measures the similarity between amino acids \(a\) and \(b\) as derived from \(a\) mutation data matrix \(m\)

References

Valdar, W. S. J. & Thornton, J. M. Protein<U+2013>protein interfaces: Analysis of amino acid conservation in homodimers. Proteins: Structure, Function, and Bioinformatics 42, 108<U+2013>124 (2001).

Examples

Run this code
# NOT RUN {
data("small_alignment")
alignment = small_alignment
weights = get_seq_weights(alignment)
# }

Run the code above in your browser using DataLab