estLogPxCatGthetaJ: Estimate log document probabilites given specific Categorical...

Description Usage Arguments Examples

Description

Estimate log document probabilites given specific Categorical parameters

Usage

1
estLogPxCatGthetaJ(X, logprob)

Arguments

X

a matrix of categorical events (row-wise)

logprob

the Categorical probability

Examples

1
2
3
4
5
6
7
8
{
X=matrix(c(1,2,1,1,1,1,2,1),2,4,byrow=TRUE) # two documents of length 4
prob=matrix(c(.9,.8,.9,.9,.1,.2,.1,.1),4,2) # prob per index
dput(mApplyCat(X,prob)) # likelihood for each index
#structure(c(0.9, 0.9, 0.2, 0.8, 0.9, 0.1, 0.9, 0.9), .Dim = c(2L, 4L))
dput(estLogPxCatGthetaJ(X,log(prob))) 
# c(-1.92551945940758, -2.73644967562391)
}


Search within the mvc package
Search all R packages, documentation and source code

Questions? Problems? Suggestions? or email at ian@mutexlabs.com.

Please suggest features or report bugs with the GitHub issue tracker.

All documentation is copyright its authors; we didn't write any of that.