Bio Causal Genomics Mediation Analysis

Decompose genetic effects into direct and indirect paths through mediating variables using the mediation R package. Tests whether gene expression, methylation, or other molecular phenotypes mediate the effect of genetic variants on disease. Use when testing whether a molecular...

2,068 stars 206 forksResearch & Science

Install

skills CLI (Claude Code, Cursor, Codex and more)
npx skills add aipoch/medical-research-skills --skill bio-causal-genomics-mediation-analysis
Manual install
git clone --depth 1 https://github.com/aipoch/medical-research-skills.git /tmp/medical-research-skills
mkdir -p ~/.claude/skills
cp -r /tmp/medical-research-skills/scientific-skills/Data Analysis/bio-causal-genomics-mediation-analysis ~/.claude/skills/bio-causal-genomics-mediation-analysis

Personal skills live in ~/.claude/skills. Use .claude/skills in a project folder to share a skill with your team.

From the SKILL.md

> **Source**: [https://github.com/aipoch/medical-research-skills](https://github.com/aipoch/medical-research-skills)

## Version Compatibility

Reference examples tested with: R stats (base), ggplot2 3.5+

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.

# Mediation Analysis

**"Test whether gene expression mediates the effect of this variant on disease"** → Decompose the total genetic effect into direct and indirect (mediated) paths through a molecular phenotype, estimating ACME, ADE, and proportion mediated with bootstrap confidence intervals.
- R: `mediation::mediate()` for causal mediation analysis

## Framework

Causal mediation decomposes the total effect of a treatment (genotype) on an outcome
(phenotype) into:

- **ACME** (Average Causal Mediation Effect) - Indirect effect through the mediator
- **ADE** (Average Direct Effect) - Direct effect not through the mediator
- **Total effect** = ACME + ADE
- **Proportion mediated** = ACME / Total effect

Typical genomic applications:
- SNP -> gene expression (mediator) -> disease
- SNP -> DNA methylation (mediator) -> gene expression
- SNP -> protein levels (mediator) -> clinical outcome

## Basic Mediation with the mediation Package
Read the full skill on GitHub

Details

Skill name
bio-causal-genomics-mediation-analysis
Path
scientific-skills/Data Analysis/bio-causal-genomics-mediation-analysis/SKILL.md
License
MIT
Repo updated
17 September 2026

FAQ

What does the Bio Causal Genomics Mediation Analysis skill do?

Decompose genetic effects into direct and indirect paths through mediating variables using the mediation R package. Tests whether gene expression, methylation, or other molecular phenotypes mediate the effect of genetic variants on disease. Use when testing whether a molecular...

How do I install the Bio Causal Genomics Mediation Analysis skill?

skills CLI (Claude Code, Cursor, Codex and more): npx skills add aipoch/medical-research-skills --skill bio-causal-genomics-mediation-analysis. Skills go in ~/.claude/skills (personal) or .claude/skills (project), and Claude loads them automatically when a task matches the description.

Is Bio Causal Genomics Mediation Analysis popular?

It lives in aipoch/medical-research-skills, which has 2,068 GitHub stars and 206 forks.

Related skills

Clinicaltrials Database

2.1k

aipoch/medical-research-skills

Query ClinicalTrials.gov via API v2. Search trials by condition, drug, location, status, or phase. Retrieve trial details by NCT ID, export data, for clinical research and patient matching.

Research & Science206

Abstract Summarizer

2.1k

aipoch/medical-research-skills

Transform lengthy academic papers into concise, structured 250-word abstracts.

Research & Science206

Abstract Trimmer

2.1k

aipoch/medical-research-skills

Precision editing tool that reduces abstract word count through intelligent compression techniques, maintaining scientific rigor while meeting strict journal and conference requirements.

Research & Science206

Bio Causal Genomics Pleiotropy Detection

2.1k

aipoch/medical-research-skills

Detect and correct for horizontal pleiotropy in Mendelian randomization analyses using MR-PRESSO for outlier removal, MR-Egger regression for directional pleiotropy, and Steiger filtering for variant directionality. Use when validating MR results, detecting pleiotropic instrum...

Research & Science206

Bidirectional Multi Phenotype Mr Research Planner

2.1k

aipoch/medical-research-skills

Generates complete bidirectional multi-phenotype Mendelian randomization research designs from a user-provided exposure family and outcome family. Always use this skill whenever a user wants to design, plan, or build a genome-wide causal-inference study based on publicly available GWAS summary statistics, especially when the article logic includes multiple exposures, multiple outcomes or subtypes, bidirectional MR, IV filtering, IVW as the main estimator, weighted median / MR-Egger / MR-PRESSO sensitivity analyses, leave-one-out testing, heterogeneity / pleiotropy checks, and multiple-testing

Research & Science206

Bioinformatics Translational Opportunity Finder

2.1k

aipoch/medical-research-skills

Identifies translationally meaningful paths for bioinformatics findings by mapping omics or computational discoveries to diagnosis, stratification, prognosis, treatment-response, monitoring, or target-nomination use cases, while auditing bridge evidence, assayability, and validation burden. Use this skill when a user wants to know whether a bioinformatics finding can be framed as a stronger translational topic without overclaiming clinical relevance. Always separate statistical signal from translational value, and never imply clinical utility, targetability, or validation depth without explici

Research & Science206

Browse the most popular Claude skills, all research & science skills, or write your own with the skills generator.