Source: http://weka.wikispaces.com/CLASSPATH
Win32 (2k and XP)
We assume that the mysql-connector-java-3.1.8-bin.jar archive is located in the following directory:- C:\Program Files\Weka-3-4
Depending on, whether you're the only person using this computer or it is a lab computer shared by many, you can either create a new system-wide (you are the only user) environment variable or a user dependent one (recommended for multi-user machines). Enter the following name for the variable
- CLASSPATH
- C:\Program Files\Weka-3-4\mysql-connector-java-3.1.8-bin.jar
Unix/Linux
I assume, that the mysql jar is located in the following directory:- /home/johndoe/jars/
- bash
export CLASSPATH=$CLASSPATH:/home/johndoe/jars/mysql-connector-java-3.1.8-bin.jar - c
shell
setenv CLASSPATH $CLASSPATH:/home/johndoe/jars/mysql-connector-java-3.1.8-bin.jar
Unix/Linux uses the colon : as path separator, in contrast to Win32, which uses the semicolon ;
Run before adding external jar Unix/Linux
java -jar weka.jar
Run after adding external jar Unix/Linux
You can not use same command java -jar , when you add external jar. You have to
use java -classpath
java -classpath $CLASSPATH:weka.jar:libsvm.jar weka.gui.GUIChooser (linux )
java -classpath "%CLASSPATH%;weka.jar;libsvm.jar" weka.gui.GUIChooser (windows)
Comments
Post a Comment