MAC {maclogp} | R Documentation |
Mac and LogP measure
Description
This function allows you to obtain a model confidence set using Mac procedure and the LogP uncertainty measure for a selection method based on an information criterion.
Usage
MAC(models, data, B, alpha, method = "bic", delta = 1e-04, eps = 1e-06)
Arguments
models |
A list with one entry for each model. Each entry is an
integer vector that specifies the columns of matrix |
data |
a list including
|
B |
number of bootstrap replicates to perform; Default value is 200. |
alpha |
a vector of significance levels. The confidence levels of the model confidence sets
are 1- |
method |
Information criterion. Users can choose from |
delta |
A small positive number added inside of LogP when the bootstrap
probability of selected model is 1. Default value is |
eps |
toterance level in choosing models with total bootstrap probabilities
at least |
Value
Returns an object of class “MAC”. An object of class “MAC” is a list containing at least the following components:
hat_M |
numeric index of selected model. |
con_sets |
a list with with one entry for a |
length_con |
lengths of confidence sets. |
order |
Model indexes with increasing information scores based on original data. |
probs_inorder |
Bootstrap probabilities for the models in |
beta_ls |
a list with one entry for each model. Each entry is a vector of estimated coefficients based on original data for that model. |
hat_prob |
the Bootstrap probability for single selected model. |
hat_logp |
the LogP measure. |
References
Liu, X., Li, Y. & Jiang, J.(2020). Simple measures of uncertainty for model selection. TEST, 1-20.
See Also
Examples
set.seed(0)
n= 50
B= 100
p= 5
x = matrix(rnorm(n*p, mean=0, sd=1), n, p)
true_b = c(1:3, rep(0,p-3))
y = x%*% true_b+rnorm(n)
alpha=c(0.1,0.05,0.01)
data=list(x=x,y=y)
models=Models_gen(1:p)
result=MAC(models, data, B, alpha)