public Map < Frame , Sequence < AminoAcidCompound > > multipleFrameTranslation ( Sequence < NucleotideCompound > dna , Frame ... frames ) { Map < Frame , Sequence < AminoAcidCompound > > results = new EnumMap < Frame , Sequence < AminoAcidCompound > > ( Frame . class ) ; for ( Frame frame : frames ) { Sequence < NucleotideCompound > rna = getDnaRnaTranslator ( ) . createSequence ( dna , frame ) ; Sequence < AminoAcidCompound > peptide = getRnaAminoAcidTranslator ( ) . createSequence ( rna ) ; results . put ( frame , peptide ) ; } return results ; }
A way of translating DNA in a number of frames