deviance.initgmf: Compute deviance, AIC and BIC of an initialized GMF model

deviance.initgmfR Documentation

Compute deviance, AIC and BIC of an initialized GMF model

Description

Compute deviance, AIC and BIC of an initialized GMF object

Usage

## S3 method for class 'initgmf'
deviance(object, ..., normalize = FALSE)

## S3 method for class 'initgmf'
AIC(object, ..., k = 2)

## S3 method for class 'initgmf'
BIC(object, ...)

Arguments

object

an object of class initgmf

...

further arguments passed to or from other methods

normalize

if TRUE, normalize the result using the null-deviance

k

the penalty parameter to be used for AIC; the default is k = 2

Value

The value of the deviance extracted from a initgmf object.

See Also

deviance.sgdgmf, AIC.sgdgmf and AIC.sgdgmf.

Examples

# Load the sgdGMF package
library(sgdGMF)

# Generate data from a Poisson model
data = sim.gmf.data(n = 100, m = 20, ncomp = 5, family = poisson())

# Fit a GMF model with 3 latent factors
init = sgdgmf.init(data$Y, ncomp = 3, family = poisson())

# Get the GMF deviance, AIC and BIC
deviance(init)
AIC(init)
BIC(init)


sgdGMF documentation built on April 3, 2025, 7:37 p.m.