Skip to content

SteppedPower

0.4.0Package record

Power Calculation for Stepped Wedge Designs

0packages depend
6.8Kdownloads / year
39.0%test coverage
13/13flavors OK

Overview

About

Tools for power and sample size calculation as well as design diagnostics for longitudinal mixed model settings, with a focus on stepped wedge designs. All calculations are oracle estimates i.e. assume random effect variances to be known (or guessed) in advance. The method is introduced in Hussey and Hughes (2007) doi:10.1016/j.cct.2006.05.007, extensions are discussed in Li et al. (2020) doi:10.1177/0962280220932962.

Changes in 0.4.0
  • glsPower() now supports count outcomes via family="poisson"
  • Added ICC (intracluster correlation) transformation functions: icc_to_RandEff(), RandEff_to_icc(), RandEff_to_alpha012(), and alpha012_to_RandEff() for converting between random effects variances and ICC/CAC/IAC parameters
  • Added vignette on binomial and count outcomes, with pre-calculated contour plots
  • In glsPower(), the argument N now overrides the N stored in a supplied

DesMat object

  • glsPower() now fails gracefully (with a warning) if the information content

cannot be calculated

  • Character input arguments (e.g. dsntype, family) now throw an error if no

known option is sufficiently similar, instead of silently choosing the closest match

  • Diagnostic output now uses message() instead of print()
  • Vignette plots now use the plotly partial bundle to reduce package size
  • Changed covariance matrix construction to use fbdiag (fast block diagonal matrix)
Show all changes in 0.4.0Hide the rest of the changes in 0.4.0
  • plot_CellWeights() now treats NA entries in incompMat as unobserved

cluster periods

  • Replaced \() with function() for backward compatibility with older R versions
  • Fixed typo in RandEff_to_alpha
  • Added tests for construct_DesMat(), construct_CovMat(), and glsPower()
  • Updated vignettes and improved documentation with additional links in help files
  • Roxygen documentation now uses markdown format; re-roxygenised all documentation

From NEWS.md in the release

Install

Health

CRAN checks
13OK
Slowest check: 3.6 min · r-oldrel-windows-x86_64
Status changes
  • OK13 OK2026-08-05
  • NOTE12 OK, 1 NOTE2026-08-01
  • OK13 OK2026-06-09
  • ERROR12 OK, 1 ERROR2026-06-08
  • OK14 OK2026-03-10
Advisories

none known

Documentation

In release 0.4.0
READMEYes · 163 wordsVignettesYes · 3 · dynamicNEWSYes · 100% structured · mentions 0.4.0Citation fileNoWebsitenot declared in DESCRIPTION
Help pages
25includes a package overview page
Examples that run
100%12 run in a plain check
Exported functions with examples
61%
Documented parameters
100%
Return-value docs
100%
Help pages citing references
16%

Downloads

6.8K
CRAN downloads in the past year
Rank #7,589 · ~19/day · ~571/mo
Daily download trend is not available in this view yet.
43430 days
1.2K90 days
6.8K1 year
Compare downloads with other packages →
Also on82 r2u5 autocran

Dependencies

Declared dependencies
6 external dependencies (excludes base and recommended)

Installing SteppedPower adds 68 packages (39 with compiled code, 65 MB of source tarballs). Heaviest: stringi 11 MB, ggplot2 6.0 MB, data.table 5.7 MB.

Depends (1)
R >= 3.5.0
Imports (6)
MatrixplotlyRfastgrDevicesstatsutils
LinkingTo (0)
none
Enhances (0)
none
Reverse dependencies
0direct
0indirect

Nothing depends on this yet.

People & History

People (2)
Author, Maintainer since 0.1.0 (2021)
Contributor
Releases (7)

Pick two releases to compare their code metrics.

  • 0.4.0Latest
    record
    2026-09-21 · current release · diff ↗ ·
    added 2 exports
    RandEff_to_icc, icc_to_RandEff
  • R
    R 4.6.0 released · 2026-04-24
  • R
    R 4.5.0 released · 2025-04-11
  • 0.3.5
    record
    2024-04-29 · diff ↗
  • R
    R 4.4.0 released · 2024-04-24
  • 0.3.4
    record
    2023-09-13 · diff ↗
  • R
    R 4.3.0 released · 2023-04-21
  • 0.3.2
    record
    2022-07-05 · diff ↗ ·
    removed 2 exports
    compute_wlsPower, wlsPower
    added 3 exports
    compute_InfoContent, compute_glsPower, glsPower
  • R
    R 4.2.0 released · 2022-04-22
  • 0.3.1
    record
    2021-12-16 · diff ↗ ·
    added 3 exports
    construct_incompMat, plot_CellWeights, plot_InfoContent
  • 0.2.0
    record
    2021-07-07 · diff ↗ ·
    removed 1 export
    construct_timeadjust
    added 5 exports
    RandEff_to_alpha012, VarClosed_Kasza, VarClosed_Li, alpha012_to_RandEff, construct_timeAdjust
  • R
    R 4.1.0 released · 2021-05-18
  • 0.1.0
    record
    2021-02-04
  • R
    R 4.0.0 released · 2020-04-24

Package metadata

First published
2021-02-04
Total releases
7 / 5 yrs
License
MIT + file LICENSE OSI
Minimum R
≥ 3.5.0
Download size
2.1 MB

Cite

Cite this package

Run in R for the authors' preferred citation:

citation("SteppedPower")
Mildenberger, P., & Marini, F. (2026). SteppedPower: Power Calculation for Stepped Wedge Designs (Version 0.4.0) [Computer software]. https://doi.org/10.32614/CRAN.package.SteppedPower

This package has no citation file, so citation() returns this entry built from DESCRIPTION.

Cite the R Observatory

For a number measured here: a download total, a coverage figure, an archival date.

APA

Balamuta, J. J. (2026). R Observatory: Metrics for SteppedPower version 0.4.0 [Data set]. HJJB, LLC. Data release v2026-10-23. https://doi.org/10.5281/zenodo.21843040

From data release v2026-10-23, which the citation names so these numbers can be found later. More on citing and the projects behind them.

Report a problem with this page →

Privacy choices

These apply to this browser and are stored on this device only. Nothing about your choice is sent to us.

Read the privacy policy