[Biojava-l] ChromatogramFactory fails on Windows and Mac

hkaya hkaya at iontek.com.tr
Sun Sep 23 10:56:08 UTC 2007


Hello

The following small code perfectly runs on Linux but
it fails on Windows and Mac. I'm using biojava 1.5. 
Could anybody tell me where i am doing something wrong? 

Thanks
Huseyin Kaya


1. TraceTest.java

   import java.io.File;
   import org.biojava.bio.chromatogram.Chromatogram;
   import org.biojava.bio.chromatogram.ChromatogramFactory;

   public class TraceTest {
	public static void main(String[] args) {		
		try {
			Chromatogram trace = ChromatogramFactory.create(new File("test.scf"));
			System.out.println("Success!");
		} catch (Exception e){
			System.out.println("Failed!");
			e.printStackTrace();	
		}
	}
   }

2. Test chromatogram file : http://istanbul.be.itu.edu.tr/~huseyin/test.scf

3. Exception thrown in Windows XP/Vista:

   Desktop> java -classpath biojava-1.5.jar;. TraceTest
   Exception in thread "main" org.biojava.bio.BioError: Unable to initialize
DNATools
        at org.biojava.bio.seq.DNATools.<clinit>(DNATools.java:117)
        at org.biojava.bio.program.scf.SCF$V3Parser.parseSamples(SCF.java:560)
        at org.biojava.bio.program.scf.SCF$Parser.parse(SCF.java:350)
        at org.biojava.bio.program.scf.SCF$ParserFactory.parse(SCF.java:206)
        at org.biojava.bio.program.scf.SCF.load(SCF.java:149)
        at org.biojava.bio.program.scf.SCF.load(SCF.java:141)
        at org.biojava.bio.program.scf.SCF.create(SCF.java:126)
        at
org.biojava.bio.chromatogram.ChromatogramFactory.create(ChromatogramFactory.java:75)
        at TraceTest.main(TraceTest.java:8)
   Caused by: org.biojava.bio.BioError: Unable to initialize RNATools
        at org.biojava.bio.seq.RNATools.<clinit>(RNATools.java:126)
        at org.biojava.bio.seq.DNATools.<clinit>(DNATools.java:110)
        ... 8 more
   Caused by: org.biojava.bio.BioError: Couldn't parse TranslationTables.xml
        at org.biojava.bio.seq.RNATools.loadGeneticCodes(RNATools.java:529)
        at org.biojava.bio.seq.RNATools.<clinit>(RNATools.java:124)
        ... 9 more
   Caused by: org.biojava.bio.symbol.IllegalSymbolException: 
        Token `his' does not appear as a named symbol in alphabet `PROTEIN-TERM'
        at
org.biojava.bio.seq.io.NameTokenization.parseToken(NameTokenization.java:110)
        at org.biojava.bio.seq.RNATools.loadGeneticCodes(RNATools.java:520)
        ... 10 more





More information about the Biojava-l mailing list