ClawKit Logo
ClawKitReliability Toolkit
Back to Registry
Official Verified data analysis Safety 4/5

sample-size-power-calculator

Advanced sample size and power calculations for complex study designs including survival analysis, clustered designs, and multiple comparisons.

skill-install — Terminal

Install via CLI (Recommended)

clawhub install openclaw/skills/skills/aipoch-ai/sample-size-power-calculator
Or

What This Skill Does

The sample-size-power-calculator is a high-precision computational agent designed to support researchers, data scientists, and academics in conducting rigorous power analysis for complex study designs. Unlike basic calculators, this tool handles advanced statistical paradigms, including survival analysis (e.g., Cox proportional hazards models), clustered and hierarchical study designs (including intraclass correlation coefficients), and corrections for multiple hypothesis testing (such as Bonferroni or False Discovery Rate adjustments). It acts as a bridge between abstract research protocols and actionable, reproducible statistical requirements, ensuring that study parameters are robust before data collection begins.

Installation

To integrate this skill into your environment, use the OpenClaw command-line interface. Ensure your local environment is configured with Python 3.10 or higher. Execute the following in your terminal:

clawhub install openclaw/skills/skills/aipoch-ai/sample-size-power-calculator

Once installed, verify the installation by checking the parsing of the primary entry point: python -m py_compile scripts/main.py

Use Cases

  • Clinical Trial Planning: Determining the necessary patient cohort size for survival analysis to achieve 80% power at a 0.05 significance level, accounting for anticipated drop-out rates.
  • Clustered Research Designs: Estimating power for group-randomized trials where subjects are nested within schools or hospitals, requiring adjustments for clustering effects.
  • Multiple Comparison Correction: Calculating the required sample size for experiments involving large-scale genomic or multi-omic datasets where controlling the Family-Wise Error Rate is essential.
  • Grant Writing: Providing reproducible, audit-ready documentation for 'Power and Sample Size' sections in grant applications, detailing exact assumptions and statistical thresholds.

Example Prompts

  1. "Calculate the required sample size for a survival analysis study with a hazard ratio of 0.75, an alpha of 0.05, and 90% power, assuming a 24-month recruitment period and 12-month follow-up."
  2. "Perform a power analysis for a cluster-randomized trial with 10 clusters per arm and an intraclass correlation coefficient (ICC) of 0.05. We need to detect a standardized mean difference of 0.4."
  3. "Evaluate the impact on study power when applying a Benjamini-Hochberg correction for 50 simultaneous hypothesis tests in our current pilot study parameters."

Tips & Limitations

  • Documentation is Key: Always document the specific assumptions (e.g., effect size, variance) in your research notes. The script is deterministic, meaning it provides outputs based strictly on your inputs.
  • Scope Sensitivity: This tool is intended for complex designs; for simple t-tests, consider if this is the most efficient path.
  • Data Validation: Always cross-reference the output with the theoretical guidance found in the references/ directory. If the script returns an error, check that your input thresholds are mathematically valid for the chosen distribution model.

Metadata

Author@aipoch-ai
Stars4473
Views0
Updated2026-05-01
View Author Profile
AI Skill Finder

Not sure this is the right skill?

Describe what you want to build — we'll match you to the best skill from 16,000+ options.

Find the right skill
Add to Configuration

Paste this into your clawhub.json to enable this plugin.

{
  "plugins": {
    "official-aipoch-ai-sample-size-power-calculator": {
      "enabled": true,
      "auto_update": true
    }
  }
}

Tags(AI)

#statistics#research#data-analysis#clinical-trials
Safety Score: 4/5

Flags: file-read, file-write, code-execution