Spaces:
Sleeping
Sleeping
Commit
·
162f5ed
1
Parent(s):
9280c78
Update code/add_alignment.py
Browse files- code/add_alignment.py +11 -11
code/add_alignment.py
CHANGED
|
@@ -7,24 +7,24 @@ from Bio.pairwise2 import format_alignment
|
|
| 7 |
|
| 8 |
|
| 9 |
def do_alignment(identifier, uniprotSequence, pdbSequence, alignment_path):
|
| 10 |
-
|
| 11 |
-
|
| 12 |
-
|
| 13 |
-
|
| 14 |
#if len(pdbSequence) >= 1:
|
| 15 |
#f = open(Path(alignment_path / f'{identifier}_alignment.txt'),"w")
|
| 16 |
aligner.mode = 'local'
|
| 17 |
-
|
| 18 |
aligner.substitution_matrix = substitution_matrices.load("BLOSUM62")
|
| 19 |
-
|
| 20 |
aligner.open_gap_score = -11
|
| 21 |
-
|
| 22 |
aligner.extend_gap_score = -1
|
| 23 |
-
|
| 24 |
-
|
| 25 |
alignments = aligner.align(uniprotSequence, pdbSequence)[0]
|
| 26 |
-
|
| 27 |
-
|
| 28 |
"""
|
| 29 |
alignments = (list(alignments))
|
| 30 |
alignment_list = []
|
|
|
|
| 7 |
|
| 8 |
|
| 9 |
def do_alignment(identifier, uniprotSequence, pdbSequence, alignment_path):
|
| 10 |
+
print(f'Aligning Datapoint: {identifier}')
|
| 11 |
+
print(pdbSequence)
|
| 12 |
+
print('uniprot Seq')
|
| 13 |
+
print(uniprotSequence)
|
| 14 |
#if len(pdbSequence) >= 1:
|
| 15 |
#f = open(Path(alignment_path / f'{identifier}_alignment.txt'),"w")
|
| 16 |
aligner.mode = 'local'
|
| 17 |
+
print('1')
|
| 18 |
aligner.substitution_matrix = substitution_matrices.load("BLOSUM62")
|
| 19 |
+
print('2')
|
| 20 |
aligner.open_gap_score = -11
|
| 21 |
+
print('3')
|
| 22 |
aligner.extend_gap_score = -1
|
| 23 |
+
print('4')
|
| 24 |
+
print(aligner.align(uniprotSequence, pdbSequence)[0])
|
| 25 |
alignments = aligner.align(uniprotSequence, pdbSequence)[0]
|
| 26 |
+
print('Alignments')
|
| 27 |
+
print(alignments)
|
| 28 |
"""
|
| 29 |
alignments = (list(alignments))
|
| 30 |
alignment_list = []
|