Introduction

This document describes the output produced by the pipeline. Most of the plots are taken from the MultiQC report, which summarises results at the end of the pipeline.

The directories listed below will be created in the results directory after the pipeline has finished. All paths are relative to the top-level results directory.

Pipeline overview

Panel preparation outputs --steps panelprep

This step of the pipeline performs a QC of the reference panel data and produces the necessary files for imputation (--steps impute). It has two optional modes:

  • reference panel phasing with SHAPEIT5

  • removal of specified samples from reference panel.

  • Normalize reference panel - Remove multiallelic sites from the reference panel and compute allele frequencies if needed

  • Convert - Convert reference panel to .hap and .legend files

  • Posfile - Produce a TSV with the list of positions to genotype for the different tools

  • Chromosomes chunks - Create chunks of the reference panel

  • CSV - Obtain a CSV from this step

The directory structure from --steps panelprep is:

β”œβ”€β”€ panel
β”œβ”€β”€ haplegend
β”œβ”€β”€ sites
β”œβ”€β”€ chunks
β”‚   β”œβ”€β”€ glimpse1
β”‚   └── glimpse2
β”œβ”€β”€ csv

Panel directory

Output files
  • prep_panel/panel/
    • *.vcf.gz: The reference panel VCF after all the preprocessing is done.
    • *.tbi*: A tbi for the prepared reference panel.

A directory containing the reference panel per chromosome after preprocessing. The files will be normalized if the flag --normalize is used (with _normalized suffix). The files will have their allele frequency computed if the flaq --compute_freq is used (with _fixup suffix). The files will be phased if the flag --phase is used (with _phased suffix).

Haplegend directory

Output files
  • prep_panel/haplegend/
    • *.hap: a .hap file for the reference panel.
    • *.legend*: a .legend file for the reference panel.

bcftools convert aids in the conversion of VCF files to .hap and .legend files. A .samples file is also generated. Once that you have generated the hap and legend files for your reference panel, you can skip the reference preparation steps and directly submit these files for imputation. The hap and legend files are input files used with --tools quilt.

Sites directory

Output files
  • prep_panel/sites/
    • *.vcf.gz: VCF with biallelic SNPs only.
    • *.csi: Index file for VCF.

bcftools query produces VCF (*.vcf.gz) files per chromosome. These QCed VCFs can be gathered into a csv and used with all the tools in --steps impute using the flag --panel.

Chunks directory

Output files
  • prep_panel/chunks/
    • *.txt: TXT file containing the chunks obtained from running GLIMPSE1_CHUNK.

Glimpse1 chunk defines chunks where to run imputation. For further reading and documentation see the Glimpse1 documentation. Once that you have generated the chunks for your reference panel, you can skip the reference preparation steps and directly submit this file for imputation.

CSV directory

Output files
  • prep_panel/csv/
    • chunks.csv: A csv containing the list of chunks obtained for each chromosome and panel.
    • panel.csv: A csv containing the final phased and prepared for each chromosome and input panel.
    • posfile.csv: A csv containing the final list of panel positions, in VCF and tsv, for each chromosome and input panel.

Imputation outputs --steps impute

The results from --steps impute will have the following directory structure:

β”œβ”€β”€ batch
β”œβ”€β”€ csv
β”œβ”€β”€ glimpse1/glimpse2/quilt/stitch
β”‚   β”œβ”€β”€ concat/
β”‚   └── samples/
β”œβ”€β”€ stats
Output files
  • imputation/batch/all.batchi.id.txt: List of samples names processed in the i^th^ batch.
  • imputation/csv/
    • impute.csv: A single csv containing the path to a VCF and its index, of each imputed sample with their corresponding tool.
  • imputation/[glimpse1,glimpse2,quilt,stitch]/
    • concat/all.batch*.vcf.gz: The concatenate VCF of all imputed samples by batches.
    • concat/all.batch*.vcf.gz.tbi: A tbi for the concatenated samples imputed VCF.
    • samples/*.vcf.gz: A VCF of each imputed sample.
    • samples/*.vcf.gz.tbi: A tbi for the imputed VCF.
  • imputation/*.<tool>.bcftools_stats.txt: The statistics of the imputed VCF target file produced by BCFTOOLS_STATS

bcftools concat will produce a single VCF from a list of imputed VCFs in chunks.

Simulation outputs --steps simulate

The results from --steps simulate will have the following directory structure:

β”œβ”€β”€ csv
β”œβ”€β”€ samples
Output files
  • simulation/
    • csv:
      • simulate.csv: Samplesheet listing all downsampled target alignment files.
    • *.depth_*x.bam: An alignment file from the target file down-sampled at the desired depth.
    • *.bam.csi: The corresponding index of the alignment file.

Validation outputs --steps validate

The results from --steps validate will have the following directory structure:

β”œβ”€β”€ concat
β”œβ”€β”€ samples
β”œβ”€β”€ stats
Output files
  • validation/
    • concat/all.truth.vcf.gz: The concatenate VCF of all truth sample.
    • concat/all.truth.vcf.gz.tbi: A tbi for the concatenated samples truth VCF.
    • samples/*.vcf.gz: A VCF of each truth sample.
    • samples/*.vcf.gz.tbi: A tbi for the truth VCF.
    • stats/:
      • *.truth.bcftools_stats.txt: The statistics of the truth VCF target file produced by BCFTOOLS_STATS
      • *.P<panel name>_T<imputation tool>_SNP.txt: Concordance metrics of the SNP variants obtained with GLIMPSE2_CONCORDANCE.
      • AllSamples.txt: Aggregation of the above GLIMPSE_CONCORDANCE output across samples and tools.

Reports

Reports contain useful metrics and pipeline information for the different modes.

  • MultiQC - Aggregate report describing results and QC from the whole pipeline.
  • Pipeline information - Report metrics generated during the workflow execution.

MultiQC

Output files
  • multiqc/
    • multiqc_report.html: a standalone HTML file that can be viewed in your web browser.
    • multiqc_data/: directory containing parsed statistics from the different tools used in the pipeline.
    • multiqc_plots/: directory containing static images from the report in various formats.

MultiQC is a visualization tool that generates a single HTML report summarising all samples in your project. Most of the pipeline QC results are visualised in the report and further statistics are available in the report data directory.

Results generated by MultiQC collate pipeline QC from supported tools e.g. FastQC. The pipeline has special steps which also allow the software versions to be reported in the MultiQC output for future traceability. For more information about how to use MultiQC reports, see http://multiqc.info.

Pipeline information

Output files
  • pipeline_info/
    • Reports generated by Nextflow: execution_report.html, execution_timeline.html, execution_trace.txt and pipeline_dag.dot/pipeline_dag.svg.
    • Reports generated by the pipeline: pipeline_report.html, pipeline_report.txt and software_versions.yml. The pipeline_report* files will only be present if the --email / --email_on_fail parameter’s are used when running the pipeline.
    • Reformatted samplesheet files used as input to the pipeline: samplesheet.valid.csv.
    • Parameters used by the pipeline run: params.json.

Nextflow provides excellent functionality for generating various reports relevant to the running and execution of the pipeline. This will allow you to troubleshoot errors with the running of the pipeline, and also provide you with other information such as launch commands, run times and resource usage.