Skip to content
This repository has been archived by the owner. It is now read-only.
Permalink
master
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Go to file
 
 
Cannot retrieve contributors at this time
import sys
import os
gfa_file_path = str(sys.argv[1])
if not os.path.exists(gfa_file_path):
print("the gfa file path you gave does not exists, pleast try again!")
sys.exit()
sequences = []
with open(gfa_file_path, "r") as lines:
for line in lines:
if line.startswith("S"):
line = line.split()
sequences.append("\n>\n")
sequences.append(line[2])
output_f_name = str(sys.argv[2])
fasta_f = open(output_f_name, "w")
for l in sequences:
fasta_f.write(l)