1 / 22

Mediation: PowMedR

Mediation: PowMedR. David A. Kenny. Mediation Webinar. Power and Effect Sizes. Installing R. Start from the beginning R already installed R and RGtk2 already installed Go to opening screen. Better yet: Find your local R expert and get help!.

calida
Download Presentation

Mediation: PowMedR

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Mediation: PowMedR David A. Kenny

  2. Mediation Webinar • Power and Effect Sizes

  3. Installing R • Start from the beginning • R already installed • R and RGtk2already installed • Go to opening screen Better yet: Find your local R expert and get help!

  4. To download R, go to the Comprehensive R Archive Network or CRAN at http://cran.r-project.org/ (if you click on this link the webinar will pause) and choose the version appropriate for your compute. The download is about 30 MB. R contains both a command line application and a GUI (graphical user interface). When R is started up for the first time, a window appears that looks like the following:

  5. Download PowMedR at http://www.davidakenny.net/progs/PowMedR.txt (webinar will pause if you click on the link) Paste this “text” onto R GUI and your screen should look like:

  6. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. # # Thanks to Jake Westfall of the University of Colorado at Boulder for suggestions. library(RGtk2) rround = function (num,dig) # Rounding function { if (dig==2) return(sprintf("%.2f", round(num,2))) if (dig==3) return(sprintf("%.3f", round(num,3))) if (dig==1) return(sprintf("%.1f", round(num,1))) if (dig==4) return(sprintf("%.4f", round(num,4))) if (dig==5) return(sprintf("%.5f", round(num,5))) }

  7. You will need to install RGtk2, the package for the PowMedR graphical interface.

  8. Choose RGkt2

  9. The Beginning Model c Y X

  10. The Mediational Model M b a c' Y X

  11. Key Effects Indirect effect: ab Direct effect: c′ Total effect: c or c′ + ab

  12. This should appear:

  13. Power calculations have begun... Effect Size Power N c .390 .986 100 a .300 .868 100 b .300 .890 100 c' .300 .890 100 ab .090 .773 100 Alpha for all power calculations set to .050. Power calculations complete.

  14. To get N for desired power, check the box. x

  15. Power calculations have begun... Effect Size Power N c .390 .800 48 a .300 .800 84 b .300 .800 78 c' .300 .800 78 ab .090 .800 105Alpha for all power calculations set to .050.Power calculations complete.

  16. PowMedR Assumes that the model is correctly specified. All variables are standardized making a, b, c, and c′ are beta coefficients. Power determined by the implied correlation between the two variables controlling for relevant variables. Joint significance method used for indirect effect.

  17. Features Can change alpha. Always two-sided. Error check for out of range values.

  18. Thanks! • Jake Westfall, Alexander Demos, and Craig Waterman

More Related