https://github.com/cran/CARBayes
Raw File
Tip revision: c30352b8452d4b535f8d97060cb142a68227bf0f authored by Duncan Lee on 30 September 2021, 07:10:05 UTC
version 5.2.5
Tip revision: c30352b
coef.CARBayes.R
coef.CARBayes <- function(object,...)
{
    #### Return the estimated regression coefficient
    if(is.null(nrow(object$samples$beta)))
    {
        return(NULL)  
    }else
    {
    beta <- apply(object$samples$beta, 2, median)
    names(beta) <- colnames(object$X)    
    return(beta)
    }
}
back to top