#' @export
#' @method print BoundIRT
print.BoundIRT=function(x, digits=3, ...){
  xx=x$output
  output=format(round(xx,digits),justify="right")

  if(x$inflated=="zero"|x$inflated=="both"){
    ind=is.infinite(xx[,"gamma0"])
    output[ind,"gamma0"]=" "
    output[ind,8]=" "

  }
  if(x$inflated=="one"|x$inflated=="both"){
    ind=is.infinite(xx[,"gamma1"])
    output[ind,"gamma1"]=" "
    if(x$inflated=="one") output[ind,8]=" "
    if(x$inflated=="both") output[ind,10]=" "
  }
  col_width <- apply(output,2,function(x) max(nchar(x)))
  colnames(output) <- mapply(formatC, colnames(output), width = col_width, MoreArgs = list(flag = " "))
  print(output,quote=FALSE)
}
