---
name: narrow-peak-coordinate-validation
description: Use when after running macs3 callpeak with the -f BEDPE flag on paired-end ChIP-Seq data (e.g., CTCF_PE_ChIP_chr22_50k.bedpe.
license: CC-BY-4.0
metadata:
  edam_operation: http://edamontology.org/operation_3222
  edam_topics:
  - http://edamontology.org/topic_3169
  - http://edamontology.org/topic_3173
  tools:
  - macs3 callpeak
  - macs3 predictd
  - MACS3
derived_from:
- doi: 10.1186/gb-2008-9-9-r137
  title: macs
evidence_spans: []
claims: []
provenance:
  collection: https://w3id.org/holobiomicslab/asb-skill/collection/epigenomics/v1
  assembled_by: scripts/collect_metabolomics_collection.py
  sources:
  - build: coll_macs
    doi: 10.1186/gb-2008-9-9-r137
    title: macs
  dedup_kept_from: coll_macs
schema_version: 0.2.0
---

# narrow-peak-coordinate-validation

## Summary

Verify that MACS3 callpeak correctly generates narrowPeak output files with valid peak coordinates and summit positions after processing paired-end ChIP-Seq data. This skill ensures the geometric correctness and completeness of peak call results before downstream analysis.

## When to use

After running macs3 callpeak with the -f BEDPE flag on paired-end ChIP-Seq data (e.g., CTCF_PE_ChIP_chr22_50k.bedpe.gz), use this skill to validate that the narrowPeak output file exists and contains properly formatted peak coordinates and summit positions that align with the input fragment length estimates.

## When NOT to use

- Input is already validated narrowPeak output from a trusted prior run; re-validation adds no new information.
- Single-end ChIP-Seq data where paired-end fragment length estimation is not applicable.
- Broad peak calling mode (bdgbroadcall) instead of narrow peak mode; validation logic for peak width assumptions differs.

## Inputs

- narrowPeak file generated by macs3 callpeak
- macs3 predictd fragment length estimate (e.g., ~253 bp)
- Original paired-end bedpe input file metadata

## Outputs

- Validated narrowPeak coordinate set
- Verification report of peak boundary correctness
- Summit position validity confirmation

## How to apply

Inspect the narrowPeak output file generated by macs3 callpeak to confirm three criteria: (1) the file is present and non-empty; (2) each peak record contains valid BED coordinates (chromosome, start, end) with start < end and within expected genomic ranges; (3) summit positions are recorded and fall within the peak interval boundaries. Cross-check that peak coordinates align with the fragment length estimate (e.g., ~253 bp for the CTCF tutorial) by verifying that peak widths and spacing are consistent with the estimated insertion length reported by macs3 predictd. This validation confirms that paired-end mode extension was correctly applied during pileup and peak calling without requiring manual --extsize specification.

## Related tools

- **macs3 callpeak** (Generates narrowPeak output file from paired-end ChIP and control bedpe input; outputs peak coordinates and summit positions to be validated) — https://github.com/macs3-project/MACS
- **macs3 predictd** (Estimates fragment length (d) from paired-end input; result (~253 bp) used as reference for validating peak coordinate consistency) — https://github.com/macs3-project/MACS
- **MACS3** (Parent tool suite providing the callpeak and predictd subcommands for ChIP-Seq analysis) — https://github.com/macs3-project/MACS

## Examples

```
macs3 callpeak -t CTCF_PE_ChIP_chr22_50k.bedpe.gz -c CTCF_Control_200K.bed.gz -f BEDPE -n ctcf_peaks && head -20 ctcf_peaks_peaks.narrowPeak
```

## Evaluation signals

- narrowPeak file exists and contains at least one peak record; file is not truncated or empty
- All peak coordinates satisfy: 0 ≤ start < end ≤ chromosome_length (for valid genomic ranges)
- Summit position field is present and falls within [start, end) for each peak
- Peak widths (end - start) correlate with the estimated fragment length (~253 bp); peaks should typically span 200–500 bp range for narrow ChIP-Seq marks
- No overlapping or malformed coordinates; BED format integrity (tab-delimited, proper column count)

## Limitations

- Validation assumes narrowPeak schema compliance; does not assess biological significance or p-value/q-value thresholds used during peak calling.
- Fragment length estimate (~253 bp) is specific to the CTCF dataset and paired-end ChIP protocol; different ChIP targets or sequencing depths may produce different fragment length distributions.
- Coordinate validation does not verify spatial concordance with input control data or signal-to-noise ratio; only geometric correctness is checked.
- Peak calling cutoff selection (default q-value 0.05) is not re-evaluated during coordinate validation; users must independently review callpeak parameters if peaks seem sparse or over-called.

## Evidence

- [methods] Verify the narrowPeak output file is generated with proper peak coordinates and summit positions: "Verify the narrowPeak output file is generated with proper peak coordinates and summit positions."
- [methods] Fragment length d is estimated by macs3 predictd for paired-end input: "This can also be accomplished using the `predictd` subcommand, which we need to apply only to ChIP data"
- [methods] Paired-end callpeak does not require manual --extsize specification: "Run macs3 callpeak with -f BEDPE flag on the paired-end ChIP sample without specifying --extsize (pileup automatically handles paired-end fragment extent)"
- [methods] Expected fragment length for CTCF paired-end ChIP-Seq is ~253 bp: "if you run this on the `CTCF_PE_ChIP_chr22_50k.bedpe.gz` file in the test directory"
- [methods] macs3 callpeak identifies regions by comparing ChIP and control signals using statistical scoring: "To identify enriched regions and predict peaks, the ChIP signals and local lambda stored in the BEDGRAPH file must be compared using a statistical model"
