@@ -30,12 +30,7 @@ class MotifPssmPattern(SequencePattern):
30
30
sequence(s) with the absolute highest possible score".
31
31
"""
32
32
33
- def __init__ (
34
- self ,
35
- pssm ,
36
- threshold = None ,
37
- relative_threshold = None ,
38
- ):
33
+ def __init__ (self , pssm , threshold = None , relative_threshold = None ):
39
34
if not isinstance (pssm , Bio .motifs .Motif ):
40
35
raise ValueError (
41
36
f"Expected PSSM type of `Bio.motifs.Motif`, but { type (pssm )} was passed"
@@ -74,9 +69,7 @@ def find_matches_in_string(self, sequence):
74
69
# sequence, threshold=self.threshold, both=False
75
70
# )
76
71
indices = find_pssm_matches_with_numpy (
77
- pssm_matrix = self .pssm_matrix ,
78
- sequence = sequence ,
79
- threshold = self .threshold ,
72
+ pssm_matrix = self .pssm_matrix , sequence = sequence , threshold = self .threshold
80
73
)
81
74
return [(i , i + self .size , 1 ) for i in indices ]
82
75
@@ -121,9 +114,7 @@ def from_sequences(
121
114
motif .name = name
122
115
pssm = motif
123
116
return MotifPssmPattern (
124
- pssm = pssm ,
125
- threshold = threshold ,
126
- relative_threshold = relative_threshold ,
117
+ pssm = pssm , threshold = threshold , relative_threshold = relative_threshold
127
118
)
128
119
129
120
@classmethod
@@ -172,9 +163,7 @@ def list_from_file(
172
163
173
164
return [
174
165
MotifPssmPattern (
175
- pssm ,
176
- threshold = threshold ,
177
- relative_threshold = relative_threshold ,
166
+ pssm , threshold = threshold , relative_threshold = relative_threshold
178
167
)
179
168
for pssm in motifs_list
180
169
]
0 commit comments