Package de.jungblut.reader
Class TwentyNewsgroupReader
- java.lang.Object
-
- de.jungblut.reader.TwentyNewsgroupReader
-
public final class TwentyNewsgroupReader extends java.lang.ObjectReads the "20news-bydate" dataset into a vector space model as well as predictions based on the category.- Author:
- thomas.jungblut
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static de.jungblut.math.tuple.Tuple3<java.util.List<java.lang.String>,de.jungblut.math.dense.DenseDoubleVector,java.lang.String[]>readTwentyNewsgroups(java.io.File directory)Needs the "20news-bydate" directory that has test and train subdirectories given.
-
-
-
Method Detail
-
readTwentyNewsgroups
public static de.jungblut.math.tuple.Tuple3<java.util.List<java.lang.String>,de.jungblut.math.dense.DenseDoubleVector,java.lang.String[]> readTwentyNewsgroups(java.io.File directory)
Needs the "20news-bydate" directory that has test and train subdirectories given.- Returns:
- in tuple3 order: document as string, prediction, name mapping for prediction
-
-