Skip to content

Commit e97e109

Browse files
fixing spacing problem within 51mer
1 parent 1e574de commit e97e109

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

scripts/color_peptides51mer.py

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -225,7 +225,7 @@ def create_stylized_sequence(peptide_sequence):
225225
new_string += nucleotide.nucleotide
226226
else:
227227
new_string += nucleotide.nucleotide
228-
return(new_string)
228+
return(new_string)
229229

230230
def main():
231231
args = parse_arguments()
@@ -324,14 +324,12 @@ def main():
324324
print("ClassI: ", classI_peptide)
325325
print("ClassII: ", classII_peptide, "\n")
326326

327-
modified_html = peptides_51mer_soup.prettify(formatter=None)
328327

329-
soup = BeautifulSoup(modified_html, 'html.parser')
330-
tag_with_search_string = soup.select_one('th:-soup-contains("51mer ID")')
328+
tag_with_search_string = peptides_51mer_soup.select_one('th:-soup-contains("51mer ID")')
331329
if tag_with_search_string:
332330
tag_with_search_string.decompose()
333331
# Now 'soup' contains the modified HTML with the tag removed
334-
modified_html = soup.prettify(formatter=None)
332+
modified_html = peptides_51mer_soup.prettify(formatter=None)
335333

336334
if args.WB:
337335
html_file_name = args.WB + '/../manual_review/' + args.samp + ".Colored_Peptides.html"

0 commit comments

Comments
 (0)