Skip to content

Commit

Permalink
typo in simple_slopes '*' should be '+'
Browse files Browse the repository at this point in the history
  • Loading branch information
Kss2k committed Jan 9, 2025
1 parent 5367ef0 commit 4b03e57
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion R/simple_slopes.R
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ simple_slopes <- function(x,

# creating margins
df <- structure(expand.grid(x = vals_x, z = vals_z), names= c("vals_x", "vals_z"))
df$predicted <- mean_y + beta_x * df$vals_x + beta_z + df$vals_z + df$vals_z * df$vals_x * beta_xz
df$predicted <- mean_y + beta_x * df$vals_x + beta_z * df$vals_z + df$vals_z * df$vals_x * beta_xz
df$std.error <- calc_se(df, e = res_y, VCOV = VCOV, se_type = ci_type)
df$z.value <- (df$predicted - h0) / df$std.error # H0 = mean_y
df$p.value <- 2 * stats::pnorm(-abs(df$z.value))
Expand Down

0 comments on commit 4b03e57

Please sign in to comment.