@@ -31,7 +31,7 @@ a fasta database of protein sequences:
3131 urlretrieve(gh + " /src/data/SimpleSearchEngine_1.mzML" , " searchfile.mzML" )
3232 urlretrieve(gh + " /src/data/SimpleSearchEngine_1.fasta" , " search.fasta" )
3333 protein_ids = []
34- peptide_ids = []
34+ peptide_ids = oms.PeptideIdentificationList()
3535 oms.SimpleSearchEngineAlgorithm().search(
3636 " searchfile.mzML" , " search.fasta" , protein_ids, peptide_ids
3737 )
@@ -143,9 +143,9 @@ ppm\ (\pm 2\ ppm)`, we expect that we will not find the hit at :math:`775.38` m/
143143 salgo.setParameters(p)
144144
145145 protein_ids = []
146- peptide_ids = []
146+ peptide_ids = oms.PeptideIdentificationList()
147147 salgo.search(" searchfile.mzML" , " search.fasta" , protein_ids, peptide_ids)
148- print (" Found" , len ( peptide_ids), " peptides" )
148+ print (" Found" , peptide_ids.size( ), " peptides" )
149149
150150 As we can see, using a smaller precursor mass tolerance leads the algorithm to
151151find only one hit instead of two. Similarly, if we use the wrong enzyme for
@@ -189,7 +189,7 @@ Now include some additional decoy database generation step as well as subsequent
189189
190190 # Run SimpleSearchAlgorithm, store protein and peptide ids
191191 protein_ids = []
192- peptide_ids = []
192+ peptide_ids = oms.PeptideIdentificationList()
193193
194194 # set some custom search parameters
195195 simplesearch = oms.SimpleSearchEngineAlgorithm()
@@ -224,7 +224,7 @@ This is done by applying one of the available protein inference algorithms on th
224224 :linenos:
225225
226226 protein_ids = []
227- peptide_ids = []
227+ peptide_ids = oms.PeptideIdentificationList()
228228
229229 # Re-run search since we need to keep decoy hits for inference
230230 simplesearch.search(searchfile, target_decoy_database, protein_ids, peptide_ids)
0 commit comments