[Biojava-l] read three letter amino acid sequence

Hongyu Zhang me at hongyu.org
Fri Dec 5 08:23:24 UTC 2008


Thanks for the hint, Mark. I found that the NameTokenization class could be used for this purpose, although it can't deal with the ambiguous amino acid "Xaa". The following code will work for regular amino acid such as "Cys" 

            Alphabet ap = AlphabetManager.alphabetForName("PROTEIN");
            NameTokenization nt = new NameTokenization((FiniteAlphabet)ap);
            Symbol s = nt.parseToken("Cys");



More information about the Biojava-l mailing list