|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.mahout.utils.vectors.VectorHelper
public class VectorHelper
Method Summary | |
---|---|
static java.lang.String[] |
loadTermDictionary(org.apache.hadoop.conf.Configuration conf,
org.apache.hadoop.fs.FileSystem fs,
java.lang.String filePattern)
Read a dictionary in SequenceFile generated by DictionaryVectorizer |
static java.lang.String[] |
loadTermDictionary(java.io.File dictFile)
Read in a dictionary file. |
static java.lang.String[] |
loadTermDictionary(java.io.InputStream is)
Read in a dictionary file. |
static java.lang.String |
vectorToString(Vector vector,
java.lang.String[] dictionary)
Create a String from a vector that fills in the values with the appropriate value from a dictionary where each the ith entry is the term for the ith vector cell.. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static java.lang.String vectorToString(Vector vector, java.lang.String[] dictionary)
vector
- dictionary
- The dictionary. See
public static java.lang.String[] loadTermDictionary(java.io.File dictFile) throws java.io.IOException
term DocFreq Index
dictFile
-
java.io.IOException
public static java.lang.String[] loadTermDictionary(org.apache.hadoop.conf.Configuration conf, org.apache.hadoop.fs.FileSystem fs, java.lang.String filePattern) throws java.io.IOException
SequenceFile
generated by DictionaryVectorizer
conf
- fs
- filePattern
- java.io.IOException
public static java.lang.String[] loadTermDictionary(java.io.InputStream is) throws java.io.IOException
term DocFreq Index
java.io.IOException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |