Skip to content

Commit

Permalink
add a new line at the end of the summary output (fixes #188)
Browse files Browse the repository at this point in the history
  • Loading branch information
paul-buerkner committed Feb 28, 2017
1 parent 13ab8b7 commit 98fa831
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions R/misc-methods.R
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ print.brmssummary <- function(x, digits = 2, ...) {
print(x$formula, wsp = 9)
cat(paste0(" Data: ", x$data.name,
" (Number of observations: ", x$nobs, ") \n"))
if (x$sampler == "") {
cat(paste("\nThe model does not contain posterior samples."))
if (!nzchar(x$sampler)) {
cat("\nThe model does not contain posterior samples.\n")
} else {
if (!is.null(x$n.iter)) {
# deprecated names are used
Expand Down Expand Up @@ -87,14 +87,15 @@ print.brmssummary <- function(x, digits = 2, ...) {
cat("\n")
}

cat(paste0("Samples were drawn using ",x$sampler,". "))
cat(paste0("Samples were drawn using ", x$sampler, ". "))
if (x$algorithm == "sampling") {
cat(paste0("For each parameter, Eff.Sample \n",
"is a crude measure of effective sample size, ",
"and Rhat is the potential \n",
"scale reduction factor on split chains ",
"(at convergence, Rhat = 1)."))
}
cat("\n")
}
invisible(x)
}
Expand Down

0 comments on commit 98fa831

Please sign in to comment.