penalized_likelihood: Penalized likelihood objective function

Description Usage Arguments Value

View source: R/LDS_GA.R

Description

Kalman_smoother returns X and likelihood. The penalized likelihood is the likelihood minus the sum-of-squares of the measurement update. This is used as the fitness function in genetic algorihm.

Usage

1
penalized_likelihood(y, u, v, theta.vec, lambda)

Arguments

y

Observation matrix (may need to be normalized and centered before hand) (q rows, T columns)

u

Input matrix for the state equation (m_u rows, T columns)

v

Input matrix for the output equation (m_v rows, T columns)

theta.vec

a vector of parameter elements (i.e, the vectorized version of theta in Kalman_smoother)

lambda

weight of the penalty

Value

The penalized likelihood (a real number)


ntthung/ldsr documentation built on Aug. 28, 2020, 2:34 a.m.