Difference between revisions of "Team:Heidelberg/internal tools"

Line 608: Line 608:
 
                     <div style="overflow-x:scroll !important; overflow-y:hidden !important; max-height: 100px !important;">
 
                     <div style="overflow-x:scroll !important; overflow-y:hidden !important; max-height: 100px !important;">
 
                         <p>Comparison:</p>
 
                         <p>Comparison:</p>
                         <p id="outstr1" style="display:inline !important; overflow: hidden !important; white-space: nowrap !important;"></p>
+
                         <p id="outstr1" style="display:inline !important; overflow: hidden !important; white-space: nowrap !important; font-family: monospace !important;"></p>
 
                         <br>
 
                         <br>
                         <p id="outstr2" style="display:inline !important; overflow: hidden !important; white-space: nowrap !important;"></p>
+
                         <p id="outstr2" style="display:inline !important; overflow: hidden !important; white-space: nowrap !important; font-family: monospace !important;"></p>
 
                     </div>
 
                     </div>
 
                     <p id="diffinfo"></p>
 
                     <p id="diffinfo"></p>
Line 776: Line 776:
 
     var i = 0;
 
     var i = 0;
 
     while(i < str1.length){
 
     while(i < str1.length){
       while(i < str2.length){
+
       if(i==str2.length){
 +
          break;
 +
      }
 
         if(str1[i]==str2[i]){
 
         if(str1[i]==str2[i]){
 
             outstr1 += str1[i];
 
             outstr1 += str1[i];
Line 787: Line 789:
 
         }
 
         }
 
         i++;
 
         i++;
     }
+
      
 
}
 
}
 
     while(i < str1.length){
 
     while(i < str1.length){

Revision as of 20:55, 21 September 2017

WikitemplateA home - 2014.igem.org

 

WikitemplateA home

From 2014.igem.org

Internal Tools

Number of mutations and mutated sequences

Expected number of mutations in a single sequence: $$p_{m} = \frac{N_{mutations}}{L_{Sequence}} = N_{generations} \cdot r_{mutation} = t_{total} \cdot \Phi \cdot r_{mutation}$$

The expected share of sequences that shows at least one mutation in \(L_{Sequence}\) bp is the probability that \(L_{sequence}\) basepairs stay unchanged when \(\frac{N_{mutations}}{L_{Sequence}}\) mutations are expected: $$p_{M} = \frac{N_{mutated}}{N_{Sequences}} = 1 - p(N_{mutations}=0) = 1 - (1-p_{m})^{L_{Sequence}} $$

With this equation we can also calculate the number of sequences \(N_{Sequences}\) that have to be sequenced in order to find a mutated one with a probability of \(p(N_{mutated} > 0)\). $$ N_{Sequences} = \frac{p(N_{mutated} > 0)}{p_{M}} $$

The probability to find at least one mutated sequence under the given conditions is $$p(N_{mutated}>0) = 1 - (1-p_{M})^{N_{sequences}}$$ which gives $$N_{Sequences} = \frac{ln(1-p(N_{mutated}>0))}{ln(1-p_{M})}$$

Set \(\Phi\) to zero to use the number of generations for the calculation. If \(\Phi\) and the number of generations are given, \(\Phi\) is used.

Consider \(L_{Sequence}\) as the number of basepairs that is expected to be mutated. If half of the sequence you are interested in, is highly conserved choose a lower \(L_{Sequence}\).

Get your mutations


\(p_{m} =\) %(bp/bp).

\(N_{mutations} =\) bp per sequence.

The share of sequences that shows at least one mutation in \(L_{Sequence}\) bp is \(p_{M}=\) % of sequences

Diff tool

Marks differences in two strings.

Comparison: