summaryrefslogtreecommitdiffstats
path: root/index.html
blob: aa3a25b94e89dcdd16bd9949b16096e0b83cb1ca (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
<!DOCTYPE html>
<html lang='en'>
  <head>
    <meta charset='utf-8'>
    <meta name='viewport'
          content='width=device-width, initial-scale=1.0'>
    <title>Molecular Evolution Simulator for Amino Acids</title>
    <link rel='shortcut icon' href='favicon.png' type='image/png'>
    <link rel='stylesheet' href='style.css'>
    <link rel='stylesheet' media='only screen'
	  href='mobile.css'>
    <link rel='stylesheet' media='only screen and (min-width: 768px)'
	  href='tablet.css'>
    <link rel='stylesheet' media='only screen and (min-width: 1024px)'
	  href='desktop.css'>
    <link rel='stylesheet' media='only print'
	  href='print.css'>
  </head>

  <body>
    <ol id='genome-history' start='0'></ol>
    </ol>

    <div id='instructions'>
      <div id='die'>
        <div class='value'>--</div>
        <button class='roll' disabled=''>Roll</button>
      </div>

      <span id='remaining-iterations'>--</span> more times:
      <ol>
        <li id='clone-nucleotide' class='step'>
          <button id='clone' disabled=''>Clone</button> the genome to
          start mutating it.
        </li>

        <li id='roll-for-nucleotide' class='step'>
          Roll to find the nucleotide to mutate.
          <ul>
            <li>If the roll is between 1 through 18, inclusive, select
              that nucleotide.</li>
            <li>Otherwise, skip mutation and clone the genome
              again.</li>
          </ul>
        </li>

        <li id='nucleotide-select' class='step'>
          Select the <span id='select-number'>rolled</span>
          nucleotide in the sequence.
        </li>

        <li id='roll-for-mutation' class='step'>
          Roll to see what kind of mutation to perform.
        </li>

        <li id='perform-mutation' class='step'>
          Depending on the roll:

          <ul>
            <li>If the roll is between 1 through 14, inclusive, perform
              a <em>transition</em> on the selected nucleotide.</li>

            <li>If the roll is between 15 through 17, inclusive,
              perform a <em>complementing transversion</em> on the selected
              nucleotide to the base it pairs with.</li>

            <li>Otherwise, perform the <em>other transversion</em> on
              the selected nucleotide.</li>
          </ul>
        </li>

        <li id='amino-acid-select' class='step'>
          Select the correct amino acid for the new codon.
        </li>

        <li id='mark-as-lethal'>
          Depending on the change to the codon:
          <ul>
            <li>If the mutation caused a change in the amino acid being
              coded, mark this mutation as <em>lethal</em>, and start
              over with the genome from the previous iteration.</li>

            <li>Otherwise, mark the mutation as <em>non-lethal</em>,
              and continue with this new genome.</li>
          </ul>
        </li>
      </ol>

      <p id='print-results' class='step'>
        <button id='print' disabled=''>Print</button> results.
      </p>
    </div>

    <div id='errors' class='hidden'>
      <p></p>
      <button>OK</button>
    </div>

    <ul id='nucleotide-selector' class='hidden'>
      <li>A</li>
      <li>G</li>
      <li>C</li>
      <li>T</li>
    </ul>

    <div id='amino-acid-selector' class='hidden'>
      <p>Select the amino acid for the codon <span class='codon'>--</span></p>
      <ul>
        <li>Ala</li>
        <li>Arg</li>
        <li>Asn</li>
        <li>Asp</li>
        <li>Cys</li>
        <li>Gln</li>
        <li>Glu</li>
        <li>Gly</li>
        <li>His</li>
        <li>Ile</li>
        <li>Leu</li>
        <li>Lys</li>
        <li>Met</li>
        <li>Phe</li>
        <li>Pro</li>
        <li>Ser</li>
        <li>Thr</li>
        <li>Trp</li>
        <li>Tyr</li>
        <li>Val</li>
        <li>STOP</li>
      </ul>
    </div>

    <div id='lethality-selector' class='hidden'>
      <button id='lethal'>Lethal</button>
      <button id='non-lethal'>Non-lethal</button>
    </div>

    <script src='main.mjs' type='module'></script>
  </body>
</html>