This function calculates the prediction error between estimates obtained after a leave-one-out cross validation for ABC and the true parameter values.
errorABC(true, estimated)
a numeric vector with the prediction error for each parameter. If column names are present in the input matrices, then this vector will also be named with the parameter names.
is a matrix where each row corresponds to the true parameter values of a given simulation and each column to a different parameter. These parameters where used as the pseudo-observed targets in the simulation study.
is a matrix with the estimated parameter values. Each row
corresponds to the estimate of the true parameter values present in the
corresponding row of the true
matrix. And each column should correspond
to a different parameter.
The prediction error is calculated as sum((E-T)^2) / (nval * var(T))
,
where T is the true parameter value, E is the estimated parameter value, and
nval is the number of points where the true and predicted values were
compared.