Skip to content

Commit b792015

Browse files
authored
Merge pull request #23 from dpellow/17
Update choice of node and its reverse complements to reflect changes …
2 parents 9304a0b + c1bd58c commit b792015

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

bin/make_fasta_from_fastg.py

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
def parse_user_input():
66
parser = argparse.ArgumentParser(
77
description=
8-
'recycle extracts cycles likely to be plasmids from metagenome and genome assembly graphs'
8+
'make_fasta_from_fastg converts fastg assembly graph to fasta format'
99
)
1010
parser.add_argument('-g','--graph',
1111
help='(spades 3.50+) FASTG file to process [recommended: before_rr.fastg]',
@@ -19,13 +19,10 @@ def parse_user_input():
1919
return parser.parse_args()
2020

2121
def parse_lines(fastg, ofile):
22-
lines = []
2322
fp = open(fastg, 'r')
24-
count = 0
2523
for name,seq,qual in readfq(fp):
26-
count += 1
27-
if count % 2 == 0: continue
2824
name = re.sub('[:,]'," ", name[:-1]).split(" ")[0]
25+
if name[-1] == "'": continue # only need one of forward and reverse complement
2926
line = ">"+name+"\n"+seq+"\n"
3027
ofile.write(line)
3128

0 commit comments

Comments
 (0)