View source: R/core-generics.R
| fim.likelihood_model | R Documentation |
Computes the Fisher information matrix by Monte Carlo simulation using
the negative expected Hessian approach. For each of n_samples replicates,
generates a single-observation dataset via rdata, computes
-hess_loglik(single_obs, theta), and averages. The result is
n_obs * I_1(theta) where I_1(theta) is the per-observation FIM.
## S3 method for class 'likelihood_model'
fim(model, ...)
model |
A likelihood model |
... |
Additional arguments passed to rdata |
This default requires the model to implement rdata and hess_loglik
(or loglik, since hess_loglik falls back to numerical differentiation).
Function that takes (theta, n_obs, n_samples, ...) and returns FIM matrix
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.