cc.mallet.topics
Class DMRTopicModel

java.lang.Object
  extended by cc.mallet.topics.LDAHyper
      extended by cc.mallet.topics.DMRTopicModel
All Implemented Interfaces:
java.io.Serializable

public class DMRTopicModel
extends LDAHyper

See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class cc.mallet.topics.LDAHyper
LDAHyper.Topication
 
Field Summary
 
Fields inherited from class cc.mallet.topics.LDAHyper
alpha, alphabet, alphaSum, beta, betaSum, burninPeriod, cachedCoefficients, data, DEFAULT_BETA, docLengthCounts, formatter, iterationsSoFar, numIterations, numTopics, numTypes, oneDocTopicCounts, optimizeInterval, outputModelFilename, outputModelInterval, printLogLikelihood, random, saveSampleInterval, saveStateInterval, showTopicsInterval, smoothingOnlyMass, stateFilename, testing, tokensPerTopic, topicAlphabet, topicDocCounts, typeTopicCounts, wordsPerTopic
 
Constructor Summary
DMRTopicModel(int numberOfTopics)
           
 
Method Summary
 void estimate(int iterationsThisRound)
           
 void learnParameters()
           
static void main(java.lang.String[] args)
           
 void printTopWords(java.io.PrintStream out, int numWords, boolean usingNewLines)
           
 void setAlphas()
          Use only the default features to set the topic prior (use no document features)
 void setAlphas(Instance instance)
          Set alpha based on features in an instance
 void setAlphas(int featureIndex)
          This method sets the alphas for a hypothetical "document" that contains a single non-default feature.
 void writeParameters(java.io.File parameterFile)
           
 
Methods inherited from class cc.mallet.topics.LDAHyper
addInstances, addInstances, empiricalLikelihood, estimate, getAlphabet, getCountFeatureTopic, getCountTokensPerTopic, getData, getNumTopics, getSortedTopicWords, getTopicAlphabet, initializeHistogramsAndCachedValues, instanceLength, modelLogLikelihood, printDocumentTopics, printDocumentTopics, printDocumentTopics, printState, printState, printTopWords, read, sampleTopicsForOneDoc, setBurninPeriod, setModelOutput, setNumIterations, setOptimizeInterval, setRandomSeed, setSaveState, setTestingInstances, setTopicDisplay, topicLabelMutualInformation, topicXMLReport, topicXMLReportPhrases, write
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DMRTopicModel

public DMRTopicModel(int numberOfTopics)
Method Detail

estimate

public void estimate(int iterationsThisRound)
              throws java.io.IOException
Overrides:
estimate in class LDAHyper
Throws:
java.io.IOException

setAlphas

public void setAlphas()
Use only the default features to set the topic prior (use no document features)


setAlphas

public void setAlphas(int featureIndex)
This method sets the alphas for a hypothetical "document" that contains a single non-default feature.


setAlphas

public void setAlphas(Instance instance)
Set alpha based on features in an instance


learnParameters

public void learnParameters()

printTopWords

public void printTopWords(java.io.PrintStream out,
                          int numWords,
                          boolean usingNewLines)
Overrides:
printTopWords in class LDAHyper

writeParameters

public void writeParameters(java.io.File parameterFile)
                     throws java.io.IOException
Throws:
java.io.IOException

main

public static void main(java.lang.String[] args)
                 throws java.io.IOException
Throws:
java.io.IOException