Skip to content

Commit 990ffad

Browse files
committed
move
1 parent dd1cdb9 commit 990ffad

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

R/p_adjust.R

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -94,11 +94,6 @@
9494
# `estimate_slopes()` was called, or a modelbased object, when processing /
9595
# formatting was already done. So we check for both, and extract the required
9696
# columns.
97-
df_column <- intersect(c("df", "df_error"), colnames(params))[1]
98-
if (is.na(df_column)) {
99-
df_column <- ".sup_df"
100-
params[[df_column]] <- Inf
101-
}
10297
coef_column <- intersect(c(.valid_coefficient_names(), "estimate"), colnames(params))[1]
10398
if (is.na(coef_column)) {
10499
insight::format_alert("Could not find coefficient column to apply `sup-t` adjustment.")
@@ -120,6 +115,11 @@
120115
insight::format_alert("Could not extract confidence intervals to apply `sup-t` adjustment.")
121116
return(params)
122117
}
118+
df_column <- intersect(c("df", "df_error"), colnames(params))[1]
119+
if (is.na(df_column)) {
120+
df_column <- ".sup_df"
121+
params[[df_column]] <- Inf
122+
}
123123
# calculate updated confidence interval level, based on simultaenous
124124
# confidence intervals (https://onlinelibrary.wiley.com/doi/10.1002/jae.2656)
125125
crit <- mvtnorm::qmvt(ci_level, df = params[[df_column]][1], tail = "both.tails", corr = vc)$quantile

0 commit comments

Comments
 (0)