R/summary.PNAR.R

Defines functions print.PNAR print.summary.PNAR summary.PNAR

Documented in print.PNAR print.summary.PNAR summary.PNAR

summary.PNAR <- function(object, ...) {
  a <- list()
  class(a) <- "summary.PNAR"
  a$coefs <- object$coefs
  a$score <- object$score
  a$loglik <- object$loglik
  a$ic <- object$ic
  return(a)
}

print.summary.PNAR <- function(x, ...) {
  cat("Coefficients: \n")
  print(x$coefs)
  cat("---", "\n")
  cat("Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1", "\n")
  cat("\n")
  cat("Log-likelihood value: ", x$loglik, "\n")
  cat("AIC:", x$ic[1], "BIC:", x$ic[2], "QIC:", x$ic[3])
}

print.PNAR <- function(x, ...) {
  cat("Coefficients: \n")
  a <- x$coefs[, 1]
  names(a) <- rownames(x$coefs)
  print(a)
}

Try the PNAR package in your browser

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

PNAR documentation built on Sept. 12, 2024, 7:30 a.m.