Performs Gauss-Newton optimisation of the variational free energy for a
non-linear forward model with Gaussian priors. Mirrors SPM25's
dcm_nlsi_GN.
dcm_nlsi_GN(M, U, Y)List with posterior expectation Ep, covariance Cp,
log-precision estimate Eh, free energy F, and components.
Most users should call dcm_estimate instead, which assembles
M, U and Y from a DCM specification and calls this
function. Use dcm_nlsi_GN directly only to invert a non-linear
model that is not an fMRI DCM.
Progress is reported per Gauss-Newton iteration as
EM:(+) k F: ..., where (+) marks an accepted step and
(-) a rejected one. Set M$noprint <- 1 to silence it.
dcm_estimate for the user-facing entry point.
# dcm_nlsi_GN is the Gauss-Newton optimiser that dcm_estimate() calls after
# assembling M, U and Y from a DCM specification. For a runnable inversion
# see the example in ?dcm_estimate; dcm_nlsi_GN returns the same posterior
# fields (Ep, Cp, Eh, F).