icmm {icmm} | R Documentation |
Empirical Bayes Variable Selection
Description
Empirical Bayes variable selection via the ICM/M algorithm.
Usage
icmm(Y, X, event, b0.start, b.start, family = "gaussian",
ising.prior = FALSE, structure, estalpha = FALSE,
alpha = 0.5, maxiter = 100)
Arguments
Y |
an (n*1) numeric matrix of responses. |
X |
an (n*p) numeric design matrix. |
event |
an (n*1) numeric matrix of status for censored data: |
b0.start |
a starting value of intercept term (optional). |
b.start |
a (p*1) matrix of starting values for regression coefficients. |
family |
specification of the model. It can be one of these three models: |
ising.prior |
a logical flag for Ising prior utilization. |
structure |
a data frame stores the information of structured predictors (need to specify when |
estalpha |
a logical flag specifying whether to obtain |
alpha |
a scalar value of scale parameter in Laplace density (non-zero part of prior). The default value is |
maxiter |
a maximum values of iterations for ICM/M algorithm. |
Details
The main function for empirical Bayes variable selection. Iterative conditional modes/medians (ICM/M) is implemented in this function. The basic problem is to estimate regression coefficients in high-dimensional data (i.e., large p small n) and we assume that most coefficients are zero. This function also allows the prior of structure of covariates to be incorporated in the model.
Value
Return a list including elements
coef |
a vector of model coefficients. The first element is an intercept term when specifying |
iterations |
number of iterations of ICM/M. |
alpha |
a scalar value of |
postprob |
a p-vector of local posterior probabilities or zeta. |
Author(s)
Vitara Pungpapong, Min Zhang, Dabao Zhang
References
Pungpapong, V., Zhang, M. and Zhang, D. (2015). Selecting massive variables using an iterated conditional modes/medians algorithm. Electronic Journal of Statistics. 9:1243-1266. <doi:10.1214/15-EJS1034>.
Pungpapong, V., Zhang, M. and Zhang, D. (2020). Integrating Biological Knowledge Into Case-Control Analysis Through Iterated Conditional Modes/Medians Algorithm. Journal of Computational Biology. 27(7): 1171-1179. <doi:10.1089/cmb.2019.0319>.
See Also
get.ab
, get.alpha
, get.beta
, get.beta.ising
, get.pseudodata.binomial
,
get.pseudodata.cox
, get.sigma
, get.wprior
, get.zeta
, get.zeta.ising
Examples
# Normal linear regression model
# With no prior on structure among predictors
data(simGaussian)
Y<-as.matrix(simGaussian[,1])
X<-as.matrix(simGaussian[,-1])
# Obtain initial values from lasso
data(initbetaGaussian)
initbeta<-as.matrix(initbetaGaussian)
result<-icmm(Y=Y, X=X, b.start=initbeta, family="gaussian",
ising.prior=FALSE, estalpha=FALSE, alpha=0.5, maxiter=100)
result$coef
result$iterations
result$alpha
result$wpost
# With prior on structure among predictors
data(linearrelation)
result<-icmm(Y=Y, X=X, b.start=initbeta, family="gaussian",
ising.prior=TRUE, structure=linearrelation,
estalpha=FALSE, alpha=0.5, maxiter=100)
result$coef
result$iterations
result$alpha
result$wpost
# Binary logistic regression model
data(simBinomial)
Y<-as.matrix(simBinomial[,1])
X<-as.matrix(simBinomial[,-1])
p<-dim(X)[2]
# Obtain initial values from lasso
data(initbetaBinomial)
initbeta<-as.matrix(initbetaBinomial)
result<-icmm(Y=Y, X=X, b0.start=0, b.start=initbeta, family="binomial",
ising.prior=TRUE, structure=linearrelation, estalpha=FALSE,
alpha=0.5, maxiter=100)
result$coef
result$iterations
result$alpha
result$wpost
# Cox's model
data(simCox)
Y<-as.matrix(simCox[,1])
event<-as.matrix(simCox[,2])
X<-as.matrix(simCox[,-(1:2)])
# Obtain initial values from lasso
data(initbetaCox)
initbeta<-as.matrix(initbetaCox)
result <- icmm(Y=Y, X=X, event=event, b.start=initbeta, family="cox",
ising.prior=TRUE, structure=linearrelation, estalpha=FALSE,
alpha=0.5, maxiter=100)
result$coef
result$iterations
result$alpha
result$wpost