handle a.c. wits properly in location analysis
[scpubgit/stemmatology.git] / stemmaweb / root / src / stexaminer.tt
CommitLineData
23306161 1[% WRAPPER header.tt
cf9626aa 2 pagetitle = "Stexaminer - $text_title"
57acbbe2 3 applicationjs = c.uri_for('/js/stexaminer.js')
4 applicationstyle = c.uri_for('/css/stexaminer.css')
cf9626aa 5%]
23306161 6<script type="text/javascript">
7var readingstats = [% reading_statistics %];
23306161 8</script>
9[% END -%]
cf9626aa 10 <h1>Stexaminer</h1>
11 <h2>[% text_title %]</h2>
cf9626aa 12 <div id="variants_table">
13 <table>
14[% FOREACH row IN variants -%]
15[% INCLUDE variantrow %]
16[% END -%]
17 </table>
18 </div>
deeeeaad 19 <div id="stemma_graph">
20 [% svg %]
21 </div>
23306161 22 <div id="row_statistics">
23 <h3>Aggregate text statistics</h3>
24 <ul>
25 <li>Total number of variant locations analyzed: [% total %]</li>
26 <li>Number of fully genealogical locations: [% genealogical %]</li>
27 <li>Number of readings that conflict with the stemma: [% conflict %]</li>
3751a3c2 28 <li>Genealogical reading transitions by relationship type: [% todo %]</li>
23306161 29 </ul>
30 <p>(Choose a row in the table to display statistics about individual readings.)</p>
31 </div>
3751a3c2 32
33 <div id="stats_template" class="template">
34 <h3>Statistics for readings at <span id="statrank"></span>:</h3>
35 <!-- reading_template will be appended here for each reading -->
36 </div>
37
38 <div id="reading_template" class="template">
39 <div class="reading_statistics">
40 <span class="readinglabel"></span> - copied <span class="reading_copied"></span> times, changed <span class="reading_changed"></span> times<br/>
41 Reading root(s) at <span class="readingroots"></span><br/>
42 <!-- reading_parent_template will be appended here if there are parents -->
43 </div>
23306161 44 </div>
3751a3c2 45
46 <div id="reading_parent_template" class="template">
47 <div class="parent_statistics">
48 Reading parent(s):
49 <ul class="reading_parent_list"></ul>
50 </div>
51 </div>
23306161 52
cf9626aa 53[% PROCESS footer.tt %]
54
6b70c348 55
56[% BLOCK variantrow -%]
57[% SET rowclass = 'class="genealogical"' IF row.genealogical -%]
58[% SET rowclass = 'class="coincidental"' UNLESS row.genealogical -%]
59 <tr [% rowclass %]>
23306161 60 <th><span class="rowid" onclick="color_row($(this));show_stats($(this).parent().parent().index())">[% row.id %]</span></th>
6b70c348 61[% FOREACH reading IN row.readings -%]
62[% SET cellclass = 'clickable conflict' IF reading.conflict -%]
63[% SET cellclass = 'clickable' IF !reading.conflict -%]
a44aaf2a 64 <td class="[% cellclass %]"><span onclick="color_nodes($(this).parent().index(), [% reading.group %], [% row.missing %]);$(this).parents('tr').addClass('active_variant_row');$(this).parent().addClass('active_variant_cell cellb'+($(this).parent().index()-1))">[% reading.text %]</span></td>
6b70c348 65[% END -%]
66[% FILTER repeat( row.empty ) -%]
67 <td/>
68[% END -%]
69 </tr>
70[% END -%]