Skip to content

Commit

Permalink
improving coloring of proteinAlphabet hydrophobicity scale
Browse files Browse the repository at this point in the history
  • Loading branch information
tnrich committed Oct 20, 2021
1 parent c28aad2 commit 411576a
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 41 deletions.
64 changes: 32 additions & 32 deletions src/proteinAlphabet.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,203 +5,203 @@ module.exports = {
threeLettersName: "Ala",
hydrophobicity: 1.8,
colorByFamily: "#00FFFF",
color: "#FF5C5C"
color: "hsl(327.3, 100%, 69%)"
},
R: {
value: "R",
name: "Arginine",
threeLettersName: "Arg",
hydrophobicity: -4.5,
colorByFamily: "#FFC0CB",
color: "#190000"
color: "hsl(258.1, 100%, 69%)"
},
N: {
value: "N",
name: "Asparagine",
threeLettersName: "Asn",
hydrophobicity: -3.5,
colorByFamily: "#D3D3D3",
color: "#4D0000"
color: "hsl(268.9, 100%, 69%)"
},
D: {
value: "D",
name: "Aspartic acid",
threeLettersName: "Asp",
hydrophobicity: -3.5,
colorByFamily: "#EE82EE",
color: "#4D0000"
color: "hsl(268.9, 100%, 69%)"
},
C: {
value: "C",
name: "Cysteine",
threeLettersName: "Cys",
hydrophobicity: 2.5,
colorByFamily: "#FFFF00",
color: "#FF8080"
color: "hsl(335.1, 100%, 69%)"
},
E: {
value: "E",
name: "Glutamic acid",
threeLettersName: "Glu",
hydrophobicity: -3.5,
colorByFamily: "#EE82EE",
color: "#4D0000"
color: "hsl(268.9, 100%, 69%)"
},
Q: {
value: "Q",
name: "Glutamine",
threeLettersName: "Gln",
hydrophobicity: -3.5,
colorByFamily: "#D3D3D3",
color: "#4D0000"
color: "hsl(268.9, 100%, 69%)"
},
G: {
value: "G",
name: "Glycine",
threeLettersName: "Gly",
hydrophobicity: -0.4,
colorByFamily: "#00FFFF",
color: "#EB0000"
color: "hsl(303.1, 100%, 69%)"
},
H: {
value: "H",
name: "Histidine",
threeLettersName: "His",
hydrophobicity: -3.2,
colorByFamily: "#FFC0CB",
color: "#5C0000"
color: "hsl(272.2, 100%, 69%)"
},
I: {
value: "I",
name: "Isoleucine ",
threeLettersName: "Ile",
hydrophobicity: 4.5,
colorByFamily: "#00FFFF",
color: "#FFE6E6"
color: "hsl(356.9, 100%, 69%)"
},
L: {
value: "L",
name: "Leucine",
threeLettersName: "Leu",
hydrophobicity: 3.8,
colorByFamily: "#00FFFF",
color: "#FFC2C2"
color: "hsl(349.4, 100%, 69%)"
},
K: {
value: "K",
name: "Lysine",
threeLettersName: "Lys",
hydrophobicity: -3.9,
colorByFamily: "#FFC0CB",
color: "#380000"
color: "hsl(264.7, 100%, 69%)"
},
M: {
value: "M",
name: "Methionine",
threeLettersName: "Met",
hydrophobicity: 1.9,
colorByFamily: "#FFFF00",
color: "#FF6161"
color: "hsl(328.5, 100%, 69%)"
},
F: {
value: "F",
name: "Phenylalanine",
threeLettersName: "Phe",
hydrophobicity: 2.8,
colorByFamily: "#FFA500",
color: "#FF8F8F"
color: "hsl(338.4, 100%, 69%)"
},
P: {
value: "P",
name: "Proline",
threeLettersName: "Pro",
hydrophobicity: -1.6,
colorByFamily: "#00FFFF",
color: "#AD0000"
color: "hsl(289.9, 100%, 69%)"
},
S: {
value: "S",
name: "Serine",
threeLettersName: "Ser",
hydrophobicity: -0.8,
colorByFamily: "#90EE90",
color: "#D60000"
color: "hsl(298.6, 100%, 69%)"
},
T: {
value: "T",
name: "Threonine",
threeLettersName: "Thr",
hydrophobicity: -0.7,
colorByFamily: "#90EE90",
color: "#DB0000"
color: "hsl(299.8, 100%, 69%)"
},
U: {
value: "U",
name: "Selenocysteine",
threeLettersName: "Sec",
colorByFamily: "#FF0000",
color: "#FF0000"
color: "hsl(0, 100%, 69%)"
},
W: {
value: "W",
name: "Tryptophan",
threeLettersName: "Trp",
hydrophobicity: -0.9,
colorByFamily: "#FFA500",
color: "#D10000"
color: "hsl(297.6, 100%, 69%)"
},
Y: {
value: "Y",
name: "Tyrosine",
threeLettersName: "Tyr",
hydrophobicity: -1.3,
colorByFamily: "#FFA500",
color: "#BD0000"
color: "hsl(293.2, 100%, 69%)"
},
V: {
value: "V",
name: "Valine",
threeLettersName: "Val",
hydrophobicity: 4.2,
colorByFamily: "#00FFFF",
color: "#FFD6D6"
color: "hsl(353.6, 100%, 69%)"
},
"*": {
value: "*",
name: "Stop",
threeLettersName: "Stop",
colorByFamily: "#FF0000",
color: "#FF0000"
color: "hsl(0, 100%, 69%)"
},
".": {
//tnr: this is actually a deletion/gap character (previously we had this as a stop character which is incorrect) https://www.dnabaser.com/articles/IUPAC%20ambiguity%20codes.html
value: ".",
name: "Gap",
threeLettersName: "Stop",
threeLettersName: "Gap",
colorByFamily: "#FF0000",
color: "#FF0000"
color: "hsl(0, 100%, 69%)"
},
"-": {
value: "-",
name: "Gap",
threeLettersName: "Gap",
colorByFamily: "#FF0000",
color: "#FF0000"
color: "hsl(0, 100%, 69%)"
},
B: {
value: "B",
threeLettersName: "ND",
colorByFamily: "lightpurple",
color: "lightpurple",
colorByFamily: "#D3D3D3",
color: "hsl(268.9, 100%, 69%)",
isAmbiguous: true,
name: "B",
aliases: "ND"
},
J: {
value: "J",
threeLettersName: "IL",
colorByFamily: "lightpurple",
color: "lightpurple",
colorByFamily: "#00FFFF",
color: "hsl(352, 100%, 69%)",
isAmbiguous: true,
name: "J",
aliases: "IL"
Expand All @@ -210,16 +210,16 @@ module.exports = {
value: "X",
threeLettersName: "ACDEFGHIKLMNPQRSTVWY",
colorByFamily: "#FFFFFF",
color: "lightpurple",
color: "hsl(60, 100%, 69%)",
isAmbiguous: true,
name: "X",
aliases: "ACDEFGHIKLMNPQRSTVWY"
},
Z: {
value: "Z",
threeLettersName: "QE",
colorByFamily: "lightpurple",
color: "lightpurple",
colorByFamily: "#D3D3D3",
color: "hsl(268.9, 100%, 69%)",
isAmbiguous: true,
name: "Z",
aliases: "QE"
Expand Down
12 changes: 3 additions & 9 deletions src/tidyUpSequenceData.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -80,9 +80,7 @@ describe("tidyUpSequenceData", function() {
aminoAcid: {
value: ".",
name: "Gap",
threeLettersName: "Stop",
colorByFamily: "#FF0000",
color: "#FF0000"
threeLettersName: "Gap"
},
positionInCodon: 0,
aminoAcidIndex: 17,
Expand All @@ -97,9 +95,7 @@ describe("tidyUpSequenceData", function() {
aminoAcid: {
value: ".",
name: "Gap",
threeLettersName: "Stop",
colorByFamily: "#FF0000",
color: "#FF0000"
threeLettersName: "Gap"
},
positionInCodon: 1,
aminoAcidIndex: 17,
Expand All @@ -114,9 +110,7 @@ describe("tidyUpSequenceData", function() {
aminoAcid: {
value: ".",
name: "Gap",
threeLettersName: "Stop",
colorByFamily: "#FF0000",
color: "#FF0000"
threeLettersName: "Gap"
},
positionInCodon: 2,
aminoAcidIndex: 17,
Expand Down

0 comments on commit 411576a

Please sign in to comment.