This function provides a logical test of whether or not a Model
specification function meets mininum requirements to be considered as
such.
is.model(Model, Initial.Values, Data)
This is a model specification function. For more
information, see the LaplacesDemon
function.
This is a vector of initial values, or current
parameter values. For more information, see the
LaplacesDemon
function.
This is a list of data. For more information, see the
LaplacesDemon
function.
The is.model
function returns a logical value of TRUE
when Model
meets minimum criteria of a model specification
function, and FALSE
otherwise.
This function tests for minimum criteria for Model
to be
considered a model specification function. Specifically, it tests:
Model
must be a function
Model
must execute without errors
Model
must return a list
Model
must have five components in the list
The first component must be named LP and have length 1
The second component must be named Dev and have length 1
The third component must be named Monitor
The lengths of Monitor and mon.names must be equal
The fourth component must be named yhat
The fifth component must be named parm
The lengths of parm and parm.names must be equal
This function is not extensive, and checks only for these minimum
criteria. Additional checks are conducted in
IterativeQuadrature
, LaplaceApproximation
,
LaplacesDemon
, PMC
, and
VariationalBayes
.
IterativeQuadrature
,
LaplaceApproximation
,
LaplacesDemon
,
PMC
, and
VariationalBayes
.