atp.MVCN {MatrixHMM}R Documentation

Atypical Detection Points Using Matrix-Variate Contaminated Normal Hidden Markov Models

Description

Detects atypical matrices via matrix-variate contaminated normal Hidden Markov Models.

Usage

atp.MVCN(Y, pgood, class)

Arguments

Y

An array with dimensions p x r x num x t, where p is the number of variables in the rows of each data matrix, r is the number of variables in the columns of each data matrix, num is the number of data observations, and t is the number of time points.

pgood

An array with dimensions num x t x k containing the estimated probability of being typical for each point, given the time and state.

class

An num x t matrix containing the state memberships.

Value

An num x t matrix containing, for each observation and time, a 0 if it that matrix is typical and 1 otherwise.

Examples

data("simData2")
Y <- simData2$Y
init <- Eigen.HMM_init(Y = Y, k = 2, density = "MVCN", mod.row = "EEE", mod.col = "EE", nstartR = 1)
fit <- Eigen.HMM_fit(Y = Y, init.par = init, nThreads = 1)
atp <- atp.MVCN(Y = Y,
               pgood = fit[["results"]][[1]][[1]][[1]][["pgood"]],
               class = fit[["results"]][[1]][[1]][[1]][["class"]])
which(atp==1)
which(simData2[["atp.tr"]]==1)

[Package MatrixHMM version 1.0.0 Index]