R/model.R

Defines functions model

Documented in model

model <-
function(object){
welcome<-function(){
    cat("=====  Model selection based on credible intervals ======")
    cat("\n")
    cat("#                                                       #")
    cat("\n")
    cat("#               Author: Rahim Alhamzawi                 #")
    cat("\n")
    cat("#               Contact: [email protected]      #")
    cat("\n")
    cat("#                      July, 2018                       #")
    cat("\n")
    cat("#                                                       #")
    cat("\n")
    cat("=========================================================")
    cat("\n")
}
##############################################################
CredInt = apply(object$beta, 2, quantile, c(0.025, 0.975))
Estimate= coef(object)

for(i in 1:length(CredInt [1,])){
if (sign(CredInt [1,i])==-1 & sign (CredInt [2,i])==1)  Estimate [i]=0 
}
result= cbind(Estimate)
welcome()
    result

}

Try the Brq package in your browser

Any scripts or data that you put into this service are public.

Brq documentation built on May 2, 2019, 4:12 a.m.