fixed a few bugs which caused the generated .arff files to be incompatible with weka