Difference between revisions of "Team:Wageningen UR/Software"

Line 20: Line 20:
 
<html>
 
<html>
 
<section id="TS_intro">
 
<section id="TS_intro">
<h1>Introduction</h1>
+
<h1>Toxin Scanner</h1>
 
<h3>iGEM and sequencing</h3>     
 
<h3>iGEM and sequencing</h3>     
<p>For iGEM 2016 we designed a high-throughput pipeline for the identification of novel proteins directly from raw genome sequencing data in fasta or fastq format. Given the specificity of our tool (link naar resultaat), and the importance of biobrick discovery in iGEM, we made this tool publicly available for everyone to modify and use. It can be found in this <a href=https://gitlab.com/rphdejongh/bioinformatics.git> Gitlab repository </a>.  
+
<p>For iGEM 2016 we designed a high-throughput pipeline for the identification of novel proteins directly from raw genome sequencing data in fasta or fastq format. Given the specificity of our tool and the importance of biobrick discovery in iGEM, we made this tool publicly available for everyone to modify and use. It can be found in this <a href=https://gitlab.com/rphdejongh/bioinformatics.git> Gitlab repository </a>.  
  
For the purpose of the BeeT project, we use it as a cry toxin (oid) predictor, given genomes of selected bacteria. </p>
+
For the purpose of the BeeT project, we use it as a cry toxin (oid) predictor, given genomes of selected bacteria. With some modifications it has the potential to be a more broadly applicable tool for finding specific genes in newly sequenced genomes. </p>
 
<h3>Background</h3>
 
<h3>Background</h3>
<p>For this project we needed a toxin specific to <i>Varroa destructor</i>. There are many insecticidal protein families, but the one we were most interested in are the "crystal" (or 'cry') proteins. These are usually found on plasmids found in <i>Bacillus Thuringiensis</i> and related species. <sup><a href="#ts14" id="ref_ts14">14</a></sup>  
+
<p>For this project we need a toxin specific to <i>Varroa destructor</i>. There are many insecticidal protein families, but the one we were most interested in are the "crystal" (or "cry") proteins. These are usually found on plasmids found in <i>Bacillus Thuringiensis</i> and related species. <sup><a href="#ts14" id="ref_ts14">14</a></sup>  
  
  
We know varroa-specific insecticidal activity exist in <i>Bacillus thuringiensis</i> and related species, due to a paper called: "In vitro susceptibility of <i>Varroa destructor </i>and <i>Apis mellifera</i> to native strains of <i>Bacillus thuringiensis</i>."  by Alquisira-Ramírez et al. <sup><a href="#ts2" id="ref_ts2">2</a></sup> In this paper several isolates are described that cause a mite mortality of up to 100% mite mortality. Importantly the strains also showed no insecticidal activity against bee larvae! Because of this we started several sub-projects in parallel to maximize our chances of finding a viable <i>V. destructor</i>-killer. The <a href=https://2016.igem.org/Team:Wageningen_UR/Description/Specificity>specificity</a>  
+
We know <i>Varroa</i>-specific insecticidal activity exists in <i>Bacillus thuringiensis</i> and related species, due to a paper called: "In vitro susceptibility of <i>Varroa destructor </i>and <i>Apis mellifera</i> to native strains of <i>Bacillus thuringiensis</i>."  by Alquisira-Ramírez et al. <sup><a href="#ts2" id="ref_ts2">2</a></sup> In this paper several isolates are described that cause a mite mortality of up to 100%. Importantly the strains also showed no insecticidal activity against bee larvae. Because of this we started several sub-projects in parallel to maximize our chances of finding a viable <i>V. destructor</i>-killer. The <a href=https://2016.igem.org/Team:Wageningen_UR/Description/Specificity>specificity</a>  
  part of our project focusses on  <a href=https://2016.igem.org/Team:Wageningen_UR/Description/Specificity#ToxinEngineering> creating </a> <i>V. destructor</i>-binding cry toxins and <a href=https://2016.igem.org/Team:Wageningen_UR/Description/Specificity#Isolates2> finding </a> <i>V. destructor</i>-specific insecticidal proteins.  
+
  part of our project focuses on  <a href=https://2016.igem.org/Team:Wageningen_UR/Description/Specificity#ToxinEngineering> creating </a> <i>V. destructor</i>-binding cry toxins and <a href=https://2016.igem.org/Team:Wageningen_UR/Description/Specificity#Isolates2> finding </a> <i>V. destructor</i>-specific insecticidal proteins.  
 
<br>
 
<br>
 
This tool was made in preparation for results of the latter, finding <i>V. destructor</i>-specific insecticidal proteins, which we assume to be of the cry protein family.  
 
This tool was made in preparation for results of the latter, finding <i>V. destructor</i>-specific insecticidal proteins, which we assume to be of the cry protein family.  
These cry proteins are a diverse group, but are known to be highly specific for individual insects and nematodes. Cry proteins are not necessarily a group of proteins that all perform the same function in the same manner. The distinction between cry and not a cry protein is defined by a committee: <a href=http://www.lifesci.sussex.ac.uk/home/Neil_Crickmore/Bt/>Cry Protein website</a> Based on 45% sequence similarity there are over 70 groups, this high amount of diversity makes it hard to predict when something is or isn't a cry protein.  
+
These cry proteins are a diverse group, but are known to be highly specific for individual insects and nematodes. Cry proteins are not necessarily a group of proteins that all perform the same function in the same manner. The distinction between cry and non-cry proteins is defined by a committee: <a href=http://www.lifesci.sussex.ac.uk/home/Neil_Crickmore/Bt/>Cry Protein website</a> Based on 45% sequence similarity there are over 70 groups, this high amount of diversity makes it hard to predict when something is or isn't a cry protein.  
  
 
<h3>Current developments</h3>  
 
<h3>Current developments</h3>  
<p>There already exists publication about a tool called “Bt Toxin Scanner”<sup><a href="#ts1" id="ref_ts1">1</a></sup>, which inspired us to make our own tool. Due to the tool not being fully supported for local deployment, which is needed for high-throughput analysis, and the relatively basic analysis done by the tool, we decided to develop our own tool that is fully open-source and improves upon the Bt Toxin Scanner. Our goal with this tool is to run raw sequencing files, and deliver potential cry proteins with just the click of a button.</p>
+
<p>There already exists a publication about a tool called “Bt Toxin Scanner”<sup><a href="#ts1" id="ref_ts1">1</a></sup>. This tool does not fully support local deployment, which is needed for high-throughput analysis, and the relatively basic analysis done by the tool. Due to these reasons we decided to develop our own tool that is fully open-source and improves upon the Bt Toxin Scanner. Our goal with this tool is to run raw sequencing files, and deliver potential cry proteins with just the click of a button.</p>
 
</section>
 
</section>
  
Line 42: Line 42:
 
<h1>Methods</h1>
 
<h1>Methods</h1>
 
<h3>Overview</h3><p>
 
<h3>Overview</h3><p>
The entire pipeline consists of four scripts in total, one of which is entirely dedicated to analysis of the Random Forest model and not further used in the main program. The others are there to group the Machine Learning specific functions, the functions that handle known cry proteins, and the functions that handle raw sequence data. Figure 1 gives a graphical representation of the pipeline, though some modules have been left out for readability's sake.
+
We use a combination of existing tools to come to the prediction of novel cry proteins. The entire pipeline consists of four scripts in total, one of which is entirely dedicated to analysis of the Random Forest model and not further used in the main program. The others are there to group the Machine Learning specific functions, the functions that handle known cry proteins, and the functions that handle raw sequence data. Figure 1 gives a graphical representation of the pipeline, though some modules have been left out for the sake of readabilit. Here, we shall go through each part of the process in a step-by-step manner.
  
 
<figure><img src="Figure not yet uploaded."><figcaption>Figure 1: A graphical representation of the pipeline showing the various methods and tools used.</figcaption></figure>
 
<figure><img src="Figure not yet uploaded."><figcaption>Figure 1: A graphical representation of the pipeline showing the various methods and tools used.</figcaption></figure>
 
</p>
 
</p>
<h2>Stepwise description</h2>
+
<h2>Software description</h2>
 
<h3>Genome assembly</h3>
 
<h3>Genome assembly</h3>
<p>Raw genome data directly from a Next Generation Sequencing device comes in the form of files containing many pieces of DNA called ‘reads’. These reads are usually obtained through cutting up the genome and sequencing the small bits at random after amplifying them many times. The idea is that many pieces will overlap and so the reads can be assembled like a big puzzle. Our pipeline uses a <i>De Novo</i> assembler, meaning that it can assemble the reads from scratch, without a reference to map them to. It does this using a 'graph based approach.'<sup><a href="#ts3" id="ref_ts3">3</a></sup>   
+
<p>Raw genome data directly from a Next Generation Sequencing device comes in the form of files containing many pieces of DNA called ‘reads’. These reads are usually obtained through cutting up the genome and sequencing the small bits at random after amplifying them many times. The idea is that many reads will overlap and can be assembled like a big puzzle. Our pipeline uses a <i>de novo</i> assembler, meaning that it can assemble the reads from scratch, without a reference genome to map them to. This is done by a  
Once the genome is assembled into 'contigs' we can start doing gene prediction.
+
<a class="tooltip"> 'graph-based approach' <span class="tooltiptext" style="width:500px;">
 +
The nodes of the graph represent whole reads or parts of each read called k-mers, while the edges represent the overlap between them.</span></a>.
 +
<sup><a href="#ts3" id="ref_ts3">3</a></sup>   
 +
Once the genome is assembled into <a class="tooltip">contigs <span class="tooltiptext" style="width:500px;">
 +
A contig is a closed loop in the graph, the longest stretches of DNA possible from all of the reads.</span></a>
 +
we can start doing gene prediction. In this pipeline we used the
 +
<a class="tooltip"> IDBA-UD <span class="tooltiptext" style="width:500px;">
 +
The Iterative De Bruijn Graph De Novo Assembler for highly Uneven sequencing Depth (<a href=http://i.cs.hku.hk/~alse/hkubrg/projects/idba_ud/>IDBA-UD</a>) is a tool for assembling genomes in a <i>de novo</i> manner. </span></a>.
 +
<sup><a href="#ts15" id="ref_ts15">15</a></sup> 
 
</p>
 
</p>
 
<h3>Gene prediction</h3>
 
<h3>Gene prediction</h3>
<p>The pipeline does gene prediction through using Hidden Markov Models (HMM) <sup><a href="#ts4" id="ref_ts4">4</a></sup>   
+
<p>The pipeline does gene prediction through the use of Hidden Markov Models (HMM) <sup><a href="#ts4" id="ref_ts4">4</a></sup>   
that have been trained to distinguish between prokaryotic coding and non-coding regions. These regions we then translate using BioPython's <sup><a href="#ts6" id="ref_ts6">6</a></sup>
+
that have been trained to distinguish between prokaryotic coding and non-coding regions. These regions are then translated using BioPython's <sup><a href="#ts6" id="ref_ts6">6</a></sup> translate function. These are the proteins we compare to our existing  <a href=http://www.lifesci.sussex.ac.uk/home/Neil_Crickmore/Bt/toxins2.html> Cry Protein database</a> <sup><a href="#ts5" id="ref_ts5">5</a></sup> 
translate function. These are the proteins we compare to our existing  <a href=http://www.lifesci.sussex.ac.uk/home/Neil_Crickmore/Bt/toxins2.html> Cry Protein database</a> <sup><a href="#ts5" id="ref_ts5">5</a></sup>   
+
In this pipeline we used the
 +
<a class="tooltip"> GeneMarkS <span class="tooltiptext" style="width:500px;">
 +
<a href=http://exon.gatech.edu/GeneMark/> GeneMarkS</a> utilizes a non-supervised training procedure and can be used for a newly sequenced prokaryotic genome with no prior knowledge of any protein or rRNA genes.
 +
</span></a>
 +
program for this purpose. <sup><a href="#ts15" id="ref_ts15">15</a></sup>   
 
  </p>
 
  </p>
 
<h3>Machine Learning </h3>
 
<h3>Machine Learning </h3>
 
<p>As cry proteins are a group that is hard to define biologically, other than having specific insecticidal activity, it is somewhat of a challenge to find them through means other than direct sequence comparisons. This is why we use three methods to find potential cry proteins: <ol>  
 
<p>As cry proteins are a group that is hard to define biologically, other than having specific insecticidal activity, it is somewhat of a challenge to find them through means other than direct sequence comparisons. This is why we use three methods to find potential cry proteins: <ol>  
<li>A direct sequence comparison with a stringent cut-off: "Blast".</li>
+
<li>A direct sequence comparison with a stringent cut-off (e-value 0.1 or lower):  
<li>A probabilistic approach based on the primary subdivision between cry proteins (45% sequence similarity): "HMM". <sup><a href="#ts4" id="ref_ts4">4</a></sup>  </li>
+
<a class="tooltip"> BLAST <span class="tooltiptext" style="width:500px;">
<li>A machine learning approach based on protein features using many weak classifiers to give a majority vote: "RandomForest".<sup><a href="#ts7" id="ref_ts7">7</a></sup></li>
+
The Basic Local Alignment Search Tool (<b>BLAST</b>) is an algorithm for comparing sequence information, such as the amino-acid (protein) or nucleic-acid (DNA/RNA) sequences.  
</ol></p>
+
</span></a>
<h3>Output </h3>
+
<sup><a href="#ts8" id="ref_ts8">8</a></sup> Using a database of only cry proteins, this tool will allow us to rapidly identify other proteins with highly similar sequences.
<p>All three separate methods give slightly different output. In order to make an easy visual comparison a webtool was found that can easily calculate and draw custom Venn diagrams. This tool was made by the university of Gent and can be found <a href=http://bioinformatics.psb.ugent.be/webtools/Venn/>here</a>.
+
</li>
</p>
+
<li>A probabilistic approach based on the primary subdivision between cry proteins (45% sequence similarity): HMMER.
<h2>Tools Used</h2>
+
<br>
<h3>IDBA-UD</h3>
+
<p>The Iterative De Bruijn Graph De Novo Assembler for highly Uneven sequencing Depth (<a href=http://i.cs.hku.hk/~alse/hkubrg/projects/idba_ud/>IDBA-UD</a>) is a tool for assembling genomes in a de novo manner. This means that it can take raw sequencing data and use it to create longer stretches of overlapping DNA called contigs.
+
</p><h3>Gene Mark</h3>
+
<p><a href=http://exon.gatech.edu/GeneMark/> GeneMark</a> is gene prediction software, making use of HMM. This will allow us to analyze novel genomic sequences.
+
</p><h3>Blast</h3>
+
<p>The Basic Local Alignment Search Tool (<b>BLAST</b>) is an algorithm for comparing sequence information, such as the amino-acid (protein) or nucleic-acid (DNA/RNA) sequences. <sup><a href="#ts8" id="ref_ts8">8</a></sup> Using a database of only cry proteins, this tool will allow us to rapidly identify other proteins with highly similar sequences.
+
</p><h3>HMMER</h3><p>
+
 
The HMMER toolkit contains several programs that the pipeline uses. <sup><a href="#ts9" id="ref_ts9">9</a></sup> The program first builds many different profiles based on the multiple sequence alignment of the primary cry protein groups. This is handled by Clustal Omega. <sup><a href="#ts10" id="ref_ts10">10</a></sup>  
 
The HMMER toolkit contains several programs that the pipeline uses. <sup><a href="#ts9" id="ref_ts9">9</a></sup> The program first builds many different profiles based on the multiple sequence alignment of the primary cry protein groups. This is handled by Clustal Omega. <sup><a href="#ts10" id="ref_ts10">10</a></sup>  
 
<ul>
 
<ul>
Line 79: Line 84:
 
<li>HMMscan: Searches a protein sequence against a protein profile HMM database. </li>
 
<li>HMMscan: Searches a protein sequence against a protein profile HMM database. </li>
 
</ul>
 
</ul>
 +
All of these methods are still based on the same Hidden Markov Model principle <sup><a href="#ts4" id="ref_ts4">4</a></sup>.  </li>
  
 +
<li>A machine learning approach based on protein features using many weak classifiers to give a majority vote: "RandomForest".<sup><a href="#ts7" id="ref_ts7">7</a></sup> This part is explained further in the protein classification section.
 +
</li>
 +
</ol>
 +
 +
</p>
 
</p><h3>Protein Classification</h3><p>
 
</p><h3>Protein Classification</h3><p>
 
The protein classification part of the machine learning is done by the pipeline in two steps: First the features of a protein are predicted using Biopython <sup><a href="#ts6" id="ref_ts6">6</a></sup> , and then the pre-trained model predicts a class based on those features.
 
The protein classification part of the machine learning is done by the pipeline in two steps: First the features of a protein are predicted using Biopython <sup><a href="#ts6" id="ref_ts6">6</a></sup> , and then the pre-trained model predicts a class based on those features.
 
</p><h4>Features</h4><p>
 
</p><h4>Features</h4><p>
After some experimentation with the features chosen for modelling, we came up with the following list which we think will capture some structural elements and allow for good predictions. <ul>
+
After some experimentation with the features chosen for modelling, we came up with the following list which we think will capture essential structural elements and allow for good predictions. <ul>
 
<li>Molecular weight of the protein.</li>
 
<li>Molecular weight of the protein.</li>
 
<li>Aromaticity, ie the relative frequency of aromatic amino acids (Phenylalanine, Tryptophan and Tyrosine)</li>
 
<li>Aromaticity, ie the relative frequency of aromatic amino acids (Phenylalanine, Tryptophan and Tyrosine)</li>
Line 92: Line 103:
 
<li>Beta Sheet fraction, the relative frequency of amino acids that tend to be in found in the secondary structure known as beta sheets.</li>
 
<li>Beta Sheet fraction, the relative frequency of amino acids that tend to be in found in the secondary structure known as beta sheets.</li>
 
</ul>
 
</ul>
</p><h3>Scikit-Learn</h3><p>
+
</p><h4>Scikit-Learn</h4><p>
We made the classification model using scikit-learn or sklearn.<sup><a href="#ts12" id="ref_ts12">12</a></sup> The class used for this model is called the <a href=http://scikit-learn.org/stable/modules/generated/sklearn.ensemble.RandomForestClassifier.html>RandomForestClassifier</a> which works by fitting a number of decision trees, in our case 2000, on various sub-samples of the dataset and averaging to improve accuracy and control overfitting. We assess the predictive accuracy of our model by doing a stratified 10-fold crossvalidation technique from the <a href=http://scikit-learn.org/stable/modules/generated/sklearn.cross_validation.StratifiedKFold.html>StratifiedKFold</a> class. These 10 crossvalidation runs were assessed with the <a href=http://scikit-learn.org/stable/modules/generated/sklearn.metrics.roc_curve.html>ROC-curves</a> method.
+
We made the classification model using scikit-learn or sklearn.<sup><a href="#ts12" id="ref_ts12">12</a></sup> The class used for this model is called the <a href=http://scikit-learn.org/stable/modules/generated/sklearn.ensemble.RandomForestClassifier.html>RandomForestClassifier</a> which works by fitting a number of decision trees, in our case 2000, on various sub-samples of the dataset and averaging these weak classifiers to improve accuracy and control for.  
 +
<a class="tooltip">overfitting<span class="tooltiptext" style="width:500px;">
 +
Overfitting is what happens when a model follows its training data so well it can not predict anything new with any accuracy because too much of the noise from the training data has been modelled, rather than the underlying relationship.
 +
</span></a>  
  
 +
We assess the predictive accuracy of our model by doing a stratified 10-fold crossvalidation technique from the <a href=http://scikit-learn.org/stable/modules/generated/sklearn.cross_validation.StratifiedKFold.html>StratifiedKFold</a> class. These 10-fold cross-validation runs were assessed with the <a href=http://scikit-learn.org/stable/modules/generated/sklearn.metrics.roc_curve.html>roc-curves</a> method. A ROC curve is a plot of the <a class="tooltip">true positive rate <span class="tooltiptext" style="width:300px;"> (TPR)
 +
The proportion of correctly predicted instances of the testing data.  </span></a>
 +
against the <a class="tooltip">false positive rate <span class="tooltiptext" style="width:300px;"> (FPR)
 +
The proportion of wrongly predicted instances of the testing data.  </span></a>
 +
<sup><a href="#ts19" id="ref_ts19">19</a></sup> These kinds of plots are extremely useful in determining whether or not a Machine Learning model such as RandomForest is well trained.
 +
<h3>Venn-Diagrams</h3>
 +
<p>All three separate methods give a different output. In order to make an easy visual comparison, we make use of a web tool that can easily calculate and draw custom Venn-diagrams. This tool was made by the university of Gent and can be found <a href=http://bioinformatics.psb.ugent.be/webtools/Venn/>here</a>.
 
</section>
 
</section>
  
 
<section id="TS_results">
 
<section id="TS_results">
  <h1>Results / 'validation'</h1>
+
  <h1>Pipeline validation</h1>
 
<h2>PRJEB5931</h2><p>
 
<h2>PRJEB5931</h2><p>
We tested the pipeline on a genome sample from a study with accession number: <a href=http://www.ebi.ac.uk/ena/data/view/PRJEB5931> PRJEB5931</a>. <sup><a href="#ts13" id="ref_ts13">13</a></sup> This genome was found after a co-evolution experiment and   a bt with known nematicidal cry proteins present.
+
We tested the pipeline on a genome sample from a study with accession number <a href=http://www.ebi.ac.uk/ena/data/view/PRJEB5931> PRJEB5931</a>. <sup><a href="#ts13" id="ref_ts13">13</a></sup> This genome was found after a co-evolution experiment, and a <i>Bacillus thuringiensis</i> with known nematicidal cry proteins present.  
 +
<br>
 +
<a href=http://www.ebi.ac.uk/ena/data/view/ERX463573>ERX463573</a> is the accession code of the experiment from which these raw read files came. The description reads: "Population of Bacillus thuringiensis coming from 5 strains experimentally coevolved with Caenorhabditis as host" and the Name: "Coevolution G12 Pop4". From the study we know to expect at the very least the following two proteins:
 +
<a href=https://www.ncbi.nlm.nih.gov/nucleotide/47500285> Cry35Aa4 </a>
 +
and
 +
<a href=https://www.ncbi.nlm.nih.gov/nucleotide/2724454>Cry21Aa2</a>. <br>
 +
According to the cry protein toxin list it is known that Cry35Aa4 is a binary toxin with <a href=https://www.ncbi.nlm.nih.gov/nucleotide/47500295> Cry34Aa4 </a> and as such we may expect to find this protein, or one like it, as well.
 +
 
  
 
</p><h2>Key result</h2><p>
 
</p><h2>Key result</h2><p>
The easiest way to visualize what the three seperate components of the pipeline have done is to compare their results in a <a href=http://bioinformatics.psb.ugent.be/webtools/Venn/>venn diagram</a> (with accompanying lists).  
+
The easiest way to visualize the results from the three separate components of the pipeline is to use a <a href=http://bioinformatics.psb.ugent.be/webtools/Venn/>Venn diagram</a> (with accompanying lists).  
  
  
<figure><img src="Figure not yet uploaded."><figcaption>Figure 2: A venn diagram showing the overlap of the output of the various methods used to predict whether or not certain genes from the genome were cry proteins or not.</figcaption></figure>
+
<figure><img src=https://static.igem.org/mediawiki/2016/2/2c/T--Wageningen_UR--Venn-Diagram_TS.png><figcaption>Figure 2: A Venn diagram showing the overlap of the output of the various methods used to predict whether or not certain genes from the genome were cry proteins or not.</figcaption></figure>
  
 +
As Blast had only 5 results it is easier to examine this method in detail. Two of the five were proteins we were expecting from the paper: Cry35Aa4 and Cry21Aa2. These were found to be: <ul>
 +
<li>Gene_5932, which had 100.00% identity with: Cry35Aa4 </li>
 +
<li>Gene_5527, which had 96.04% identity with: Cry21Aa2</li>
 +
<ul>
 +
Based on the fact that Cry35Aa4 is a binary protein we expected to find its complementary protein as well, which we did: <ul>
 +
<li>Gene_5931, which had 100.00% identity with all four proteins in the Cry34Aa group.</li>
 +
</ul>
 +
Two other proteins appeared with a good overlap and a good e-value, namely: <ul>
 +
<li>Gene_5934, which had 98.39% identity with: Cry38Aa1, which has no known insecticidal target, but is highly similar to proteins that do: Cry15Aa1, Cry23Aa1, and Cry33Aa1.  <sup><a href="#ts17" id="ref_ts17">17</a></sup></li>
 +
<li>Gene_5518, which had 85.87% identity with: Cry14Ab1. Which is only mentioned in a patent by Sampson et al. 2012. <sup><a href="#ts18" id="ref_ts18">18</a></sup> </li>
 +
</ul>
 +
Both of these were also picked up by the Hidden Markov Model method of cry protein detection as shown in figure 2, but not by the RandomForest method.
  
</section><section id="TS_discussion">  
+
</section>
<h1>Discussion</h1>
+
 
<p>It seems to work, but the definition of cry protein is vague, so the ML could be further optimized based on a more rigorous examination of what is and what is not a cry protein.</p>
+
<section id="TS_discussion"><h1>Discussion</h1>
 +
<p>All three methods were fully able to pick up the nematicidal proteins from the study we had expected to find, and the complementary protein we predicted to be present ourselves.
 +
<h4> Blast</h4>
 +
As we had intended the Blast method proved to be the most stringent, detecting at least known cry proteins with high accuracy. However, in order to find new cry proteins that perform a similar function to a known cry protein but are not exactly like one, we can still turn to the other methods.
 +
<h4> HMM </h4>
 +
 
 +
<h4> RandomForest </h4>
 +
The ML could be further optimized based on a more rigorous examination of what is and what is not a cry protein.
 +
For 5934 the RF prediction didn’t happen because it did not have the right amount of aromatic residues, which caused a high increase in the probability of it not being a cry protein. (Instance 23 of the last list of RF_analysis.txt)
 +
 
 +
The idea behind the training set used for this model was that the model should be able to distinguish what is defined as cry and what is not cry, but still similar in sequence. To that end the uniprot database was queried and 200 proteins that came back using this query in the uniprot web interface:
 +
<code> [my list] NOT go:"sporulation resulting in formation of a cellular spore [0030435]" NOT family:"delta endotoxin" NOT cry NOT pesticidal active:yes NOT annotation:(type:"positional domain" "Endotoxin M") NOT name:crystal</code>
 +
This list of 200 proteins was investigated (somewhat)
 +
</p>
 
</section><h1>References</h1>
 
</section><h1>References</h1>
<a id="ts1" href=http://aem.asm.org/content/78/14/4795.short>1.</a> Ye, W., Zhu, L., Liu, Y., Crickmore, N., Peng, D., Ruan, L., & Sun, M. (2012). Mining new crystal protein genes from Bacillus thuringiensis on the basis of mixed plasmid-enriched genome sequencing and a computational pipeline. Applied and environmental microbiology, 78(14), 4795-4801.
+
<a id="ts1" href=http://aem.asm.org/content/78/14/4795.short>1.</a> Ye, W., Zhu, L., Liu, Y., Crickmore, N., Peng, D., Ruan, L., & Sun, M. (2012). Mining new crystal protein genes from <i>Bacillus thuringiensis</i> on the basis of mixed plasmid-enriched genome sequencing and a computational pipeline. Applied and environmental microbiology, 78(14), 4795-4801.
 
<a href="#ts1" title="Jump back to footnote 1 in the text.">↩</a>
 
<a href="#ts1" title="Jump back to footnote 1 in the text.">↩</a>
 
<br><br>
 
<br><br>
<a id="ts2" href=http://link.springer.com/article/10.1007/s13592-014-0288-z>2.</a> Alquisira-Ramírez, E. V., Paredes-Gonzalez, J. R., Hernández-Velázquez, V. M., Ramírez-Trujillo, J. A., & Peña-Chora, G. (2014). In vitro susceptibility of Varroa destructor and Apis mellifera to native strains of Bacillus thuringiensis. Apidologie, 45(6), 707-718.
+
<a id="ts2" href=http://link.springer.com/article/10.1007/s13592-014-0288-z>2.</a> Alquisira-Ramírez, E. V., Paredes-Gonzalez, J. R., Hernández-Velázquez, V. M., Ramírez-Trujillo, J. A., & Peña-Chora, G. (2014). In vitro susceptibility of Varroa destructor and Apis mellifera to native strains of <i>Bacillus thuringiensis</i>. Apidologie, 45(6), 707-718.
 
<a href="#ts2" title="Jump back to footnote 2 in the text.">↩</a>
 
<a href="#ts2" title="Jump back to footnote 2 in the text.">↩</a>
 
<br><br>
 
<br><br>
Line 125: Line 178:
 
<a href="#ts4" title="Jump back to footnote 4 in the text.">↩</a>
 
<a href="#ts4" title="Jump back to footnote 4 in the text.">↩</a>
 
<br><br>
 
<br><br>
<a id="ts5" href=http://www.btnomenclature.info/  >5.</a>  Crickmore, N., Baum, J., Bravo, A., Lereclus, D., Narva, K., Sampson, K., Schnepf, E., Sun, M. and Zeigler, D.R. "Bacillus thuringiensis toxin nomenclature" (2016)
+
<a id="ts5" href=http://www.btnomenclature.info/  >5.</a>  Crickmore, N., Baum, J., Bravo, A., Lereclus, D., Narva, K., Sampson, K., Schnepf, E., Sun, M. and Zeigler, D.R. " <i>Bacillus thuringiensis</i> toxin nomenclature" (2016)
 
http://www.btnomenclature.info/  
 
http://www.btnomenclature.info/  
 
<a href="#ts5" title="Jump back to footnote 5 in the text.">↩</a>
 
<a href="#ts5" title="Jump back to footnote 5 in the text.">↩</a>
Line 153: Line 206:
 
<a href="#ts13 " title="Jump back to footnote 13  in the text.">↩</a>
 
<a href="#ts13 " title="Jump back to footnote 13  in the text.">↩</a>
 
<br><br>
 
<br><br>
<a id="ts14" href= >14.</a>de Maagd, R. A., Bravo, A., & Crickmore, N. (2001). How Bacillus thuringiensis has evolved specific toxins to colonize the insect world. TRENDS in Genetics, 17(4), 193-199.
+
<a id="ts14" href=http://www.ncbi.nlm.nih.gov/pubmed/11275324>14.</a>de Maagd, R. A., Bravo, A., & Crickmore, N. (2001). How <i>Bacillus thuringiensis</i> has evolved specific toxins to colonize the insect world. TRENDS in Genetics, 17(4), 193-199.
 
<a href="#ts14 " title="Jump back to footnote 14  in the text.">↩</a><br><br>
 
<a href="#ts14 " title="Jump back to footnote 14  in the text.">↩</a><br><br>
<a id="ts@" href=  >@.</a>   
+
<a id="ts15" href=http://bioinformatics.oxfordjournals.org/content/28/11/1420.short >15.</a>  Peng, Y., Leung, H. C., Yiu, S. M., & Chin, F. Y. (2012). IDBA-UD: a de novo assembler for single-cell and metagenomic sequencing data with highly uneven depth. Bioinformatics, 28(11), 1420-1428.
<a href="#ts@ " title="Jump back to footnote @ in the text.">↩</a>
+
<a href="#ts15 " title="Jump back to footnote 15 in the text.">↩</a>
 
<br><br>
 
<br><br>
<a id="ts@" href= >@.</a>   
+
<a id="ts16" href=http://www.ncbi.nlm.nih.gov/pubmed/11410670>16.</a>  Besemer, J., Lomsadze, A., & Borodovsky, M. (2001). GeneMarkS: a self-training method for prediction of gene starts in microbial genomes. Implications for finding sequence motifs in regulatory regions. Nucleic acids research, 29(12), 2607-2618.
<a href="#ts@ " title="Jump back to footnote @ in the text.">↩</a>
+
<a href="#ts16 " title="Jump back to footnote 16 in the text.">↩</a>
 
<br><br>
 
<br><br>
<a id="ts@" href=  >@.</a>   
+
<a id="ts17" href=http://aem.asm.org/content/70/8/4889.long >17.</a>  Baum, J. A., Chu, C. R., Rupar, M., Brown, G. R., Donovan, W. P., Huesing, J. E., ... & Vaughn, T. (2004). Binary toxins from Bacillus thuringiensis active against the western corn rootworm, Diabrotica virgifera virgifera LeConte. Applied and environmental microbiology, 70(8), 4889-4898.
<a href="#ts@ " title="Jump back to footnote @ in the text.">↩</a>
+
<a href="#ts17 " title="Jump back to footnote 17 in the text.">↩</a>
 
<br><br>
 
<br><br>
<a id="ts@" href=  >@.</a>  
+
<a id="ts18" href= https://www.google.com/patents/US8318900 >18.</a> Sampson, K. S., Tomso, D. J., & Dumitru, R. V. (2012). U.S. Patent No. 8,318,900. Washington, DC: U.S. Patent and Trademark Office.  
<a href="#ts@ " title="Jump back to footnote @ in the text.">↩</a>
+
<a href="#ts18" title="Jump back to footnote 18  in the text.">↩</a>
 +
<br><br>
 +
<a id="ts19" href=  >19.</a> Bradley, A. P. (1997). The use of the area under the ROC curve in the evaluation of machine learning algorithms. Pattern recognition, 30(7), 1145-1159.
 +
<a href="#ts19 " title="Jump back to footnote 19 in the text.">↩</a>
 
<br><br>
 
<br><br>
<a id="ts@" href=  >@.</a> 
 
<a href="#ts@ " title="Jump back to footnote @  in the text.">↩</a>
 
 
 
Stuff I'm not sure what to do with:
 
<h3>Side features</h3><p>
 
has overwrite protection
 
can be multi threaded
 
creates its own directory structure
 
Has tools to do detailed analysis of the random forest/machine learning model created(plotting decision boundaries, interpreting specific predictions)
 
The tool can also be modified to search and compare other sets of genes against raw genome sequences. This would be done by providing different input and modifying some of the internal code handling filenames. </p>
 
 
<h4>Exploring cry protein features </h4>
 
<p>Creating sub divisions based on clustering, PCA and kmeans clustering show that the only feature where  to be made on the simple features.  Other than the proteins clustering by protein length/molecular weight, there do not seem to be clear clusters to be made based on the basic features we chose for identifying cry toxins. </p>
 
 
  
 
</html>
 
</html>
 
{{Wageningen_UR/footer}}
 
{{Wageningen_UR/footer}}

Revision as of 13:23, 12 October 2016

Wageningen UR iGEM 2016

 

Toxin Scanner

iGEM and sequencing

For iGEM 2016 we designed a high-throughput pipeline for the identification of novel proteins directly from raw genome sequencing data in fasta or fastq format. Given the specificity of our tool and the importance of biobrick discovery in iGEM, we made this tool publicly available for everyone to modify and use. It can be found in this Gitlab repository . For the purpose of the BeeT project, we use it as a cry toxin (oid) predictor, given genomes of selected bacteria. With some modifications it has the potential to be a more broadly applicable tool for finding specific genes in newly sequenced genomes.

Background

For this project we need a toxin specific to Varroa destructor. There are many insecticidal protein families, but the one we were most interested in are the "crystal" (or "cry") proteins. These are usually found on plasmids found in Bacillus Thuringiensis and related species. 14 We know Varroa-specific insecticidal activity exists in Bacillus thuringiensis and related species, due to a paper called: "In vitro susceptibility of Varroa destructor and Apis mellifera to native strains of Bacillus thuringiensis." by Alquisira-Ramírez et al. 2 In this paper several isolates are described that cause a mite mortality of up to 100%. Importantly the strains also showed no insecticidal activity against bee larvae. Because of this we started several sub-projects in parallel to maximize our chances of finding a viable V. destructor-killer. The specificity part of our project focuses on creating V. destructor-binding cry toxins and finding V. destructor-specific insecticidal proteins.
This tool was made in preparation for results of the latter, finding V. destructor-specific insecticidal proteins, which we assume to be of the cry protein family. These cry proteins are a diverse group, but are known to be highly specific for individual insects and nematodes. Cry proteins are not necessarily a group of proteins that all perform the same function in the same manner. The distinction between cry and non-cry proteins is defined by a committee: Cry Protein website Based on 45% sequence similarity there are over 70 groups, this high amount of diversity makes it hard to predict when something is or isn't a cry protein.

Current developments

There already exists a publication about a tool called “Bt Toxin Scanner”1. This tool does not fully support local deployment, which is needed for high-throughput analysis, and the relatively basic analysis done by the tool. Due to these reasons we decided to develop our own tool that is fully open-source and improves upon the Bt Toxin Scanner. Our goal with this tool is to run raw sequencing files, and deliver potential cry proteins with just the click of a button.

Methods

Overview

We use a combination of existing tools to come to the prediction of novel cry proteins. The entire pipeline consists of four scripts in total, one of which is entirely dedicated to analysis of the Random Forest model and not further used in the main program. The others are there to group the Machine Learning specific functions, the functions that handle known cry proteins, and the functions that handle raw sequence data. Figure 1 gives a graphical representation of the pipeline, though some modules have been left out for the sake of readabilit. Here, we shall go through each part of the process in a step-by-step manner.

Figure 1: A graphical representation of the pipeline showing the various methods and tools used.

Software description

Genome assembly

Raw genome data directly from a Next Generation Sequencing device comes in the form of files containing many pieces of DNA called ‘reads’. These reads are usually obtained through cutting up the genome and sequencing the small bits at random after amplifying them many times. The idea is that many reads will overlap and can be assembled like a big puzzle. Our pipeline uses a de novo assembler, meaning that it can assemble the reads from scratch, without a reference genome to map them to. This is done by a 'graph-based approach' The nodes of the graph represent whole reads or parts of each read called k-mers, while the edges represent the overlap between them.. 3 Once the genome is assembled into contigs A contig is a closed loop in the graph, the longest stretches of DNA possible from all of the reads. we can start doing gene prediction. In this pipeline we used the IDBA-UD The Iterative De Bruijn Graph De Novo Assembler for highly Uneven sequencing Depth (IDBA-UD) is a tool for assembling genomes in a de novo manner. . 15

Gene prediction

The pipeline does gene prediction through the use of Hidden Markov Models (HMM) 4 that have been trained to distinguish between prokaryotic coding and non-coding regions. These regions are then translated using BioPython's 6 translate function. These are the proteins we compare to our existing Cry Protein database 5 In this pipeline we used the GeneMarkS GeneMarkS utilizes a non-supervised training procedure and can be used for a newly sequenced prokaryotic genome with no prior knowledge of any protein or rRNA genes. program for this purpose. 15

Machine Learning

As cry proteins are a group that is hard to define biologically, other than having specific insecticidal activity, it is somewhat of a challenge to find them through means other than direct sequence comparisons. This is why we use three methods to find potential cry proteins:

  1. A direct sequence comparison with a stringent cut-off (e-value 0.1 or lower): BLAST The Basic Local Alignment Search Tool (BLAST) is an algorithm for comparing sequence information, such as the amino-acid (protein) or nucleic-acid (DNA/RNA) sequences. 8 Using a database of only cry proteins, this tool will allow us to rapidly identify other proteins with highly similar sequences.
  2. A probabilistic approach based on the primary subdivision between cry proteins (45% sequence similarity): HMMER.
    The HMMER toolkit contains several programs that the pipeline uses. 9 The program first builds many different profiles based on the multiple sequence alignment of the primary cry protein groups. This is handled by Clustal Omega. 10
    • HMMbuild: Builds a profile HMM from an input multiple alignment.
    • HMMpress: Formats an HMM database into a binary format for hmmscan.
    • HMMscan: Searches a protein sequence against a protein profile HMM database.
    All of these methods are still based on the same Hidden Markov Model principle 4.
  3. A machine learning approach based on protein features using many weak classifiers to give a majority vote: "RandomForest".7 This part is explained further in the protein classification section.

Protein Classification

The protein classification part of the machine learning is done by the pipeline in two steps: First the features of a protein are predicted using Biopython 6 , and then the pre-trained model predicts a class based on those features.

Features

After some experimentation with the features chosen for modelling, we came up with the following list which we think will capture essential structural elements and allow for good predictions.

  • Molecular weight of the protein.
  • Aromaticity, ie the relative frequency of aromatic amino acids (Phenylalanine, Tryptophan and Tyrosine)
  • Instability index, ie the relative frequency of instability causing dipeptides, for more information see Guruprasad et al 1990.11
  • Isoelectric point, which is the pH at which a particular molecule carries no net electrical charge.
  • Alpha Helix fraction, the relative frequency of amino acids that tend to be in found in the secondary structure known as alpha helices.
  • Turn fraction, the relative frequency of amino acids that tend to be in found in the secondary structure known as turns.
  • Beta Sheet fraction, the relative frequency of amino acids that tend to be in found in the secondary structure known as beta sheets.

Scikit-Learn

We made the classification model using scikit-learn or sklearn.12 The class used for this model is called the RandomForestClassifier which works by fitting a number of decision trees, in our case 2000, on various sub-samples of the dataset and averaging these weak classifiers to improve accuracy and control for. overfitting Overfitting is what happens when a model follows its training data so well it can not predict anything new with any accuracy because too much of the noise from the training data has been modelled, rather than the underlying relationship. We assess the predictive accuracy of our model by doing a stratified 10-fold crossvalidation technique from the StratifiedKFold class. These 10-fold cross-validation runs were assessed with the roc-curves method. A ROC curve is a plot of the true positive rate (TPR) The proportion of correctly predicted instances of the testing data. against the false positive rate (FPR) The proportion of wrongly predicted instances of the testing data. 19 These kinds of plots are extremely useful in determining whether or not a Machine Learning model such as RandomForest is well trained.

Venn-Diagrams

All three separate methods give a different output. In order to make an easy visual comparison, we make use of a web tool that can easily calculate and draw custom Venn-diagrams. This tool was made by the university of Gent and can be found here.

Pipeline validation

PRJEB5931

We tested the pipeline on a genome sample from a study with accession number PRJEB5931. 13 This genome was found after a co-evolution experiment, and a Bacillus thuringiensis with known nematicidal cry proteins present.
ERX463573 is the accession code of the experiment from which these raw read files came. The description reads: "Population of Bacillus thuringiensis coming from 5 strains experimentally coevolved with Caenorhabditis as host" and the Name: "Coevolution G12 Pop4". From the study we know to expect at the very least the following two proteins: Cry35Aa4 and Cry21Aa2.
According to the cry protein toxin list it is known that Cry35Aa4 is a binary toxin with Cry34Aa4 and as such we may expect to find this protein, or one like it, as well.

Key result

The easiest way to visualize the results from the three separate components of the pipeline is to use a Venn diagram (with accompanying lists).

Figure 2: A Venn diagram showing the overlap of the output of the various methods used to predict whether or not certain genes from the genome were cry proteins or not.
As Blast had only 5 results it is easier to examine this method in detail. Two of the five were proteins we were expecting from the paper: Cry35Aa4 and Cry21Aa2. These were found to be:
  • Gene_5932, which had 100.00% identity with: Cry35Aa4
  • Gene_5527, which had 96.04% identity with: Cry21Aa2
    • Based on the fact that Cry35Aa4 is a binary protein we expected to find its complementary protein as well, which we did:
      • Gene_5931, which had 100.00% identity with all four proteins in the Cry34Aa group.
      Two other proteins appeared with a good overlap and a good e-value, namely:
      • Gene_5934, which had 98.39% identity with: Cry38Aa1, which has no known insecticidal target, but is highly similar to proteins that do: Cry15Aa1, Cry23Aa1, and Cry33Aa1. 17
      • Gene_5518, which had 85.87% identity with: Cry14Ab1. Which is only mentioned in a patent by Sampson et al. 2012. 18
      Both of these were also picked up by the Hidden Markov Model method of cry protein detection as shown in figure 2, but not by the RandomForest method.

Discussion

All three methods were fully able to pick up the nematicidal proteins from the study we had expected to find, and the complementary protein we predicted to be present ourselves.

Blast

As we had intended the Blast method proved to be the most stringent, detecting at least known cry proteins with high accuracy. However, in order to find new cry proteins that perform a similar function to a known cry protein but are not exactly like one, we can still turn to the other methods.

HMM

RandomForest

The ML could be further optimized based on a more rigorous examination of what is and what is not a cry protein. For 5934 the RF prediction didn’t happen because it did not have the right amount of aromatic residues, which caused a high increase in the probability of it not being a cry protein. (Instance 23 of the last list of RF_analysis.txt) The idea behind the training set used for this model was that the model should be able to distinguish what is defined as cry and what is not cry, but still similar in sequence. To that end the uniprot database was queried and 200 proteins that came back using this query in the uniprot web interface: [my list] NOT go:"sporulation resulting in formation of a cellular spore [0030435]" NOT family:"delta endotoxin" NOT cry NOT pesticidal active:yes NOT annotation:(type:"positional domain" "Endotoxin M") NOT name:crystal This list of 200 proteins was investigated (somewhat)

References

1. Ye, W., Zhu, L., Liu, Y., Crickmore, N., Peng, D., Ruan, L., & Sun, M. (2012). Mining new crystal protein genes from Bacillus thuringiensis on the basis of mixed plasmid-enriched genome sequencing and a computational pipeline. Applied and environmental microbiology, 78(14), 4795-4801.

2. Alquisira-Ramírez, E. V., Paredes-Gonzalez, J. R., Hernández-Velázquez, V. M., Ramírez-Trujillo, J. A., & Peña-Chora, G. (2014). In vitro susceptibility of Varroa destructor and Apis mellifera to native strains of Bacillus thuringiensis. Apidologie, 45(6), 707-718.

3. Compeau, P. E., Pevzner, P. A., & Tesler, G. (2011). How to apply de Bruijn graphs to genome assembly. Nature biotechnology, 29(11), 987-991.

4. Rabiner, L., & Juang, B. (1986). An introduction to hidden Markov models. ieee assp magazine, 3(1), 4-16.

5. Crickmore, N., Baum, J., Bravo, A., Lereclus, D., Narva, K., Sampson, K., Schnepf, E., Sun, M. and Zeigler, D.R. " Bacillus thuringiensis toxin nomenclature" (2016) http://www.btnomenclature.info/

6. Cock PA, Antao T, Chang JT, Bradman BA, Cox CJ, Dalke A, Friedberg I, Hamelryck T, Kauff F, Wilczynski B and de Hoon MJL (2009) Biopython: freely available Python tools for computational molecular biology and bioinformatics. Bioinformatics, 25, 1422-1423

7. Liaw, A., & Wiener, M. (2002). Classification and regression by randomForest. R news, 2(3), 18-22.

@. Altschul, S. F., Gish, W., Miller, W., Myers, E. W., & Lipman, D. J. (1990). Basic local alignment search tool. Journal of molecular biology, 215(3), 403-410.

9. Eddy, S. R. (1998). Profile hidden Markov models. Bioinformatics, 14(9), 755-763.

10. Sievers, F., & Higgins, D. G. (2014). Clustal Omega, accurate alignment of very large numbers of sequences. Multiple sequence alignment methods, 105-116.

11. Guruprasad, K., Reddy, B. B., & Pandit, M. W. (1990). Correlation between stability of a protein and its dipeptide composition: a novel approach for predicting in vivo stability of a protein from its primary sequence. Protein engineering, 4(2), 155-161.

12. Pedregosa, F., Varoquaux, G., Gramfort, A., Michel, V., Thirion, B., Grisel, O., ... & Vanderplas, J. (2011). Scikit-learn: Machine learning in Python. Journal of Machine Learning Research, 12(Oct), 2825-2830.

13. Masri, L., Branca, A., Sheppard, A. E., Papkou, A., Laehnemann, D., Guenther, P. S., ... & Brzuszkiewicz, E. (2015). Host–pathogen coevolution: the selective advantage of Bacillus thuringiensis virulence and its cry toxin genes. PLoS Biol, 13(6), e1002169.

14.de Maagd, R. A., Bravo, A., & Crickmore, N. (2001). How Bacillus thuringiensis has evolved specific toxins to colonize the insect world. TRENDS in Genetics, 17(4), 193-199.

15. Peng, Y., Leung, H. C., Yiu, S. M., & Chin, F. Y. (2012). IDBA-UD: a de novo assembler for single-cell and metagenomic sequencing data with highly uneven depth. Bioinformatics, 28(11), 1420-1428.

16. Besemer, J., Lomsadze, A., & Borodovsky, M. (2001). GeneMarkS: a self-training method for prediction of gene starts in microbial genomes. Implications for finding sequence motifs in regulatory regions. Nucleic acids research, 29(12), 2607-2618.

17. Baum, J. A., Chu, C. R., Rupar, M., Brown, G. R., Donovan, W. P., Huesing, J. E., ... & Vaughn, T. (2004). Binary toxins from Bacillus thuringiensis active against the western corn rootworm, Diabrotica virgifera virgifera LeConte. Applied and environmental microbiology, 70(8), 4889-4898.

18. Sampson, K. S., Tomso, D. J., & Dumitru, R. V. (2012). U.S. Patent No. 8,318,900. Washington, DC: U.S. Patent and Trademark Office.

19. Bradley, A. P. (1997). The use of the area under the ROC curve in the evaluation of machine learning algorithms. Pattern recognition, 30(7), 1145-1159.