Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

OneStepMarkovChain Class Reference

One step markov chain translation model, not fully tested yet. More...

#include <OneStepMarkovChain.hpp>

List of all members.

Public Methods

 OneStepMarkovChain (const WeightedIDSet &docSet, const Index &homeIndex, double *wdNorm, double stopProbAlpha)
 construct a MC restricted to a subset of docs

 ~OneStepMarkovChain ()
Iteration support
void startFromWordIteration (TERMID_T toWord) const
 Start iteration over w's for t(toWord |w).

bool hasMoreFromWord () const
void nextFromWordProb (TERMID_T &fromWord, double &prob) const
 Fetch the next word and the prob of "translating" it to the toWord.


Detailed Description

One step markov chain translation model, not fully tested yet.

This code is included mainly to illustrate how the toolkit can be used for estimating such models.


Constructor & Destructor Documentation

OneStepMarkovChain::OneStepMarkovChain const WeightedIDSet   docSet,
const Index   homeIndex,
double *    wdNorm,
double    stopProbAlpha
 

construct a MC restricted to a subset of docs

OneStepMarkovChain::~OneStepMarkovChain  
 


Member Function Documentation

bool OneStepMarkovChain::hasMoreFromWord   const [inline]
 

void OneStepMarkovChain::nextFromWordProb TERMID_T   fromWord,
double &    prob
const
 

Fetch the next word and the prob of "translating" it to the toWord.

void OneStepMarkovChain::startFromWordIteration TERMID_T    toWord const
 

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).


The documentation for this class was generated from the following files:
Generated on Wed Nov 3 12:59:49 2004 for Lemur Toolkit by doxygen1.2.18