geney 1.3.58__py2.py3-none-any.whl → 1.3.60__py2.py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
geney/SeqMats.py
CHANGED
|
@@ -300,6 +300,10 @@ class SeqMat:
|
|
|
300
300
|
def raw_indices(self):
|
|
301
301
|
return self.seqmat[self.ROW_INDS, :] + (self.seqmat[self.ROW_SUPERINDS, :] / 10)
|
|
302
302
|
|
|
303
|
+
@property
|
|
304
|
+
def filter(self):
|
|
305
|
+
return self.seqmat[:, self.seqmat[self.ROW_SEQ, :] != 5]
|
|
306
|
+
|
|
303
307
|
|
|
304
308
|
def mutate(self, mut, inplace=False):
|
|
305
309
|
"""
|
|
@@ -357,15 +361,19 @@ class SeqMat:
|
|
|
357
361
|
if tis_index not in self.indices:
|
|
358
362
|
return SeqMat.from_seq({'seq': ''})
|
|
359
363
|
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
+
raw_seq = SeqMat(self.seqmat[:, self._rel_index(tis_index):])
|
|
365
|
+
raw_seq = SeqMat(raw_seq.filter)
|
|
366
|
+
|
|
367
|
+
# temp = temp[:, temp[0, :] != 5]
|
|
368
|
+
# temp = SeqMat(temp) # .drop_indices()
|
|
369
|
+
# raw_seq = temp.seq # Extract the raw sequence
|
|
364
370
|
pattern = re.compile(r"(?:[NACGT]{3})*?(TAA|TAG|TGA)")
|
|
365
|
-
|
|
366
|
-
match
|
|
367
|
-
|
|
371
|
+
match = pattern.match(raw_seq.seq)
|
|
372
|
+
print(match)
|
|
373
|
+
# match = [(m.group(), m.start()+1) for m in re.finditer(r"(?:[NACGT]{3})*?(TAA|TAG|TGA)", raw_seq.seq)]# if
|
|
374
|
+
# # (m.start()+1) % 3 == 0]
|
|
368
375
|
|
|
376
|
+
# print(match)
|
|
369
377
|
if len(match) > 0:
|
|
370
378
|
stop_index = match[0][-1] #.end()
|
|
371
379
|
else:
|
|
@@ -373,7 +381,7 @@ class SeqMat:
|
|
|
373
381
|
|
|
374
382
|
end_index = stop_index
|
|
375
383
|
# assert (end_index+1) % 3 == 0, f"{end_index} is not a multiple of 3"
|
|
376
|
-
return SeqMat(
|
|
384
|
+
return SeqMat(raw_seq.seqmat[:, :end_index])
|
|
377
385
|
|
|
378
386
|
def translate(self, tis_index):
|
|
379
387
|
"""
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
geney/Fasta_segment.py,sha256=99HxNGNh_MfdVW6hhtlb1vOn7eSmT7oFoEfHDFMxG8w,11275
|
|
2
2
|
geney/Gene.py,sha256=nMWJjoQaiVFm2iRjoiq7ghZqnXtW0tJDcq2S0AyOIvY,6883
|
|
3
|
-
geney/SeqMats.py,sha256=
|
|
3
|
+
geney/SeqMats.py,sha256=DwEq_452FsF-zrr2nE1MMSTfKf54931yJERfXq0Ak7k,19460
|
|
4
4
|
geney/Transcript.py,sha256=CpfxYkuCwFILozrtLuiWnlr1mRnMKn4o84HVJislgYs,14499
|
|
5
5
|
geney/__init__.py,sha256=eBdDl42N6UhcYeZDjOnv199Z88fI5_8Y6xW8447OKXM,755
|
|
6
6
|
geney/_mutation_utils.py,sha256=dHssUsnii_mf-wuRoMmF13UlD7k3ml_VwQMItTYnXpU,1132
|
|
@@ -25,7 +25,7 @@ geney/translation_initiation/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NM
|
|
|
25
25
|
geney/translation_initiation/tis_utils.py,sha256=AF3siFjuQH-Rs44EV-80zHdbxRMvN4woLFSHroWIETc,4448
|
|
26
26
|
geney/translation_initiation/resources/kozak_pssm.json,sha256=pcd0Olziutq-6H3mFWDCD9cujQ_AlZO-iiOvBl82hqE,1165
|
|
27
27
|
geney/translation_initiation/resources/tis_regressor_model.joblib,sha256=IXb4DUDhJ5rBDKcqMk9zE3ECTZZcdj7Jixz3KpoZ7OA,2592025
|
|
28
|
-
geney-1.3.
|
|
29
|
-
geney-1.3.
|
|
30
|
-
geney-1.3.
|
|
31
|
-
geney-1.3.
|
|
28
|
+
geney-1.3.60.dist-info/METADATA,sha256=9RdNxrkkxfNmokUDoatZq-ALXfGVcfyXXR5bEFI0_Ck,990
|
|
29
|
+
geney-1.3.60.dist-info/WHEEL,sha256=AHX6tWk3qWuce7vKLrj7lnulVHEdWoltgauo8bgCXgU,109
|
|
30
|
+
geney-1.3.60.dist-info/top_level.txt,sha256=O-FuNUMb5fn9dhZ-dYCgF0aZtfi1EslMstnzhc5IIVo,6
|
|
31
|
+
geney-1.3.60.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|