From 001d029b058432b3ae0a4431e5bcd4116ee7694a Mon Sep 17 00:00:00 2001 From: Jim Procter Date: Wed, 9 Aug 2017 21:14:58 +0100 Subject: [PATCH] JAL-2397 JAL-2398 documentation for reinstating legacy PCA calculation with asymmetric Blosum62 matrix. --- examples/legacyblosum62.scm | 33 ++++++++++++++++++++++++++ help/html/calculations/pca.html | 50 +++++++++++++++++++++++---------------- 2 files changed, 62 insertions(+), 21 deletions(-) create mode 100644 examples/legacyblosum62.scm diff --git a/examples/legacyblosum62.scm b/examples/legacyblosum62.scm new file mode 100644 index 0000000..57072cf --- /dev/null +++ b/examples/legacyblosum62.scm @@ -0,0 +1,33 @@ +ScoreMatrix BLOSUM62Legacy +# +# The BLOSUM62 substitution matrix, as used in earlier versions of jalview +# +# Scores are not symbol case sensitive, unless column(s) are provided for lower case characters +# The 'guide symbol' at the start of each row of score values is optional +# Values may be integer or floating point, delimited by tab, space, comma or combinations +# + A R N D C Q E G H I L K M F P S T W Y V B Z X * +A 4 -1 -2 -2 0 -1 -1 0 -2 -1 -1 -1 -1 -2 -1 1 0 -3 -2 0 -2 -1 0 -4 +R -1 5 0 -2 -3 1 0 -2 0 -3 -2 2 -1 -3 -2 -1 -1 -3 -2 -3 -1 0 -1 -4 +N -2 0 6 1 -3 0 0 0 1 -3 -3 0 -2 -3 -2 1 0 -4 -2 -3 3 0 -1 -4 +D -2 -2 1 6 -3 0 2 -1 -1 -3 -4 -1 -3 -3 -1 0 -1 -4 -3 -3 4 1 -1 -4 +C 0 3 -3 -3 9 -3 -4 -3 -3 -1 -1 -3 -1 -2 -3 -1 -1 -2 -2 -1 -3 -3 -2 -4 +Q -1 1 0 0 -3 5 2 -2 0 -3 -2 1 0 -3 -1 0 -1 -2 -1 -2 0 3 -1 -4 +E -1 0 0 2 -4 2 5 -2 0 -3 -3 1 -2 -3 -1 0 -1 -3 -2 -2 1 4 -1 -4 +G 0 -2 0 -1 -3 -2 -2 6 -2 -4 -4 -2 -3 -3 -2 0 -2 -2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 -1 -1 -1 -1 -1 -4 +* -4 -4 -4 -4 -4 -4 -4 -4 -4 -4 -4 -4 -4 -4 -4 -4 -4 -4 -4 -4 -4 -4 -4 1 diff --git a/help/html/calculations/pca.html b/help/html/calculations/pca.html index 7ffb160..14bb9ee 100755 --- a/help/html/calculations/pca.html +++ b/help/html/calculations/pca.html @@ -26,9 +26,12 @@

Principal Component Analysis

-

A principal component analysis can be performed via the - calculations dialog which is accessed by selecting Calculate→Calculate - Tree or PCA....

+

+ A principal component analysis can be performed via the calculations dialog which is accessed + by selecting Calculate→Calculate Tree or + PCA.... +

This calculation creates a spatial representation of the similarities within a selected group, or all of the sequences in an alignment. After the calculation finishes, a 3D viewer displays the @@ -67,24 +70,6 @@ calculation are given in the Change Parameters menu.

-

- PCA Calculation modes
The default Jalview - calculation mode (indicated when Jalview - PCA Calculation is ticked in the Change - Parameters menu) is to perform a PCA on a matrix where elements - in the upper diagonal give the sum of scores for mutating in one - direction, and the lower diagonal is the sum of scores for mutating - in the other. For protein substitution models like BLOSUM62, this - gives an asymmetric matrix, and a different PCA to a matrix produced - with the method described in the paper by G. Casari, C. Sander and - A. Valencia. Structural Biology volume 2, no. 2, February 1995 (pubmed) - and implemented at the SeqSpace server at the EBI. This method - preconditions the matrix by multiplying it with its transpose, and - can be employed in the PCA viewer by unchecking the Jalview - PCA Calculation option in the Change - Parameters menu. -

The PCA Viewer @@ -145,5 +130,28 @@ left-clicking and dragging the mouse over the display. --> added to the Jalview desktop in v2.7. The Reset button and Change Parameters menu were added in Jalview 2.8. Support for PAM250 based PCA was added in Jalview 2.8.1. +

+

+ Reproducing PCA calculations performed with older + Jalview releases Jalview 2.10.2 included a revised PCA + implementation which treated Gaps and non-standard residues in the + same way as a matrix produced with the method described in the paper + by G. Casari, C. Sander and A. Valencia. Structural Biology volume + 2, no. 2, February 1995 (pubmed) + and implemented at the SeqSpace server at the EBI. To reproduce + calculations performed with earlier Jalview releases it is necessary + to execute the following Groovy script: + +

+    jalview.analysis.scoremodels.ScoreMatrix.scoreGapAsAny=true
+    
+ Additionally, for PCAs performed with older versions of Jalview and + the Blosum62 matrix, it is also necessary to import the legacy + BLOSUM62 score matrix (which is asymmetric for mutations between C to + R) which can be downloaded at + http://www.jalview.org/examples/legacyBlosum62.scm +

+ -- 1.7.10.2