10 | | # Reads: | {{mini_summary_d['n_reads']}} |
11 | {% if mini_summary_d['uniqmapped_pct'] == 'N/A' %}
12 | | % of uniquely mapped reads: | N/A |
13 | | % of multi-mapped reads: | N/A |
14 | | % of unmapped reads: | N/A |
15 | | % of filtered reads mapping to genome: | N/A |
16 | {% else %}
17 | | % of uniquely mapped reads: | {{'%.2f%%' % mini_summary_d['uniqmapped_pct']}} |
18 | | % of multi-mapped reads: | {{'%.2f%%' % mini_summary_d['multimapped_pct']}} |
19 | | % of unmapped reads: | {{'%.2f%%' % mini_summary_d['unmapped_pct']}} |
20 | | % of filtered reads mapping to genome: | {{'%.2f%%' % mini_summary_d['genomic_read_pct']}} |
21 | {% endif %}
22 | | Sequencing saturation rate: | {{'%.2f%%' % mini_summary_d['seq_sat_rate']}} |
23 | |   |
24 | | # Cells: | {{'%d' % mini_summary_d['n_cells']}} |
25 | | Median molecules per cell: | {{'%d' % mini_summary_d['med_molcs_per_cell']}} |
26 | | Average reads per cell: | {{'%d' % mini_summary_d['avg_reads_per_cell']}} |
27 | | Average reads per molecule: | {{'%.2f' % mini_summary_d['avg_reads_per_molc']}} |
28 | {% if 'mt_rna_fraction' in mini_summary_d %}
29 | | % of cells filtered by high mt-RNA content: | {{'%.2f%%' % mini_summary_d['mt_rna_fraction']}} |
30 | {% endif %}
31 |
32 |
33 |
6 | {% for name, c in section.content.items() %}
7 |
8 |
{{name}}
9 |
10 | {% if c.keys is defined %}
11 |
12 | {% for k in c.keys %}
13 | {{k}}
14 | {% endfor %}
15 |
16 |
17 | {% for v in c.values %}
18 | {{v}}
19 | {% endfor %}
20 |
21 | {% elif c.text is defined %}
22 |
23 | {{c.text}}
24 |
25 | {% elif c.image is defined %}
26 |
27 |

28 |
29 |
30 | {{c.legend}}
31 |
32 | {% endif %}
33 |
34 | {% endfor %}
35 |
36 | {% endblock %}
--------------------------------------------------------------------------------
/src/seqc/summary/test.py:
--------------------------------------------------------------------------------
1 | import nose2
2 | import unittest
3 | from seqc.summary import summary
4 | from collections import OrderedDict
5 |
6 |
7 | class TestSummary(unittest.TestCase):
8 |
9 | def test_render_section(self):
10 | s1 = summary.Section.from_alignment_summary(
11 | '/var/folders/y3/ysxvl2w921d881nfpvx5ypvh0000gn/T/seqc/test_no_aws_in_drop_v2'
12 | '/alignment_summary.txt')
13 | s1.render('./src/seqc/summary/test_summary.html')
14 |
15 | if __name__ == "__main__":
16 | nose2.main()
17 |
--------------------------------------------------------------------------------
/src/seqc/version.py:
--------------------------------------------------------------------------------
1 | __version__ = "0.2.0"
2 |
--------------------------------------------------------------------------------