Identify variants with allelic effects on TF or histone modification binding from heterozygous-variant ChIP-seq. Covers WASP (mandatory reference-bias filter), RASQUAL (joint cis-QTL + bias-aware testing), BaalChIP (Bayesian beta-binomial with copy-number-aware overdispersion), and AlleleSeq (personalized diploid genome). Embeds the three universal pitfalls (reference bias, imprinted loci, X-inactivation, copy-number imbalance) and integrates with downstream caQTL / bQTL / fine-mapping.
# WASP (mandatory upstream)
git clone https://github.com/bmvdgeijn/WASP.git
# Requires Python 3, pysam, pytables
# Aligner
conda install -c bioconda bowtie2 samtools bcftools
# Variant calling (for sample-specific hetSNPs)
conda install -c bioconda gatk4
BiocManager::install(c('BaalChIP', 'AllelicImbalance'))
# RASQUAL
git clone https://github.com/dg13/rasqual.git
# Build with `make` in repo
# AlleleSeq
# https://github.com/gerstein-lab/AlleleSeq
Tell the agent what to do: - "Apply WASP reference-bias filter to my ChIP-seq BAM before any ASB analysis (mandatory step)" - "Run BaalChIP on TNBC cancer samples with copy-number-aware overdispersion" - "Use RASQUAL for joint cis-QTL + ASB analysis on a population of 50 samples" - "Build a personalized diploid genome with AlleleSeq for a single-sample ASB analysis" - "Filter imprinted loci and X-inactivated chrX before reporting ASB" - "Validate chromBPNet variant effect predictions against ASB measurements"
"Run the WASP mapping pipeline on a bowtie2-aligned ChIP-seq BAM with my sample's heterozygous SNP VCF. Apply the three steps: find intersecting SNPs, re-map swapped reads, filter discordant mappings. Output WASP-filtered BAM (will lose 22-31% of reads)."
"I have FOXA1 ChIP-seq in HCC1395 (TNBC). Run BaalChIP with copy-number-aware overdispersion using my ASCAT CNV calls. Output ASB sites with posterior > 0.95."
"I have 50 individuals' CTCF ChIP-seq with phased genotypes. Run RASQUAL for cis-QTL mapping with built-in bias correction (
phiparameter). Window 250 kb around each peak."
"Build a personalized diploid genome from my sample's phased VCF. Align ChIP reads to maternal and paternal copies separately, then merge for binomial ASB test."
"I have chromBPNet variant predictions and BaalChIP ASB measurements. Compare: variants with |log2_fc| > 1 in chromBPNet should show ASB; variants with no ASB but predicted strong effect may be in extrapolation regime."
"Before reporting ASB: (1) verify WASP was applied; (2) filter imprinted loci (H19, IGF2, MEG3, KCNQ1OT1); (3) exclude chrX in female samples; (4) for cancer, exclude CN-altered regions or use BaalChIP with CN file."
phi parameter is the per-feature bias estimate; can be cross-checked against WASP filter loss.WASP not applied or sample-specific hetSNPs missing from WASP SNP file. Build WASP table from sample's own genotype VCF.
Imprinted loci not filtered. Apply imprinted-genes BED before reporting.
X-inactivation. Filter chrX or use X-inactivation-aware methods.
Copy-number imbalance. Use BaalChIP with CN file OR exclude CN-altered regions.
hetSNP / peak chromosome naming mismatch. Standardize chr prefixes.
Many large SVs in genome. Use small-variant-only VCF; exclude SV-rich regions.
ASB needs ≥20 reads per allele to detect a 2:1 ratio at p<0.05. Increase sequencing depth (2× normal ChIP for ASB power) or combine replicates.