Skip to content

Commit

Permalink
Merge pull request #413 from nf-core/remove_harsh_trimming
Browse files Browse the repository at this point in the history
remove harsh trimming option --trim
  • Loading branch information
rannick authored Oct 2, 2023
2 parents 9d5c410 + 94966e5 commit c64830c
Show file tree
Hide file tree
Showing 7 changed files with 5 additions and 128 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

### Removed

- Remove harsh trimming option `--trim` [#413](https://github.com/nf-core/rnafusion/pull/413)

## v2.4.0 - [2023/09/22]

### Added
Expand Down
19 changes: 2 additions & 17 deletions docs/usage.md
Original file line number Diff line number Diff line change
Expand Up @@ -184,10 +184,7 @@ You can also generate such `YAML`/`JSON` files via [nf-core/launch](https://nf-c

#### Trimming

There are 2 options to trim

1. Fastp
In this case all tools use the trimmed reads. Quality and adapter trimming by default. In addition, tail trimming and adapter_fastq specification are possible. Example usage:
When the flag `--fastp_trim` is used, `fastp` is used to provide all tools with trimmed reads. Quality and adapter trimming by default. In addition, tail trimming and adapter_fastq specification are possible. Example usage:

```bash
nextflow run nf-core/rnafusion \
Expand All @@ -200,19 +197,7 @@ nextflow run nf-core/rnafusion \
--adapter_fastq <PATH/TO/ADAPTER/FASTQ> (optional)
```

2. Hard trimming
In this case, only reads fed to fusioncatcher are trimmed. This is a harsh workaround in case of high read-through. The recommended trimming is thus the fastp_trim one. The trimming is done at 75 bp from the tails. Example usage:

```bash
nextflow run nf-core/rnafusion \
--<tool1> --<tool2> ... \
--input <SAMPLE_SHEET.CSV> \
--genomes_base <PATH/TO/REFERENCES> \
--outdir <OUTPUT/PATH> \
--trim
```

#### Filter out fusions detected by less than INT tools
#### Filter fusions detected by 2 or more tools

```bash
nextflow run nf-core/rnafusion \
Expand Down
53 changes: 0 additions & 53 deletions modules/local/reformat/main.nf

This file was deleted.

40 changes: 0 additions & 40 deletions modules/local/reformat/meta.yml

This file was deleted.

1 change: 0 additions & 1 deletion nextflow.config
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ params {
tools_cutoff = 1

// Trimming
trim = false
fastp_trim = false
trim_tail = null
adapter_fasta = []
Expand Down
5 changes: 0 additions & 5 deletions nextflow_schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -267,11 +267,6 @@
"fa_icon": "fas fa-cut",
"description": "Options to adjust read trimming criteria.",
"properties": {
"trim": {
"type": "boolean",
"description": "Preform trimming of reads, default: false",
"fa_icon": "fas fa-cut"
},
"fastp_trim": {
"type": "boolean",
"description": "Preform fastp trimming of reads, default: false",
Expand Down
13 changes: 1 addition & 12 deletions subworkflows/local/trim_workflow.nf
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
include { REFORMAT } from '../../modules/local/reformat/main'
include { FASTQC as FASTQC_FOR_TRIM } from '../../modules/nf-core/fastqc/main'
include { FASTP } from '../../modules/nf-core/fastp/main'
include { FASTQC as FASTQC_FOR_FASTP } from '../../modules/nf-core/fastqc/main'
Expand All @@ -11,17 +10,7 @@ workflow TRIM_WORKFLOW {
main:
ch_versions = Channel.empty()

if (params.trim) {

REFORMAT( reads )
ch_versions = ch_versions.mix(REFORMAT.out.versions)
FASTQC_FOR_TRIM (REFORMAT.out.reads_out)
ch_versions = ch_versions.mix(FASTQC_FOR_TRIM.out.versions)

ch_reads_all = reads
ch_reads_fusioncatcher = REFORMAT.out.reads_out
}
else if (params.fastp_trim) {
if (params.fastp_trim) {
FASTP(reads, params.adapter_fasta, false, false)
ch_versions = ch_versions.mix(FASTP.out.versions)

Expand Down

0 comments on commit c64830c

Please sign in to comment.