def branching(peptide): branch = [] amino_table = integer_mass() for AA in peptide: for A in amino_table.keys(): branch += [AA+A] return branch
def branching(peptide): branch = [] amino_table = integer_mass() for AA in peptide: for A in amino_table.keys(): branch += [AA + A] return branch
def single_amino(spectrum): amino_table = integer_mass() match_AA = [] for mas in spectrum: for aa, mass in amino_table.items(): if mas == mass: match_AA += [aa] return list(set(match_AA))
def single_amino(spectrum): amino_table = integer_mass() match_AA = [] for mas in spectrum: for aa, mass in amino_table.items(): if mas == mass: match_AA += [aa] return list(set(match_AA))
__author__ = 'Mohammad Yousuf Ali, [email protected]' from TheoreticalSpectrum import integer_mass, total_mass mass_table = integer_mass() def cyclic_spectra(peptide): out_spectrum = [0, total_mass(peptide)] peptide_2 = peptide + peptide for k in range(1, len(peptide)): for n in range(len(peptide)): subpep = peptide_2[n:n+k] out_spectrum.append(total_mass(subpep)) return sorted(out_spectrum) spectrum = [] L = [] file = open('score.txt','r') L = file.readlines() peptide = L[0].rstrip() for item in L[1:]: spectrum += item.rstrip().split() ex_spectrum = [int(x) for x in spectrum] th_spectrum = cyclic_spectra(peptide) # For cyclic mass spectrum
__author__ = 'Mohammad Yousuf Ali, [email protected]' from TheoreticalSpectrum import integer_mass, total_mass from Trim import trim from LinearScoring import linear_score from Score import score file = open('LBS.txt','r') file = file.readlines() N = int(file[0].rstrip()) - 450 spectrum = file[1].rstrip().split() #print(spectrum) spectrum = sorted([int(x) for x in spectrum]) amino_table = integer_mass() def branching(peptide): branch = [] #amino_table = integer_mass() for AA in peptide: for A in amino_table.keys(): branch += [AA+A] return branch def single_amino(spectrum): amino_table = integer_mass() match_AA = [] for mas in spectrum: for aa, mass in amino_table.items(): if mas == mass:
__author__ = 'Mohammad Yousuf Ali, [email protected]' from TheoreticalSpectrum import integer_mass, total_mass mass_table = integer_mass() def cyclic_spectra(peptide): out_spectrum = [0, total_mass(peptide)] peptide_2 = peptide + peptide for k in range(1, len(peptide)): for n in range(len(peptide)): subpep = peptide_2[n:n + k] out_spectrum.append(total_mass(subpep)) return sorted(out_spectrum) spectrum = [] L = [] file = open('score.txt', 'r') L = file.readlines() peptide = L[0].rstrip() for item in L[1:]: spectrum += item.rstrip().split() ex_spectrum = [int(x) for x in spectrum] th_spectrum = cyclic_spectra(peptide) # For cyclic mass spectrum count = 0 for i in ex_spectrum:
# Please take a look at my explantion of this problem # at: https://sites.google.com/site/aliyyousuf/genome-sequencing-bioinformatics-ii/cyclo-peptide-sequencing spectrum = [] file = open('peptide.txt','r') for line in file: spectrum += line.rstrip().split() spectrum = [int(x) for x in spectrum] from TheoreticalSpectrum import integer_mass, total_mass amino_acid = integer_mass() def single_amino(spectrum): amino_table = integer_mass() match_AA = [] for mas in spectrum: for aa, mass in amino_table.items(): if mas == mass: match_AA += [aa] return list(set(match_AA)) def branching(peptide): branch = [] amino_table = integer_mass() for AA in peptide:
__author__ = 'Mohammad Yousuf Ali, aliyyousuf@gmail' # Please take a look at my explantion of this problem # at: https://sites.google.com/site/aliyyousuf/genome-sequencing-bioinformatics-ii/cyclo-peptide-sequencing spectrum = [] file = open('peptide.txt', 'r') for line in file: spectrum += line.rstrip().split() spectrum = [int(x) for x in spectrum] from TheoreticalSpectrum import integer_mass, total_mass amino_acid = integer_mass() def single_amino(spectrum): amino_table = integer_mass() match_AA = [] for mas in spectrum: for aa, mass in amino_table.items(): if mas == mass: match_AA += [aa] return list(set(match_AA)) def branching(peptide): branch = [] amino_table = integer_mass() for AA in peptide: for A in amino_table.keys(): branch += [AA + A]
__author__ = 'Mohammad Yousuf Ali, [email protected]' from TheoreticalSpectrum import integer_mass, total_mass from Trim import trim from LinearScoring import linear_score from Score import score file = open('LBS.txt', 'r') file = file.readlines() N = int(file[0].rstrip()) - 450 spectrum = file[1].rstrip().split() #print(spectrum) spectrum = sorted([int(x) for x in spectrum]) amino_table = integer_mass() def branching(peptide): branch = [] #amino_table = integer_mass() for AA in peptide: for A in amino_table.keys(): branch += [AA + A] return branch def single_amino(spectrum): amino_table = integer_mass() match_AA = [] for mas in spectrum: for aa, mass in amino_table.items():