[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M7EC4HEMP14MX1V10C3CFNSK":3,"skill-same:01M7EC4HEMP14MX1V10C3CFNSK":62},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":30,"commitSha":31,"skillDirectory":32,"forksCount":14,"repositoryHtmlUrl":33,"repositoryHomepageUrl":33,"ownerHtmlUrl":34,"ownerBlogUrl":6,"ownerDescription":6,"updatedAt":35,"install":36,"resources":49},"01M7EC4HEMP14MX1V10C3CFNSK","bio-clip-seq-clip-peak-calling",null,"Call protein-RNA binding sites from CLIP-seq BAM with CLIPper, PureCLIP, Skipper, Piranha, omniCLIP, CTK, CLAM, or Paraclu. Use when choosing between coverage-based, HMM-based, beta-binomial window-based, and crosslink-site-based peak callers; applying ENCODE eCLIP thresholds (log2 IP\u002FSMInput >= 3, -log10 p >= 3); deciding when SMInput is mandatory; or reconciling peak-set discordance between callers for the same RBP.","Mr-Nobody-Anonymous\u002FAll-skills","Mr-Nobody-Anonymous","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F184253119?v=4","01M7AEXFJHKTYQW5R0ZCQQTWFV","anonymous","01M7C00M3GQR4QKP9GZA42GFAK",0,"MIT","https:\u002F\u002Fgithub.com\u002FMr-Nobody-Anonymous\u002FAll-skills\u002Fblob\u002Fmain\u002Fawesome_skills\u002Fbiology\u002Fbio-clip-seq-clip-peak-calling\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: bio-clip-seq-clip-peak-calling\ndescription: Call protein-RNA binding sites from CLIP-seq BAM with CLIPper, PureCLIP, Skipper, Piranha, omniCLIP, CTK, CLAM, or Paraclu. Use when choosing between coverage-based, HMM-based, beta-binomial window-based, and crosslink-site-based peak callers; applying ENCODE eCLIP thresholds (log2 IP\u002FSMInput >= 3, -log10 p >= 3); deciding when SMInput is mandatory; or reconciling peak-set discordance between callers for the same RBP.\ntool_type: cli\nprimary_tool: CLIPper\nsource: \"https:\u002F\u002Fgithub.com\u002FGPTomics\u002FbioSkills\"\nsource_repository: \"GPTomics\u002FbioSkills\"\nsource_path: \"clip-seq\u002Fclip-peak-calling\u002FSKILL.md\"\nlicense: \"MIT\"\nimported_at: \"2026-09-20\"\n---\n\n## Version Compatibility\n\nReference examples tested with: CLIPper 2.0+, PureCLIP 1.3.1+, Piranha 1.2.1+, omniCLIP 0.2.0+, CTK 1.1.4+, CLAM 1.2+, Paraclu 9+, Skipper (commit 2023.05+), MACS3 3.0+, bedtools 2.31+, samtools 1.19+, idr 2.0.4+.\n\nBefore using code patterns, verify installed versions match. If versions differ:\n- Python: `pip show \u003Cpackage>` then `help(module.function)` to check signatures\n- CLI: `\u003Ctool> --version` then `\u003Ctool> --help` to confirm flags\n\nIf code throws unexpected errors, introspect the installed binary and adapt the example to match the actual CLI rather than retrying. PureCLIP 2.x changed several flag names; Skipper is distributed as a Snakemake workflow with frequently-evolving paths.\n\n# CLIP-seq Peak Calling\n\n**\"Call protein-RNA binding sites from my deduplicated CLIP BAM\"** -> Identify regions where read pile-up (and, for iCLIP\u002FeCLIP, single-nucleotide truncations) exceed background from a size-matched input (SMInput) control. The choice of peak caller depends on (a) the CLIP variant (HITS-CLIP, iCLIP, eCLIP, PAR-CLIP), (b) whether SMInput is available, (c) the RBP binding mode (narrow motif vs broad zones vs repeat-binding), and (d) the goal (publication-comparable ENCODE peaks vs single-nucleotide crosslink sites vs high-recall site lists).\n\n- CLI (ENCODE eCLIP canonical): `clipper -b dedup.bam -s hg38 -o peaks.bed --save-pickle --FDR-alpha 0.05 --superlocal` then `eclip-norm peaks.bed -i sminput.bam` for log2 fold-change against SMInput (`--FDR-alpha` is the CLIPper flag for the FDR cutoff; older docs sometimes shorten to `--FDR`)\n- CLI (single-nucleotide crosslink sites, iCLIP\u002FeCLIP): `pureclip -i dedup.bam -bai dedup.bam.bai -g genome.fa -ibam sminput.bam -ibai sminput.bam.bai -o sites.bed -or regions.bed -nt 8 -dm 8`\n- CLI (high-recall, beta-binomial windowed; needs SMInput): `Skipper` Snakemake workflow with config matching cell type and SMInput BAM\n- CLI (no SMInput, no truncation): `Piranha -b 50 -p 0.01 -d ZeroTruncatedNegativeBinomial -s -o peaks.bed dedup.bam` (Piranha takes the BAM as a positional argument, not via `-s`)\n- CLI (CIMS\u002FCITS single-nt from CTK): `tag2cluster.pl dedup.bed cluster.bed --multi-tag-method coverage`; then `bedExtractCIMS.pl cluster.bed cims.bed`\n- CLI (multi-mapper rescue for repeat-binding RBPs): `CLAM peakcaller -i unique.bam multimap.bam -o clam_out_dir\u002F --gtf gencode.gtf` (CLAM peakcaller writes peaks into an OUTPUT DIRECTORY, not a single file)\n\nThe ENCODE eCLIP gold standard for \"stringent\" peaks is: log2(IP \u002F SMInput) >= 3 AND -log10(p-value) >= 3. \"Lenient\" peaks use log2 >= 1 AND -log10 >= 2. Both filters operate on CLIPper peak output normalized against SMInput. Without SMInput, neither stringency level can be reproduced - the algorithm has no background term.\n\n## Algorithmic Taxonomy\n\n| Caller | Model | Resolution | SMInput required | Strength | Fails when |\n|--------|-------|------------|------------------|----------|------------|\n| CLIPper (Yeo) | Poisson with 500 bp local lambda, cubic-spline interpolation | Peak (10-500 nt) | Not for calling; required for ENCODE normalization | ENCODE eCLIP standard; reproducible against published ENCODE peak sets | Assumes most reads not from binding; fails when IP signal dominates a gene; sensitive to highly expressed transcripts |\n| PureCLIP (Krakau 2017) | Non-homogeneous HMM jointly modeling enrichment + truncation + sequence biases | Single-nucleotide CL + broad region | Optional via -ibam; recommended | Single-nt resolution; only caller that explicitly models the iCLIP truncation pattern | Misses broad binding zones; very focal (low recall on broad-binding RBPs in the Boyle 2023 benchmark) |\n| Skipper (Boyle 2023) | GC-stratified beta-binomial, 100 bp feature-respecting windows | Window (~100 nt) | Mandatory | 210-320% more sites than CLIPper; 8x faster; properly normalizes against input | Loses single-nt resolution; relatively new (2023); fewer published peak sets to compare |\n| Piranha (Smith lab) | Zero-truncated negative binomial regression with optional covariates | Bin (50-200 nt) | Optional; pass as covariate | Mature, widely cited, handles count overdispersion | Biased toward high-expression transcripts; convergence fails with large covariate values (use `-l` log-space) |\n| omniCLIP (Drewe-Boss 2018) | Non-homogeneous HMM with Dirichlet-multinomial of variants | Peak | Required | Models replicate variance; integrates background; can call peaks on any CLIP variant | Slow on deep libraries; blind to mitochondrial transcripts (misses chrM windows for FASTKD2) |\n| CTK CIMS\u002FCITS (Shah 2017) | Empirical FDR on crosslink-induced mutations or truncations | Single-nucleotide | No (uses background mutation rate from non-bound transcripts) | Single-nt resolution; works on HITS-CLIP deletions, PAR-CLIP T->C, iCLIP truncations | Empirical FDR less principled than HMM\u002Fbeta-binomial; perl-based pipeline harder to integrate |\n| CLAM peakcaller (Zhang & Xing 2017) | EM-assigned multi-mapper count + Piranha-like negative binomial | Peak | Optional | Only solution for repeat-binding RBPs; 10-30% additional sites in repeats | Inherits Piranha limitations on coverage-based stats; slower than Piranha |\n| Paraclu (Frith) | Parametric clustering with min-density and max-density thresholds | Variable | No | Simple, parameter-tunable, works on bedgraph | Heuristic; no statistical significance; cluster boundaries sensitive to thresholds |\n| PIPE-CLIP | Online CLIP pipeline with custom peak caller | Peak | Optional | Web interface; integrated end-to-end | Slow on cloud; less customizable; community has moved on |\n| CLIPick (Park 2018) | Expression-deconvolved peak caller | Peak | No (RNA-seq used instead) | Models RNA-seq abundance as background | RNA-seq cannot capture nonspecific binding; less popular post-Skipper |\n| Flipper (Flanagan 2026) | Negative-binomial differential test downstream of Skipper | Window | Yes | Companion differential tool to Skipper | Only meaningful in differential context; see clip-seq\u002Fdifferential-clip |\n| MACS3 callpeak | Local Poisson | Peak | Optional (treats SMInput as ChIP-seq input) | Familiar, fast | Not designed for CLIP; misses truncation signal; produces wider-than-typical peaks |\n\nMethodology evolves; verify the current ENCODE eCLIP standard operating procedure (encodeproject.org\u002Feclip) and the nf-core\u002Fclipseq pipeline configuration before locking on a single caller. The 2023 Skipper benchmark (Boyle Cell Genomics) is the most recent comprehensive comparison and is the rationale for many recent eCLIP reanalyses.\n\n## Critical Choice: Coverage-Based vs Crosslink-Site-Based vs Window-Based\n\nThree fundamentally different statistical frameworks:\n\n**Coverage-based (CLIPper, Piranha, MACS3, Paraclu):** Tally reads in a window; significance from local Poisson or negative binomial. Produces multi-nt peaks. Best when binding zones are broader than the read footprint (PUM2 3' UTR, HuR ARE elements).\n\n**Crosslink-site-based (PureCLIP, CTK CIMS\u002FCITS, PARalyzer):** Identify single nucleotides enriched in truncations (iCLIP\u002FeCLIP) or specific mutations (PAR-CLIP T->C, HITS-CLIP deletions). Produces single-nt sites that can be aggregated into footprints. Best when single-nt resolution is essential (motif registration with mCross; allele-specific binding).\n\n**Window-based (Skipper):** Tile transcriptome a priori into fixed-size feature-respecting windows; test each window's IP\u002FIN ratio with beta-binomial. Produces window-level calls. Best when SMInput is available and the goal is high-recall, comparable-across-RBPs site sets.\n\n| Goal | Recommended caller | Why |\n|------|-------------------|-----|\n| Reproduce ENCODE published peaks | CLIPper + IP\u002FSMInput normalization | The Yeo lab pipeline is the canonical reference |\n| Maximum sensitivity, modern statistics, SMInput available | Skipper | 210-320% more sites; explicit input normalization |\n| Single-nucleotide crosslink-site map (motif registration, ASB) | PureCLIP (HMM) or CTK CITS (empirical) | True single-nt resolution |\n| Repeat-binding RBP (Alu, LINE, LTR) | STAR multi-mapper + CLAM peakcaller | Only solution that uses multi-mappers |\n| No SMInput control | Piranha or PureCLIP with no -ibam | Both work without input but lose specificity |\n| PAR-CLIP T->C signature | PARalyzer or CTK CIMS (-substitution) | Designed for the T->C signal |\n| HITS-CLIP deletion signature | CTK CIMS (-deletion) | Designed for the deletion signal |\n| Custom statistical model needed | omniCLIP | Most flexible HMM among the options |\n| Online interactive analysis | Galaxy CLIP-Explorer or PIPE-CLIP | Web interface |\n\n## ENCODE eCLIP Stringency Thresholds\n\nThe Van Nostrand et al. ENCODE eCLIP standards define two stringency levels for CLIPper peaks normalized against SMInput:\n\n| Stringency | log2(IP \u002F SMInput) | -log10(p-value) | Use case |\n|------------|--------------------|-----------------|----------|\n| Stringent (publication) | >= 3 | >= 3 | High-confidence binding sites; differential analysis; motif discovery |\n| Lenient (discovery) | >= 1 | >= 2 | Catalogue of all enriched windows; sensitive analyses |\n\nBoth thresholds are applied to the IDR-passing reproducible peak set. ENCODE requires:\n- >= 2 biological replicates\n- >= 1M unique fragments per replicate (or saturated peak detection)\n- IDR rescue ratio and self-consistency ratio both \u003C 2\n- Narrow-binding RBPs: FRiP >= 0.005 (atypical-binding RBPs exempt)\n\n```bash\n# CLIPper -> SMInput normalization -> ENCODE thresholds\nclipper -b dedup.bam -s hg38 -o peaks.bed --save-pickle --FDR-alpha 0.05 --superlocal\n\n# Normalize against SMInput; eclip-norm is the Yeo lab tool\npython overlap_peakfi_with_bam_PE.py peaks.bed dedup.bam sminput.bam dedup.bam.readnum.txt sminput.bam.readnum.txt peaks.normed.bed\npython compress_l2foldenrpeakfi_for_replicate_overlapping_bedformat.py peaks.normed.bed peaks.compressed.bed\n\n# Stringent filter: log2 FC >= 3, -log10 p >= 3\nawk 'BEGIN{FS=OFS=\"\\t\"} $4 >= 3 && $5 >= 3' peaks.compressed.bed > peaks.stringent.bed\n\n# Lenient\nawk 'BEGIN{FS=OFS=\"\\t\"} $4 >= 1 && $5 >= 2' peaks.compressed.bed > peaks.lenient.bed\n```\n\nThe Yeo lab scripts (`overlap_peakfi_with_bam_PE.py`, `compress_l2foldenrpeakfi_for_replicate_overlapping_bedformat.py`) live in the eclip-pipeline repository; they implement the exact log2 fold-change computation used for ENCODE data downloads.\n\n## Per-Caller Failure Modes\n\n### CLIPper -- High-expression transcript bias\n\n**Trigger:** RBP that binds rare transcripts (snoRNAs, tRNAs, mitochondrial mRNAs) such as TROVE2 (Y RNA), NSUN2 (tRNA), or FASTKD2 (chrM).\n\n**Mechanism:** CLIPper's Poisson local-lambda model assumes only a minority of reads come from binding. For rare-transcript binders, the IP reads ARE the majority signal on that transcript; the model treats them as background.\n\n**Symptom:** Per-transcript peak count plummets compared to qualitatively-visible IP signal; chrM peaks called by Skipper but missed by CLIPper for FASTKD2.\n\n**Fix:** Use Skipper for rare-transcript binders (beta-binomial against SMInput respects the actual IP\u002FIN ratio independently of local lambda). Or pre-restrict CLIPper to the target transcript with `--gene custom.bed`.\n\n### CLIPper -- Requires SMInput downstream\n\n**Trigger:** Submitting CLIPper output as \"peaks\" without IP\u002FSMInput log2 normalization.\n\n**Mechanism:** CLIPper's own p-value is uncorrected for SMInput background. ENCODE peak BED files distributed on the portal are CLIPper + SMInput log2 normalization combined.\n\n**Symptom:** Peak count from the analysis is 5-10x higher than ENCODE values for the same RBP; the peak set includes obvious housekeeping-gene noise.\n\n**Fix:** Always normalize CLIPper output against SMInput. The Yeo lab scripts (`overlap_peakfi_with_bam_PE.py` + `compress_l2foldenrpeakfi_for_replicate_overlapping_bedformat.py`) produce the canonical ENCODE-style peak.\n\n### PureCLIP -- Too focal; misses broad binding zones\n\n**Trigger:** RBP with broad binding mode (PUM2 in 3' UTR clusters; SR proteins across exonic enhancer regions); using PureCLIP and disappointed.\n\n**Mechanism:** PureCLIP's HMM emits single-nt crosslink-site state at high stringency. In the Boyle 2023 Skipper benchmark, PureCLIP was highly focal with low recall on broad-binding RBPs (few true-positive windows).\n\n**Symptom:** Site count 100x lower than expected; sites cluster within known binding regions but vast majority of region is \"background\" in PureCLIP output.\n\n**Fix:** Use PureCLIP for single-nt CL maps (motif registration, ASB) but pair with CLIPper or Skipper for the broader binding-site list. PureCLIP's `-or` regions file gives broader output but is still focal compared to CLIPper.\n\n### Piranha -- Top-expression-decile bias\n\n**Trigger:** Highly expressed transcript (GAPDH, ACTB, rRNA-flanking) appears in most-significant Piranha peaks even when RBP biology is elsewhere.\n\n**Mechanism:** ZTNB regression weights peak significance by absolute count, not relative enrichment. Genes with 10x baseline expression dominate the top of the peak list.\n\n**Symptom:** Top-100 Piranha peaks include housekeeping genes; motif enrichment in top peaks is weak; functional GO term analysis of peak-bearing genes returns generic \"cellular metabolism.\"\n\n**Fix:** Use Piranha with SMInput as a covariate (`-c sminput_counts.bed -l`) so the regression accounts for input pile-up. Or switch to Skipper for principled input normalization.\n\n### Piranha -- Convergence failure with covariates\n\n**Trigger:** `-c rna_seq.bed` for expression normalization; large per-bin RNA-seq counts (> 10000).\n\n**Mechanism:** ZTNB optimization fails on extreme covariate values; the iterative algorithm diverges.\n\n**Symptom:** \"Maximum iterations reached\" or \"Singularity in regression\" error; or output BED file empty.\n\n**Fix:** Pass `-l` to convert covariates to log-space; or pre-filter covariate BED to remove top-1% outlier bins; or switch to Skipper which handles input normalization internally.\n\n### omniCLIP -- Mitochondrial transcript blind spot\n\n**Trigger:** Mitochondrial RBP (FASTKD2, LRPPRC) submitted to omniCLIP.\n\n**Mechanism:** omniCLIP's HMM is trained on autosomal\u002FX transcripts; chrM has different background statistics that the model treats as outlier (or excludes if blacklisted).\n\n**Symptom:** chrM peaks return 0; FASTKD2 peak file has no peaks at all.\n\n**Fix:** Use Skipper for chrM-binding RBPs (GC-stratified beta-binomial is per-bin and indifferent to chromosome). Or call peaks on chrM separately with PureCLIP.\n\n### CTK CIMS -- HITS-CLIP only; iCLIP\u002FeCLIP misuse\n\n**Trigger:** CTK CIMS (`-mutation` flag) applied to iCLIP\u002FeCLIP data.\n\n**Mechanism:** iCLIP\u002FeCLIP use truncation (RT stops at adduct), not mutations. CIMS expects deletions\u002Fsubstitutions inside the read; CITS is the truncation-based companion.\n\n**Symptom:** CIMS returns very few sites (mutation rate of CL is ~3-7% for HITS-CLIP, but only ~1-2% for iCLIP since most reads truncate before reaching the adduct).\n\n**Fix:** For iCLIP\u002FeCLIP, use CTK CITS (`tag2cluster.pl ... -cs5 5` truncation-mode). For HITS-CLIP and PAR-CLIP, CIMS is correct (HITS deletions, PAR T->C).\n\n### CLAM peakcaller -- Multi-mapper BAM absent\n\n**Trigger:** Ran STAR with `--outFilterMultimapNmax 1` then tried CLAM; CLAM fails or returns identical output to Piranha.\n\n**Mechanism:** CLAM's EM rescue requires the multi-mapper BAM from STAR (`--outFilterMultimapNmax 100 --outSAMmultNmax -1`). Without it, CLAM falls back to unique-only Piranha-style peak calling.\n\n**Symptom:** CLAM output looks identical to Piranha; repeat peaks not rescued.\n\n**Fix:** Re-align with multi-mapper-aware STAR parameters (see clip-seq\u002Fclip-alignment). Verify the multi-mapper BAM has alignments at non-unique positions before running CLAM.\n\n### MACS3 callpeak -- Wide peaks miss footprint\n\n**Trigger:** MACS3 used because the user is familiar from ATAC\u002FChIP work.\n\n**Mechanism:** MACS3 model is for DNA-protein binding at ~100-500 nt scale; CLIP-seq RBP footprints are 8-30 nt. MACS3 wide peaks (300+ nt) merge multiple distinct binding sites.\n\n**Symptom:** MACS3 peak count is much lower than CLIPper\u002FSkipper; mean peak width >> 100 nt; multiple known motif instances inside one MACS peak.\n\n**Fix:** Use CLIP-specific callers. If MACS3 is forced (institutional pipeline), pass `--nomodel --shift -1 --extsize 50` for narrower peaks and accept the limitation.\n\n## IDR for CLIP-seq\n\nIDR (Li 2011) measures reproducibility of peak rankings across biological replicates. ENCODE eCLIP convention is per-rep + pooled + pseudoreplicates, identical to the ChIP-seq IDR pattern. The CLIP-specific consideration: rank by `signalValue` (column 7) NOT by `score` (column 5), because CLIPper's score is sparse and tied across many peaks.\n\n```bash\n# Per-replicate CLIPper + SMInput normalization yields .compressed.bed files\nsort -k7,7nr rep1_peaks.compressed.bed > rep1.sorted\nsort -k7,7nr rep2_peaks.compressed.bed > rep2.sorted\n\nidr --samples rep1.sorted rep2.sorted \\\n    --input-file-type bed --rank 7 \\\n    --output-file idr.out --idr-threshold 0.05 \\\n    --plot --log-output-file idr.log\n```\n\nENCODE IDR rules for eCLIP:\n- Nt (true replicates) and Nself (pseudoreplicates): max(Nt, Nself) \u002F min(Nt, Nself) \u003C= 2 -> pass\n- Both ratios > 2 -> library rejected\n- IDR threshold 0.05 for true reps; 0.10 for pseudoreplicates\n\n## Decision Tree by Scenario\n\n| Scenario | Caller + parameters | Why |\n|----------|---------------------|-----|\n| Standard eCLIP with SMInput, ENCODE-comparable | CLIPper + SMInput log2 norm + IDR | Reproducible against ENCODE peak files |\n| Standard eCLIP with SMInput, maximum sensitivity | Skipper Snakemake workflow | 210-320% more sites, beta-binomial input-norm |\n| iCLIP\u002FiCLIP2, want single-nt CL map | PureCLIP + SMInput (or empty bam if no SMI) | HMM jointly models enrichment + truncation |\n| HITS-CLIP, want CIMS deletions | CTK `parseAlignment.pl` + `tag2cluster.pl` + `bedExtractCIMS.pl` | Empirical FDR on deletion-induced mutations |\n| PAR-CLIP, T->C signal | PARalyzer or CTK CIMS `-substitution T C` | Designed for the T->C signature |\n| Repeat-binding RBP (MATR3, LINE-1) | CLAM peakcaller on multi-mapper BAM | Only solution that recovers repeat peaks |\n| No SMInput, mostly hopeless | Piranha `-d ZeroTruncatedNegativeBinomial` or PureCLIP w\u002Fo -ibam | Lose ENCODE comparability but get a peak set |\n| Mitochondrial RBP (FASTKD2) | Skipper (window-based, chrM-friendly) | omniCLIP\u002FCLIPper miss chrM |\n| Highly multiplexed (SPIDR) | Custom Snakemake; no single-tool solution | Each barcode's reads are deep enough for CLIPper |\n| Long-read CLIP (dirCLIP) | Custom analysis from BAM; long-read tools not yet mature | Isoform-resolved binding-site calls |\n| Need maximum precision for motif analysis | PureCLIP (single-nt) + mCross downstream | mCross requires registered CL positions |\n| Replicates with unequal library complexity (>2x diff in unique fragments) | Skipper (more robust to depth imbalance) OR `samtools view -s` down-sample to common depth then CLIPper + IDR | Skipper's GC-stratified beta-binomial handles per-sample depth; CLIPper without down-sampling lets the deeper replicate dominate joint analysis |\n\n## Reconciliation: When Callers Disagree\n\n| Pattern | Likely cause | Action |\n|---------|--------------|--------|\n| Skipper >> CLIPper site count | Skipper better recovers low-abundance and rare-transcript binders | Trust Skipper for rare transcripts; trust CLIPper for ENCODE-comparable counts |\n| PureCLIP \u003C\u003C CLIPper | PureCLIP is single-nt focal; CLIPper is broad peak | Both correct; report at the resolution the downstream analysis needs |\n| Piranha top peaks dominated by housekeeping | No input normalization | Add SMInput as `-c` covariate or switch to Skipper |\n| CLAM > Piranha by 10-30% | CLAM rescued multi-mappers in repeats | Trust CLAM if RBP biologically binds repeats |\n| omniCLIP wider peaks than CLIPper | HMM smoothes binding state across nearby positions | Both correct; choose by downstream analysis needs |\n| Per-rep CLIPper calls peak; pooled does not | Replicates inconsistent; one rep dominates | Inspect with IGV; trust IDR-passing peaks only |\n| MACS3 \u003C CLIPper peak count | MACS3 wide peaks merge multiple CLIP sites | Use CLIP-specific caller |\n| FASTKD2 chrM peaks: Skipper finds; CLIPper \u002F omniCLIP find none | Coverage-based callers blind to chrM lambda | Trust Skipper for organelle-binding RBPs |\n| chimeric eCLIP peaks for snoRNA: standard tools find few | snoRNA-targeting eCLIP needs custom processing | Use VanNostrandLab\u002FsnoRNA-chimeric pipeline |\n\n**Operational rule for high-confidence reporting:** Require a peak to pass (a) IDR \u003C= 0.05 on true replicates, (b) log2(IP\u002FSMInput) >= 3 AND -log10 p >= 3 (ENCODE stringent), (c) overlap with at least one independent caller within 100 nt. For motif analysis, additionally require PureCLIP single-nt sites within the peak. For ASB, require WASP-filtered alignment + PureCLIP CL sites overlapping heterozygous SNPs.\n\n## Strand-Specific Peak Calling\n\nCLIP libraries are strand-specific by design. Most callers handle strands correctly when the BAM is stranded (read flags 99\u002F147\u002F83\u002F163 for paired). If a caller bug or unstranded library forces manual split:\n\n```bash\n# Plus strand reads (F flag NOT 0x10)\nsamtools view -h -b -F 16 dedup.bam > plus.bam\nsamtools index plus.bam\n# Minus strand reads (F flag 0x10)\nsamtools view -h -b -f 16 dedup.bam > minus.bam\nsamtools index minus.bam\n\n# Call peaks on each strand independently, then merge\nclipper -b plus.bam -s hg38 -o peaks_plus.bed\nclipper -b minus.bam -s hg38 -o peaks_minus.bed\ncat peaks_plus.bed peaks_minus.bed | sort -k1,1 -k2,2n > peaks_stranded.bed\n```\n\nFor paired-end CLIP, mate orientation determines strand: RF (R1 reverse) means R2 5' is the truncation = CL site -1 on plus-strand transcripts. ENCODE eCLIP convention: read 2 of pair is the truncation-bearing read.\n\n## Multi-Mapper Rescue with CLAM (Repeat Binders)\n\n```bash\n# Assume STAR was run with --outFilterMultimapNmax 100 --outSAMmultNmax -1\nsamtools sort -o multimap.bam aligned_multimap.bam\nsamtools index multimap.bam\n\n# Split unique vs multi\nCLAM preprocessor -i multimap.bam -o clam_out\u002F --read-tagger-method median\n\n# EM-based reassignment\nCLAM realigner -i clam_out\u002Funique.sorted.bam -o clam_out\u002F --winsize 50 --max-tags 0\n\n# Peak calling with reassigned multi-mappers\nCLAM peakcaller -i clam_out\u002Funique.sorted.bam clam_out\u002Frealigned.sorted.bam \\\n    -o clam_peaks.bed -p 8 --gtf gencode.v38.annotation.gtf\n```\n\nCLAM rescues 10-30% additional peaks in repeat-rich regions. The trade-off: peak coordinates in repeat instances are probabilistic (single best from EM), so motif analysis on CLAM repeat peaks requires careful interpretation.\n\n## Quality Metrics for Peak Sets\n\n```python\nimport pandas as pd\n\ndef peak_qc(peaks_bed):\n    peaks = pd.read_csv(peaks_bed, sep='\\t', header=None,\n                        names=['chrom','start','end','name','score','strand'])\n    peaks['width'] = peaks['end'] - peaks['start']\n    return {\n        'n_peaks': len(peaks),\n        'mean_width': peaks['width'].mean(),\n        'median_width': peaks['width'].median(),\n        'width_5p_95p': (peaks['width'].quantile(0.05), peaks['width'].quantile(0.95)),\n        'chroms_with_peaks': peaks['chrom'].nunique(),\n        'peaks_chrM': (peaks['chrom'] == 'chrM').sum()\n    }\n```\n\n| Metric | Expected | Interpretation |\n|--------|----------|----------------|\n| n_peaks (CLIPper stringent) | 5k - 100k | \u003C5k = under-IP or stringency too high; >>100k = noisy library |\n| Mean peak width (CLIPper) | 40-200 nt | Wider = caller over-merging; narrower = under-coverage |\n| Peak width 5-95% range | 20-500 nt | Tight range = consistent peaks; wide = mixed sharp + broad |\n| FRiP (fraction reads in peaks) | >= 0.005 | ENCODE narrow-binding RBP minimum; many RBPs higher |\n| chrM peaks | 0 unless mt-RBP | FASTKD2, LRPPRC expected to have chrM enrichment |\n| TPM-rank distribution | Spread across deciles | Concentrated in top decile = caller has expression bias (Piranha symptom) |\n\n## Common Errors\n\n| Error \u002F symptom | Cause | Solution |\n|-----------------|-------|----------|\n| CLIPper \"no peaks found\" | BAM not sorted\u002Findexed; gene annotation missing | `samtools sort && index`; verify `-s hg38` (or `--gene custom.bed`) |\n| CLIPper out-of-memory on 50M BAM | `--save-pickle` keeps intermediates in RAM | Remove `--save-pickle`; or use machine with > 64 GB |\n| PureCLIP slow (>24h) | `-iv` interval file missing | Restrict to one chromosome with `-iv chr1` for testing; provide GTF |\n| Piranha returns no peaks | ZTNB convergence failed silently | Add `-l`; or reduce `-b` bin size; or switch to Skipper |\n| omniCLIP segmentation fault | Replicate BAMs differ in chromosome order | Re-sort all BAMs with identical reference dictionary |\n| CTK CITS finds nothing on PAR-CLIP | Used CITS (truncation) for substitution data | Use CIMS `-substitution T C` for PAR-CLIP |\n| Multi-mapper rescue returns 0 extra peaks | STAR was run unique-only; no multi-mapper BAM | Re-align with `--outFilterMultimapNmax 100 --outSAMmultNmax -1` |\n| ENCODE stringent peak count = 0 | Forgot SMInput normalization step | Run Yeo lab `overlap_peakfi_with_bam_PE.py` first; thresholds apply to normalized peaks |\n| Strand information lost | `samtools view -F 16` filter applied to merged BAM | Strand is encoded in BAM flags; do not pre-split |\n| IDR returns no reproducible peaks | Wrong ranking column | Sort by signalValue \u002F log2FC, not score; for narrowPeak format use `--rank p.value` |\n\n## References\n\n- Van Nostrand EL et al 2016 Nat Methods 13:508 (eCLIP, SMInput, ENCODE pipeline)\n- Lovci MT et al 2013 Nat Struct Mol Biol 20:1434 (CLIPper algorithm)\n- Krakau S et al 2017 Genome Biol 18:240 (PureCLIP HMM)\n- Boyle EA et al 2023 Cell Genomics 3:100317 (Skipper, GC-stratified beta-binomial)\n- Uren PJ et al 2012 Bioinformatics 28:3013 (Piranha, ZTNB)\n- Drewe-Boss P et al 2018 Genome Biol 19:183 (omniCLIP)\n- Shah A et al 2017 Bioinformatics 33:566 (CTK \u002F CIMS \u002F CITS)\n- Zhang Z & Xing Y 2017 Nucleic Acids Res 45:9260 (CLAM multi-mapper)\n- Frith MC et al 2008 Genome Res 18:1-12 (paraclu)\n- Li Q et al 2011 Ann Appl Stat 5:1752 (IDR framework)\n- Van Nostrand EL et al 2020 Nature 583:711 (A large-scale binding and functional map of human RNA-binding proteins)\n- ENCODE eCLIP Standards (encodeproject.org\u002Feclip) - canonical thresholds\n\n## Related Skills\n\n- clip-seq\u002Fclip-preprocessing - Upstream preprocessing producing dedup BAM\n- clip-seq\u002Fclip-alignment - Upstream alignment with crosslink-preserving parameters\n- clip-seq\u002Fclip-qc - FRiP, library complexity, IDR before\u002Fafter peak calling\n- clip-seq\u002Fcrosslink-site-detection - PureCLIP \u002F CTK CITS \u002F PARalyzer for single-nt CL sites\n- clip-seq\u002Fdifferential-clip - DEWSeq \u002F Flipper for cross-condition differential binding\n- clip-seq\u002Fbinding-site-annotation - Annotate called peaks to 5' UTR \u002F CDS \u002F 3' UTR \u002F intron\n- clip-seq\u002Fclip-motif-analysis - Motif discovery on called peaks\n- clip-seq\u002Fago-clip-mirna-targets - Chimeric eCLIP peak calling\n- clip-seq\u002Fm6a-clip - miCLIP2-specific peak calling\n- chip-seq\u002Fpeak-calling - DNA-protein peak calling for comparison\n","## Version Compatibility\n\nReference examples tested with: CLIPper 2.0+, PureCLIP 1.3.1+, Piranha 1.2.1+, omniCLIP 0.2.0+, CTK 1.1.4+, CLAM 1.2+, Paraclu 9+, Skipper (commit 2023.05+), MACS3 3.0+, bedtools 2.31+, samtools 1.19+, idr 2.0.4+.\n\nBefore using code patterns, verify installed versions match. If versions differ:\n- Python: `pip show \u003Cpackage>` then `help(module.function)` to check signatures\n- CLI: `\u003Ctool> --version` then `\u003Ctool> --help` to confirm flags\n\nIf code throws unexpected errors, introspect the installed binary and adapt the example to match the actual CLI rather than retrying. PureCLIP 2.x changed several flag names; Skipper is distributed as a Snakemake workflow with frequently-evolving paths.\n\n# CLIP-seq Peak Calling\n\n**\"Call protein-RNA binding sites from my deduplicated CLIP BAM\"** -> Identify regions where read pile-up (and, for iCLIP\u002FeCLIP, single-nucleotide truncations) exceed background from a size-matched input (SMInput) control. The choice of peak caller depends on (a) the CLIP variant (HITS-CLIP, iCLIP, eCLIP, PAR-CLIP), (b) whether SMInput is available, (c) the RBP binding mode (narrow motif vs broad zones vs repeat-binding), and (d) the goal (publication-comparable ENCODE peaks vs single-nucleotide crosslink sites vs high-recall site lists).\n\n- CLI (ENCODE eCLIP canonical): `clipper -b dedup.bam -s hg38 -o peaks.bed --save-pickle --FDR-alpha 0.05 --superlocal` then `eclip-norm peaks.bed -i sminput.bam` for log2 fold-change against SMInput (`--FDR-alpha` is the CLIPper flag for the FDR cutoff; older docs sometimes shorten to `--FDR`)\n- CLI (single-nucleotide crosslink sites, iCLIP\u002FeCLIP): `pureclip -i dedup.bam -bai dedup.bam.bai -g genome.fa -ibam sminput.bam -ibai sminput.bam.bai -o sites.bed -or regions.bed -nt 8 -dm 8`\n- CLI (high-recall, beta-binomial windowed; needs SMInput): `Skipper` Snakemake workflow with config matching cell type and SMInput BAM\n- CLI (no SMInput, no truncation): `Piranha -b 50 -p 0.01 -d ZeroTruncatedNegativeBinomial -s -o peaks.bed dedup.bam` (Piranha takes the BAM as a positional argument, not via `-s`)\n- CLI (CIMS\u002FCITS single-nt from CTK): `tag2cluster.pl dedup.bed cluster.bed --multi-tag-method coverage`; then `bedExtractCIMS.pl cluster.bed cims.bed`\n- CLI (multi-mapper rescue for repeat-binding RBPs): `CLAM peakcaller -i unique.bam multimap.bam -o clam_out_dir\u002F --gtf gencode.gtf` (CLAM peakcaller writes peaks into an OUTPUT DIRECTORY, not a single file)\n\nThe ENCODE eCLIP gold standard for \"stringent\" peaks is: log2(IP \u002F SMInput) >= 3 AND -log10(p-value) >= 3. \"Lenient\" peaks use log2 >= 1 AND -log10 >= 2. Both filters operate on CLIPper peak output normalized against SMInput. Without SMInput, neither stringency level can be reproduced - the algorithm has no background term.\n\n## Algorithmic Taxonomy\n\n| Caller | Model | Resolution | SMInput required | Strength | Fails when |\n|--------|-------|------------|------------------|----------|------------|\n| CLIPper (Yeo) | Poisson with 500 bp local lambda, cubic-spline interpolation | Peak (10-500 nt) | Not for calling; required for ENCODE normalization | ENCODE eCLIP standard; reproducible against published ENCODE peak sets | Assumes most reads not from binding; fails when IP signal dominates a gene; sensitive to highly expressed transcripts |\n| PureCLIP (Krakau 2017) | Non-homogeneous HMM jointly modeling enrichment + truncation + sequence biases | Single-nucleotide CL + broad region | Optional via -ibam; recommended | Single-nt resolution; only caller that explicitly models the iCLIP truncation pattern | Misses broad binding zones; very focal (low recall on broad-binding RBPs in the Boyle 2023 benchmark) |\n| Skipper (Boyle 2023) | GC-stratified beta-binomial, 100 bp feature-respecting windows | Window (~100 nt) | Mandatory | 210-320% more sites than CLIPper; 8x faster; properly normalizes against input | Loses single-nt resolution; relatively new (2023); fewer published peak sets to compare |\n| Piranha (Smith lab) | Zero-truncated negative binomial regression with optional covariates | Bin (50-200 nt) | Optional; pass as covariate | Mature, widely cited, handles count overdispersion | Biased toward high-expression transcripts; convergence fails with large covariate values (use `-l` log-space) |\n| omniCLIP (Drewe-Boss 2018) | Non-homogeneous HMM with Dirichlet-multinomial of variants | Peak | Required | Models replicate variance; integrates background; can call peaks on any CLIP variant | Slow on deep libraries; blind to mitochondrial transcripts (misses chrM windows for FASTKD2) |\n| CTK CIMS\u002FCITS (Shah 2017) | Empirical FDR on crosslink-induced mutations or truncations | Single-nucleotide | No (uses background mutation rate from non-bound transcripts) | Single-nt resolution; works on HITS-CLIP deletions, PAR-CLIP T->C, iCLIP truncations | Empirical FDR less principled than HMM\u002Fbeta-binomial; perl-based pipeline harder to integrate |\n| CLAM peakcaller (Zhang & Xing 2017) | EM-assigned multi-mapper count + Piranha-like negative binomial | Peak | Optional | Only solution for repeat-binding RBPs; 10-30% additional sites in repeats | Inherits Piranha limitations on coverage-based stats; slower than Piranha |\n| Paraclu (Frith) | Parametric clustering with min-density and max-density thresholds | Variable | No | Simple, parameter-tunable, works on bedgraph | Heuristic; no statistical significance; cluster boundaries sensitive to thresholds |\n| PIPE-CLIP | Online CLIP pipeline with custom peak caller | Peak | Optional | Web interface; integrated end-to-end | Slow on cloud; less customizable; community has moved on |\n| CLIPick (Park 2018) | Expression-deconvolved peak caller | Peak | No (RNA-seq used instead) | Models RNA-seq abundance as background | RNA-seq cannot capture nonspecific binding; less popular post-Skipper |\n| Flipper (Flanagan 2026) | Negative-binomial differential test downstream of Skipper | Window | Yes | Companion differential tool to Skipper | Only meaningful in differential context; see clip-seq\u002Fdifferential-clip |\n| MACS3 callpeak | Local Poisson | Peak | Optional (treats SMInput as ChIP-seq input) | Familiar, fast | Not designed for CLIP; misses truncation signal; produces wider-than-typical peaks |\n\nMethodology evolves; verify the current ENCODE eCLIP standard operating procedure (encodeproject.org\u002Feclip) and the nf-core\u002Fclipseq pipeline configuration before locking on a single caller. The 2023 Skipper benchmark (Boyle Cell Genomics) is the most recent comprehensive comparison and is the rationale for many recent eCLIP reanalyses.\n\n## Critical Choice: Coverage-Based vs Crosslink-Site-Based vs Window-Based\n\nThree fundamentally different statistical frameworks:\n\n**Coverage-based (CLIPper, Piranha, MACS3, Paraclu):** Tally reads in a window; significance from local Poisson or negative binomial. Produces multi-nt peaks. Best when binding zones are broader than the read footprint (PUM2 3' UTR, HuR ARE elements).\n\n**Crosslink-site-based (PureCLIP, CTK CIMS\u002FCITS, PARalyzer):** Identify single nucleotides enriched in truncations (iCLIP\u002FeCLIP) or specific mutations (PAR-CLIP T->C, HITS-CLIP deletions). Produces single-nt sites that can be aggregated into footprints. Best when single-nt resolution is essential (motif registration with mCross; allele-specific binding).\n\n**Window-based (Skipper):** Tile transcriptome a priori into fixed-size feature-respecting windows; test each window's IP\u002FIN ratio with beta-binomial. Produces window-level calls. Best when SMInput is available and the goal is high-recall, comparable-across-RBPs site sets.\n\n| Goal | Recommended caller | Why |\n|------|-------------------|-----|\n| Reproduce ENCODE published peaks | CLIPper + IP\u002FSMInput normalization | The Yeo lab pipeline is the canonical reference |\n| Maximum sensitivity, modern statistics, SMInput available | Skipper | 210-320% more sites; explicit input normalization |\n| Single-nucleotide crosslink-site map (motif registration, ASB) | PureCLIP (HMM) or CTK CITS (empirical) | True single-nt resolution |\n| Repeat-binding RBP (Alu, LINE, LTR) | STAR multi-mapper + CLAM peakcaller | Only solution that uses multi-mappers |\n| No SMInput control | Piranha or PureCLIP with no -ibam | Both work without input but lose specificity |\n| PAR-CLIP T->C signature | PARalyzer or CTK CIMS (-substitution) | Designed for the T->C signal |\n| HITS-CLIP deletion signature | CTK CIMS (-deletion) | Designed for the deletion signal |\n| Custom statistical model needed | omniCLIP | Most flexible HMM among the options |\n| Online interactive analysis | Galaxy CLIP-Explorer or PIPE-CLIP | Web interface |\n\n## ENCODE eCLIP Stringency Thresholds\n\nThe Van Nostrand et al. ENCODE eCLIP standards define two stringency levels for CLIPper peaks normalized against SMInput:\n\n| Stringency | log2(IP \u002F SMInput) | -log10(p-value) | Use case |\n|------------|--------------------|-----------------|----------|\n| Stringent (publication) | >= 3 | >= 3 | High-confidence binding sites; differential analysis; motif discovery |\n| Lenient (discovery) | >= 1 | >= 2 | Catalogue of all enriched windows; sensitive analyses |\n\nBoth thresholds are applied to the IDR-passing reproducible peak set. ENCODE requires:\n- >= 2 biological replicates\n- >= 1M unique fragments per replicate (or saturated peak detection)\n- IDR rescue ratio and self-consistency ratio both \u003C 2\n- Narrow-binding RBPs: FRiP >= 0.005 (atypical-binding RBPs exempt)\n\n```bash\n# CLIPper -> SMInput normalization -> ENCODE thresholds\nclipper -b dedup.bam -s hg38 -o peaks.bed --save-pickle --FDR-alpha 0.05 --superlocal\n\n# Normalize against SMInput; eclip-norm is the Yeo lab tool\npython overlap_peakfi_with_bam_PE.py peaks.bed dedup.bam sminput.bam dedup.bam.readnum.txt sminput.bam.readnum.txt peaks.normed.bed\npython compress_l2foldenrpeakfi_for_replicate_overlapping_bedformat.py peaks.normed.bed peaks.compressed.bed\n\n# Stringent filter: log2 FC >= 3, -log10 p >= 3\nawk 'BEGIN{FS=OFS=\"\\t\"} $4 >= 3 && $5 >= 3' peaks.compressed.bed > peaks.stringent.bed\n\n# Lenient\nawk 'BEGIN{FS=OFS=\"\\t\"} $4 >= 1 && $5 >= 2' peaks.compressed.bed > peaks.lenient.bed\n```\n\nThe Yeo lab scripts (`overlap_peakfi_with_bam_PE.py`, `compress_l2foldenrpeakfi_for_replicate_overlapping_bedformat.py`) live in the eclip-pipeline repository; they implement the exact log2 fold-change computation used for ENCODE data downloads.\n\n## Per-Caller Failure Modes\n\n### CLIPper -- High-expression transcript bias\n\n**Trigger:** RBP that binds rare transcripts (snoRNAs, tRNAs, mitochondrial mRNAs) such as TROVE2 (Y RNA), NSUN2 (tRNA), or FASTKD2 (chrM).\n\n**Mechanism:** CLIPper's Poisson local-lambda model assumes only a minority of reads come from binding. For rare-transcript binders, the IP reads ARE the majority signal on that transcript; the model treats them as background.\n\n**Symptom:** Per-transcript peak count plummets compared to qualitatively-visible IP signal; chrM peaks called by Skipper but missed by CLIPper for FASTKD2.\n\n**Fix:** Use Skipper for rare-transcript binders (beta-binomial against SMInput respects the actual IP\u002FIN ratio independently of local lambda). Or pre-restrict CLIPper to the target transcript with `--gene custom.bed`.\n\n### CLIPper -- Requires SMInput downstream\n\n**Trigger:** Submitting CLIPper output as \"peaks\" without IP\u002FSMInput log2 normalization.\n\n**Mechanism:** CLIPper's own p-value is uncorrected for SMInput background. ENCODE peak BED files distributed on the portal are CLIPper + SMInput log2 normalization combined.\n\n**Symptom:** Peak count from the analysis is 5-10x higher than ENCODE values for the same RBP; the peak set includes obvious housekeeping-gene noise.\n\n**Fix:** Always normalize CLIPper output against SMInput. The Yeo lab scripts (`overlap_peakfi_with_bam_PE.py` + `compress_l2foldenrpeakfi_for_replicate_overlapping_bedformat.py`) produce the canonical ENCODE-style peak.\n\n### PureCLIP -- Too focal; misses broad binding zones\n\n**Trigger:** RBP with broad binding mode (PUM2 in 3' UTR clusters; SR proteins across exonic enhancer regions); using PureCLIP and disappointed.\n\n**Mechanism:** PureCLIP's HMM emits single-nt crosslink-site state at high stringency. In the Boyle 2023 Skipper benchmark, PureCLIP was highly focal with low recall on broad-binding RBPs (few true-positive windows).\n\n**Symptom:** Site count 100x lower than expected; sites cluster within known binding regions but vast majority of region is \"background\" in PureCLIP output.\n\n**Fix:** Use PureCLIP for single-nt CL maps (motif registration, ASB) but pair with CLIPper or Skipper for the broader binding-site list. PureCLIP's `-or` regions file gives broader output but is still focal compared to CLIPper.\n\n### Piranha -- Top-expression-decile bias\n\n**Trigger:** Highly expressed transcript (GAPDH, ACTB, rRNA-flanking) appears in most-significant Piranha peaks even when RBP biology is elsewhere.\n\n**Mechanism:** ZTNB regression weights peak significance by absolute count, not relative enrichment. Genes with 10x baseline expression dominate the top of the peak list.\n\n**Symptom:** Top-100 Piranha peaks include housekeeping genes; motif enrichment in top peaks is weak; functional GO term analysis of peak-bearing genes returns generic \"cellular metabolism.\"\n\n**Fix:** Use Piranha with SMInput as a covariate (`-c sminput_counts.bed -l`) so the regression accounts for input pile-up. Or switch to Skipper for principled input normalization.\n\n### Piranha -- Convergence failure with covariates\n\n**Trigger:** `-c rna_seq.bed` for expression normalization; large per-bin RNA-seq counts (> 10000).\n\n**Mechanism:** ZTNB optimization fails on extreme covariate values; the iterative algorithm diverges.\n\n**Symptom:** \"Maximum iterations reached\" or \"Singularity in regression\" error; or output BED file empty.\n\n**Fix:** Pass `-l` to convert covariates to log-space; or pre-filter covariate BED to remove top-1% outlier bins; or switch to Skipper which handles input normalization internally.\n\n### omniCLIP -- Mitochondrial transcript blind spot\n\n**Trigger:** Mitochondrial RBP (FASTKD2, LRPPRC) submitted to omniCLIP.\n\n**Mechanism:** omniCLIP's HMM is trained on autosomal\u002FX transcripts; chrM has different background statistics that the model treats as outlier (or excludes if blacklisted).\n\n**Symptom:** chrM peaks return 0; FASTKD2 peak file has no peaks at all.\n\n**Fix:** Use Skipper for chrM-binding RBPs (GC-stratified beta-binomial is per-bin and indifferent to chromosome). Or call peaks on chrM separately with PureCLIP.\n\n### CTK CIMS -- HITS-CLIP only; iCLIP\u002FeCLIP misuse\n\n**Trigger:** CTK CIMS (`-mutation` flag) applied to iCLIP\u002FeCLIP data.\n\n**Mechanism:** iCLIP\u002FeCLIP use truncation (RT stops at adduct), not mutations. CIMS expects deletions\u002Fsubstitutions inside the read; CITS is the truncation-based companion.\n\n**Symptom:** CIMS returns very few sites (mutation rate of CL is ~3-7% for HITS-CLIP, but only ~1-2% for iCLIP since most reads truncate before reaching the adduct).\n\n**Fix:** For iCLIP\u002FeCLIP, use CTK CITS (`tag2cluster.pl ... -cs5 5` truncation-mode). For HITS-CLIP and PAR-CLIP, CIMS is correct (HITS deletions, PAR T->C).\n\n### CLAM peakcaller -- Multi-mapper BAM absent\n\n**Trigger:** Ran STAR with `--outFilterMultimapNmax 1` then tried CLAM; CLAM fails or returns identical output to Piranha.\n\n**Mechanism:** CLAM's EM rescue requires the multi-mapper BAM from STAR (`--outFilterMultimapNmax 100 --outSAMmultNmax -1`). Without it, CLAM falls back to unique-only Piranha-style peak calling.\n\n**Symptom:** CLAM output looks identical to Piranha; repeat peaks not rescued.\n\n**Fix:** Re-align with multi-mapper-aware STAR parameters (see clip-seq\u002Fclip-alignment). Verify the multi-mapper BAM has alignments at non-unique positions before running CLAM.\n\n### MACS3 callpeak -- Wide peaks miss footprint\n\n**Trigger:** MACS3 used because the user is familiar from ATAC\u002FChIP work.\n\n**Mechanism:** MACS3 model is for DNA-protein binding at ~100-500 nt scale; CLIP-seq RBP footprints are 8-30 nt. MACS3 wide peaks (300+ nt) merge multiple distinct binding sites.\n\n**Symptom:** MACS3 peak count is much lower than CLIPper\u002FSkipper; mean peak width >> 100 nt; multiple known motif instances inside one MACS peak.\n\n**Fix:** Use CLIP-specific callers. If MACS3 is forced (institutional pipeline), pass `--nomodel --shift -1 --extsize 50` for narrower peaks and accept the limitation.\n\n## IDR for CLIP-seq\n\nIDR (Li 2011) measures reproducibility of peak rankings across biological replicates. ENCODE eCLIP convention is per-rep + pooled + pseudoreplicates, identical to the ChIP-seq IDR pattern. The CLIP-specific consideration: rank by `signalValue` (column 7) NOT by `score` (column 5), because CLIPper's score is sparse and tied across many peaks.\n\n```bash\n# Per-replicate CLIPper + SMInput normalization yields .compressed.bed files\nsort -k7,7nr rep1_peaks.compressed.bed > rep1.sorted\nsort -k7,7nr rep2_peaks.compressed.bed > rep2.sorted\n\nidr --samples rep1.sorted rep2.sorted \\\n    --input-file-type bed --rank 7 \\\n    --output-file idr.out --idr-threshold 0.05 \\\n    --plot --log-output-file idr.log\n```\n\nENCODE IDR rules for eCLIP:\n- Nt (true replicates) and Nself (pseudoreplicates): max(Nt, Nself) \u002F min(Nt, Nself) \u003C= 2 -> pass\n- Both ratios > 2 -> library rejected\n- IDR threshold 0.05 for true reps; 0.10 for pseudoreplicates\n\n## Decision Tree by Scenario\n\n| Scenario | Caller + parameters | Why |\n|----------|---------------------|-----|\n| Standard eCLIP with SMInput, ENCODE-comparable | CLIPper + SMInput log2 norm + IDR | Reproducible against ENCODE peak files |\n| Standard eCLIP with SMInput, maximum sensitivity | Skipper Snakemake workflow | 210-320% more sites, beta-binomial input-norm |\n| iCLIP\u002FiCLIP2, want single-nt CL map | PureCLIP + SMInput (or empty bam if no SMI) | HMM jointly models enrichment + truncation |\n| HITS-CLIP, want CIMS deletions | CTK `parseAlignment.pl` + `tag2cluster.pl` + `bedExtractCIMS.pl` | Empirical FDR on deletion-induced mutations |\n| PAR-CLIP, T->C signal | PARalyzer or CTK CIMS `-substitution T C` | Designed for the T->C signature |\n| Repeat-binding RBP (MATR3, LINE-1) | CLAM peakcaller on multi-mapper BAM | Only solution that recovers repeat peaks |\n| No SMInput, mostly hopeless | Piranha `-d ZeroTruncatedNegativeBinomial` or PureCLIP w\u002Fo -ibam | Lose ENCODE comparability but get a peak set |\n| Mitochondrial RBP (FASTKD2) | Skipper (window-based, chrM-friendly) | omniCLIP\u002FCLIPper miss chrM |\n| Highly multiplexed (SPIDR) | Custom Snakemake; no single-tool solution | Each barcode's reads are deep enough for CLIPper |\n| Long-read CLIP (dirCLIP) | Custom analysis from BAM; long-read tools not yet mature | Isoform-resolved binding-site calls |\n| Need maximum precision for motif analysis | PureCLIP (single-nt) + mCross downstream | mCross requires registered CL positions |\n| Replicates with unequal library complexity (>2x diff in unique fragments) | Skipper (more robust to depth imbalance) OR `samtools view -s` down-sample to common depth then CLIPper + IDR | Skipper's GC-stratified beta-binomial handles per-sample depth; CLIPper without down-sampling lets the deeper replicate dominate joint analysis |\n\n## Reconciliation: When Callers Disagree\n\n| Pattern | Likely cause | Action |\n|---------|--------------|--------|\n| Skipper >> CLIPper site count | Skipper better recovers low-abundance and rare-transcript binders | Trust Skipper for rare transcripts; trust CLIPper for ENCODE-comparable counts |\n| PureCLIP \u003C\u003C CLIPper | PureCLIP is single-nt focal; CLIPper is broad peak | Both correct; report at the resolution the downstream analysis needs |\n| Piranha top peaks dominated by housekeeping | No input normalization | Add SMInput as `-c` covariate or switch to Skipper |\n| CLAM > Piranha by 10-30% | CLAM rescued multi-mappers in repeats | Trust CLAM if RBP biologically binds repeats |\n| omniCLIP wider peaks than CLIPper | HMM smoothes binding state across nearby positions | Both correct; choose by downstream analysis needs |\n| Per-rep CLIPper calls peak; pooled does not | Replicates inconsistent; one rep dominates | Inspect with IGV; trust IDR-passing peaks only |\n| MACS3 \u003C CLIPper peak count | MACS3 wide peaks merge multiple CLIP sites | Use CLIP-specific caller |\n| FASTKD2 chrM peaks: Skipper finds; CLIPper \u002F omniCLIP find none | Coverage-based callers blind to chrM lambda | Trust Skipper for organelle-binding RBPs |\n| chimeric eCLIP peaks for snoRNA: standard tools find few | snoRNA-targeting eCLIP needs custom processing | Use VanNostrandLab\u002FsnoRNA-chimeric pipeline |\n\n**Operational rule for high-confidence reporting:** Require a peak to pass (a) IDR \u003C= 0.05 on true replicates, (b) log2(IP\u002FSMInput) >= 3 AND -log10 p >= 3 (ENCODE stringent), (c) overlap with at least one independent caller within 100 nt. For motif analysis, additionally require PureCLIP single-nt sites within the peak. For ASB, require WASP-filtered alignment + PureCLIP CL sites overlapping heterozygous SNPs.\n\n## Strand-Specific Peak Calling\n\nCLIP libraries are strand-specific by design. Most callers handle strands correctly when the BAM is stranded (read flags 99\u002F147\u002F83\u002F163 for paired). If a caller bug or unstranded library forces manual split:\n\n```bash\n# Plus strand reads (F flag NOT 0x10)\nsamtools view -h -b -F 16 dedup.bam > plus.bam\nsamtools index plus.bam\n# Minus strand reads (F flag 0x10)\nsamtools view -h -b -f 16 dedup.bam > minus.bam\nsamtools index minus.bam\n\n# Call peaks on each strand independently, then merge\nclipper -b plus.bam -s hg38 -o peaks_plus.bed\nclipper -b minus.bam -s hg38 -o peaks_minus.bed\ncat peaks_plus.bed peaks_minus.bed | sort -k1,1 -k2,2n > peaks_stranded.bed\n```\n\nFor paired-end CLIP, mate orientation determines strand: RF (R1 reverse) means R2 5' is the truncation = CL site -1 on plus-strand transcripts. ENCODE eCLIP convention: read 2 of pair is the truncation-bearing read.\n\n## Multi-Mapper Rescue with CLAM (Repeat Binders)\n\n```bash\n# Assume STAR was run with --outFilterMultimapNmax 100 --outSAMmultNmax -1\nsamtools sort -o multimap.bam aligned_multimap.bam\nsamtools index multimap.bam\n\n# Split unique vs multi\nCLAM preprocessor -i multimap.bam -o clam_out\u002F --read-tagger-method median\n\n# EM-based reassignment\nCLAM realigner -i clam_out\u002Funique.sorted.bam -o clam_out\u002F --winsize 50 --max-tags 0\n\n# Peak calling with reassigned multi-mappers\nCLAM peakcaller -i clam_out\u002Funique.sorted.bam clam_out\u002Frealigned.sorted.bam \\\n    -o clam_peaks.bed -p 8 --gtf gencode.v38.annotation.gtf\n```\n\nCLAM rescues 10-30% additional peaks in repeat-rich regions. The trade-off: peak coordinates in repeat instances are probabilistic (single best from EM), so motif analysis on CLAM repeat peaks requires careful interpretation.\n\n## Quality Metrics for Peak Sets\n\n```python\nimport pandas as pd\n\ndef peak_qc(peaks_bed):\n    peaks = pd.read_csv(peaks_bed, sep='\\t', header=None,\n                        names=['chrom','start','end','name','score','strand'])\n    peaks['width'] = peaks['end'] - peaks['start']\n    return {\n        'n_peaks': len(peaks),\n        'mean_width': peaks['width'].mean(),\n        'median_width': peaks['width'].median(),\n        'width_5p_95p': (peaks['width'].quantile(0.05), peaks['width'].quantile(0.95)),\n        'chroms_with_peaks': peaks['chrom'].nunique(),\n        'peaks_chrM': (peaks['chrom'] == 'chrM').sum()\n    }\n```\n\n| Metric | Expected | Interpretation |\n|--------|----------|----------------|\n| n_peaks (CLIPper stringent) | 5k - 100k | \u003C5k = under-IP or stringency too high; >>100k = noisy library |\n| Mean peak width (CLIPper) | 40-200 nt | Wider = caller over-merging; narrower = under-coverage |\n| Peak width 5-95% range | 20-500 nt | Tight range = consistent peaks; wide = mixed sharp + broad |\n| FRiP (fraction reads in peaks) | >= 0.005 | ENCODE narrow-binding RBP minimum; many RBPs higher |\n| chrM peaks | 0 unless mt-RBP | FASTKD2, LRPPRC expected to have chrM enrichment |\n| TPM-rank distribution | Spread across deciles | Concentrated in top decile = caller has expression bias (Piranha symptom) |\n\n## Common Errors\n\n| Error \u002F symptom | Cause | Solution |\n|-----------------|-------|----------|\n| CLIPper \"no peaks found\" | BAM not sorted\u002Findexed; gene annotation missing | `samtools sort && index`; verify `-s hg38` (or `--gene custom.bed`) |\n| CLIPper out-of-memory on 50M BAM | `--save-pickle` keeps intermediates in RAM | Remove `--save-pickle`; or use machine with > 64 GB |\n| PureCLIP slow (>24h) | `-iv` interval file missing | Restrict to one chromosome with `-iv chr1` for testing; provide GTF |\n| Piranha returns no peaks | ZTNB convergence failed silently | Add `-l`; or reduce `-b` bin size; or switch to Skipper |\n| omniCLIP segmentation fault | Replicate BAMs differ in chromosome order | Re-sort all BAMs with identical reference dictionary |\n| CTK CITS finds nothing on PAR-CLIP | Used CITS (truncation) for substitution data | Use CIMS `-substitution T C` for PAR-CLIP |\n| Multi-mapper rescue returns 0 extra peaks | STAR was run unique-only; no multi-mapper BAM | Re-align with `--outFilterMultimapNmax 100 --outSAMmultNmax -1` |\n| ENCODE stringent peak count = 0 | Forgot SMInput normalization step | Run Yeo lab `overlap_peakfi_with_bam_PE.py` first; thresholds apply to normalized peaks |\n| Strand information lost | `samtools view -F 16` filter applied to merged BAM | Strand is encoded in BAM flags; do not pre-split |\n| IDR returns no reproducible peaks | Wrong ranking column | Sort by signalValue \u002F log2FC, not score; for narrowPeak format use `--rank p.value` |\n\n## References\n\n- Van Nostrand EL et al 2016 Nat Methods 13:508 (eCLIP, SMInput, ENCODE pipeline)\n- Lovci MT et al 2013 Nat Struct Mol Biol 20:1434 (CLIPper algorithm)\n- Krakau S et al 2017 Genome Biol 18:240 (PureCLIP HMM)\n- Boyle EA et al 2023 Cell Genomics 3:100317 (Skipper, GC-stratified beta-binomial)\n- Uren PJ et al 2012 Bioinformatics 28:3013 (Piranha, ZTNB)\n- Drewe-Boss P et al 2018 Genome Biol 19:183 (omniCLIP)\n- Shah A et al 2017 Bioinformatics 33:566 (CTK \u002F CIMS \u002F CITS)\n- Zhang Z & Xing Y 2017 Nucleic Acids Res 45:9260 (CLAM multi-mapper)\n- Frith MC et al 2008 Genome Res 18:1-12 (paraclu)\n- Li Q et al 2011 Ann Appl Stat 5:1752 (IDR framework)\n- Van Nostrand EL et al 2020 Nature 583:711 (A large-scale binding and functional map of human RNA-binding proteins)\n- ENCODE eCLIP Standards (encodeproject.org\u002Feclip) - canonical thresholds\n\n## Related Skills\n\n- clip-seq\u002Fclip-preprocessing - Upstream preprocessing producing dedup BAM\n- clip-seq\u002Fclip-alignment - Upstream alignment with crosslink-preserving parameters\n- clip-seq\u002Fclip-qc - FRiP, library complexity, IDR before\u002Fafter peak calling\n- clip-seq\u002Fcrosslink-site-detection - PureCLIP \u002F CTK CITS \u002F PARalyzer for single-nt CL sites\n- clip-seq\u002Fdifferential-clip - DEWSeq \u002F Flipper for cross-condition differential binding\n- clip-seq\u002Fbinding-site-annotation - Annotate called peaks to 5' UTR \u002F CDS \u002F 3' UTR \u002F intron\n- clip-seq\u002Fclip-motif-analysis - Motif discovery on called peaks\n- clip-seq\u002Fago-clip-mirna-targets - Chimeric eCLIP peak calling\n- clip-seq\u002Fm6a-clip - miCLIP2-specific peak calling\n- chip-seq\u002Fpeak-calling - DNA-protein peak calling for comparison\n",{"name":5,"source":24,"license":15,"tool_type":25,"description":7,"imported_at":26,"source_path":27,"primary_tool":28,"source_repository":29},"https:\u002F\u002Fgithub.com\u002FGPTomics\u002FbioSkills","cli","2026-09-20","clip-seq\u002Fclip-peak-calling\u002FSKILL.md","CLIPper","GPTomics\u002FbioSkills","main","2d1750717747097b602acf30bd09a7cbd4b4c6ea","awesome_skills\u002Fbiology\u002Fbio-clip-seq-clip-peak-calling","https:\u002F\u002Fgithub.com\u002FMr-Nobody-Anonymous\u002FAll-skills","https:\u002F\u002Fgithub.com\u002FMr-Nobody-Anonymous","2026-11-09 11:45:36",{"source":8,"skillName":5,"commands":37,"prompt":47,"zipAvailable":48},[38,41,44],{"tool":39,"command":40},"npx","npx skills add Mr-Nobody-Anonymous\u002FAll-skills --skill bio-clip-seq-clip-peak-calling",{"tool":42,"command":43},"bunx","bunx skills add Mr-Nobody-Anonymous\u002FAll-skills --skill bio-clip-seq-clip-peak-calling",{"tool":45,"command":46},"pnpm","pnpm dlx skills add Mr-Nobody-Anonymous\u002FAll-skills --skill bio-clip-seq-clip-peak-calling","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002FMr-Nobody-Anonymous\u002FAll-skills\u002Fblob\u002Fmain\u002Fawesome_skills\u002Fbiology\u002Fbio-clip-seq-clip-peak-calling\u002FSKILL.md",true,[50,56],{"path":51,"resourceType":52,"resourceTypeDesc":53,"sizeBytes":54,"sourceHtmlUrl":55},"examples\u002Fcall_peaks.sh","SCRIPT","脚本",4060,"https:\u002F\u002Fgithub.com\u002FMr-Nobody-Anonymous\u002FAll-skills\u002Fblob\u002Fmain\u002Fawesome_skills\u002Fbiology\u002Fbio-clip-seq-clip-peak-calling\u002Fexamples\u002Fcall_peaks.sh",{"path":57,"resourceType":58,"resourceTypeDesc":59,"sizeBytes":60,"sourceHtmlUrl":61},"usage-guide.md","REFERENCE","参考文档",5068,"https:\u002F\u002Fgithub.com\u002FMr-Nobody-Anonymous\u002FAll-skills\u002Fblob\u002Fmain\u002Fawesome_skills\u002Fbiology\u002Fbio-clip-seq-clip-peak-calling\u002Fusage-guide.md",[63,71,78,85,92,99],{"skillNo":64,"name":65,"nameZh":6,"description":66,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":67,"categories":68,"keywords":69,"publishedAt":70},"01M7FFFZPC2025JQQHPHDX154J","dei-assessment","Assess diversity, equity, and inclusion with metrics. TRIGGERS - Use when user needs help with dei-assessment related tasks.","https:\u002F\u002Fgithub.com\u002FMr-Nobody-Anonymous\u002FAll-skills\u002Fblob\u002Fmain\u002Fawesome_skills\u002Fhr-people\u002Fdei-assessment\u002FSKILL.md",[],[],"2026-11-16 10:05:34",{"skillNo":72,"name":73,"nameZh":6,"description":74,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":75,"categories":76,"keywords":77,"publishedAt":70},"01M7FFFWN8H4WA7A6Y398QKB6J","dei-action-plan","Create DEI action plans with goals and initiatives. TRIGGERS - Use when user needs help with dei-action-plan related tasks.","https:\u002F\u002Fgithub.com\u002FMr-Nobody-Anonymous\u002FAll-skills\u002Fblob\u002Fmain\u002Fawesome_skills\u002Fhr-people\u002Fdei-action-plan\u002FSKILL.md",[],[],{"skillNo":79,"name":80,"nameZh":6,"description":81,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":82,"categories":83,"keywords":84,"publishedAt":70},"01M7FFFSHTM0QZRVZ2NRJTJ0PY","culture-fit-assessment","Design culture add assessment processes. TRIGGERS - Use when user needs help with culture-fit-assessment related tasks.","https:\u002F\u002Fgithub.com\u002FMr-Nobody-Anonymous\u002FAll-skills\u002Fblob\u002Fmain\u002Fawesome_skills\u002Fhr-people\u002Fculture-fit-assessment\u002FSKILL.md",[],[],{"skillNo":86,"name":87,"nameZh":6,"description":88,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":89,"categories":90,"keywords":91,"publishedAt":70},"01M7FFFMA12RKEQA38KHJSXXPS","cowork-to-code-bridge","Use an already-installed, independently verified cowork-to-code bridge to run narrowly approved actions on the user's own macOS, Linux, or WSL2 machine through a local file queue.","https:\u002F\u002Fgithub.com\u002FMr-Nobody-Anonymous\u002FAll-skills\u002Fblob\u002Fmain\u002Fawesome_skills\u002Fhr-people\u002Fcowork-to-code-bridge\u002FSKILL.md",[],[],{"skillNo":93,"name":94,"nameZh":6,"description":95,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":96,"categories":97,"keywords":98,"publishedAt":70},"01M7FFFH1F6M8YRGW5V487GH1K","counter-offer-response","Draft counter-offer responses for retention. TRIGGERS - Use when user needs help with counter-offer-response related tasks.","https:\u002F\u002Fgithub.com\u002FMr-Nobody-Anonymous\u002FAll-skills\u002Fblob\u002Fmain\u002Fawesome_skills\u002Fhr-people\u002Fcounter-offer-response\u002FSKILL.md",[],[],{"skillNo":100,"name":101,"nameZh":6,"description":102,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":103,"categories":104,"keywords":105,"publishedAt":70},"01M7FFFDGEHV8Y7J9N40HZXW52","continuous-feedback-system","Design continuous feedback systems. TRIGGERS - Use when user needs help with continuous-feedback-system related tasks.","https:\u002F\u002Fgithub.com\u002FMr-Nobody-Anonymous\u002FAll-skills\u002Fblob\u002Fmain\u002Fawesome_skills\u002Fhr-people\u002Fcontinuous-feedback-system\u002FSKILL.md",[],[]]