TriaLab Power Studio · Method
Two regression slopes (group × predictor interaction)
Sizes a study to show that the slope of an outcome on a predictor differs between two groups — the group-by-predictor interaction of a linear model — by the t-test on n₁ + n₂ − 4 degrees of freedom, with equal or unequal groups (Dupont and Plummer; G*Power).
Also known as: two slopes, interaction, moderation, parallel lines, difference in slopes, Dupont and Plummer, Armitage.
Maturity
Validated: 7 published examples from 2 independent publications (G*Power; PASS) reproduce on every build (ADR-0001 §58).
What it solves for
- Sample size: offered.
- Power: offered.
- Detectable effect: offered.
- Precision: not offered — A confidence-interval width for a difference of slopes is not sized here: the G*Power manual offers none and PASS’s chapter is not on disk.
- Assurance: not offered — No source on disk states a prior on this design’s effect, so the assurance modifier is not admitted here.
- Duration: not offered — This design has no time axis: each subject is observed once, so calendar time does not enter the power function.
Size axes:
- Observations in group 1 (group 2 is the allocation ratio times this) (
participants_per_group), Count
Inputs
Every field as the form shows it, with its help. A field marked advanced sits behind Expert mode.
Common to every method
- Significance level (alpha) (
alpha): a number, above 0 and below 1; default 0.05; typically 0.01 to 0.05 (0.05 in most trials; 0.01 for confirmatory claims); entered as proportion (0-1) or percent The type I error rate. Interpreted as two-sided when testing plain equality and one-sided when a margin frame is active, following the usual convention. - Target power (
power_target): a number, above 0 and below 1; default 0.8; typically 0.8 to 0.9 (0.80 is conventional; 0.90 for definitive trials); entered as proportion (0-1) or percent The chance of a significant result if the assumed effect is real. Used when solving for sample size or detectable effect; ignored when solving for power.
The method’s own
- Slope in group 1 (b₁) (
slope_1): a number, any finite number; default 0 The change in the outcome per unit of the predictor in the first group, whose size is the axis. - Slope in group 2 (b₂) (
slope_2): a number, any finite number; default 0.5 The slope in the second group. - Difference between the slopes (b₂ − b₁) (
slope_difference), advanced: a number, any finite number The canonical effect, which the detectable-effect target solves. - Predictor SD in group 1 (σ_x1) (
sd_x_1): a number, above 0; default 1 The spread of the predictor in group 1. - Predictor SD in group 2 (σ_x2) (
sd_x_2): a number, above 0; default 1 The spread of the predictor in group 2. - Common residual SD (σ) (
sd_residual): a number, above 0; default 1 The spread of the outcome about its line, pooled over the two groups: √((n₁σ²_r1 + n₂σ²_r2)/(n₁ + n₂)). - Sidedness of the equality test (
tails): a choice; defaulttwo_sidedTwo-sided unless the direction of the difference is known in advance; one-sided looks in the direction of b₂ − b₁.two_sidedTwo-sided: Either direction rejects.one_sidedOne-sided: Only the anticipated direction rejects; alpha is spent on that tail.
Sizes entered when another axis is solved for
- Observations in group 1 (group 2 is the allocation ratio times this) (
participants_per_group): a whole number, at least 1 Observations in group 1 (group 2 is the allocation ratio times this). Required when solving for power or detectable effect; produced by the solver when solving for sample size.
Ways to express an input
Effect size — Group 2’s slope, or its difference from group 1’s.
- Slope in group 2, the form’s default: The clinical quantity. (fields
slope_2) - Difference: b₂ − b₁, the canonical effect. (fields
slope_difference)
Modifiers admitted
allocation: Allocationdropout: Dropout
Published examples it reproduces (7)
Each is a worked example: the inputs as a user enters them, and the number the source prints, which the engine reproduces within the tolerance on every build (the Validation screen runs them on your machine).
| Source | Example | Solves for | Inputs | Published |
|---|---|---|---|---|
| G*Power 3.1 manual §17.3, after Dupont & Plummer 1998 p. 594 and Armitage et al. 2002 p. 325 | slopes −0.04653 and −0.03061 (a difference of 0.01592), σ_x 9.029 and 11.868, residual σ 0.5578, allocation 1.571428, two-sided 0.05, power 0.80 => 163 in group 1 (G*Power: 163 and 256; Dupont & Plummer’s shifted t: 166 and 261) | Sample size | allocation_ratio = 1.571428; alpha = 0.05; power_target = 0.8; sd_residual = 0.557841; sd_x_1 = 9.02914; sd_x_2 = 11.86779; slope_1 = -0.04653; slope_2 = -0.03061; effect expressed as slope_2 (with allocation) |
participants_per_group = 163 ± 0 |
| G*Power 3.1 manual §17.3 | the same design at 163 in group 1 => power 0.800980 (G*Power, with group 2 rounded to 256; the engine carries 256.14) | Power | allocation_ratio = 1.571428; alpha = 0.05; participants_per_group = 163; sd_residual = 0.557841; sd_x_1 = 9.02914; sd_x_2 = 11.86779; slope_1 = -0.04653; slope_2 = -0.03061; effect expressed as slope_2 (with allocation) |
power = 0.80098 ± 0.0003 |
| PASS chapter 854, Example 1 (printed p. 854-5) | equal groups, slope difference 1, σ_x 2 in both groups, residual σ 2, two-sided 0.05, power 0.90 => 23 a group | Sample size | alpha = 0.05; power_target = 0.9; sd_residual = 2; sd_x_1 = 2; sd_x_2 = 2; slope_1 = 0; slope_difference = 1; effect expressed as slope_difference |
participants_per_group = 23 ± 0 |
| PASS chapter 854, Example 1 (printed p. 854-5) | equal groups, slope difference 1, σ_x 2 in both groups, residual σ 3, two-sided 0.05, power 0.90 => 49 a group | Sample size | alpha = 0.05; power_target = 0.9; sd_residual = 3; sd_x_1 = 2; sd_x_2 = 2; slope_1 = 0; slope_difference = 1; effect expressed as slope_difference |
participants_per_group = 49 ± 0 |
| PASS chapter 854, Example 1 (printed p. 854-5) | equal groups, slope difference 1, σ_x 2 in both groups, residual σ 4, two-sided 0.05, power 0.90 => 86 a group | Sample size | alpha = 0.05; power_target = 0.9; sd_residual = 4; sd_x_1 = 2; sd_x_2 = 2; slope_1 = 0; slope_difference = 1; effect expressed as slope_difference |
participants_per_group = 86 ± 0 |
| PASS chapter 854, Example 2 (printed p. 854-8), after Dupont & Plummer 1998 pp. 594–595 | Dupont & Plummer’s printed inputs: σ_x 12.0 (unexposed, group 1) and 9.19 (exposed), residual σ 0.574, slope difference −0.0159, allocation 0.636, two-sided 0.05, power 0.80 => 263 unexposed (PASS: 263 and 167; the paper’s PS: 261 and 166) | Sample size | allocation_ratio = 0.636; alpha = 0.05; power_target = 0.8; sd_residual = 0.574; sd_x_1 = 12; sd_x_2 = 9.19; slope_1 = 0; slope_difference = -0.0159; effect expressed as slope_difference (with allocation) |
participants_per_group = 263 ± 0 |
| PASS chapter 854, Example 2 (printed p. 854-8), after Dupont & Plummer 1998 pp. 594–595 | the same with a target power of 0.797, PASS’s remark => 261 unexposed, the paper’s size | Sample size | allocation_ratio = 0.636; alpha = 0.05; power_target = 0.797; sd_residual = 0.574; sd_x_1 = 12; sd_x_2 = 9.19; slope_1 = 0; slope_difference = -0.0159; effect expressed as slope_difference (with allocation) |
participants_per_group = 261 ± 0 |
Sources
- Faul F, Erdfelder E, Buchner A, Lang A-G. G*Power 3.1 manual, §17: t test — Linear Regression (two groups).
- NCSS, LLC. PASS 2026 documentation, chapter 854: Tests for the Difference Between Two Linear Regression Slopes. Kaysville, UT: NCSS, LLC; 2026.
- Dupont WD, Plummer WD. Power and sample size calculations for studies involving linear regression. Control Clin Trials. 1998;19(6):589-601.
- Armitage P, Berry G, Matthews JNS. Statistical Methods in Medical Research. 4th ed. Oxford: Blackwell; 2002. Chapter 11.
This page was generated from TriaLab Power Studio 2.0.1's engine, as the method is built, and is published in English only. All methods →