subgroup-analysis

Conduct subgroup analyses to examine effect moderation. Use when: (1) Testing pre-specified moderators, (2) Exploring heterogeneity, (3) Identifying differential effects, (4) Meta-analysis synthesis.

⭐5stars🔀1forks📁View on GitHub🕐Updated Jan 11, 2026⬇️1downloads

When & Why to Use This Skill

This Claude skill enables researchers and data analysts to perform rigorous subgroup analyses to identify effect moderation and explore data heterogeneity. It provides a structured framework for testing pre-specified moderators, identifying differential impacts across demographics, and synthesizing meta-analysis results to ensure statistically sound conclusions.

Use Cases

  • Clinical Trials: Determining if a specific medication shows varying levels of efficacy or safety across different age groups, genders, or pre-existing conditions.
  • A/B Testing & Product Development: Analyzing user behavior data to see if a new feature performs better for specific segments, such as premium subscribers versus free users.
  • Academic & Social Research: Investigating whether educational or social interventions have different outcomes based on socioeconomic status or geographic location.
  • Meta-Analysis Synthesis: Evaluating multiple studies to identify the sources of inconsistent findings and understanding the variables that moderate overall effect sizes.
namesubgroup-analysis
description"Conduct subgroup analyses to examine effect moderation. Use when: (1) Testing pre-specified moderators, (2) Exploring heterogeneity, (3) Identifying differential effects, (4) Meta-analysis synthesis."
allowed-toolsRead, Write, Bash
version1.0.0

Subgroup Analysis Skill

Purpose

Examine whether effects differ across subgroups of participants or studies.

Planning Subgroup Analyses

Pre-Specify:

  • Which subgroups (age, sex, severity)
  • Rationale for each
  • Statistical approach

Limit Number:

  • Too many = Type I error inflation
  • Focus on theoretically important
  • Correct for multiple comparisons

Subgroup Analysis Methods

1. Interaction Tests

  • Test group × subgroup interaction
  • More powerful than separate analyses

2. Stratified Analysis

  • Separate analysis per subgroup
  • Compare effect sizes

3. Meta-Regression

  • Continuous moderators
  • Multiple moderators simultaneously

Interpretation Cautions

Observational Nature:

  • Subgroups not randomized
  • Confounding possible
  • Generate hypotheses, don't confirm

Multiple Testing:

  • Adjust alpha (Bonferroni)
  • Or report as exploratory

Example: "Pre-specified subgroup analysis showed larger effects in younger participants (<50 years, d=0.68) versus older (≥50 years, d=0.34), interaction p=.02."


Version: 1.0.0