goodnessfit {lba}R Documentation

Goodness of Fit results for Latent Budget Analysis

Description

The goodness of fit results assesses how well the model fits the data. It consists of measures of the resemblance between the observed and the expected data, and the parsimony of the model.

Usage

goodnessfit(object,...)

## S3 methods
## Default S3 method:
goodnessfit(object, ...)

## S3 method for class 'lba.ls'
goodnessfit(object, ...)
    
## S3 method for class 'lba.ls.fe'
goodnessfit(object, ...)    
    
## S3 method for class 'lba.ls.logit'
goodnessfit(object, ...)
    
## S3 method for class 'lba.mle'
goodnessfit(object, ...)    

## S3 method for class 'lba.mle.fe'
goodnessfit(object, ...)    
 
## S3 method for class 'lba.mle.logit'
goodnessfit(object, ...) 

Arguments

object

An object of one of following classes: lba.ls, lba.ls.fe, lba.ls.logit, lba.mle, lba.mle.fe, lba.mle.logit

...

Further arguments (required by generic).

Value

The goodnessfit function of the method lba.mle, lba.mle.fe and lba.mle.logit returns a list with the slots:

dfdb

Degrees of freedom of the base model

dfd

Degrees of freedom of the full model

G2b

Likelihood ratio statistic of the base model

G2

Likelihood ratio statistic of the full model

chi2b

Chi-square statistic of the base model

chi2

Chi-square statistic of the full model

proG1

P-value of likelihood ratio statistic of the base model

proG

P-value of likelihood ratio statistic of the full model

prochi1

P-value of chi-square statistic of the base model

prochi

P-value of chi-square statistic of the full model

AICb

AIC criteria of the base model

AICC

AIC criteria of the full model

BICb

BIC criteria of the base model

BICC

BIC criteria of the full model

CAICb

CAIC criteria of the base model

CAIC

CAIC criteria of the full model

delta1

Normed fit index

delta2

Normed fit index modified

rho1

Bollen index

rho2

Tucker-Lewis index

RSS1

Residual sum of square of the base model

RSS

Residual sum of square of the full model

impRSS

Improvement of RSS

impPB

Improvement per budget

impDF

Average improvement per degree of freedom

D1

Index of dissimilarity of the base model

D

Index of dissimilarity of the full model

pccb

Proportion of correctly classified data of the base model

pcc

Proportion of correctly classified data of the full model

impD

Improvement of proportion of correctly classified data

impPCCB

Improvement of Proportion of correctly classified data per budget

AimpPCCDF

Average improvement of Proportion of correctly classified data per degree of freedom

mad1

Mean angular deviation of the base model

madk

Mean angular deviation of the full model

impMad

Improvement mean angular deviation

impPBsat

Improvement mean angular deviation per budget

impDFsat

Average improvement mean angular deviation per degree of freedom

The goodnessfit function of the method lba.ls, lba.ls.fe and lba.ls.logit returns a list with the slots:

dfdb

Degrees of freedom of the base model

dfd

Degrees of freedom of the full model

RSS1

Residual sum of square of the base model

RSS

Residual sum of square of the full model

impRSS

Improvement of RSS

impPB

Improvement per budget

impDF

Average improvement per degree of freedom

D1

Index of dissimilarity of the base model

D

Index of dissimilarity of the full model

pccb

Proportion of correctly classified data of the base model

pcc

Proportion of correctly classified data of the full model

impD

Improvement of proportion of correctly classified data

impPCCB

Improvement of Proportion of correctly classified data per budget

AimpPCCDF

Average improvement of Proportion of correctly classified data per degree of freedom

mad1

Mean angular deviation of the base model

madk

Mean angular deviation of the full model

impMad

Improvement mean angular deviation

impPBsat

Improvement mean angular deviation per budget

impDFsat

Average improvement mean angular deviation per degree of freedom

Note

For a detailed and complete discussion about goodness of fit results for latent budget analysis, see van der Ark 1999.

References

Agresti, Alan. 2002. Categorical Data Analysis, second edition. Hoboken: John Wiley and Sons.

van der Ark, A. L. 1999. Contributions to Latent Budget Analysis, a tool for the analysis of compositional data. Ph.D. Thesis University of Utrecht.

See Also

summary.goodnessfit.lba.ls, summary.goodnessfit.lba.mle,lba

Examples

data('votB')

# Using LS method (default) without constraint
# K = 2
ex1 <- lba(parties ~ city,
           votB,
           K = 2)

gx1 <- goodnessfit(ex1)
gx1

# Using MLE method without constraint
# K = 2
exm <- lba(parties ~ city,
           votB,
           K = 2,
           method='mle')

gxm <- goodnessfit(exm)
gxm

# Using LS method (default) with LOGIT constrain
data('housing')

# Make cross-table to matrix design.
tbh <- xtabs(value ~ Influence + Housing, housing)

Xis <- model.matrix(~ Housing*Influence,
                    tbh,
                    contrasts=list(Housing='contr.sum',
                                   Influence='contr.sum'))

tby <- xtabs(value ~ Satisfaction + Contact, housing)

Yis <- model.matrix(~ Satisfaction*Contact,
                    tby,
                    contrasts=list(Satisfaction='contr.sum',
                                   Contact='contr.sum'))[,-1]

S <- 12
T <- 5

tabs <- xtabs(value ~ interaction(Housing,
                                  Influence) + interaction(Satisfaction,
                                  Contact),
              housing)
## Not run: 
ex2 <- lba(tabs,
           K = 2,
           logitA = Xis,
           logitB = Yis,
           S = S,
           T = T,
           trace.lba=FALSE) 

gex2 <- goodnessfit(ex2)
gex2

## End(Not run)

[Package lba version 2.4.52 Index]