pmv_tmet: Approximate Log-Likelihood via TMET

pmvn_tmetR Documentation

Approximate Log-Likelihood via TMET

Description

Computes the approximate log-likelihood for a count time series model based on a Gaussian and Student –t copula using the Time Series Minimax Exponential Tilting (TMET) method.

Usage

pmvn_tmet(lower, upper, tau, od, pm = 30, M = 1000, QMC = TRUE, ret_llk = TRUE)

pmvt_tmet(
  lower,
  upper,
  tau,
  od,
  pm = 30,
  M = 1000,
  QMC = TRUE,
  ret_llk = TRUE,
  df
)

Arguments

lower

Numeric vector of length n giving the lower bounds of the transformed latent variables.

upper

Numeric vector of length n giving the upper bounds of the transformed latent variables.

tau

Numeric vector of ARMA dependence parameters ordered as c(phi_1, ..., phi_p, theta_1, ..., theta_q), where \phi_i are autoregressive (AR) coefficients and \theta_j are moving-average (MA) coefficients.

od

Integer vector c(p, q) specifying the AR and MA orders.

pm

Integer specifying the number of past lags used when approximating an ARMA(p,q) process by an AR representation (required if q > 0).

M

Positive integer specifying the number of Monte Carlo or quasi-Monte Carlo samples used in the simulation.

QMC

Logical; if TRUE (default), quasi-Monte Carlo integration is used. Otherwise, standard Monte Carlo sampling is applied.

ret_llk

Logical; if TRUE (default), returns the approximate log-likelihood. If FALSE, internal diagnostic quantities from the GHK simulator are returned. This option is primarily intended for internal use and methodological research.

df

Degrees of freedom for the t copula. Must be greater than 2. Required only for pmvt_ghk().

Details

TMET exploits the autoregressive moving-average (ARMA) structure of the latent Gaussian or Scale mixture normal representation of Student–t process to evaluate high-dimensional multivariate normal/t rectangle probabilities via adaptive importance sampling with an optimal tilting parameter.

The implementation combines the Innovations Algorithm for exact conditional mean and variance computation with exponential tilting, resulting in a scalable and variance-efficient likelihood approximation.

In this package, the latent dependence structure is parameterized through an ARMA(p,q) process.

Value

A numeric scalar giving the approximate log-likelihood. If ret_llk = FALSE, diagnostic output from the TMET sampler is returned (primarily for research use).

References

Nguyen, Q. N., & De Oliveira, V. (2026). Likelihood Inference in Gaussian Copula Models for Count Time Series via Minimax Exponential Tilting Journal of Computational Statistics and Data Analysis.

Nguyen, Q. N., & De Oliveira, V. (2026). Scalable Likelihood Inference for Student–t Copula Count Time Series. Manuscript in preparation.

See Also

pmvn_ghk, pmvt_ghk

Examples

## Gaussian copula example
mu <- 10
tau <- 0.2
arma_order <- c(1, 0)

sim_data <- sim_poisson(mu = mu, tau = tau, arma_order = arma_order,
                        nsim = 1000, seed = 1)

y <- sim_data$y
a <- qnorm(ppois(y - 1, lambda = mu))
b <- qnorm(ppois(y, lambda = mu))

# Approximate log-likelihood using TMET
llk_tmet <- pmvn_tmet(lower = a, upper = b,
                      tau = tau, od = arma_order)
llk_tmet

## Student--t copula example
df <- 8

sim_data_t <- sim_poisson(mu = mu, tau = tau, arma_order = arma_order,
                          nsim = 500, family = "t", df = df, seed = 1)

y_t <- sim_data_t$y
a_t <- qt(ppois(y_t - 1, lambda = mu), df = df)
b_t <- qt(ppois(y_t, lambda = mu), df = df)

llk_t <- pmvt_tmet(lower = a_t, upper = b_t, tau = tau, od = arma_order,
                  M = 1000, df = df)
                  

gctsc documentation built on March 20, 2026, 9:11 a.m.