Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Properly name percentiles in sequence length distribution #198

Merged
merged 1 commit into from
Oct 4, 2024
Merged
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
2 changes: 2 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ Changelog

version 0.12.0-dev
------------------
+ Properly name percentiles as such in the sequence length distribution rather
than using N50 nomenclature which is not correct.
+ Fix a bug where BAM files with missing quality sequences were inproperly
handled.
+ Update internal UniVec database to version from November 21st 2023.
Expand Down
19 changes: 10 additions & 9 deletions src/sequali/report_modules.py
Original file line number Diff line number Diff line change
Expand Up @@ -499,15 +499,16 @@ def distribution_table(self):
return ""
return f"""
<table>
<tr><td>N1</td><td style="text-align:right;">{self.q1:,}</td></tr>
<tr><td>N5</td><td style="text-align:right;">{self.q5:,}</td></tr>
<tr><td>N10</td><td style="text-align:right;">{self.q10:,}</td></tr>
<tr><td>N25</td><td style="text-align:right;">{self.q25:,}</td></tr>
<tr><td>N50</td><td style="text-align:right;">{self.q50:,}</td></tr>
<tr><td>N75</td><td style="text-align:right;">{self.q75:,}</td></tr>
<tr><td>N90</td><td style="text-align:right;">{self.q90:,}</td></tr>
<tr><td>N95</td><td style="text-align:right;">{self.q95:,}</td></tr>
<tr><td>N99</td><td style="text-align:right;">{self.q99:,}</td></tr>
<tr><th>Percentile</th><th>Read length</th></tr>
<tr><td>1</td><td style="text-align:right;">{self.q1:,}</td></tr>
<tr><td>5</td><td style="text-align:right;">{self.q5:,}</td></tr>
<tr><td>10</td><td style="text-align:right;">{self.q10:,}</td></tr>
<tr><td>25</td><td style="text-align:right;">{self.q25:,}</td></tr>
<tr><td>50</td><td style="text-align:right;">{self.q50:,}</td></tr>
<tr><td>75</td><td style="text-align:right;">{self.q75:,}</td></tr>
<tr><td>90</td><td style="text-align:right;">{self.q90:,}</td></tr>
<tr><td>95</td><td style="text-align:right;">{self.q95:,}</td></tr>
<tr><td>99</td><td style="text-align:right;">{self.q99:,}</td></tr>
</table>
"""

Expand Down
Loading