Skip to content

Commit

Permalink
lintr
Browse files Browse the repository at this point in the history
  • Loading branch information
strengejacke committed Jun 24, 2024
1 parent 53fad3f commit b6b0039
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions R/repeated_measures_d.R
Original file line number Diff line number Diff line change
Expand Up @@ -185,9 +185,9 @@ repeated_measures_d <- function(x, y,
probs <- c(alpha / 2, 1 - alpha / 2)
qs <- stats::qnorm(probs)

confint <- out[["d"]] + qs * values[["se"]]
out$CI_low <- confint[1]
out$CI_high <- confint[2]
conf_int <- out[["d"]] + qs * values[["se"]]
out$CI_low <- conf_int[1]
out$CI_high <- conf_int[2]

ci_method <- list(method = "normal")
out <- .limit_ci(out, alternative, -Inf, Inf)
Expand Down Expand Up @@ -231,11 +231,11 @@ rm_d <- repeated_measures_d

m <- mean(x - y)
n <- length(x)
df <- n - 1
dof <- n - 1
r <- stats::cor(x, y)
f <- 2 * (1 - r)

if (method == "rm") {
if (method == "rm") { # nolint
s <- stats::sd(x - y) / sqrt(f)
d <- (m - mu) / s

Expand All @@ -261,7 +261,7 @@ rm_d <- repeated_measures_d
se <- sqrt(f / n + (d^2) / (2 * n))
}

.nlist(d, se, df)
.nlist(d, se, dof)
}

#' @keywords internal
Expand Down

0 comments on commit b6b0039

Please sign in to comment.