Skip to content

Instantly share code, notes, and snippets.

@eharkins
Created September 6, 2018 01:16
Show Gist options
  • Save eharkins/dfae7087eb308dfaa1da0bcb44efdbfa to your computer and use it in GitHub Desktop.
Save eharkins/dfae7087eb308dfaa1da0bcb44efdbfa to your computer and use it in GitHub Desktop.
def parse_fasta_string(fasta_string):
return dict([tuple(s.replace('\n', ':', 1).replace('\n','').split(':')) for s in fasta_string.split('>')[1:]])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment