Stepped Wedge Cluster Randomized Trial (SW CRT) Design

A set of tools for examining the design and analysis aspects of stepped wedge cluster randomized trials (SW CRT) based on a repeated cross-sectional or cohort sampling scheme (Hussey MA and Hughes JP (2007) Contemporary Clinical Trials 28:182-191).


swCRTdesign

swCRTdesign includes functions for the design and analysis of stepped wedge cluster randomized trials.

Installation

You can install the development version of swCRTdesign like so:

# install.packages("devtools")
devtools::install_github("jphughes9/swCRTdesign")

Example

This is a basic example which shows you how find the power of a SW trial with 24 clusters and 5 periods

library(swCRTdesign)
swPwr(swDsn(c(6,6,6,6)), distn="binomial",
n=120, mu0=0.05, mu1=0.035, tau=0.01, eta=0, rho=0, gamma=0, alpha=0.05, retDATA=FALSE)
#> Warning in swPwr(swDsn(c(6, 6, 6, 6)), distn = "binomial", n = 120, mu0 = 0.05,
#> : Cross-sectional design assumed
#> treatment.1 
#>   0.7861896

#You’ll still need to render README.Rmd regularly, to keep README.md up-to-date. #devtools::build_readme() is handy for this.

#In that case, don’t forget to commit and push the resulting figure files, so they #display on GitHub and CRAN.

Reference manual

It appears you don't have a PDF plugin for this browser. You can click here to download the reference manual.

install.packages("swCRTdesign")

4.1 by Jim Hughes, a year ago


Browse source code at https://github.com/cran/swCRTdesign


Authors: Jim Hughes [aut, cre] , Navneet R. Hakhu [aut] , Emily Voldal [aut] , Fan Xia [aut]


Documentation:   PDF Manual  


GPL-2 license


Imports stats, lme4, lmerTest, glmmTMB


Suggested by magentabook.


See at CRAN