Skip to content

Commit 91d7d26

Browse files
committed
Tweak to only use BAM files with --skip_alignment
1 parent 818d79d commit 91d7d26

File tree

3 files changed

+7
-5
lines changed

3 files changed

+7
-5
lines changed

docs/output.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ nextflow run nf-core/rnaseq -profile test_full,<docker/singularity/institute>
1111
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.
1212

1313
:::tip
14-
Many of the BAM files produced by this pipeline can be reused as input for future runs. This is particularly useful for reprocessing data or running downstream analysis steps without repeating computationally expensive alignment. See the [usage documentation](https://nf-co.re/rnaseq/usage#using-bam-files-as-input) for details on using BAM files as input.
14+
Many of the BAM files produced by this pipeline can be reused as input for future runs with `--skip_alignment`. This is particularly useful for reprocessing data or running downstream analysis steps without repeating computationally expensive alignment. See the [usage documentation](https://nf-co.re/rnaseq/usage#bam-input-for-reprocessing-workflow) for details on using BAM files as input.
1515
:::
1616

1717
## Pipeline overview
@@ -869,7 +869,7 @@ A number of genome-specific files are generated by the pipeline because they are
869869
- Reformatted samplesheet files used as input to the pipeline: `samplesheet.valid.csv`.
870870
- Parameters used by the pipeline run: `params.json`.
871871
- `samplesheets/`
872-
- `samplesheet_with_bams.csv`: **Auto-generated complete samplesheet** (only created when using `--save_align_intermeds`) containing all samples with BAM file paths. For samples processed from FASTQ, includes paths to newly generated BAMs; for samples that were BAM input, preserves the original input paths. This comprehensive samplesheet can be used directly for future pipeline runs, enabling efficient reprocessing without re-alignment.
872+
- `samplesheet_with_bams.csv`: **Auto-generated samplesheet for BAM reprocessing** (only created when using `--save_align_intermeds`) containing all samples with BAM file paths. For samples processed from FASTQ, includes paths to newly generated BAMs; for samples that were BAM input, preserves the original input paths. This samplesheet can be used directly for future pipeline runs with `--skip_alignment`, enabling efficient reprocessing without re-alignment.
873873

874874
</details>
875875

docs/usage.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ nextflow run nf-core/rnaseq \
136136
-profile docker
137137
```
138138

139-
The pipeline will skip alignment and indexing steps, putting the BAM files through post-processing and quantification only.
139+
The `--skip_alignment` flag tells the pipeline to skip alignment, and in this situation it will use any provided BAM files instead of performing alignment, putting them through post-processing and quantification only.
140140

141141
#### Example of generated samplesheet
142142

@@ -156,9 +156,11 @@ SAMPLE2,/path/sample2_R1.fastq.gz,,reverse,results/star_salmon/SAMPLE2.sorted.ba
156156
157157
**Key technical details:**
158158

159+
- BAM files are only used when `--skip_alignment` is specified
159160
- The pipeline automatically indexes provided BAM files
160161
- You can provide just `genome_bam`, just `transcriptome_bam`, or both
161-
- Mixed samplesheets (some samples with FASTQ, others with BAM) are supported
162+
- Mixed samplesheets are supported, but samples with BAM files require `--skip_alignment`
163+
- Without `--skip_alignment`, the pipeline will perform alignment even if BAM files are provided
162164
- For BAM file locations from pipeline outputs, see the [output documentation](https://nf-co.re/rnaseq/output)
163165

164166
This workflow is ideal for tweaking downstream processing steps (quantification methods, QC parameters, differential expression analysis) without repeating time-consuming alignment.

workflows/rnaseq/main.nf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ workflow RNASEQ {
125125
}
126126
.branch {
127127
meta, reads, genome_bam, transcriptome_bam ->
128-
bam: genome_bam || transcriptome_bam
128+
bam: params.skip_alignment && (genome_bam || transcriptome_bam)
129129
return [ meta, genome_bam, transcriptome_bam ]
130130
fastq: reads.size() > 0 && reads[0]
131131
return [ meta.findAll {it.key != 'percent_mapped'}, reads ]

0 commit comments

Comments
 (0)