Run your first pipeline
With Nextflow and your software dependency manager installed, you are ready to run your first nf-core pipeline. It is ideal for, verifying your environment is correctly configured, learning how nf-core pipelines work, and testing your installation.
nf-core/demo
nf-core/demo is a lightweight demonstration pipeline designed to introduce running nf-core pipelines. It performs basic quality control and processing on sequencing data, showcasing the structure and best practices followed by all nf-core pipelines.
The [nf-core/demo] pipeline runs three processes:
- Read QC (FastQC)
- Quality control checks on raw sequencing reads
- Adapter and quality trimming (seqtk trim)
- Removes adapter sequences and low-quality bases
- QC report aggregation (MultiQC)
- Combines QC metrics into a single interactive report
It is purposefully lightweight and should run within a few minutes on most systems.
Quick start
The following sections cover common operations for getting started with nf-core/demo.
Use test data
To run nf-core/demo with test data:
-
Run
nf-core/demowith the built-in test profile and a profile to manage software dependencies:nextflow run nf-core/demo -profile test,docker --outdir resultsTipCommon configure software dependencies and compute environments include:
docker: Uses Docker containerssingularity: Uses Singularity containersconda: Uses Conda environments
Combine profiles with commas:
-profile test,docker -
Once complete, view your
results/directory:results/ ├── fastqc/ # Raw FastQC reports for each sample ├── fq/ # Trimmed FastQ files ├── multiqc/ # Aggregated QC report │ └── multiqc_report.html └── pipeline_info/ # Execution logs and metadata
Use your own data
To run nf-core/demo with your own sequencing data:
-
Create
samplesheet.csvwith the following contents:Column Description sampleUnique sample identifier fastq_1Path to gzipped first-read FastQ file fastq_2Path to gzipped second-read FastQ file (leave empty for single-end) Example:
sample,fastq_1,fastq_2 SAMPLE1,</path/to/sample1_R1.fastq.gz>,</path/to/sample1_R2.fastq.gz> SAMPLE2,</path/to/sample2_R1.fastq.gz>, -
Run
nf-core/demowith yoursamplesheet.csvas input:nextflow run nf-core/demo \ -profile <docker> \ --input samplesheet.csv \ --outdir resultsReplace
<docker>with your preferred software dependency and compute environment manager.
Use parameter files
To run nf-core/demo with a parameters file:
-
Create
params.jsonwith the following contents:params { input = 'samplesheet.csv' // This requires the samplesheet.csv created above outdir = 'results' } -
Run
nf-core/demowith youparams.jsonfile:nextflow run nf-core/demo \ -profile <docker> \ -params-file params.jsonReplace
<docker>with your preferred software dependency and compute environment manager.TipParameter files make it easier to rerun pipelines with the same settings and keep track of your analysis configurations.
Resume interrupted runs
To resume an interrupted run, add the -resume flag:
nextflow run nf-core/demo \
-profile docker \
--input samplesheet.csv \
--outdir results \
-resumeOnly steps with changed inputs will re-execute, saving time and computational resources.
Version control
To specify a pipeline version, add the -r option with a version, revision, or commit ID:
nextflow run nf-core/demo \
-r 1.0.2 \
-profile docker \
--input samplesheet.csv \
--outdir resultsVersion information is automatically recorded in pipeline reports. Check available releases on GitHub.
Next steps
Now that you’ve successfully run your first nf-core pipeline:
- Browse the nf-core pipeline catalog to find workflows for your research area
- Learn to adjust resource requirements and parameters for your infrastructure
- Join the nf-core Slack community