Introduction

nf-core/smrnaseq is a bioinformatics best-practice analysis pipeline used for small RNA sequencing data analysis.

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

The pipeline is built using Nextflow and processes data using the following steps:

  • Preprocessing - Preprocessing of reference files
  • Reference genome files - Indices generated by the pipeline, saved with --save_reference
  • FastQC - read quality control
  • UMI-tools extract - UMI barcode extraction
  • UMI-collapse deduplicate - read deduplication
  • FastP - adapter trimming
  • Bowtie2 - contamination filtering
  • Bowtie - alignment against mature miRNAs and miRNA precursors (hairpins)
  • SAMtools - alignment result processing and read counts per reference sequence
  • edgeR - normalization, MDS plot and sample pairwise distance heatmap
  • Bowtie - alignment against reference genome for QC purpose (genome quantification, only with --fasta or --genome)
  • mirtop - miRNA and isomiR annotation
  • miRNA identifiers - table mapping the reported miRNA names to miRBase accessions
  • miRDeep2 - known and novel miRNA annotation
  • miRTrace - a comprehensive tool for QC purpose
  • MultiQC - aggregate report, describing results of the whole pipeline
  • Pipeline information - Report metrics generated during the workflow execution

If --save_intermediates is specified, intermediate files generated by each process will be saved in the output directory.

Preprocessing

Output files
  • bowtie_index/genome: Cleaned genome FASTA (_clean.fa) and, if the pipeline built it, the genome Bowtie index (bowtie/) (only with --save_intermediates, and only if --save_reference is not set: see Reference genome files).
  • untar/bowtie_index: Uncompressed bowtie index, when --bowtie_index is a .tar.gz archive (only with --save_intermediates).

Preprocessing is done to format reference files before using them in the workflow, it includes untar and bioawk. If the bowtie_index file provided is in gzip format it will be processed by untar. The fasta file provided will be cleaned using bioawk.

Reference genome files

Output files
  • genome/
    • _clean.fa: Cleaned genome FASTA, when --fasta is given.
    • index/
      • bowtie/: Bowtie index of the genome, when the pipeline built it from --fasta (no --bowtie_index given).
      • mirna_mature/bowtie/: Bowtie index of the formatted mature miRNA FASTA.
      • mirna_hairpin/bowtie/: Bowtie index of the formatted hairpin miRNA FASTA.
      • contaminants/<rRNA,tRNA,cDNA,ncRNA,piRNA,other>/bowtie2/: Bowtie2 indices of the contaminant databases, with --filter_contamination.

If --save_reference is specified, the reference files and indices that the pipeline generates are saved to genome/. Indices you provide yourself (e.g. --bowtie_index) are not copied. To skip building the genome index in future runs, pass it back with --bowtie_index <outdir>/genome/index/bowtie, together with the same --fasta (or the saved _clean.fa). The miRNA and contaminant indices are saved for inspection and reproducibility: the pipeline currently has no parameters to reuse them, so they are rebuilt on every run.

--save_intermediates also saves the cleaned genome FASTA and the Bowtie indices, to bowtie_index/ (see Preprocessing and Bowtie). Each file is saved only once: when both flags are set, these files go to genome/ instead of bowtie_index/. The contaminant Bowtie2 indices are only saved with --save_reference.

Merged technical replicates

Output files
  • cat_fastq/
    • *.merged.fastq.gz: If --save_merged is specified, the FastQ files of samples with multiple runs (technical replicates) are concatenated per sample and saved in this directory.

FastQC

Output files
  • fastqc/raw/: reports for the raw reads.
  • fastqc/trimmed/: reports for the reads after adapter and quality trimming.
    • *_fastqc.html: FastQC report containing quality metrics.
    • *_fastqc.zip: Zip archive containing the FastQC report, tab-delimited data file and plot images.
Note

The FastQC files are only published with --save_intermediates. By default, FastQC still runs and its results are included in the MultiQC report, but the individual reports are not written to the output directory.

FastQC gives general quality metrics about your sequenced reads. It provides information about the quality score distribution across your reads, per base sequence content (%A/T/G/C), adapter contamination and overrepresented sequences. For further reading and documentation see the FastQC help pages.

MultiQC - FastQC sequence counts plot

UMI-tools extract

Output files
  • umi_dedup/fastq_extracted_umi/
    • *.fastq.gz: If --save_umi_intermeds is specified, FastQ files after UMI extraction will be placed in this directory.
    • *.log: Log file generated by the UMI-tools extract command.

With --with_umi, UMI-tools extract is the first step after read QC. It runs on the raw reads and uses --umitools_bc_pattern to move the UMI from the read sequence into the read name and to remove the kit sequences around it, so that only the insert remains. fastp then filters and clips the inserts (see FastP), and they are deduplicated (see UMI-collapse deduplicate). The log reports how many reads matched the pattern. See the UMI handling section of the usage documentation for the order of the steps and the recommended parameters.

FastP

FastP is used for removal of adapter contamination and trimming of low-quality regions.

MultiQC reports the percentage of bases removed by FastP in the General Statistics table, along some further information on the results.

Output directory: results/fastp

Contains FastQ files with quality and adapter-trimmed reads for each sample, along with a log file describing the trimming.

  • sample_fastp.json - JSON report file with information on parameters and trimming metrics
  • sample_fastp.html - HTML report with some visualizations of trimming metrics
  • fastq/*.fastp.fastq.gz - Trimmed reads, if --save_merged is specified

FastP can automatically detect adapter sequences when not specified directly by the user - the pipeline also comes with a feature and a supplied miRNA adapters file to ensure adapters auto-detected are more accurate. If there are needs to add more known miRNA adapters to this list, please open a pull request.

With --with_umi, FastP runs on the inserts after UMI-tools extract, before deduplication, so its reports describe the extracted inserts. With --umitools_extract_method regex, it does not trim adapters (the UMI pattern removes them).

UMI-collapse deduplicate

Output files
  • umi_dedup/fastq_deduplicated/
    • *.umi_dedup.fastq.gz: If --save_umi_intermeds is specified, the deduplicated reads (inserts, with the UMI in the read name) will be placed in this directory. These are the reads used for miRNA quantification.
  • umi_dedup/saturation/
    • *.umi_saturation.tsv: UMI saturation statistics for each sample, computed on the deduplicated reads: UMI length, number of reads, number of distinct insert sequences, the most frequent insert sequence and its number of reads, the number of possible UMIs (4^UMI length) and the fraction of them that the most frequent sequence uses (top_sequence_umi_fraction).

With --with_umi, UMICollapse deduplicates the extracted inserts directly on the FastQ files, without mapping the reads first. The UMI is moved from the read name to the start of the sequence for this step, so that reads with the same UMI and insert sequence, up to one substitution by default, are collapsed into one read; it is removed from the sequence again afterwards. The deduplication algorithm is set with --umitools_method. MultiQC reports the number of reads before and after deduplication from the UMICollapse log.

If top_sequence_umi_fraction is above 0.005 (0.5% of all possible UMIs), the pipeline prints a UMI saturation warning: one-mismatch deduplication then merges distinct molecules of the most abundant sequences. See Choosing a UMI strategy.

Bowtie2

Output files
  • contaminant_filter/filter/ (only with --filter_contamination and --save_intermediates)
    • *.filtered.fastq.gz: Reads that did not align to any of the contaminant databases. These reads are used for miRNA quantification, genome mapping and miRDeep2.
    • *.contamination_mqc.yaml: Number of reads removed per contaminant class (rRNA, tRNA, cDNA, ncRNA, piRNA, other) and number of remaining reads. These files feed the “Contamination Filtering” plot in MultiQC.

Bowtie2 is used to build indices for the --filter_contamination databases (--rrna, --trna, --cdna, --ncrna, --pirna, --other_contamination) and to align the reads to them, one database after the other.

MultiQC reports the number of reads that were removed by each of the contaminant databases. The reads that align to a database are discarded: the pipeline keeps only their total per class, not alignments or counts per sequence. See the usage documentation for details, and Small RNA biotypes other than miRNAs for what the pipeline offers for tRNA, piRNA and other small RNAs.

Bowtie

Bowtie is used for building the index for the fasta genome, if needed. It is also used for mapping adapter trimmed reads against the mature miRNAs and miRNA precursors (hairpins) of the chosen database miRBase or MirGeneDB.

Output directory: results/

  • bowtie_index/
    • mirna_hairpin/bowtie: hairpin.fa bowtie index files (saved to genome/index/mirna_hairpin/bowtie instead with --save_reference).
    • mirna_mature/bowtie: mature.fa bowtie index files (saved to genome/index/mirna_mature/bowtie instead with --save_reference).
  • genome_quant/bam/ (only when a genome FASTA is given with --fasta or --genome; see genome quantification): alignment against the genome of the reads that did not align to the mature miRNAs or hairpins. Up to 50 alignments are reported per read. The pipeline does not count these reads against a genome annotation; see the usage documentation for how to do this, and Small RNA biotypes other than miRNAs for an overview of what the pipeline offers for other small RNAs. Only with --save_intermediates:
    • {sample.id}_mature_hairpin_genome.bam: Unsorted Bowtie alignment against the genome.
    • {sample.id}_mature_hairpin_genome.sorted.bam and .sorted.bam.csi: Sorted and indexed alignment.
    • {sample.id}_mature_hairpin_genome.out: Bowtie log.
    • {sample.id}_mature_hairpin_genome.unmapped.fastq.gz: Reads that did not align to the genome.
  • mirna_quant/
    • mirna_quant/bam/{hairpin,mature,seqcluster}/.*bam: The aligned BAM file results against hairpin, mature or seqcluster.
    • mirna_quant/bam/{hairpin,mature,seqcluster}/.*unmapped.fastq.gz: Unmapped reads for hairpin, mature or seqcluster.

If --save_intermediates is specified, these files will be placed in this directory.

SAMtools

SAMtools is used for sorting and indexing the output BAM files from Bowtie. In addition, the number of reads per reference sequence is counted with idxstats: per mature miRNA or hairpin for mirna_quant/, and per chromosome (not per gene) for genome_quant/.

Output directory: results/{genome_quant,mirna_quant}/bam

The statistics for the miRNA alignments (mirna_quant/bam) are saved only with --save_intermediates. The statistics for the genome alignments (genome_quant/bam) are always saved when genome quantification runs. In any case, these stats will always be available in the MultiQC report.

  • .*stats|.*idxstats|.*flagstat: BAM stats for each of the files listed above.
    • For the genome alignments, {sample.id}_mature_hairpin_genome.sorted.idxstats gives the number of reads aligned to each genome sequence (chromosome or contig). The pipeline does not count reads per gene or other genomic feature.

samtools

edgeR

edgeR is an R package used for differential expression analysis of RNA-seq expression profiles.

Output directory: results/mirna_quant/edger_qc

  • [mature/hairpin]_counts.csv Raw read counts of reads aligned to mature miRNAs/miRNA precursors (hairpins), one row per sample
  • [mature/hairpin]_logtpm.{txt,csv} log10(CPM + 0.001) of reads aligned to mature miRNAs/miRNA precursors (hairpins), one row per sample. Despite the filename, these values are counts per million scaled by library size only: they are neither TMM- nor length-normalised (not TPM). CPM is appropriate here because each small RNA read represents one whole (~22 nt) mature miRNA molecule, so read counts do not scale with feature length. The filenames are kept for backwards compatibility.
  • [mature/hairpin]_normalized_CPM.txt TMM normalized counts per million (CPM, not log-transformed) of reads aligned to mature miRNAs/miRNA precursors (hairpins), one row per miRNA
  • [mature/hairpin]_edgeR_MDS_plot.pdf Multidimensional scaling plot of all samples based on the expression profile of mature miRNAs/miRNA precursors (hairpins)
  • [mature/hairpin]_CPM_heatmap.pdf Heatmap based on the expression profile of mature miRNAs/miRNA precursors (hairpins)
  • [mature/hairpin]_log2CPM_sample_distances_dendrogram.pdf Dendrograms of distance among samples based on the expression profile of mature miRNAs/miRNA precursors (hairpins)
  • [mature/hairpin]_log2CPM_sample_distances_heatmap.pdf Pairwise correlation of samples based on the expression profile of mature miRNAs/miRNA precursors (hairpins)

miRNAs are identified by name, not by miRBase accession. See miRNA identifiers for the table that maps names to accessions such as MIMAT0000062.

Example: MDS plot of 10 samples based on their expression profiles of mature miRNAs. Here we can see that samples cluster based on different sample types and library preparation kits. edgeR

Example: Heatmap of tumor and normal samples based on the top differentially expressed mature miRNAs. edgeR

mirtop

mirtop is used to parse the BAM files from bowtie alignment, and produce a mirgff3 file with information about miRNAs and isomirs.

Output directory: results/mirna_quant/mirtop (not created with --skip_mirtop)

  • gff/mirtop/{sample.id}_mirtop.gff: mirgff3 file

  • joined_samples_mirtop.tsv: a tabular version of the previous file for easy integration with downstream analysis.

  • export/{sample.id}_mirtop_rawData.tsv: File compatible with isomiRs Bioconductor package to perform isomiRs analysis.

  • mirna.tsv: tabular file with integer miRNA counts per sample, obtained by summarizing the isomiRs of each miRNA. It is derived from joined_samples_mirtop.tsv as follows:

    1. All rows with the same isomiR UID and miRNA are summed. The same sequence can appear in several rows of joined_samples_mirtop.tsv that differ only in precursor-dependent annotation columns (e.g. iso_3p_nt, iso_snp_nt), typically holding counts for different samples.
    2. An isomiR UID that is assigned to more than one miRNA (e.g. miRNAs with identical or overlapping mature sequences such as hsa-miR-365a-3p/hsa-miR-365b-3p, or hsa-miR-103a-3p/hsa-miR-107) is listed once per candidate miRNA in joined_samples_mirtop.tsv, with the same reads in each row. In mirna.tsv its reads are counted once and split between the candidate miRNAs, separately for each sample, in proportion to each candidate’s unambiguous counts in that sample (the sum of the isomiRs assigned only to that miRNA). If none of the candidates has unambiguous counts in that sample, the reads are split equally. For example, a shared isomiR with 12 reads in a sample where miR-A has 6 and miR-B has 2 unambiguous reads adds 9 reads to miR-A and 3 to miR-B. isomiRs assigned to a single miRNA are not affected.
    3. The isomiR counts are summed per miRNA and rounded to integers with the largest remainder method: in each sample, the fractional counts are rounded down and the remaining reads go to the miRNAs with the largest fractional parts (ties go to the miRNA listed first). Each count therefore differs by less than 1 from the exact proportional value, and the column total of each sample equals the number of reads assigned to isomiRs in that sample.

    Because shared isomiRs are counted only once, the column totals of mirna.tsv are lower than the sum of all counts in joined_samples_mirtop.tsv, which counts them once per candidate miRNA. A miRNA whose isomiRs are all shared with other miRNAs that have unambiguous counts can get 0 counts. Use joined_samples_mirtop.tsv if you want to handle ambiguous isomiRs differently.

miRNAs are identified by name, not by miRBase accession. See miRNA identifiers for the table that maps names to accessions such as MIMAT0000062.

miRNA identifiers

Output files
  • mirna_quant/
    • mirna_ids.tsv: Table of the miRNA names used in the edgeR and mirtop outputs, with their miRBase accessions and precursors.

The edgeR and mirtop count tables identify miRNAs by name, for example hsa-let-7a-5p (mature) or hsa-let-7a-1 (hairpin). They do not contain miRBase accessions (MIMAT… for mature miRNAs, MI… for hairpins). The names come from the reference files:

Output miRBase (default) MirGeneDB (--mirgenedb)
edger_qc/mature_* first word of the --mature FASTA headers, e.g. hsa-let-7a-5p --mirgenedb_mature (and --mirgenedb_star) FASTA headers, e.g. Hsa-Let-7-P1b_5p
edger_qc/hairpin_* first word of the --hairpin FASTA headers, e.g. hsa-let-7a-1 --mirgenedb_hairpin FASTA headers, e.g. Hsa-Let-7-P1b_pre
mirtop miRNA column (mirna.tsv, joined_samples_mirtop.tsv) Name attribute of the --mirna_gtf GFF3, e.g. hsa-let-7a-5p ID attribute of the --mirgenedb_gff, e.g. Hsa-Let-7-P1b_3p*
mirtop Parent attribute (gff/) hairpin name, e.g. hsa-let-7a-1 hairpin ID, e.g. Hsa-Let-7-P1b_pre

The pipeline keeps only the first word of each FASTA header, which is why the accession that follows the name in miRBase’s mature.fa and hairpin.fa (>hsa-let-7a-5p MIMAT0000062 Homo sapiens let-7a-5p) is not carried into the count tables.

mirna_ids.tsv maps these names to accessions. It is built from the GFF file used for the run (--mirna_gtf for miRBase, --mirgenedb_gff for MirGeneDB) and has one row per miRNA name and type:

Column Content
name Name as used in the edgeR and mirtop outputs
accession miRBase accession (MIMAT… for mature miRNAs, MI… for hairpins), from the GFF Alias attribute, or from the reference FASTA header for names that are not in the GFF. Empty if neither has one
type mature or hairpin
precursor For mature miRNAs, the hairpin(s) they come from, comma-separated. Empty for hairpins
precursor_accession Accessions of the hairpins in precursor, in the same order
database miRBase or MirGeneDB
source gff if the row comes from the GFF, fasta if the name is only in the FASTA files

For example:

name accession type precursor precursor_accession database source
hsa-let-7a-5p MIMAT0000062 mature hsa-let-7a-1,hsa-let-7a-2,hsa-let-7a-3 MI0000060,MI0000061,MI0000062 miRBase gff

Names that are in the FASTA files but not in the GFF are still listed, with source set to fasta. This happens when the GFF is from another release, when it covers only some of the species of the run (for example several --mirtrace_species with the GFF of one of them), or when no GFF is used at all (for example with --skip_mirtop). For these rows, the accession is read from the reference FASTA headers given to the pipeline (miRBase headers carry it, e.g. >hsa-let-7a-5p MIMAT0000062 Homo sapiens let-7a-5p), and the precursor and precursor_accession columns are empty. MirGeneDB FASTA headers have no accession, so accession is empty too.

To add accessions to a count table, join it with mirna_ids.tsv, for example in R:

ids <- read.delim("mirna_quant/mirna_ids.tsv", colClasses = "character")
mature_ids <- ids[ids$type == "mature", c("name", "accession")]
# mirtop: one row per miRNA, names in the "miRNA" column
counts <- read.delim("mirna_quant/mirtop/mirna.tsv", check.names = FALSE)
counts <- merge(mature_ids, counts, by.x = "name", by.y = "miRNA", all.y = TRUE)
# edgeR: one row per miRNA, names in the row names
cpm <- read.delim("mirna_quant/edger_qc/mature_normalized_CPM.txt", check.names = FALSE)
cpm$accession <- mature_ids$accession[match(rownames(cpm), mature_ids$name)]

Keep these points in mind:

  • Names change between miRBase releases (for example, hsa-miR-375 became hsa-miR-375-3p), while the accession (MIMAT0000728) stays the same. This makes accessions the safer key when you compare results across releases or pipeline runs. Use FASTA and GFF files from the same release: names that are only in the FASTA files are still listed in mirna_ids.tsv with the accession from the FASTA header, but without precursors.
  • The same mature miRNA can come from several hairpins. For example, hsa-miR-1-3p (MIMAT0000416) comes from both hsa-mir-1-1 and hsa-mir-1-2. Mature counts are per mature sequence, not per genomic locus. Hairpin-level counts are in edger_qc/hairpin_*.
  • MirGeneDB only lists a miRBase accession for miRNAs that are also in miRBase. MirGeneDB-only miRNAs have an empty accession.

MirGeneDB star arms

MirGeneDB names the star (less abundant) arm of a miRNA with a trailing *, for example Hsa-Mir-3613_3p*, both in its GFF and in its FASTA downloads. mirtop finds star arms through the hairpin FASTA and the GFF, so they are always in the mirtop outputs. The MirGeneDB ‘Mature sequences’ FASTA, however, only contains the dominant arms, and the star arms are a separate ‘Star sequences’ download. To also count star arms in the edgeR mature tables, under the same names as in mirtop, download the star FASTA for your species from MirGeneDB and pass it with --mirgenedb_star. The star sequences are then added to the --mirgenedb_mature reference. Reads that map to star arms are then handled like reads of the dominant arms: they are counted in the mature tables and are not passed on to the hairpin alignment. miRDeep2 also receives the star sequences as known mature miRNAs.

miRDeep2

miRDeep2 is used for the identification of novel and known miRNAs in deep sequencing data.

miRDeep2 runs only when a genome FASTA is given (--fasta or --genome), and can be turned off with --skip_mirdeep.

Output directory: results/mirdeep2

  • mirdeep2/result_{sample.id}.bed File with the known and novel miRNAs in bed format.
  • mirdeep2/result_{sample.id}.csv File with an overview of all detected miRNAs (known and novel) in csv format.
  • mirdeep2/result_{sample.id}.html A HTML report with an overview of all detected miRNAs (known and novel) in html format.
  • mirdeep2/pdfs_{sample.id}/ Only if you turn the PDFs on (see below): one PDF per miRNA, with its hairpin structure and the reads on it. The HTML report links to these files, so keep the folder next to the report.
  • mirdeep2/mirdeep2_consensus.bed and mirdeep2/mirdeep2_consensus.tsv (only with --mirdeep2_consensus_min_samples of 1 or more): Cross-sample consensus of the per-sample BED files, see below.

miRDeep2 runs on each sample separately. The only files that combine samples are the optional cross-sample consensus files. See the usage documentation for the inputs and options of miRDeep2.

How to read the results:

  • The CSV file is tab-separated, even though its extension is .csv. It has these parts:
    • A table of score cut-offs. For each miRDeep2 score, it lists the number of novel miRNAs reported, the estimated false and true positives among them, the number of known miRNAs detected, and the estimated signal-to-noise ratio. Use this table to choose a score cut-off for novel miRNAs.
    • novel miRNAs predicted by miRDeep2: candidate precursors that do not match a known hairpin.
    • mature miRBase miRNAs detected by miRDeep2: known miRNAs that miRDeep2 also finds in the data.
    • #miRBase miRNAs not detected by miRDeep2: known miRNAs with reads in the sample that miRDeep2 does not report as precursors.
  • Important columns of the novel and detected tables:
    • miRDeep2 score: higher is more likely to be a real miRNA.
    • estimated probability that the miRNA candidate is a true positive: for a candidate with this score or higher.
    • rfam alert: the hairpin is similar to an rRNA or tRNA. The miRDeep2 authors advise that this warning should overrule the probability.
    • total read count, mature read count, loop read count and star read count: the reads on each part of the precursor.
    • significant randfold p-value: whether the hairpin folds more stably than shuffled sequences.
    • example miRBase miRNA with the same seed: a known miRNA with the same seed, if one exists.
    • consensus mature sequence, consensus star sequence and consensus precursor sequence: the sequences of the candidate.
    • precursor coordinate: the genome position as chromosome:start..end:strand.
  • The BED file holds the novel and detected known miRNAs from the CSV. Column 4 is novel:<provisional id> or known:<provisional id> and column 5 is the miRDeep2 score. The colour is red for the + strand and blue for the - strand. Scores and provisional IDs are specific to each sample, so you cannot compare them between samples directly. To get one set of loci for all samples, use the cross-sample consensus.
  • The HTML report shows the same tables. The ID in its first column links to the structure PDF of that miRNA in pdfs_{sample.id}/. By default, the pipeline runs miRDeep2 with -d, which skips the PDFs, so these links do not work. The PDFs are about 0.3 MB each, and there is one for every reported miRNA and every known miRNA with reads, which can add up to hundreds of MB per sample. To get them, leave out -d as described in the usage documentation.
  • Novel miRNAs are not added to the miRNA count tables. See the usage documentation for how to count them in all samples.

Cross-sample consensus of miRDeep2 loci

With --mirdeep2_consensus_min_samples of 1 or more, the loci of the per-sample miRDeep2 BED files are combined across samples. With --mirdeep2_consensus_min_probability, entries with a lower estimated true-positive probability, or without one, are removed from each sample first. Loci that overlap by at least one base on the same strand are then merged into one locus that spans them. Loci that only touch (one ends where the next starts) or that are on opposite strands are not merged. Loci found in fewer than --mirdeep2_consensus_min_samples samples are removed. Coordinates are taken from the miRDeep2 BED files unchanged. Two files are written, with one line per locus in the same order:

  • mirdeep2/mirdeep2_consensus.bed: a standard six-column BED file without a header, which can be loaded in a genome browser or used with tools such as BEDTools. The columns are chrom, start, end, name, score and strand. The name is known:consensus_<n> if any sample reported a known miRBase miRNA at the locus, otherwise novel:consensus_<n>. The score is the number of samples that support the locus (at most 1000, the highest score that BED allows), not the miRDeep2 score. The file is empty if no locus is left.
  • mirdeep2/mirdeep2_consensus.tsv: a tab-separated table with a header line and the support of each locus. The name column links it to the BED file. The columns are:
    • name, chrom, start, end, strand: as in the BED file.
    • n_samples: number of samples that reported the locus.
    • samples: comma-separated list of these samples.
    • score: highest miRDeep2 score across the samples.
    • probability: highest estimated true-positive probability in percent across the samples, or - if miRDeep2 gave none (this only occurs without --mirdeep2_consensus_min_probability).
    • mirdeep2_ids: the per-sample miRDeep2 IDs as <sample>:<known|novel>:<id>, which link back to the result_{sample.id}.csv files.

miRTrace

miRTrace is a quality control specifically for small RNA sequencing data (smRNA-Seq). Each sample is characterized by profiling sequencing quality, read length, sequencing depth and miRNA complexity and also the amounts of miRNAs versus undesirable sequences (derived from tRNAs, rRNAs and sequencing artifacts). By default, the pipeline sets the PHRED offset to the most common value of +33, so if you need to adjust this, use the params.phred_offset option to include this accordingly for your FASTQ files. miRTrace is run on the raw (untrimmed, but concatenated if needed) reads, because it performs its own adapter removal (using --three_prime_adapter) and quality and length filtering. The QC-passed reads it writes are named after the sample, for example qc_passed_reads.all.collapsed/<sample>.fasta.

Output directory: results/mirtrace/${sample.id}

  • mirtrace-report.html An interactive HTML report summarizing all output statistics from miRTrace
  • mirtrace-results.json A JSON file with all output statistics from miRTrace
  • mirtrace-stats-*.tsv Tab-separated statistics files
  • qc_passed_reads.all.collapsed FASTA file per sample with sequence reads that passed QC in miRTrace
  • qc_passed_reads.rnatype_unknown.collapsed FASTA file per sample with unknown reads in the RNA type analysis

The files for each sample can also be visualized into a single plot in the MultiQC report. Refer to the tool manual for detailed specifications about output files. Here is an example of the RNA types plot that you will see:

mirtrace

MultiQC

MultiQC - FastQC adapter content plot

Note

The FastQC plots displayed in the MultiQC report shows untrimmed reads. They may contain adapter sequence and potentially regions with low quality.

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. The report also has a methods description: suggested text for the methods section of a publication, with citations and a bibliography for the tools that ran (read from the modules’ meta.yml files). For more information about how to use MultiQC reports, see http://multiqc.info.

Note

There may be a discrepancy in read counts number displayed in MultiQC between the original FASTQ and BAM files, this is due to secondary alignments being reported by the aligner, which can inflate the total read count number in the BAM files. More info about this behavior can be found here.

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 nf_core_smrnaseq_software_mqc_versions.yml. The pipeline_report* files will only be present if the --email / --email_on_fail parameters are used when running the pipeline.
    • The software versions file also lists the miRNA reference database under MIRNA_REFERENCE, e.g. miRBase: v22 or MirGeneDB: v2.0 and genome_build: GRCh38. These values come from the # microRNAs: and # genome-build-id: header lines of the miRNA GFF3 (--mirna_gtf, --mirgenedb_gff or the GFF3 downloaded for --mirtrace_species). If the GFF3 has no such header, the entry reads mirna_gff: unknown (<file name>). When reading this header, the pipeline also checks the file. A GFF that is an HTML page (e.g. <p>##gff-version 3<br>... from the miRBase website) stops the run with an error. A file that does not start with ##gff-version only gives a warning. Gzipped files are decompressed for these checks. The --mature/--hairpin FASTA files carry no version information, so make sure they come from the same database release as the GFF3.
    • If no miRNA GFF3 is used (e.g. when mirtop is skipped), MIRNA_REFERENCE instead lists the database (miRBase or MirGeneDB) and the names of the mature and hairpin FASTA files, e.g. miRBase: unknown (no GFF), mature: mature.fa, hairpin: hairpin.fa. The version is only known in this case if the directory of the mature or hairpin file is a release number (e.g. .../22.1/mature.fa gives v22.1 (from file path)). A missing GFF3 never stops the run.
    • Parameters used by the pipeline run: params_<timestamp>.json.
    • Provenance report written by nf-prov: manifest_<timestamp>.bco.json, a BioCompute Object describing the run, its parameters, inputs and published outputs.
    • Energy use and CO₂-equivalent estimates written by nf-co2footprint: co2footprint_report_<timestamp>.html (report with plots), co2footprint_summary_<timestamp>.txt (totals for the run), co2footprint_trace_<timestamp>.txt (per task) and co2footprint_provenance_<timestamp>.json (the inputs used for the estimate). See CO₂ footprint estimates for how to make them match your location.

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.