Skip to content

Commit

Permalink
styler and lintrs
Browse files Browse the repository at this point in the history
  • Loading branch information
mattansb committed Sep 3, 2024
1 parent 7c4b2b9 commit 026189d
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 8 deletions.
6 changes: 3 additions & 3 deletions R/bci.R
Original file line number Diff line number Diff line change
Expand Up @@ -300,8 +300,8 @@ bci.get_predicted <- function(x, ci = 0.95, use_iterations = FALSE, verbose = TR
upper <- stats::quantile(x, upper.inv, names = FALSE, na.rm = TRUE)

data.frame(
"CI" = ci,
"CI_low" = lower,
"CI_high" = upper
CI = ci,
CI_low = lower,
CI_high = upper
)
}
4 changes: 2 additions & 2 deletions R/format.R
Original file line number Diff line number Diff line change
Expand Up @@ -225,8 +225,8 @@ format.bayesfactor_restricted <- function(x,
BFE$BF[sgn] <- paste0("-", BFE$BF[sgn])
}
BFE$log_BF <- NULL
colnames(BFE)[colnames(BFE)=="p_prior"] <- "P(Prior)"
colnames(BFE)[colnames(BFE)=="p_posterior"] <- "P(Posterior)"
colnames(BFE)[colnames(BFE) == "p_prior"] <- "P(Prior)"
colnames(BFE)[colnames(BFE) == "p_posterior"] <- "P(Posterior)"

# footer
if (is.null(format) || format == "text") {
Expand Down
6 changes: 4 additions & 2 deletions R/print.equivalence_test.R
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,10 @@ print.equivalence_test <- function(x, digits = 2, ...) {
x$HDI <- sprintf("[%*s %*s]", maxlen_low, x$HDI_low, maxlen_high, x$HDI_high)

ci <- unique(x$CI)
keep.columns <- c(attr(x, "grid_cols"), "Parameter", "Effects", "Component",
"ROPE_Equivalence", "ROPE_Percentage", "CI", "HDI")
keep.columns <- c(
attr(x, "grid_cols"), "Parameter", "Effects", "Component",
"ROPE_Equivalence", "ROPE_Percentage", "CI", "HDI"
)

x <- x[, intersect(keep.columns, colnames(x))]

Expand Down
1 change: 0 additions & 1 deletion R/utils.R
Original file line number Diff line number Diff line change
Expand Up @@ -176,4 +176,3 @@
attr(results, "grid_cols") <- grid_names
results
}

0 comments on commit 026189d

Please sign in to comment.