Esempio n. 1
0
 def testHammingDistanceFromFile(self):
     with open('data/hammingDistance.txt') as fp:
         sequence1, sequence2 = map(lambda x: x.strip(), fp.readlines())
         self.assertEqual(483, hammingDistance(sequence1, sequence2))
Esempio n. 2
0
 def testHammingDistanceFromFile(self):
     with open('data/hammingDistance.txt') as fp:
         sequence1, sequence2 = map(lambda x: x.strip(), fp.readlines())
         self.assertEqual(483, hammingDistance(sequence1, sequence2))
Esempio n. 3
0
 def testHammingDistance(self):
     sequence1, sequence2 = 'GAGCCTACTAACGGGAT', 'CATCGTAATGACGGCCT'
     self.assertEqual(7, hammingDistance(sequence1, sequence2))
Esempio n. 4
0
 def testHammingDistance(self):
     sequence1, sequence2 = 'GAGCCTACTAACGGGAT', 'CATCGTAATGACGGCCT'
     self.assertEqual(7, hammingDistance(sequence1, sequence2))