def translate(self, frame=<NUM_LIT:0>):
return Fasta(self.id, '<STR_LIT>'.join([genetic_codes.codes[genetic_code].get(self.seq[x:x+<NUM_LIT:3>].upper(), '<STR_LIT:X>') for x in range(frame, len(self)-<NUM_LIT:1>-frame, <NUM_LIT:3>)]))<EOL>
Returns a Fasta sequence, translated into amino acids. Starts translating from 'frame', where frame expected to be 0,1 or 2