agentsclimarketplace

Power analysis

Skill BioTender-max/awesome-bio-agent-skills/skills/bioskills/power-analysis

A curated collection of AI agent skills for biomedical research, covering genomics, proteomics, single-cell analysis, clinical AI, and protein design.

Install
npx -y skills add BioTender-max/awesome-bio-agent-skills --skill power-analysis

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

One thing to look at

  • no licenseNo license file was found in the repository. Code published without one is not open source by default, so using it at work is a question for whoever answers licensing questions where you are.

What its author says it does

Copied from the file, not written here

Calculates statistical power and minimum sample sizes for RNA-seq, ATAC-seq, and other sequencing experiments. Use when planning experiments, determining how many replicates are needed, or assessing whether a study is adequately powered to detect expected effect sizes.

SKILL.md

3.0 KB, 698 tokens by cl100k_base, as published. Nobody here has run it

Version Compatibility

Reference examples tested with: RNASeqPower 1.42+, pwr 1.3+

Before using code patterns, verify installed versions match. If versions differ:

  • R: packageVersion("<pkg>") then ?function_name to verify parameters

If code throws ImportError, AttributeError, or TypeError, introspect the installed package and adapt the example to match the actual API rather than retrying.

Power Analysis for Sequencing Experiments

"How many replicates do I need for RNA-seq?" → Calculate statistical power or minimum sample size given sequencing depth, biological variability, and expected effect size.

  • R: RNASeqPower::rnapower(), pwr::pwr.t.test()

Core Concept

Power = probability of detecting a true effect. Underpowered studies waste resources; overpowered studies are inefficient.

RNA-seq Power Analysis

Goal: Determine whether a planned RNA-seq experiment has sufficient statistical power to detect biologically meaningful fold changes, or calculate the minimum sample size needed for a target power.

Approach: Provide sequencing depth, biological coefficient of variation, expected fold change, and significance level to rnapower, which uses a negative binomial model to compute power or required sample size.

library(RNASeqPower)

# Typical parameters
# - depth: sequencing depth per sample (reads/gene)
# - cv: biological coefficient of variation (0.1-0.4 typical)
# - effect: fold change to detect (1.5 = 50% change)
# - alpha: significance level (0.05 standard)

# Calculate power for given sample size
rnapower(depth = 20, n = 3, cv = 0.4, effect = 2, alpha = 0.05)

# Calculate required samples for target power
rnapower(depth = 20, cv = 0.4, effect = 2, alpha = 0.05, power = 0.8)

CV Guidelines

Experiment TypeTypical CVNotes
Cell lines0.1-0.2Low variability
Inbred mice0.2-0.3Moderate
Human samples0.3-0.5High variability
Primary cells0.3-0.4Donor-dependent

ATAC-seq Power (ssizeRNA)

library(ssizeRNA)

# For differential accessibility
size.zhao(m = 10000, m1 = 500, fc = 2, fdr = 0.05, power = 0.8,
          mu = 10, disp = 0.1)

Quick Reference

Effect SizeRecommended n (CV=0.4)
4-fold3 per group
2-fold5-6 per group
1.5-fold10-12 per group
1.25-fold20+ per group

Related Skills

  • experimental-design/sample-size - Detailed sample size calculations
  • experimental-design/batch-design - Accounting for batch effects in design
  • differential-expression/deseq2-basics - Running the actual DE analysis

What ships with it: 2 files

5.3 KB alongside SKILL.md

examples/

Keep looking

Skills are one crate of 328,083. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.