You'll need a file called NC_007605.1.fa in the same directory as ORFs.bed, which contains the sequence data for that chromosome.
You'll also need to edit line 67 to get FASTA headers to look the way you want. I won't explain how, but it should be straightforward from the code. As a further hint, how you process $id can help you stitch exons together further down the line.
Note: In the future, try to avoid posting graphics to questions. Graphics can't be indexed for search engines, the way text can. This question may get deleted by a moderator, for that reason.
handle = open("new_file.txt", "w")
handle.write("My FIRST line of text.\n")
handle.write("My SECOND line of text.\n")
handle.write("My THIRD line of text.\n")
handle = open("new_file.txt","r")
saved_line = handle.readline()
print(saved_line+ "is my favorite.")
print(saved_line.strip() + "is my favorite.")
for line in handle:
GeneBedfile = sys.argv
with open(GeneBedfile) as bfile:
for line in bfile:
start = int(line.strip().split("\t"))
end = int(line.strip().split("\t"))
geneName = str(line.strip().split("\t"))
print(geneName, "gene", "starts at", start, "ends at", end)