dlm-js
    Preparing search index...

    Type Alias DlmLossFn

    DlmLossFn: (
        deviance: np.Array,
        params: np.Array,
        meta: DlmParamMeta,
    ) => np.Array

    Custom loss function type for MAP estimation.

    Receives the Kalman deviance (−2·logL, scalar np.Array), the current parameter vector in natural scale (np.Array), and a layout descriptor (DlmParamMeta). Must return a scalar np.Array. All operations on the inputs must be AD-safe (jax-js ops only).

    params layout: [s?, w₀, …, w_{m-1}, φ₁, …, φ_p]

    • s and wᵢ are positive std devs (not log-transformed).
    • φⱼ are unconstrained AR coefficients.

    Type Declaration

      • (deviance: np.Array, params: np.Array, meta: DlmParamMeta): np.Array
      • Parameters

        Returns np.Array