| lav_fdr | R Documentation |
Apply a false discovery rate correction (Benjamini-Yekutieli by default) to
the p-values of selected parameters from a fitted lavaan object.
lav_fdr(
fit,
ops = c("reg", "load", "var.cov"),
family = c("by_group", "selected"),
method = "BY",
alpha = 0.05,
standardized = c("std.all", "std.lv", "std.nox", "none")
)
## S3 method for class 'lav_fdr'
print(x, ...)
## S3 method for class 'lav_fdr'
summary(object, ...)
fit |
A fitted |
ops |
Character. One of |
family |
Character. If |
method |
Character method passed to |
alpha |
Numeric significance threshold for adjusted p-values (default 0.05). |
standardized |
Which standardized column to include, or |
x |
A 'lav_fdr' object. |
... |
Passed to |
object |
A 'lav_fdr' object. |
Useful when a SEM includes many structural paths (or many other parameters of substantive interest) and there is the need to control the expected proportion of false positives among the parameters declared 'statistically significant'.
With many simultaneous tests, using p < .05 for each parameter
inflates the expected number of false positives (about m * .05 under
all true null hypotheses, where m is the number of tested parameters).
Benjamini-Yekutieli (BY) controls the False Discovery Rate (FDR) under
arbitrary dependence structures, which is suitable for SEMs where structural
paths are inherently dependent through shared latent variables, covariance
matrices, and model constraints.
A list with:
fdr_table: data.frame with raw and FDR-adjusted p-values.
settings: list of settings used.
group_var: group variable name (or NULL).
group_labels: group labels if available.
call: matched call.
The returned object has class "lav_fdr".
library("lavaan")
model <- "
ind60 =~ x1 + x2 + x3
dem60 =~ y1 + y2 + y3 + y4
dem65 =~ y5 + y6 + y7 + y8
dem60 ~ ind60
dem65 ~ ind60 + dem60
y1 ~~ y5
y2 ~~ y6
"
fit <- lavaan::sem(
model = model,
data = lavaan::PoliticalDemocracy,
std.lv = TRUE,
estimator = "MLR",
meanstructure = TRUE)
lav_fdr(fit = fit)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.