-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathprotein-tests.py
320 lines (293 loc) · 17.7 KB
/
protein-tests.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
from hw6_protein import *
### WEEK 1 TESTS ###
def testReadFile():
print("Testing readFile()...", end="")
# Check that the function works on the provided test file
text1 = readFile("data/test_dna.txt")
assert(text1 == "ATGGATGGACTCTAACGCAATGCCCTTTTAG")
# Now check the human DNA file you loaded
text2 = readFile("data/human_p53.txt")
assert(text2[:10] == "GATGGGATTG") # the whole sequence is too long to check here!
assert(len(text2) == 19149)
# If the length is not correct, check that you're
# removing newlines, and that you copied the whole sequence
print("... done!")
def testDnaToRna():
print("Testing dnaToRna()...", end="")
# Test a basic sequence
dna = "ATGGATGGACTCTAA"
assert(dnaToRna(dna, 0) == ["AUG", "GAU", "GGA", "CUC", "UAA"])
# Test two mRNA strands in a row, with a random codon in between
dna = "ATGGATGGACTCTAACTCATGCCCTTTTAG"
assert(dnaToRna(dna, 0) == ["AUG", "GAU", "GGA", "CUC", "UAA"])
assert(dnaToRna(dna, 18) == ["AUG", "CCC", "UUU", "UAG"])
# Test a DNA strand that doesn't end properly
dna = "CCTATGGACCAT"
assert(dnaToRna(dna, 3) == ["AUG", "GAC", "CAU"])
# Test a DNA strand with random bases in between
dna = "ATGGATGGACTCTAACGCAATGCCCTTTTAG"
assert(dnaToRna(dna, 0) == ["AUG", "GAU", "GGA", "CUC", "UAA"])
assert(dnaToRna(dna, 19) == ["AUG", "CCC", "UUU", "UAG"])
print("... done!")
def testMakeCodonDictionary():
print("Testing makeCodonDictionary()...", end="")
d = makeCodonDictionary()
assert(d["AAA"] == "Lys")
assert(d["GGA"] == "Gly")
assert(d["AUG"] == "Met")
assert(d["UAA"] == "Stop")
print("... done!")
def testGenerateProtein():
print("Testing generateProtein()...", end="")
codonD = makeCodonDictionary()
rna = ["AUG", "GAU", "GGA", "CUC", "UAA"]
assert(generateProtein(rna, codonD) == ["Start", "Asp", "Gly", "Leu", "Stop"])
rna = ["AUG", "CCC", "UUU", "UAG"]
assert(generateProtein(rna, codonD) == ["Start", "Pro", "Phe", "Stop"])
rna = ["AUG", "GAC", "CAU"]
assert(generateProtein(rna, codonD) == [ "Start", "Asp", "His"])
# Note: "AUG" only maps to "Start" if it's at the beginning. "AUG" in the middle should become "Met"
rna = ["AUG", "CGA", "AUG", "GGG", "UGG", "UGA"]
assert(generateProtein(rna, codonD) == [ "Start", "Arg", "Met", "Gly", "Trp", "Stop"])
print("... done!")
def testSynthesizeProteins():
print("Testing synthesizeProteins()...", end="")
# First, test on the provided test data
proteins1 = synthesizeProteins("data/test_dna.txt")
# The function should say there are 31 total bases,
# 4 unused bases, and 2 synthesized proteins
assert(proteins1 == [ ['Start', 'Asp', 'Gly', 'Leu', 'Stop'],
['Start', 'Pro', 'Phe', 'Stop']])
# Now test on the actual data
proteins2 = synthesizeProteins("data/human_p53.txt")
# The function should say there are 19149 total bases,
# 10560 unused bases, and 119 synthesized proteins
assert(len(proteins2) == 119)
assert(proteins2[0] == ['Start', 'Gly', 'Leu', 'Gly', 'Phe', 'Ser', 'Pro',
'Pro', 'Met', 'Cys', 'Ser', 'Arg', 'Leu', 'Ala',
'Leu', 'Lys', 'Val', 'Leu', 'Ser', 'Phe', 'Ser',
'Lys', 'Val', 'Stop'])
assert(proteins2[1] == ['Start', 'Ser', 'Pro', 'Leu', 'Stop'])
assert(proteins2[118] == ['Start', 'Met', 'Ile', 'Trp', 'Ile', 'His', 'Gln',
'Asp', 'Leu', 'Phe', 'Tyr', 'Ala', 'Gln', 'Gly',
'Gln', 'Phe', 'Leu', 'Phe', 'Ser', 'Phe', 'Phe',
'Phe', 'Phe', 'Phe', 'Phe', 'Phe', 'Phe', 'Phe',
'Glu', 'Thr', 'Gly', 'Ser', 'Arg', 'Phe', 'Val',
'Ala', 'Gln', 'Ala', 'Gly', 'Val', 'Glu', 'Trp',
'Arg', 'Asp', 'Leu', 'Gly', 'Leu', 'Leu', 'Gln',
'Pro', 'Leu', 'Pro', 'Pro', 'Arg', 'Leu', 'Glu',
'Gln', 'Ser', 'Cys', 'Leu', 'Ser', 'Leu', 'Arg',
'Ser', 'Ser', 'Trp', 'Asp', 'His', 'Arg', 'Phe',
'Met', 'Pro', 'Pro', 'Trp', 'Pro', 'Ala', 'Asn',
'Phe', 'Cys', 'Met', 'Phe', 'Cys', 'Arg', 'Asp',
'Gly', 'Val', 'Ser', 'Gln', 'Cys', 'Cys', 'Pro',
'Gly', 'Trp', 'Ser', 'Gln', 'Thr', 'Pro', 'Gly',
'Leu', 'Arg', 'Arg', 'Ser', 'Thr', 'Cys', 'Leu',
'Ser', 'Leu', 'Pro', 'Glu', 'Cys', 'Trp', 'Asp',
'Tyr', 'Asn', 'Cys', 'Glu', 'Pro', 'Pro', 'Arg',
'Pro', 'Ala', 'Gly', 'Arg', 'Val', 'Asn', 'Ile',
'Phe', 'Tyr', 'Ile', 'Leu', 'Gln', 'Ala', 'His',
'Leu', 'His', 'Phe', 'His', 'Pro', 'Thr', 'Leu',
'Pro', 'Leu', 'Leu', 'Leu', 'Pro', 'Phe', 'Tyr',
'Ile', 'Pro', 'Phe', 'Leu', 'Tyr', 'Arg', 'Ser',
'Leu', 'Ile', 'Leu', 'Gln', 'Stop'])
print("... done!")
def week1Tests():
testReadFile()
testDnaToRna()
testMakeCodonDictionary()
testGenerateProtein()
testSynthesizeProteins()
### WEEK 2 TESTS ###
def testCommonProteins():
print("Testing commonProteins()...", end="")
plist1 = [ [ "Start", "Pro", "Val", "Stop" ], [ "Start", "Phe", "Stop" ],
[ "Start", "Asp", "Glu", "Stop" ], [ "Start", "His", "Stop" ] ]
plist2 = [ [ "Start", "Cys", "Cys", "Tyr", "Stop" ], ["Start", "Glu", "Asp", "Stop" ],
[ "Start", "His", "Stop" ], [ "Start", "Stop" ], [ "Start", "Met", "Leu", "Stop" ] ]
plist3 = [ [ "Start", "Asp", "Glu", "Stop" ], [ "Start", "Phe", "Stop" ],
[ "Start", "Asp", "Glu", "Stop" ], [ "Start", "Lys", "Stop" ],
[ "Start", "Asn", "Asn", "Asn", "Asn", "Stop" ] ]
assert(commonProteins(plist1, plist2) == [ [ "Start", "His", "Stop" ] ])
assert(sorted(commonProteins(plist1, plist3)) == [ [ "Start", "Asp", "Glu", "Stop" ],
[ "Start", "Phe", "Stop" ] ])
assert(commonProteins(plist2, plist3) == [ ])
print("... done!")
def testCombineProteins():
print("Testing combineProteins()...", end="")
plist1 = [ [ "Start", "Pro", "Val", "Stop" ], [ "Start", "Phe", "Stop" ],
[ "Start", "Asp", "Glu", "Stop" ], [ "Start", "His", "Stop" ] ]
plist2 = [ [ "Start", "Cys", "Cys", "Tyr", "Stop" ], ["Start", "Glu", "Asp", "Stop" ],
[ "Start", "His", "Stop" ], [ "Start", "Stop" ], [ "Start", "Met", "Leu", "Stop" ] ]
plist3 = [ [ "Start", "Asp", "Glu", "Stop" ], [ "Start", "Phe", "Stop" ],
[ "Start", "Asp", "Glu", "Stop" ], [ "Start", "Lys", "Stop" ],
[ "Start", "Asn", "Asn", "Asn", "Asn", "Stop" ] ]
assert(combineProteins(plist1) == [ "Start", "Pro", "Val", "Stop", "Start",
"Phe", "Stop", "Start", "Asp", "Glu",
"Stop", "Start", "His", "Stop" ])
assert(combineProteins(plist2) == [ "Start", "Cys", "Cys", "Tyr", "Stop",
"Start", "Glu", "Asp", "Stop", "Start",
"His", "Stop", "Start", "Stop", "Start",
"Met", "Leu", "Stop" ])
assert(combineProteins(plist3) == [ "Start", "Asp", "Glu", "Stop", "Start",
"Phe", "Stop", "Start", "Asp", "Glu",
"Stop", "Start", "Lys", "Stop", "Start",
"Asn", "Asn", "Asn", "Asn", "Stop" ])
print("... done!")
def testAminoAcidDictionary():
print("Testing aminoAcidDictionary()...", end="")
aaList1 = [ "Start", "Pro", "Val", "Stop", "Start", "Phe", "Stop", "Start",
"Asp", "Glu", "Stop", "Start", "His", "Stop" ]
aaList2 = [ "Start", "Cys", "Cys", "Tyr", "Stop", "Start", "Glu", "Asp",
"Stop", "Start", "His", "Stop", "Start", "Stop", "Start", "Met",
"Leu", "Stop" ]
aaList3 = [ "Start", "Asp", "Glu", "Stop", "Start", "Phe", "Stop", "Start",
"Asp", "Glu", "Stop", "Start", "Lys", "Stop", "Start", "Asn",
"Asn", "Asn", "Asn", "Stop" ]
assert(aminoAcidDictionary(aaList1) == { "Start" : 4, "Pro" : 1, "Val" : 1,
"Stop" : 4, "Phe" : 1, "Asp" : 1, "Glu" : 1, "His" : 1 })
assert(aminoAcidDictionary(aaList2) == { "Start" : 5, "Cys" : 2, "Tyr" : 1,
"Stop" : 5, "Glu" : 1, "Asp" : 1, "His" : 1, "Met" : 1, "Leu" : 1 })
assert(aminoAcidDictionary(aaList3) == { "Start" : 5, "Asp" : 2, "Glu" : 2,
"Stop" : 5, "Phe" : 1, "Lys" : 1, "Asn" : 4 })
print("... done!")
def testFindAminoAcidDifferences():
print("Testing findAminoAcidDifferences()...", end="")
set1 = [ [ 'Start', 'Gly', 'Leu', 'Gly', 'Phe', 'Ser', 'Pro', 'Pro', 'Met',
'Cys', 'Ser', 'Arg', 'Leu', 'Ala', 'Leu', 'Lys', 'Val', 'Leu',
'Ser', 'Phe', 'Ser', 'Lys', 'Val', 'Stop' ],
[ 'Start', 'Ser', 'Pro', 'Leu', 'Stop' ],
[ 'Start', 'Glu', 'Ala', 'Trp', 'Leu', 'Glu', 'Gly', 'Ser', 'Ser', 'Stop'],
[ 'Start', 'Met', 'Gly', 'Met', 'Leu', 'Gly', 'Pro', 'Ser', 'Glu',
'Leu', 'Lys', 'Val', 'Glu', 'Arg', 'Leu', 'Gly', 'Arg', 'Gly',
'Val', 'Glu', 'Leu', 'Trp', 'Gly', 'Thr', 'Leu', 'Ser', 'Arg',
'Pro', 'Lys', 'Ala', 'Tyr', 'Phe', 'Phe', 'Ala', 'His', 'Pro',
'Pro', 'Gly', 'Ala', 'Gly', 'Arg', 'Arg', 'Glu', 'Ser', 'Leu',
'Lys', 'Stop' ],
[ 'Start', 'His', 'Lys', 'Ala', 'Leu', 'Arg', 'Ser', 'Glu', 'Thr',
'Phe', 'Gly', 'Ser', 'Arg', 'Asn', 'Ile', 'Glu', 'Asn', 'Ser', 'Stop' ] ]
set2 = [ [ 'Start', 'Ala', 'Stop' ],
[ 'Start', 'Phe', 'Ser', 'Ile', 'Asn', 'Ser', 'Thr', 'Leu', 'Ala',
'Ala', 'Leu', 'Val', 'Cys', 'Arg', 'Thr', 'Ser', 'Pro', 'Pro',
'Gln', 'Asn', 'Pro', 'Gly', 'Ser', 'Leu', 'Arg', 'Ser', 'Leu',
'Leu', 'Phe', 'His', 'Ser', 'Leu', 'Ser', 'Ala', 'Ser', 'Pro',
'Leu', 'Pro', 'Thr', 'Gly', 'Lys', 'Leu', 'Leu', 'Ala', 'Leu',
'Thr', 'Cys', 'His', 'Gly', 'Asp', 'Cys', 'Pro', 'Ala', 'Leu',
'Cys', 'Gln', 'Lys', 'Pro', 'Arg', 'Gly', 'Gly', 'Cys', 'Trp',
'Asp', 'Trp', 'Glu', 'Phe', 'Pro', 'Phe', 'Pro', 'Cys', 'Ala',
'His', 'Thr', 'Gly', 'Ala', 'Lys', 'Ser', 'Phe', 'Gln', 'Leu',
'Phe', 'Lys', 'Ser', 'Pro', 'Lys', 'Pro', 'Pro', 'Ser', 'Trp',
'Leu', 'Gln', 'Leu', 'Ala', 'Ala', 'Gly', 'Leu', 'Trp', 'Arg',
'Tyr', 'Leu', 'Val', 'Ser', 'Gly', 'Leu', 'Gly', 'Pro', 'Cys',
'Phe', 'Gln', 'Gly', 'Arg', 'Leu', 'His', 'Ala', 'Arg', 'Leu',
'Arg', 'Phe', 'Gly', 'Stop' ],
[ 'Start', 'Ser', 'Pro', 'Leu', 'Stop' ],
[ 'Start', 'Phe', 'Arg', 'Ala', 'Leu', 'Gly', 'Val', 'Glu', 'Stop' ],
[ 'Start', 'Leu', 'Val', 'Pro', 'Ala', 'Asp', 'Leu', 'Glu', 'Leu', 'Stop'] ]
result1 = findAminoAcidDifferences(set1, set2, 0.02) # 2% difference
result1.sort()
assert(len(result1) == 12)
assert((result1[0][0] == "Ala") and (0.057 < result1[0][1] < 0.058) and (0.087 < result1[0][2] < 0.088))
assert((result1[1][0] == "Arg") and (0.076 < result1[1][1] < 0.077) and (0.054 < result1[1][2] < 0.055))
assert(result1[11][0] == "Ser" and (0.123 < result1[11][1] < 0.124) and (0.087 < result1[11][2] < 0.088))
result2 = findAminoAcidDifferences(set1, set2, 0.05) # 5% difference
assert(len(result2) == 1)
assert((result2[0][0] == "Glu") and (0.076 < result2[0][1] < 0.077) and (0.020 < result2[0][2] < 0.021))
result3 = findAminoAcidDifferences(set1, set2, 0.005) # 0.5% difference
assert(len(result3) == 18)
print("... done!")
def week2Tests():
testCommonProteins()
testCombineProteins()
testAminoAcidDictionary()
testFindAminoAcidDifferences()
### WEEK 3 TESTS ###
def testMakeAminoAcidLabels():
print("Testing makeAminoAcidLabels()...", end="")
plist1 = [ [ "Start", "Pro", "Val", "Stop" ], [ "Start", "Phe", "Stop" ],
[ "Start", "Asp", "Glu", "Stop" ], [ "Start", "His", "Stop" ] ]
plist2 = [ [ "Start", "Cys", "Cys", "Tyr", "Stop" ], ["Start", "Glu", "Asp", "Stop" ],
[ "Start", "His", "Stop" ], [ "Start", "Stop" ], [ "Start", "Met", "Leu", "Stop" ] ]
plist3 = [ [ "Start", "Asp", "Glu", "Stop" ], [ "Start", "Phe", "Stop" ],
[ "Start", "Asp", "Glu", "Stop" ], [ "Start", "Lys", "Stop" ],
[ "Start", "Asn", "Asn", "Asn", "Asn", "Stop" ] ]
assert(makeAminoAcidLabels(plist1, plist2) == ['Asp', 'Cys', 'Glu', 'His',
'Leu', 'Met', 'Phe', 'Pro', 'Start', 'Stop', 'Tyr', 'Val'])
assert(makeAminoAcidLabels(plist1, plist3) == ['Asn', 'Asp', 'Glu', 'His',
'Lys', 'Phe', 'Pro', 'Start', 'Stop', 'Val'])
assert(makeAminoAcidLabels(plist2, plist3) == ['Asn', 'Asp', 'Cys', 'Glu',
'His', 'Leu', 'Lys', 'Met', 'Phe', 'Start', 'Stop', 'Tyr'])
print("... done!")
def testSetupChartData():
print("Testing setupChartData()...", end="")
plist1 = [ [ "Start", "Pro", "Val", "Stop" ], [ "Start", "Phe", "Stop" ],
[ "Start", "Asp", "Glu", "Stop" ], [ "Start", "His", "Stop" ] ]
plist2 = [ [ "Start", "Cys", "Cys", "Tyr", "Stop" ], ["Start", "Glu", "Asp", "Stop" ],
[ "Start", "His", "Stop" ], [ "Start", "Stop" ],
[ "Start", "Met", "Leu", "Stop" ] ]
labels = makeAminoAcidLabels(plist1, plist2)
result = setupChartData(labels, plist1)
assert(len(result) == 12)
assert((0.071 < result[0] < 0.072) and (result[1] == 0) and (0.071 < result[11] < 0.072))
result = setupChartData(labels, plist2)
assert(len(result) == 12)
assert((0.055 < result[0] < 0.056) and (0.111 < result[1] < 0.112) and (result[11] == 0))
print("... done!")
def testCreateChart():
print("Testing createChart()...", end="")
plist1 = [ [ "Start", "Pro", "Val", "Stop" ], [ "Start", "Phe", "Stop" ],
[ "Start", "Asp", "Glu", "Stop" ], [ "Start", "His", "Stop" ] ]
plist2 = [ [ "Start", "Cys", "Cys", "Tyr", "Stop" ], ["Start", "Glu", "Asp", "Stop" ],
[ "Start", "His", "Stop" ], [ "Start", "Stop" ],
[ "Start", "Met", "Leu", "Stop" ] ]
labels = makeAminoAcidLabels(plist1, plist2)
freqList1 = setupChartData(labels, plist1)
freqList2 = setupChartData(labels, plist2)
createChart(labels, freqList1, "Ex1", freqList2, "Ex2")
print("... check your chart!")
def testMakeEdgeList():
print("Testing makeEdgeList()...", end="")
set1 = [ [ 'Start', 'Gly', 'Leu', 'Gly', 'Phe', 'Ser', 'Pro', 'Pro', 'Met',
'Cys', 'Ser', 'Arg', 'Leu', 'Ala', 'Leu', 'Lys', 'Val', 'Leu',
'Ser', 'Phe', 'Ser', 'Lys', 'Val', 'Stop' ],
[ 'Start', 'Ser', 'Pro', 'Leu', 'Stop' ],
[ 'Start', 'Glu', 'Ala', 'Trp', 'Leu', 'Glu', 'Gly', 'Ser', 'Ser', 'Stop'],
[ 'Start', 'Met', 'Gly', 'Met', 'Leu', 'Gly', 'Pro', 'Ser', 'Glu',
'Leu', 'Lys', 'Val', 'Glu', 'Arg', 'Leu', 'Gly', 'Arg', 'Gly',
'Val', 'Glu', 'Leu', 'Trp', 'Gly', 'Thr', 'Leu', 'Ser', 'Arg',
'Pro', 'Lys', 'Ala', 'Tyr', 'Phe', 'Phe', 'Ala', 'His', 'Pro',
'Pro', 'Gly', 'Ala', 'Gly', 'Arg', 'Arg', 'Glu', 'Ser', 'Leu',
'Lys', 'Stop' ],
[ 'Start', 'His', 'Lys', 'Ala', 'Leu', 'Arg', 'Ser', 'Glu', 'Thr',
'Phe', 'Gly', 'Ser', 'Arg', 'Asn', 'Ile', 'Glu', 'Asn', 'Ser', 'Stop' ] ]
set2 = [ [ 'Start', 'Ala', 'Stop' ],
[ 'Start', 'Phe', 'Ser', 'Ile', 'Asn', 'Ser', 'Thr', 'Leu', 'Ala',
'Ala', 'Leu', 'Val', 'Cys', 'Arg', 'Thr', 'Ser', 'Pro', 'Pro',
'Gln', 'Asn', 'Pro', 'Gly', 'Ser', 'Leu', 'Arg', 'Ser', 'Leu',
'Leu', 'Phe', 'His', 'Ser', 'Leu', 'Ser', 'Ala', 'Ser', 'Pro',
'Leu', 'Pro', 'Thr', 'Gly', 'Lys', 'Leu', 'Leu', 'Ala', 'Leu',
'Thr', 'Cys', 'His', 'Gly', 'Asp', 'Cys', 'Pro', 'Ala', 'Leu',
'Cys', 'Gln', 'Lys', 'Pro', 'Arg', 'Gly', 'Gly', 'Cys', 'Trp',
'Asp', 'Trp', 'Glu', 'Phe', 'Pro', 'Phe', 'Pro', 'Cys', 'Ala',
'His', 'Thr', 'Gly', 'Ala', 'Lys', 'Ser', 'Phe', 'Gln', 'Leu',
'Phe', 'Lys', 'Ser', 'Pro', 'Lys', 'Pro', 'Pro', 'Ser', 'Trp',
'Leu', 'Gln', 'Leu', 'Ala', 'Ala', 'Gly', 'Leu', 'Trp', 'Arg',
'Tyr', 'Leu', 'Val', 'Ser', 'Gly', 'Leu', 'Gly', 'Pro', 'Cys',
'Phe', 'Gln', 'Gly', 'Arg', 'Leu', 'His', 'Ala', 'Arg', 'Leu',
'Arg', 'Phe', 'Gly', 'Stop' ],
[ 'Start', 'Ser', 'Pro', 'Leu', 'Stop' ],
[ 'Start', 'Phe', 'Arg', 'Ala', 'Leu', 'Gly', 'Val', 'Glu', 'Stop' ],
[ 'Start', 'Leu', 'Val', 'Pro', 'Ala', 'Asp', 'Leu', 'Glu', 'Leu', 'Stop'] ]
labels = makeAminoAcidLabels(set1, set2)
biggestDiffs = findAminoAcidDifferences(set1, set2, 0.02)
result = makeEdgeList(labels, biggestDiffs)
assert(result == ['black', 'black', 'white', 'black', 'black', 'black',
'black', 'black', 'white', 'white', 'black', 'black',
'black', 'white', 'black', 'black', 'white', 'white',
'white', 'white', 'white', 'white'])
print("... done!")
def week3Tests():
testMakeAminoAcidLabels()
testSetupChartData()
testCreateChart()
testMakeEdgeList()