steinian_estimate | R Documentation |
This function computes the Steinian estimate for model risk by fitting a sequence of
Generalized Linear Models (GLMs) with varying values of tau
. It combines the preliminary
estimate from a model fitted with an initial tau_0
value with a penalty term that incorporates
the in-sample prediction error and a covariance penalty, which is based on models fitted by inverting
the response of individual observations.
steinian_estimate(formula, cat_init, tau_seq, tau_0, ...)
formula |
A formula specifying the GLMs. Should at least include response variables. |
cat_init |
A list generated from |
tau_seq |
A sequence of tuning parameter values ( |
tau_0 |
A reference value for |
... |
Other arguments passed to other internal functions. |
Preliminary Estimate Model: The function first fits a GLM model using the observed and
synthetic data with an initial value of tau_0
for the synthetic data weights.
In-sample Prediction Error: For each value of tau
in tau_seq
, the function computes
the in-sample prediction error (logistic deviance).
Steinian Penalty: The function calculates the Steinian covariance penalty for each observation by fitting a modified model that inverts one observation at a time. The penalty is added to the in-sample prediction error to obtain the final risk estimate.
Steinian Risk Estimate: The final Steinian risk estimate is calculated by summing the
in-sample prediction error and the Steinian penalty term for each value of tau
in tau_seq
.
A numeric vector of Steinian risk estimates, one for each value of tau
in tau_seq
.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.