Learn R Programming

FIAR (version 0.6)

dcmEvidence: modelfit

Description

Compute AIC and BIC of a DCM

Usage

dcmEvidence(DCM, ts)

Arguments

DCM

DCM object.

ts

Timeseries to fit the model to.

Value

Creates 2 extra fields DCM$AIC and DCM$BIC

See Also

spm.dcm.estimate

Examples

Run this code
# NOT RUN {
# Compute how well the model DCMex fits the timeseries DCMex$sim
 ts <-  dcmGenerate(DCMex, SNR=1, ar=.2, names=c('V1','V2','V3'))
 DCMex <- dcmEvidence(DCMex, ts)

 DCMex$AIC
 DCMex$BIC


# }

Run the code above in your browser using DataLab