Skip to content

Commit

Permalink
Fixed bug when reading in vote.arff dataset (bundled with weka)
Browse files Browse the repository at this point in the history
  • Loading branch information
theJenix committed Mar 26, 2013
1 parent a9abda1 commit 15157e8
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/shared/reader/ArffDataSetReader.java
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,9 @@ private Instance[] processInstances(BufferedReader in,
String[] values = pattern.split(line.trim());
double[] ins = new double[values.length];
for (int i = 0; i < values.length; i++) {
String v = values[i];
//some values are single quoted (especially in datafiles bundled
// with weka)
String v = values[i].replaceAll("'", "");
// defaulting to 0 if attribute value unknown.
double d = 0;
try {
Expand Down

0 comments on commit 15157e8

Please sign in to comment.