#include <OneStepMarkovChain.hpp>
Public Methods | |
OneStepMarkovChain (WeightedIDSet &docSet,Index &homeIndex,double *wdNorm,double stopProbAlpha) | |
construct a MC restricted to a subset of docs. | |
~OneStepMarkovChain () | |
Iteration support | |
void | startFromWordIteration (int toWord) |
Start iteration over w's for t(toWord |w). More... | |
bool | hasMoreFromWord () |
void | nextFromWordProb (int &fromWord,double &prob) |
Fetch the next word and the prob of "translating" it to the toWord. |
This code is included mainly to illustrate how the toolkit can be used for estimating such models.
|
construct a MC restricted to a subset of docs.
|
|
|
|
|
|
Fetch the next word and the prob of "translating" it to the toWord.
|
|
Start iteration over w's for t(toWord |w). Given a word, this provides a way to access the translation probability from any word to this word. E.g., given w, each iteration would give us t(w|w1), t(w|w2), ..., t(w|w_n). |