The pipeline is built using Nextflow, a workflow tool to run tasks across multiple compute infrastructures in a very portable manner. It comes with docker containers making installation trivial and results highly reproducible.

nf-core/phaseimpute is a bioinformatics pipeline that …

Main steps of the pipeline

The phaseimpute pipeline is constituted of 5 main steps:

Metro mapModes
metromap- Pre-processing: Phasing, QC, variant filtering, variant annotation of the reference panel
- Phase: Phasing of the target dataset on the reference panel
- Simulate: Simulation of the target dataset from high quality target data
- Concordance: Concordance between the target dataset and a truth dataset
- Post-processing: Variant filtering based on their imputation quality


Note If you are new to Nextflow and nf-core, please refer to this page on how to set-up Nextflow. Make sure to test your setup with -profile test before running the workflow on actual data.

Now, you can run the pipeline using:

nextflow run nf-core/phaseimpute \
   -profile <docker/singularity/.../institute> \
   --input samplesheet.csv \
   --outdir <OUTDIR>

Warning: Please provide pipeline parameters via the CLI or Nextflow -params-file option. Custom config files including those provided by the -c Nextflow option can be used to provide any configuration except for parameters; see docs.

For more details and further functionality, please refer to the usage documentation and the parameter documentation.

Simple test

To run a simple test with the example dataset, install Nextflow and run the following command:

nextflow run -profile test,mamba --outdir test -resume

Pipeline output

To see the results of an example test run with a full size dataset refer to the results tab on the nf-core website pipeline page. For more details about the output files and reports, please refer to the output documentation.


The nf-core/phaseimpute pipeline comes with documentation about the pipeline, found in the docs/ directory:

  1. Installation
  2. Pipeline configuration
  3. Running the pipeline
  4. Output and how to interpret the results
  5. Troubleshooting

Description of the different mode of the pipeline

Here is a short description of the different mode of the pipeline. For more information please refer to the documentation.

ModeFlow chartDescription
Preprocessingphase_metroThe preprocessing mode is responsible to the preparation of the multiple input file that will be used by the phasing process.
The main processes are :
- Haplotypes phasing of the reference panel using Shapeit5.
- Filter the reference panel to select only the necessary variants.
- Chunking the reference panel in a subset of region for all the chromosomes.
- Extract the positions where to perform the imputation.
Phasingphase_metroThe phasing mode is the core mode of this pipeline.
It is constituted of 3 main steps:
- Phasing: Phasing of the target dataset on the reference panel using either:
  - Glimpse1
  It’s come with the necessety to compute the genotype likelihoods of the target dataset.
  This step is done using BCFTOOLS_mpileup
  - Glimpse2 For this step the reference panel is transformed to binary chunks.
  - Stitch
  - Quilt
- Ligation: all the different chunks are merged together.
- Sampling (optional)
Simulatesimulate_metroThe simulation mode is used to create artificial low informative genetic information from high density data. This allow to compare the imputed result to a truth and therefore evaluate the quality of the imputation.
For the moment it is possible to simulate:
- Low-pass data by downsample BAM or CRAM using SAMTOOLS_view -s at different depth
- Genotype data by SNP selecting the position used by a designated SNP chip.
The simulation mode will also compute the Genotype likelihoods of the high density data.
Concordanceconcordance_metroThis mode compare two vcf together to compute a summary of the differences between them.
To do so it use either:
- Glimpse1 concordance process.
- Glimpse2 concordance process
- Or convert the two vcf fill to .zarr using Scikit allele and anndata before comparing the SNPs.
Postprocessingpostprocessing_metroThis final process unable to loop the whole pipeline for increasing the performance of the imputation. To do so it filter out the best imputed position and rerun the analysis using this positions.


nf-core/phaseimpute was originally written by @LouisLeNezet.

We thank the following people for their extensive assistance in the development of this pipeline:

Contributions and Support

If you would like to contribute to this pipeline, please see the contributing guidelines.

For further information or help, don’t hesitate to get in touch on the Slack #phaseimpute channel (you can join with this invite).


An extensive list of references for the tools used by the pipeline can be found in the file.

You can cite the nf-core publication as follows:

The nf-core framework for community-curated bioinformatics pipelines.

Philip Ewels, Alexander Peltzer, Sven Fillinger, Harshil Patel, Johannes Alneberg, Andreas Wilm, Maxime Ulysse Garcia, Paolo Di Tommaso & Sven Nahnsen.

Nat Biotechnol. 2020 Feb 13. doi: 10.1038/s41587-020-0439-x.