Team:TU-Munich/AnnotatorCode.js
From 2013.igem.org
ChristopherW (Talk | contribs) |
ChristopherW (Talk | contribs) |
||
Line 198: | Line 198: | ||
* FUNCTIONS | * FUNCTIONS | ||
*/ | */ | ||
+ | |||
+ | |||
+ | function go_countingFun() { | ||
+ | var input = readSequence(); | ||
+ | var counting_result = count_amino_acids(input); | ||
+ | var amino_content = counting_result[0]; | ||
+ | var amino_freq = counting_result[1]; | ||
+ | var total_aminos = input.length; | ||
+ | var molecular_weight = compute_molecular_weight(amino_content); | ||
+ | |||
+ | // --- Create the output --- | ||
+ | var outputText = ""; | ||
+ | /* for (aa in amino_acids) { | ||
+ | outputText = outputText + " " +aa +" "+ amino_content[aa] + " " | ||
+ | + amino_freq[aa].toFixed(2) + "%" + "<br>"; | ||
+ | }; | ||
+ | */ | ||
+ | outputText = outputText | ||
+ | + "{|cellspacing=\"0\" border=\"1\" " | ||
+ | + "<br>|colspan=\"20\"|'''Automatically determined parameters using the [http://www.mediawiki.org/wiki/Table BioBrick-AutoAnnotator]'''" | ||
+ | + "<br>|-" | ||
+ | + "<br>|colspan=\"10\"|BioBrick: <partinfo>BBa_K1159000</partinfo>" | ||
+ | + "<br>|colspan=\"10\"|Used open reading frame from position ?x? to ?y?." | ||
+ | + "<br>|-" | ||
+ | + "<br>|A (Ala)" | ||
+ | + "<br>|" + amino_content.A + " (" + amino_freq.A.toFixed(2) + "%)" | ||
+ | + "<br>|R (Arg)" | ||
+ | + "<br>|" + amino_content.R + " (" + amino_freq.R.toFixed(2) + "%)" | ||
+ | + "<br>|N (Asn)" | ||
+ | + "<br>|" + amino_content.N + " (" + amino_freq.N.toFixed(2) + "%)" | ||
+ | + "<br>|D (Asp)" | ||
+ | + "<br>|" + amino_content.D + " (" + amino_freq.D.toFixed(2) + "%)" | ||
+ | + "<br>|C (Cys)" | ||
+ | + "<br>|" + amino_content.C + " (" + amino_freq.C.toFixed(2) + "%)" | ||
+ | + "<br>|Q (Gln)" | ||
+ | + "<br>|" + amino_content.Q + " (" + amino_freq.Q.toFixed(2) + "%)" | ||
+ | + "<br>|E (Glu)" | ||
+ | + "<br>|" + amino_content.E + " (" + amino_freq.E.toFixed(2) + "%)" | ||
+ | + "<br>|G (Gly)" | ||
+ | + "<br>|" + amino_content.G + " (" + amino_freq.G.toFixed(2) + "%)" | ||
+ | + "<br>|H (His)" | ||
+ | + "<br>|" + amino_content.H + " (" + amino_freq.H.toFixed(2) + "%)" | ||
+ | + "<br>|-" | ||
+ | + "<br>|K (Lys):" | ||
+ | + "<br>|" + amino_content.K + " (" + amino_freq.K.toFixed(2) + "%)" | ||
+ | + "<br>|M (Met)" | ||
+ | + "<br>|" + amino_content.M + " (" + amino_freq.M.toFixed(2) + "%)" | ||
+ | + "<br>|F (Phe)" | ||
+ | + "<br>|" + amino_content.F + " (" + amino_freq.F.toFixed(2) + "%)" | ||
+ | + "<br>|P (Pro)" | ||
+ | + "<br>|" + amino_content.P + " (" + amino_freq.P.toFixed(2) + "%)" | ||
+ | + "<br>|S (Ser)" | ||
+ | + "<br>|" + amino_content.S + " (" + amino_freq.S.toFixed(2) + "%)" | ||
+ | + "<br>|T (Thr)" | ||
+ | + "<br>|" + amino_content.T + " (" + amino_freq.T.toFixed(2) + "%)" | ||
+ | + "<br>|W (Trp)" | ||
+ | + "<br>|" + amino_content.W + " (" + amino_freq.W.toFixed(2) + "%)" | ||
+ | + "<br>|Y (Tyr)" | ||
+ | + "<br>|" + amino_content.Y + " (" + amino_freq.Y.toFixed(2) + "%)" | ||
+ | + "<br>|V (Val)" | ||
+ | + "<br>|" + amino_content.V + " (" + amino_freq.V.toFixed(2) + "%)" | ||
+ | + "<br>|-" | ||
+ | + "<br>|colspan=\"3\"|'''Amino acid counting:'''" | ||
+ | + "<br>|colspan=\"3\"|Total number of amino acids (aa):" | ||
+ | + "<br>|colspan=\"2\"|" + total_aminos | ||
+ | + "<br>|colspan=\"3\"|Number of positively charged aa:" | ||
+ | + "<br>|colspan=\"2\"|?9?" | ||
+ | + "<br>|colspan=\"3\"|Number of negatively charged aa:" | ||
+ | + "<br>|colspan=\"2\"|?9?" | ||
+ | + "<br>|-" | ||
+ | + "<br>|colspan=\"3\"|'''Biochemical parameters:'''" | ||
+ | + "<br>|colspan=\"3\"|Molecular weight [Da]:" | ||
+ | + "<br>|colspan=\"2\"|" + molecular_weight.toFixed(2) | ||
+ | + "<br>|colspan=\"3\"|Theoretical pI:" | ||
+ | + "<br>|colspan=\"2\"|?4?" | ||
+ | + "<br>|colspan=\"3\"|Extinction coefficient:" | ||
+ | + "<br>|colspan=\"2\"|?4?" | ||
+ | + "<br>|-" | ||
+ | + "<br>|colspan=\"3\"|'''Estimated half-life:'''" | ||
+ | + "<br>|colspan=\"3\"|Mammals:" | ||
+ | + "<br>|colspan=\"2\"|?4 h?" | ||
+ | + "<br>|colspan=\"3\"|Yeast:" | ||
+ | + "<br>|colspan=\"2\"|?4?" | ||
+ | + "<br>|colspan=\"3\"|''E. coli'':" | ||
+ | + "<br>|colspan=\"2\"|?4?" | ||
+ | + "<br>|-" | ||
+ | + "<br>|colspan=\"3\"|'''Codon usage:'''" | ||
+ | + "<br>|colspan=\"3\"|Mammals:" | ||
+ | + "<br>|colspan=\"2\"|?good?" | ||
+ | + "<br>|colspan=\"3\"|Yeast:" | ||
+ | + "<br>|colspan=\"2\"|?Ok?" | ||
+ | + "<br>|colspan=\"3\"|''E. coli'':" | ||
+ | + "<br>|colspan=\"2\"|?bad ?" | ||
+ | + "<br>|-" | ||
+ | + "<br>|colspan=\"3\"|'''RFC standard:'''" | ||
+ | + "<br>|colspan=\"17\"|This is a RFC 25 BioBrick, thus ATGGCCGGC and ACCGGT were added to the 5' and 3' ends." | ||
+ | + "<br>|-" | ||
+ | + "<br>|colspan=\"20\"| The BioBrick-AutoAnnotator was created by [https://2013.igem.org/Team:TU-Munich TU-Munich 2013] iGEM team. For information please read the [https://2013.igem.org/Team:TU-Munich/Results/Software description]." | ||
+ | + "<br>|}" | ||
+ | + "<br><br>"; | ||
+ | |||
+ | $("#newoutput").html(outputText); | ||
+ | $("#CountingResult").html("<strong>Copy the following into the wiki to get the protein-data-table:</strong>"); | ||
+ | |||
+ | }; | ||
function readSequence() { | function readSequence() { |
Revision as of 16:57, 15 July 2013
/**
* DATA VALUES */
var amino_acids = {A:0,R:0,N:0,D:0,C:0,Q:0,E:0,G:0,H:0,K:0,M:0,F:0,P:0,S:0,T:0,W:0,Y:0,V:0};
// amino acid weights - http://web.expasy.org/findmod/findmod_masses.html#AA var amino_weights = { "A": 71.0788, "C": 103.1388, "D": 115.0886, "E": 129.1155, "F": 147.1766, "G": 57.0519, "H": 137.1411, "I": 113.1594, "K": 128.1741, "L": 113.1594, "M": 131.1926, "N": 114.1038, "P": 97.1167, "Q": 128.1307, "R": 156.1875, "S": 87.0782, "T": 101.1051, "V": 99.1326, "W": 186.2132, "Y": 163.1760 }; var water_weight = 18.01528; //average molecular weight of one molecule of water
// Kyte & Doolittle index of hydrophobicity var kd = { 'A': 1.8, 'R':-4.5, 'N':-3.5, 'D':-3.5, 'C': 2.5,
'Q':-3.5, 'E':-3.5, 'G':-0.4, 'H':-3.2, 'I': 4.5, 'L': 3.8, 'K':-3.9, 'M': 1.9, 'F': 2.8, 'P':-1.6, 'S':-0.8, 'T':-0.7, 'W':-0.9, 'Y':-1.3, 'V': 4.2 };
// Flexibility // Normalized flexibility parameters (B-values), average (Vihinen et al., 1994) var Flex= { 'A': 0.984, 'C': 0.906, 'E': 1.094, 'D': 1.068,
'G': 1.031, 'F': 0.915, 'I': 0.927, 'H': 0.950, 'K': 1.102, 'M': 0.952, 'L': 0.935, 'N': 1.048, 'Q': 1.037, 'P': 1.049, 'S': 1.046, 'R': 1.008, 'T': 0.997, 'W': 0.904, 'V': 0.931, 'Y': 0.929};
// Hydrophilicity // 1 Hopp & Wood // Proc. Natl. Acad. Sci. U.S.A. 78:3824-3828(1981). var hw = { 'A':-0.5, 'R': 3.0, 'N': 0.2, 'D': 3.0, 'C':-1.0,
'Q': 0.2, 'E': 3.0, 'G': 0.0, 'H':-0.5, 'I':-1.8, 'L':-1.8, 'K': 3.0, 'M':-1.3, 'F':-2.5, 'P': 0.0, 'S': 0.3, 'T':-0.4, 'W':-3.4, 'Y':-2.3, 'V':-1.5 };
// Surface accessibility // 1 Emini Surface fractional probability var em = { 'A': 0.815, 'R': 1.475, 'N': 1.296, 'D': 1.283, 'C': 0.394,
'Q': 1.348, 'E': 1.445, 'G': 0.714, 'H': 1.180, 'I': 0.603, 'L': 0.603, 'K': 1.545, 'M': 0.714, 'F': 0.695, 'P': 1.236, 'S': 1.115, 'T': 1.184, 'W': 0.808, 'Y': 1.089, 'V': 0.606 };
// 2 Janin Interior to surface transfer energy scale var ja = { 'A': 0.28, 'R':-1.14, 'N':-0.55, 'D':-0.52, 'C': 0.97,
'Q':-0.69, 'E':-1.01, 'G': 0.43, 'H':-0.31, 'I': 0.60, 'L': 0.60, 'K':-1.62, 'M': 0.43, 'F': 0.46, 'P':-0.42, 'S':-0.19, 'T':-0.32, 'W': 0.29, 'Y':-0.15, 'V': 0.60 };
// A two dimentional dictionary for calculating the instability index. // Guruprasad K., Reddy B.V.B., Pandit M.W. Protein Engineering 4:155-161(1990). // It is based on dipeptide values therefore the vale for the dipeptide DG is DIWV['D']['G']. var DIWV = { 'A': {'A': 1.0, 'C': 44.94, 'E': 1.0, 'D': -7.49,
'G': 1.0, 'F': 1.0, 'I': 1.0, 'H': -7.49, 'K': 1.0, 'M': 1.0, 'L': 1.0, 'N': 1.0, 'Q': 1.0, 'P': 20.26, 'S': 1.0, 'R': 1.0, 'T': 1.0, 'W': 1.0, 'V': 1.0, 'Y': 1.0 }, 'C': {'A': 1.0, 'C': 1.0, 'E': 1.0, 'D': 20.26, 'G': 1.0, 'F': 1.0, 'I': 1.0, 'H': 33.60, 'K': 1.0, 'M': 33.60, 'L': 20.26, 'N': 1.0, 'Q': -6.54, 'P': 20.26, 'S': 1.0, 'R': 1.0, 'T': 33.60, 'W': 24.68, 'V': -6.54, 'Y': 1.0}, 'E': {'A': 1.0, 'C': 44.94, 'E': 33.60, 'D': 20.26, 'G': 1.0, 'F': 1.0, 'I': 20.26, 'H': -6.54, 'K': 1.0, 'M': 1.0, 'L': 1.0, 'N': 1.0, 'Q': 20.26, 'P': 20.26, 'S': 20.26, 'R': 1.0, 'T': 1.0, 'W': -14.03, 'V': 1.0, 'Y': 1.0}, 'D': {'A': 1.0, 'C': 1.0, 'E': 1.0, 'D': 1.0, 'G': 1.0, 'F': -6.54, 'I': 1.0, 'H': 1.0, 'K': -7.49, 'M': 1.0, 'L': 1.0, 'N': 1.0, 'Q': 1.0, 'P': 1.0, 'S': 20.26, 'R': -6.54, 'T': -14.03, 'W': 1.0, 'V': 1.0, 'Y': 1.0}, 'G': {'A': -7.49, 'C': 1.0, 'E': -6.54, 'D': 1.0, 'G': 13.34, 'F': 1.0, 'I': -7.49, 'H': 1.0, 'K': -7.49, 'M': 1.0, 'L': 1.0, 'N': -7.49, 'Q': 1.0, 'P': 1.0, 'S': 1.0, 'R': 1.0, 'T': -7.49, 'W': 13.34, 'V': 1.0, 'Y': -7.49}, 'F': {'A': 1.0, 'C': 1.0, 'E': 1.0, 'D': 13.34, 'G': 1.0, 'F': 1.0, 'I': 1.0, 'H': 1.0, 'K': -14.03, 'M': 1.0, 'L': 1.0, 'N': 1.0, 'Q': 1.0, 'P': 20.26, 'S': 1.0, 'R': 1.0, 'T': 1.0, 'W': 1.0, 'V': 1.0, 'Y': 33.601}, 'I': {'A': 1.0, 'C': 1.0, 'E': 44.94, 'D': 1.0, 'G': 1.0, 'F': 1.0, 'I': 1.0, 'H': 13.34, 'K': -7.49, 'M': 1.0, 'L': 20.26, 'N': 1.0, 'Q': 1.0, 'P': -1.88, 'S': 1.0, 'R': 1.0, 'T': 1.0, 'W': 1.0, 'V': -7.49, 'Y': 1.0}, 'H': {'A': 1.0, 'C': 1.0, 'E': 1.0, 'D': 1.0, 'G': -9.37, 'F': -9.37, 'I': 44.94, 'H': 1.0, 'K': 24.68, 'M': 1.0, 'L': 1.0, 'N': 24.68, 'Q': 1.0, 'P': -1.88, 'S': 1.0, 'R': 1.0, 'T': -6.54, 'W': -1.88, 'V': 1.0, 'Y': 44.94}, 'K': {'A': 1.0, 'C': 1.0, 'E': 1.0, 'D': 1.0, 'G': -7.49, 'F': 1.0, 'I': -7.49, 'H': 1.0, 'K': 1.0, 'M': 33.60, 'L': -7.49, 'N': 1.0, 'Q': 24.64, 'P': -6.54, 'S': 1.0, 'R': 33.60, 'T': 1.0, 'W': 1.0, 'V': -7.49, 'Y': 1.0}, 'M': {'A': 13.34, 'C': 1.0, 'E': 1.0, 'D': 1.0, 'G': 1.0, 'F': 1.0, 'I': 1.0, 'H': 58.28, 'K': 1.0, 'M': -1.88, 'L': 1.0, 'N': 1.0, 'Q': -6.54, 'P': 44.94, 'S': 44.94, 'R': -6.54, 'T': -1.88, 'W': 1.0, 'V': 1.0, 'Y': 24.68}, 'L': {'A': 1.0, 'C': 1.0, 'E': 1.0, 'D': 1.0, 'G': 1.0, 'F': 1.0, 'I': 1.0, 'H': 1.0, 'K': -7.49, 'M': 1.0, 'L': 1.0, 'N': 1.0, 'Q': 33.60, 'P': 20.26, 'S': 1.0, 'R': 20.26, 'T': 1.0, 'W': 24.68, 'V': 1.0, 'Y': 1.0}, 'N': {'A': 1.0, 'C': -1.88, 'E': 1.0, 'D': 1.0, 'G': -14.03, 'F': -14.03, 'I': 44.94, 'H': 1.0, 'K': 24.68, 'M': 1.0, 'L': 1.0, 'N': 1.0, 'Q': -6.54, 'P': -1.88, 'S': 1.0, 'R': 1.0, 'T': -7.49, 'W': -9.37, 'V': 1.0, 'Y': 1.0}, 'Q': {'A': 1.0, 'C': -6.54, 'E': 20.26, 'D': 20.26, 'G': 1.0, 'F': -6.54, 'I': 1.0, 'H': 1.0, 'K': 1.0, 'M': 1.0, 'L': 1.0, 'N': 1.0, 'Q': 20.26, 'P': 20.26, 'S': 44.94, 'R': 1.0, 'T': 1.0, 'W': 1.0, 'V': -6.54, 'Y': -6.54}, 'P': {'A': 20.26, 'C': -6.54, 'E': 18.38, 'D': -6.54, 'G': 1.0, 'F': 20.26, 'I': 1.0, 'H': 1.0, 'K': 1.0, 'M': -6.54, 'L': 1.0, 'N': 1.0, 'Q': 20.26, 'P': 20.26, 'S': 20.26, 'R': -6.54, 'T': 1.0, 'W': -1.88, 'V': 20.26, 'Y': 1.0}, 'S': {'A': 1.0, 'C': 33.60, 'E': 20.26, 'D': 1.0, 'G': 1.0, 'F': 1.0, 'I': 1.0, 'H': 1.0, 'K': 1.0, 'M': 1.0, 'L': 1.0, 'N': 1.0, 'Q': 20.26, 'P': 44.94, 'S': 20.26, 'R': 20.26, 'T': 1.0, 'W': 1.0, 'V': 1.0, 'Y': 1.0}, 'R': {'A': 1.0, 'C': 1.0, 'E': 1.0, 'D': 1.0, 'G': -7.49, 'F': 1.0, 'I': 1.0, 'H': 20.26, 'K': 1.0, 'M': 1.0, 'L': 1.0, 'N': 13.34, 'Q': 20.26, 'P': 20.26, 'S': 44.94, 'R': 58.28, 'T': 1.0, 'W': 58.28, 'V': 1.0, 'Y': -6.54}, 'T': {'A': 1.0, 'C': 1.0, 'E': 20.26, 'D': 1.0, 'G': -7.49, 'F': 13.34, 'I': 1.0, 'H': 1.0, 'K': 1.0, 'M': 1.0, 'L': 1.0, 'N': -14.03, 'Q': -6.54, 'P': 1.0, 'S': 1.0, 'R': 1.0, 'T': 1.0, 'W': -14.03, 'V': 1.0, 'Y': 1.0}, 'W': {'A': -14.03, 'C': 1.0, 'E': 1.0, 'D': 1.0, 'G': -9.37, 'F': 1.0, 'I': 1.0, 'H': 24.68, 'K': 1.0, 'M': 24.68, 'L': 13.34, 'N': 13.34, 'Q': 1.0, 'P': 1.0, 'S': 1.0, 'R': 1.0, 'T': -14.03, 'W': 1.0, 'V': -7.49, 'Y': 1.0}, 'V': {'A': 1.0, 'C': 1.0, 'E': 1.0, 'D': -14.03, 'G': -7.49, 'F': 1.0, 'I': 1.0, 'H': 1.0, 'K': -1.88, 'M': 1.0, 'L': 1.0, 'N': 1.0, 'Q': 1.0, 'P': 20.26, 'S': 1.0, 'R': 1.0, 'T': -7.49, 'W': 1.0, 'V': 1.0, 'Y': -6.54}, 'Y': {'A': 24.68, 'C': 1.0, 'E': -6.54, 'D': 24.68, 'G': -7.49, 'F': 1.0, 'I': 1.0, 'H': 13.34, 'K': 1.0, 'M': 44.94, 'L': 1.0, 'N': 1.0, 'Q': 1.0, 'P': 13.34, 'S': 1.0, 'R': -15.91, 'T': -7.49, 'W': -9.37, 'V': 1.0, 'Y': 13.34} };
// Data for the calculation of the Isoelectric Point /* pK values are from:
* Bjellqvist, B.,Hughes, G.J., Pasquali, Ch., Paquet, N., Ravier, F., Sanchez,
J.-Ch., Frutiger, S. & Hochstrasser, D.F. The focusing positions of polypeptides in immobilized pH gradients can be predicted from their amino acid sequences. Electrophoresis 1993, 14, 1023-1031. * Bjellqvist, B., Basse, B., Olsen, E. and Celis, J.E. Reference points for comparisons of two-dimensional maps of proteins from different human cell types defined in a pH scale where isoelectric points correlate with polypeptide compositions. Electrophoresis 1994, 15, 529-539.
- /
var positive_pKs = {'Nterm': 7.5 , 'K': 10.0, 'R': 12.0, 'H': 5.98 }; var negative_pKs = {'Cterm': 3.55, 'D': 4.05, 'E': 4.45, 'C': 9.0 , 'Y': 10.0}; var pKcterminal = {'D': 4.55, 'E': 4.75}; var pKnterminal = {'A': 7.59, 'M': 7.0, 'S': 6.93, 'P': 8.36, 'T': 6.82, 'V': 7.44, 'E': 7.7}; var charged_aas = ['K', 'R', 'H', 'D', 'E', 'C', 'Y']; // or ProMost?
/**
* FUNCTIONS */
function go_countingFun() {
var input = readSequence();
var counting_result = count_amino_acids(input);
var amino_content = counting_result[0];
var amino_freq = counting_result[1];
var total_aminos = input.length;
var molecular_weight = compute_molecular_weight(amino_content);
// --- Create the output ---
var outputText = "";
/* for (aa in amino_acids) {
outputText = outputText + " " +aa +" "+ amino_content[aa] + " "
+ amino_freq[aa].toFixed(2) + "%" + "
";
};
- /
outputText = outputText
+ "{|cellspacing=\"0\" border=\"1\" "
+ "
|colspan=\"20\"|Automatically determined parameters using the [http://www.mediawiki.org/wiki/Table BioBrick-AutoAnnotator]"
+ "
|-"
+ "
|colspan=\"10\"|BioBrick: <partinfo>BBa_K1159000</partinfo>"
+ "
|colspan=\"10\"|Used open reading frame from position ?x? to ?y?."
+ "
|-"
+ "
|A (Ala)"
+ "
|" + amino_content.A + " (" + amino_freq.A.toFixed(2) + "%)"
+ "
|R (Arg)"
+ "
|" + amino_content.R + " (" + amino_freq.R.toFixed(2) + "%)"
+ "
|N (Asn)"
+ "
|" + amino_content.N + " (" + amino_freq.N.toFixed(2) + "%)"
+ "
|D (Asp)"
+ "
|" + amino_content.D + " (" + amino_freq.D.toFixed(2) + "%)"
+ "
|C (Cys)"
+ "
|" + amino_content.C + " (" + amino_freq.C.toFixed(2) + "%)"
+ "
|Q (Gln)"
+ "
|" + amino_content.Q + " (" + amino_freq.Q.toFixed(2) + "%)"
+ "
|E (Glu)"
+ "
|" + amino_content.E + " (" + amino_freq.E.toFixed(2) + "%)"
+ "
|G (Gly)"
+ "
|" + amino_content.G + " (" + amino_freq.G.toFixed(2) + "%)"
+ "
|H (His)"
+ "
|" + amino_content.H + " (" + amino_freq.H.toFixed(2) + "%)"
+ "
|-"
+ "
|K (Lys):"
+ "
|" + amino_content.K + " (" + amino_freq.K.toFixed(2) + "%)"
+ "
|M (Met)"
+ "
|" + amino_content.M + " (" + amino_freq.M.toFixed(2) + "%)"
+ "
|F (Phe)"
+ "
|" + amino_content.F + " (" + amino_freq.F.toFixed(2) + "%)"
+ "
|P (Pro)"
+ "
|" + amino_content.P + " (" + amino_freq.P.toFixed(2) + "%)"
+ "
|S (Ser)"
+ "
|" + amino_content.S + " (" + amino_freq.S.toFixed(2) + "%)"
+ "
|T (Thr)"
+ "
|" + amino_content.T + " (" + amino_freq.T.toFixed(2) + "%)"
+ "
|W (Trp)"
+ "
|" + amino_content.W + " (" + amino_freq.W.toFixed(2) + "%)"
+ "
|Y (Tyr)"
+ "
|" + amino_content.Y + " (" + amino_freq.Y.toFixed(2) + "%)"
+ "
|V (Val)"
+ "
|" + amino_content.V + " (" + amino_freq.V.toFixed(2) + "%)"
+ "
|-"
+ "
|colspan=\"3\"|Amino acid counting:"
+ "
|colspan=\"3\"|Total number of amino acids (aa):"
+ "
|colspan=\"2\"|" + total_aminos
+ "
|colspan=\"3\"|Number of positively charged aa:"
+ "
|colspan=\"2\"|?9?"
+ "
|colspan=\"3\"|Number of negatively charged aa:"
+ "
|colspan=\"2\"|?9?"
+ "
|-"
+ "
|colspan=\"3\"|Biochemical parameters:"
+ "
|colspan=\"3\"|Molecular weight [Da]:"
+ "
|colspan=\"2\"|" + molecular_weight.toFixed(2)
+ "
|colspan=\"3\"|Theoretical pI:"
+ "
|colspan=\"2\"|?4?"
+ "
|colspan=\"3\"|Extinction coefficient:"
+ "
|colspan=\"2\"|?4?"
+ "
|-"
+ "
|colspan=\"3\"|Estimated half-life:"
+ "
|colspan=\"3\"|Mammals:"
+ "
|colspan=\"2\"|?4 h?"
+ "
|colspan=\"3\"|Yeast:"
+ "
|colspan=\"2\"|?4?"
+ "
|colspan=\"3\"|E. coli:"
+ "
|colspan=\"2\"|?4?"
+ "
|-"
+ "
|colspan=\"3\"|Codon usage:"
+ "
|colspan=\"3\"|Mammals:"
+ "
|colspan=\"2\"|?good?"
+ "
|colspan=\"3\"|Yeast:"
+ "
|colspan=\"2\"|?Ok?"
+ "
|colspan=\"3\"|E. coli:"
+ "
|colspan=\"2\"|?bad ?"
+ "
|-"
+ "
|colspan=\"3\"|RFC standard:"
+ "
|colspan=\"17\"|This is a RFC 25 BioBrick, thus ATGGCCGGC and ACCGGT were added to the 5' and 3' ends."
+ "
|-"
+ "
|colspan=\"20\"| The BioBrick-AutoAnnotator was created by TU-Munich 2013 iGEM team. For information please read the description."
+ "
|}"
+ "
";
$("#newoutput").html(outputText); $("#CountingResult").html("Copy the following into the wiki to get the protein-data-table:");
};
function readSequence() { var sequence = document.getElementById("EnteredSequence").value; var cleanSequence = sequence.replace(/ /g, ""); return cleanSequence; };
function count_amino_acids(sequence){
//Counts standard amino acids, returns an array {AminoAcid:Number}
var amino_acids_content = {A:0,R:0,N:0,D:0,C:0,Q:0,E:0,G:0,H:0,K:0,M:0,F:0,P:0,S:0,T:0,W:0,Y:0,V:0}; var amino_acids_freq = {A:0,R:0,N:0,D:0,C:0,Q:0,E:0,G:0,H:0,K:0,M:0,F:0,P:0,S:0,T:0,W:0,Y:0,V:0}; for (i=0; i<sequence.length; i++){ amino_acids_content[sequence[i]]++; } var total=sequence.length; for (aa in amino_acids){ amino_acids_freq[aa] = amino_acids_content[aa] * (100 / total); }; return [amino_acids_content,amino_acids_freq]; };
function compute_molecular_weight(amino_acids_content){ var molec_weight = water_weight; for (aa in amino_acids){ molec_weight = molec_weight + amino_acids_content[aa] * amino_weights[aa]; } return molec_weight; }
function findReadingFrame(sequence){ var a = 0; return a; }