simulation

How to do power simulations for structural equation models in R

Computing a priori power analyses for simple statistical models can be done analytically (e.g., with G*Power or the pwr package in R). However, estimating the power for more complex models and in particular structural equation models (SEM) is not as straightforward and requires simulations. I recently came across the package paramtest (Hughes, 2017) which provides a great framework for conducting more complex power simulations. In what follows, I provide some examples of how to simulate… Read More »How to do power simulations for structural equation models in R

How to visualize interaction effects

I recently gave a workshop on data visualization. One of the topics was visualizing interaction effects (or “moderation” analyses). I think it is a great topic because it exemplifies quite well that there is not one solution to all problems. In general, I would argue that trying to visualize interaction effects is great idea. Due to the conditional nature of the effects obtained from standard regression analyses that include an interaction term, it is often… Read More »How to visualize interaction effects

How to center in multilevel models

Have you ever thought about centering your variables before running an regression based analysis? From my personal experiences, chances are high are that you haven’t: Although a useful data transformation procedure for many statistical analyses, centering is seldom taught in fundamental statistic courses. Although the mathematical principles behind it may seem arbitrary, its implications are oftentimes quite strong. Although centering is already useful in standard statistical modeling (e.g., OLS regression), its usefulness is particularly evident… Read More »How to center in multilevel models