Learn R Programming

ldr (version 1.3.3)

structure.test: Test of covariance structure for PFC models

Description

Information criterion and likelihood ratio test for the structure of the covariance matrix of PFC models.

Usage

structure.test(object1, object2)

Arguments

object1
An object of class pfc
object2
A second object of class pfc, fitted exactly as for object1 except for the covariance structure $\Delta$.

Details

Consider two PFC models $M_1$ and $M_2$, with the same parameters, except for the conditional covariance that is $\Delta_1$ for $M_1$ and $\Delta_2$ for $M_2$ such that model $M_1$ is nested in model $M_2$. We implemented the likelihood ratio test for the hypotheses: $H_0: \Delta=\Delta_1$ versus $H_a: \Delta=\Delta_2$. The test is implemented for the isotropic, anisotropic, and the unstructured PFC models. One may test isotropic against either anisotropic or unstructured, or test anisotropic against unstructured. The degrees of freedom are given by the difference in the number of parameters in the covariances. Information criterion AIC and BIC are also provided.

Examples

Run this code
data(bigmac)
fit1 <- pfc(X=bigmac[,-1], y=bigmac[,1], fy=bf(y=bigmac[,1], case="poly", 
        degree=3), numdir=3, structure="iso")
fit2 <- pfc(X=bigmac[,-1], y=bigmac[,1], fy=bf(y=bigmac[,1], case="poly", 
        degree=3), numdir=3, structure="aniso")
fit3 <- pfc(X=bigmac[,-1], y=bigmac[,1], fy=bf(y=bigmac[,1], case="poly", 
        degree=3), numdir=3, structure="unstr")
structure.test(fit1, fit3)
structure.test(fit2, fit3)

Run the code above in your browser using DataLab