deeptools

0
0
Source

NGS analysis toolkit. BAM to bigWig conversion, QC (correlation, PCA, fingerprints), heatmaps/profiles (TSS, peaks), for ChIP-seq, RNA-seq, ATAC-seq visualization.

Install

mkdir -p .claude/skills/deeptools && curl -L -o skill.zip "https://mcp.directory/api/skills/download/5168" && unzip -o skill.zip -d .claude/skills/deeptools && rm skill.zip

Installs to .claude/skills/deeptools

About this skill

deepTools: NGS Data Analysis Toolkit

Overview

deepTools is a comprehensive suite of Python command-line tools designed for processing and analyzing high-throughput sequencing data. Use deepTools to perform quality control, normalize data, compare samples, and generate publication-quality visualizations for ChIP-seq, RNA-seq, ATAC-seq, MNase-seq, and other NGS experiments.

Core capabilities:

  • Convert BAM alignments to normalized coverage tracks (bigWig/bedGraph)
  • Quality control assessment (fingerprint, correlation, coverage)
  • Sample comparison and correlation analysis
  • Heatmap and profile plot generation around genomic features
  • Enrichment analysis and peak region visualization

When to Use This Skill

This skill should be used when:

  • File conversion: "Convert BAM to bigWig", "generate coverage tracks", "normalize ChIP-seq data"
  • Quality control: "check ChIP quality", "compare replicates", "assess sequencing depth", "QC analysis"
  • Visualization: "create heatmap around TSS", "plot ChIP signal", "visualize enrichment", "generate profile plot"
  • Sample comparison: "compare treatment vs control", "correlate samples", "PCA analysis"
  • Analysis workflows: "analyze ChIP-seq data", "RNA-seq coverage", "ATAC-seq analysis", "complete workflow"
  • Working with specific file types: BAM files, bigWig files, BED region files in genomics context

Quick Start

For users new to deepTools, start with file validation and common workflows:

1. Validate Input Files

Before running any analysis, validate BAM, bigWig, and BED files using the validation script:

python scripts/validate_files.py --bam sample1.bam sample2.bam --bed regions.bed

This checks file existence, BAM indices, and format correctness.

2. Generate Workflow Template

For standard analyses, use the workflow generator to create customized scripts:

# List available workflows
python scripts/workflow_generator.py --list

# Generate ChIP-seq QC workflow
python scripts/workflow_generator.py chipseq_qc -o qc_workflow.sh \
    --input-bam Input.bam --chip-bams "ChIP1.bam ChIP2.bam" \
    --genome-size 2913022398

# Make executable and run
chmod +x qc_workflow.sh
./qc_workflow.sh

3. Most Common Operations

See assets/quick_reference.md for frequently used commands and parameters.

Installation

uv pip install deeptools

Core Workflows

deepTools workflows typically follow this pattern: QC → Normalization → Comparison/Visualization

ChIP-seq Quality Control Workflow

When users request ChIP-seq QC or quality assessment:

  1. Generate workflow script using scripts/workflow_generator.py chipseq_qc
  2. Key QC steps:
    • Sample correlation (multiBamSummary + plotCorrelation)
    • PCA analysis (plotPCA)
    • Coverage assessment (plotCoverage)
    • Fragment size validation (bamPEFragmentSize)
    • ChIP enrichment strength (plotFingerprint)

Interpreting results:

  • Correlation: Replicates should cluster together with high correlation (>0.9)
  • Fingerprint: Strong ChIP shows steep rise; flat diagonal indicates poor enrichment
  • Coverage: Assess if sequencing depth is adequate for analysis

Full workflow details in references/workflows.md → "ChIP-seq Quality Control Workflow"

ChIP-seq Complete Analysis Workflow

For full ChIP-seq analysis from BAM to visualizations:

  1. Generate coverage tracks with normalization (bamCoverage)
  2. Create comparison tracks (bamCompare for log2 ratio)
  3. Compute signal matrices around features (computeMatrix)
  4. Generate visualizations (plotHeatmap, plotProfile)
  5. Enrichment analysis at peaks (plotEnrichment)

Use scripts/workflow_generator.py chipseq_analysis to generate template.

Complete command sequences in references/workflows.md → "ChIP-seq Analysis Workflow"

RNA-seq Coverage Workflow

For strand-specific RNA-seq coverage tracks:

Use bamCoverage with --filterRNAstrand to separate forward and reverse strands.

Important: NEVER use --extendReads for RNA-seq (would extend over splice junctions).

Use normalization: CPM for fixed bins, RPKM for gene-level analysis.

Template available: scripts/workflow_generator.py rnaseq_coverage

Details in references/workflows.md → "RNA-seq Coverage Workflow"

ATAC-seq Analysis Workflow

ATAC-seq requires Tn5 offset correction:

  1. Shift reads using alignmentSieve with --ATACshift
  2. Generate coverage with bamCoverage
  3. Analyze fragment sizes (expect nucleosome ladder pattern)
  4. Visualize at peaks if available

Template: scripts/workflow_generator.py atacseq

Full workflow in references/workflows.md → "ATAC-seq Workflow"

Tool Categories and Common Tasks

BAM/bigWig Processing

Convert BAM to normalized coverage:

bamCoverage --bam input.bam --outFileName output.bw \
    --normalizeUsing RPGC --effectiveGenomeSize 2913022398 \
    --binSize 10 --numberOfProcessors 8

Compare two samples (log2 ratio):

bamCompare -b1 treatment.bam -b2 control.bam -o ratio.bw \
    --operation log2 --scaleFactorsMethod readCount

Key tools: bamCoverage, bamCompare, multiBamSummary, multiBigwigSummary, correctGCBias, alignmentSieve

Complete reference: references/tools_reference.md → "BAM and bigWig File Processing Tools"

Quality Control

Check ChIP enrichment:

plotFingerprint -b input.bam chip.bam -o fingerprint.png \
    --extendReads 200 --ignoreDuplicates

Sample correlation:

multiBamSummary bins --bamfiles *.bam -o counts.npz
plotCorrelation -in counts.npz --corMethod pearson \
    --whatToShow heatmap -o correlation.png

Key tools: plotFingerprint, plotCoverage, plotCorrelation, plotPCA, bamPEFragmentSize

Complete reference: references/tools_reference.md → "Quality Control Tools"

Visualization

Create heatmap around TSS:

# Compute matrix
computeMatrix reference-point -S signal.bw -R genes.bed \
    -b 3000 -a 3000 --referencePoint TSS -o matrix.gz

# Generate heatmap
plotHeatmap -m matrix.gz -o heatmap.png \
    --colorMap RdBu --kmeans 3

Create profile plot:

plotProfile -m matrix.gz -o profile.png \
    --plotType lines --colors blue red

Key tools: computeMatrix, plotHeatmap, plotProfile, plotEnrichment

Complete reference: references/tools_reference.md → "Visualization Tools"

Normalization Methods

Choosing the correct normalization is critical for valid comparisons. Consult references/normalization_methods.md for comprehensive guidance.

Quick selection guide:

  • ChIP-seq coverage: Use RPGC or CPM
  • ChIP-seq comparison: Use bamCompare with log2 and readCount
  • RNA-seq bins: Use CPM
  • RNA-seq genes: Use RPKM (accounts for gene length)
  • ATAC-seq: Use RPGC or CPM

Normalization methods:

  • RPGC: 1× genome coverage (requires --effectiveGenomeSize)
  • CPM: Counts per million mapped reads
  • RPKM: Reads per kb per million (accounts for region length)
  • BPM: Bins per million
  • None: Raw counts (not recommended for comparisons)

Full explanation: references/normalization_methods.md

Effective Genome Sizes

RPGC normalization requires effective genome size. Common values:

OrganismAssemblySizeUsage
HumanGRCh38/hg382,913,022,398--effectiveGenomeSize 2913022398
MouseGRCm38/mm102,652,783,500--effectiveGenomeSize 2652783500
ZebrafishGRCz111,368,780,147--effectiveGenomeSize 1368780147
Drosophiladm6142,573,017--effectiveGenomeSize 142573017
C. elegansce10/ce11100,286,401--effectiveGenomeSize 100286401

Complete table with read-length-specific values: references/effective_genome_sizes.md

Common Parameters Across Tools

Many deepTools commands share these options:

Performance:

  • --numberOfProcessors, -p: Enable parallel processing (always use available cores)
  • --region: Process specific regions for testing (e.g., chr1:1-1000000)

Read Filtering:

  • --ignoreDuplicates: Remove PCR duplicates (recommended for most analyses)
  • --minMappingQuality: Filter by alignment quality (e.g., --minMappingQuality 10)
  • --minFragmentLength / --maxFragmentLength: Fragment length bounds
  • --samFlagInclude / --samFlagExclude: SAM flag filtering

Read Processing:

  • --extendReads: Extend to fragment length (ChIP-seq: YES, RNA-seq: NO)
  • --centerReads: Center at fragment midpoint for sharper signals

Best Practices

File Validation

Always validate files first using scripts/validate_files.py to check:

  • File existence and readability
  • BAM indices present (.bai files)
  • BED format correctness
  • File sizes reasonable

Analysis Strategy

  1. Start with QC: Run correlation, coverage, and fingerprint analysis before proceeding
  2. Test on small regions: Use --region chr1:1-10000000 for parameter testing
  3. Document commands: Save full command lines for reproducibility
  4. Use consistent normalization: Apply same method across samples in comparisons
  5. Verify genome assembly: Ensure BAM and BED files use matching genome builds

ChIP-seq Specific

  • Always extend reads for ChIP-seq: --extendReads 200
  • Remove duplicates: Use --ignoreDuplicates in most cases
  • Check enrichment first: Run plotFingerprint before detailed analysis
  • GC correction: Only apply if significant bias detected; never use --ignoreDuplicates after GC correction

RNA-seq Specific

  • Never extend reads for RNA-seq (would span splice junctions)
  • Strand-specific: Use --filterRNAstrand forward/reverse for stranded libraries
  • Normalization: CPM for bins, RPKM for genes

ATAC-seq Specific

  • Apply Tn5 correction: Use alignmentSieve with --ATACshift
  • Fragment filtering: Set appropriate min/max fragment lengths
  • Check nucleosome pattern:

Content truncated.

scroll-experience

davila7

Expert in building immersive scroll-driven experiences - parallax storytelling, scroll animations, interactive narratives, and cinematic web experiences. Like NY Times interactives, Apple product pages, and award-winning web experiences. Makes websites feel like experiences, not just pages. Use when: scroll animation, parallax, scroll storytelling, interactive story, cinematic website.

6230

software-architecture

davila7

Guide for quality focused software architecture. This skill should be used when users want to write code, design architecture, analyze code, in any case that relates to software development.

8125

senior-fullstack

davila7

Comprehensive fullstack development skill for building complete web applications with React, Next.js, Node.js, GraphQL, and PostgreSQL. Includes project scaffolding, code quality analysis, architecture patterns, and complete tech stack guidance. Use when building new projects, analyzing code quality, implementing design patterns, or setting up development workflows.

8022

senior-security

davila7

Comprehensive security engineering skill for application security, penetration testing, security architecture, and compliance auditing. Includes security assessment tools, threat modeling, crypto implementation, and security automation. Use when designing security architecture, conducting penetration tests, implementing cryptography, or performing security audits.

6819

game-development

davila7

Game development orchestrator. Routes to platform-specific skills based on project needs.

5414

2d-games

davila7

2D game development principles. Sprites, tilemaps, physics, camera.

4812

You might also like

flutter-development

aj-geddes

Build beautiful cross-platform mobile apps with Flutter and Dart. Covers widgets, state management with Provider/BLoC, navigation, API integration, and material design.

641968

drawio-diagrams-enhanced

jgtolentino

Create professional draw.io (diagrams.net) diagrams in XML format (.drawio files) with integrated PMP/PMBOK methodologies, extensive visual asset libraries, and industry-standard professional templates. Use this skill when users ask to create flowcharts, swimlane diagrams, cross-functional flowcharts, org charts, network diagrams, UML diagrams, BPMN, project management diagrams (WBS, Gantt, PERT, RACI), risk matrices, stakeholder maps, or any other visual diagram in draw.io format. This skill includes access to custom shape libraries for icons, clipart, and professional symbols.

590705

godot

bfollington

This skill should be used when working on Godot Engine projects. It provides specialized knowledge of Godot's file formats (.gd, .tscn, .tres), architecture patterns (component-based, signal-driven, resource-based), common pitfalls, validation tools, code templates, and CLI workflows. The `godot` command is available for running the game, validating scripts, importing resources, and exporting builds. Use this skill for tasks involving Godot game development, debugging scene/resource files, implementing game systems, or creating new Godot components.

339397

ui-ux-pro-max

nextlevelbuilder

"UI/UX design intelligence. 50 styles, 21 palettes, 50 font pairings, 20 charts, 8 stacks (React, Next.js, Vue, Svelte, SwiftUI, React Native, Flutter, Tailwind). Actions: plan, build, create, design, implement, review, fix, improve, optimize, enhance, refactor, check UI/UX code. Projects: website, landing page, dashboard, admin panel, e-commerce, SaaS, portfolio, blog, mobile app, .html, .tsx, .vue, .svelte. Elements: button, modal, navbar, sidebar, card, table, form, chart. Styles: glassmorphism, claymorphism, minimalism, brutalism, neumorphism, bento grid, dark mode, responsive, skeuomorphism, flat design. Topics: color palette, accessibility, animation, layout, typography, font pairing, spacing, hover, shadow, gradient."

318395

nano-banana-pro

garg-aayush

Generate and edit images using Google's Nano Banana Pro (Gemini 3 Pro Image) API. Use when the user asks to generate, create, edit, modify, change, alter, or update images. Also use when user references an existing image file and asks to modify it in any way (e.g., "modify this image", "change the background", "replace X with Y"). Supports both text-to-image generation and image-to-image editing with configurable resolution (1K default, 2K, or 4K for high resolution). DO NOT read the image file first - use this skill directly with the --input-image parameter.

450339

fastapi-templates

wshobson

Create production-ready FastAPI projects with async patterns, dependency injection, and comprehensive error handling. Use when building new FastAPI applications or setting up backend API projects.

304231

Stay ahead of the MCP ecosystem

Get weekly updates on new skills and servers.