×

nf-core/alleleexpression

Alleleexpression is a nf-core pipeline for allele-specific expression (ASE) analysis using STAR-WASP for alignment, UMI-tools for deduplication, and phaser for haplotype phasing and ASE detection.

Version: 0.0.0-985ad30 Git revision: 985ad30a891f4f77802ea44295cdcdfcd521af66 Commit: Content hash:
Run:
Workflow: main.nf

nf-core/alleleexpression

Nextflow nf-core template version

Overview

Alleleexpression is a Nextflow pipeline for allele-specific expression (ASE) analysis using STAR-WASP for alignment, UMI-tools for deduplication, and phaser for haplotype phasing and ASE detection.

Features

  • STAR alignment with WASP mode for allele-specific mapping
  • UMI-based deduplication
  • Chromosome-specific analysis with configurable chromosome selection
  • Beagle phasing integration
  • Phaser-based allele-specific expression analysis
  • Comprehensive QC with FastQC and MultiQC reporting

Requirements

  • Nextflow (>=25.04.0)
  • Singularity or Docker
  • Reference genome and annotation files
  • Beagle reference panel and genetic map (for phasing)

With -profile docker, the phASER image must be built locally first:

docker build -t phaser:latest containers/phaser

With -profile singularity it is pulled automatically from Zenodo.

Testing

The test profile downloads a simulated dataset from Zenodo (2 Mb of GRCh38 chr11, two 1000 Genomes samples with planted allele-specific expression, plus truth tables):

nextflow run nf-core/alleleexpression -profile test,docker --outdir results

To rebuild the dataset locally, run tests/scripts/make_ase_sim_data.sh (see tests/data/ase_sim/README.md).

Pipeline steps

  1. Input validation and VCF preparation
  2. FastQC for raw reads
  3. STAR alignment with WASP mode
  4. Filtering of WASP-passing reads
  5. UMI-based deduplication
  6. Sorting and indexing of BAM files
  7. Chromosome extraction from VCF
  8. Beagle phasing
  9. Phaser for haplotype-level expression
  10. Phaser_gene_ae for gene-level ASE
  11. ASE calling per gene: binomial or beta-binomial test (--ase_test), Benjamini-Hochberg FDR (--ase_fdr) and optional minimum effect size (--ase_min_effect); see usage
  12. MultiQC report generation

Output

The pipeline organizes outputs by sample name in the specified output directory:

  • fastqc/: FastQC reports
  • star/: STAR alignment results
  • wasp/: WASP-filtered BAM files
  • umi/: UMI-deduplicated BAM files
  • beagle/: Phased VCF files
  • phaser/: Phaser results
  • ase/: Allele-specific expression results
  • multiqc/: MultiQC report

Credits

  • Pipeline framework: nf-core
  • Tools: FastQC, STAR, UMI-tools, samtools, bcftools, Beagle, phaser, MultiQC

Contributing

Alleleexpression is under active development and we welcome contributions! If you find a bug, have an idea to improve it, or want to help implement new features (like better sex-chromosome support), feel free to open an issue or submit a pull request.

Let’s build this together.

43 parameter(s) in 7 group(s)

ASE calling options#

Options for calling allele-specific expression from gene-level haplotype counts.

Benjamini-Hochberg FDR threshold for calling a gene ASE.

type number
default 0.05

Statistical test for allele-specific expression: binomial or betabinomial.

More detail

Each gene is tested for a departure from a balanced (0.5) haplotype ratio using its phASER haplotype counts.

  • binomial: exact two-sided binomial test. Assumes counts vary only through read sampling. With deep coverage it also calls small imbalances caused by technical or biological noise, so it reports more false positives on real data.
  • betabinomial: two-sided beta-binomial test that allows extra-binomial variation (overdispersion, rho). rho is estimated per sample from the data (see --ase_overdispersion_trim) or fixed with --ase_overdispersion. Recommended for real data.
type string
default binomial
one of binomial, betabinomial

Minimum haplotypic reads (aCount + bCount) for a gene to be tested for ASE.

type integer
default 20

Minimum effect size to call a gene ASE, as |major haplotype fraction - 0.5|.

More detail

Applied on top of the statistical test with either --ase_test. For example 0.1 requires at least a 60:40 haplotype ratio and 0.15 at least 65:35. The default 0 calls every significant gene.

type number
default 0

Fixed beta-binomial overdispersion (rho) for --ase_test betabinomial. Estimated from the data if not set.

More detail

rho is the intra-class correlation of the beta-binomial: variance = n p (1 - p) (1 + (n - 1) rho). When not set, it is estimated per sample by trimmed maximum likelihood (see --ase_overdispersion_trim). Set it when a sample has few testable genes (the pipeline warns below 50), or to use one value across samples. Ignored with --ase_test binomial.

type number

Fraction of tested genes left out when estimating the beta-binomial overdispersion.

More detail

The estimate repeatedly fits rho, keeps the best-fitting (1 - trim) fraction of tested genes and refits, so that genes with real ASE do not inflate rho. Set it to roughly the largest share of tested genes you expect to show ASE. Higher values give a smaller rho (more calls); lower values a larger rho (fewer calls). Ignored with --ase_test binomial or when --ase_overdispersion is set.

type number
default 0.2

UMI options#

Options for UMI processing.

UMI separator character in read IDs.

type string
default :

Generic options#

Less common options for the pipeline, typically set in a config file.

Display help text.

type boolean

Internal parameter to store module-specific options.

type string

Display version and exit.

type boolean

Incoming hook URL for messaging service

More detail

Incoming hook URL for messaging service. Currently, MS Teams and Slack are supported.

<