Esempio n. 1
0
def calcDiff(s, R):
    global s_s, i, x, weights
    s_s = set()

    weights = []
    for i in range(1, len(s)):
        weights.append(getIsotopicWeight(s[:i]))
        weights.append(getIsotopicWeight(s[-i:]))
    weights.append(getIsotopicWeight(s))
    diff = mDiff(weights, R)
    max, max_key = getMaxMultiplicity(diff)
    return max
Esempio n. 2
0
from python.util import getIsotopicWeight

protein = input()
print(getIsotopicWeight(protein))