Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,12 @@
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [3.2.3] - 2025-08-22

### Fixes
- Fixed logic error in linear deduplication where the reads with the lowest MAPQ were kept instead.


## [3.2.2] - 2024-02-01

### Enhancements
Expand Down
6 changes: 3 additions & 3 deletions bin/find_unique_reads.py
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@
alignments[unique_id] = [row[3], row[4]]

# If ID already exists, check whether mapping quality is better
elif alignments[unique_id][1] > row[4]:
elif alignments[unique_id][1] < row[4]:
alignments[unique_id] = [row[3], row[4]]

# Increase counter
Expand All @@ -98,12 +98,12 @@
alignments = [i[1][0][:-2] for i in alignments.items()]

# Line to be saved in MultiQC file
mqc_line = f"LA duplicates removed (%)\t{round((i-len(alignments))/i*100, 2)}"
mqc_line = f"LA duplicates removed (%)\t{round((i - len(alignments)) / i * 100, 2) if i > 0 else 'NA'}"

# Collect metrics into a string
report = "LINEAR AMPLIFICATION DUPLICATION METRICS"
report += f"\nReads before filtering\t{i}"
report += f"\nLA duplicates removed (n)\t{i-len(alignments)}"
report += f"\nLA duplicates removed (n)\t{i - len(alignments)}"
report += "\n" + mqc_line
report += f"\nUnique reads after LA duplicate removal\t{len(alignments)}"

Expand Down
2 changes: 1 addition & 1 deletion nextflow.config
Original file line number Diff line number Diff line change
Expand Up @@ -338,7 +338,7 @@ manifest {
description = """Analysis pipeline for CUT&RUN and CUT&TAG experiments that includes sequencing QC, spike-in normalisation, IgG control normalisation, peak calling and downstream peak analysis."""
mainScript = 'main.nf'
nextflowVersion = '!>=23.04.0'
version = '3.2.2'
version = '3.2.3'
doi = 'https://doi.org/10.5281/zenodo.5653535'
}

Expand Down
Loading