Learn R Programming

LICORS (version 0.2.0)

compute_LICORS_loglik: Log-likelihood of LICORS model

Description

Computes the average log-likelihood \(\frac{1}{N} \ell(\mathbf{W}; \mathcal{D})\) as a function of the weight matrix \(\mathbf{W}\) and the predictive state distributions \(P(X = x \mid S = s_j) \approx P(X = x \mid \mathbf{W}_j)\) for all \(j = 1, \ldots, K\). See References.

Usage

compute_LICORS_loglik(weight.matrix, pdfs.FLC, lambda = 0, penalty = "entropy", q = 2, 
    base = exp(1))

Arguments

weight.matrix

\(N \times K\) weight matrix

pdfs.FLC

an \(N \times K\) matrix containing the estimates of all \(K\) FLC densities evaluated at all \(N\) sample FLCs.

lambda

regularization parameter. Default: lambda=0 (penalty and q will be ignored in this case).

penalty

type of penalty: c("entropy", "1-Lq", "lognorm"). Default: "entropy"

base

logarithm base for the "entropy" penalty. Default: base = 2. Any other real number is allowed; if base = "num.states" then it will internally assign it base = ncol(weight.matrix).

q

exponent for \(L_q\) norm.