power_search | R Documentation |
The function that initializes the search process. The powerNLSEM
function actually is a wrapper function for power_search
.
power_search(
POI,
method,
lavModel,
lavModel_Analysis,
data_transformations,
search_method,
power_modeling_method,
R = 1000,
power_aim = 0.8,
alpha = 0.05,
alpha_power_modeling = 0.05,
CORES,
verbose,
Ns = NULL,
N_start = nrow(lavModel[lavModel$op != "~1", ]) * 10,
distRj = "increasing",
steps = 10,
nlb = nrow(lavModel[lavModel$op != "~1", ]) * 5,
switchStep = round(steps/2),
FSmethod = "SL",
test = "onesided",
matchPI = TRUE,
PIcentering = "doubleMC",
liberalInspection = FALSE,
constrainRelChange = TRUE,
seeds,
pathLMS = tempdir()
)
POI |
Parameter Of Interest as a vector of strings. Must be in lavaan-syntax without any spaces. Nonlinear effects should have the same ordering as in model. |
method |
Method used to fit to the data. Can be LMS or UPI. |
lavModel |
lavModel object describing the model. |
lavModel_Analysis |
lavModel object containg the parameters to be estimated. |
data_transformations |
Object containing info on data transformations. |
search_method |
String stating the search method. Default to |
power_modeling_method |
Power modeling method used to model significant parameter estimates. Default to |
R |
Total number of models to be fitted. Higher number results in higher precision and longer runtime. |
power_aim |
Minimal power value to approximate. Default to .8. |
alpha |
Type I-error rate for significance decision. Default to |
alpha_power_modeling |
Type I-error rate for confidence band around predicted power rate. Used to ensure that the computed |
CORES |
Number of cores used for parallelization. Default to number of available cores - 2. |
verbose |
Logical whether progress should be printed in console. Default to TRUE. |
Ns |
Sample sizes used in power estimation process. Default to |
N_start |
Starting sample size for smart algorithm. Default to |
distRj |
Indicator how the samples sizes should be used in the steps of the smart algorithm: |
steps |
Steps used in |
nlb |
Lower bound of N used in search. Default to |
switchStep |
Steps after which smart search method changes from exploration to exploitation. Default to |
FSmethod |
Method to be used to extract factor scores. Default to |
test |
Should the parameter be tested with a directed hypothesis (onesided) or with an undirected hypothesis (twosided, also equivalent to Wald-Test for single parameter). Default to |
matchPI |
Logical passed to |
PIcentering |
String indicating which method of centering should be used when constructing product indicators. String is converted to the arguments |
liberalInspection |
Logical whether the inspection of estimation truthworthiness should be very liberal (i.e., allowing for non-positive definite Hessians in standard error estimation or non-positive residual covariance matrices or latent covariance matrices). Default to |
constrainRelChange |
Logical whether the change in the bounds of the interval for N using the smart algorithm should be constrained. This prevents divergence (which is especially an issue for small effect sizes and small |
seeds |
Seeds for reproducibility. |
pathLMS |
path where (temporal) data and scripts for running LMS using Mplus are stored (using |
Returns a list
that includes the results on model-implied simulation-based power estimation.
Wolf, E. J., Harrington, K. M., Clark, S. L., & Miller, M. W. (2013). Sample Size Requirements for Structural Equation Models: An Evaluation of Power, Bias, and Solution Propriety. Educational and Psychological Measurement, 76(6), 913–934. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1177/0013164413495237")}
Irmer, J. P., Klein, A. G., & Schermelleh-Engel, K. (2024). Behavior Research Methods, 0(00), Advance Online Publication.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.