Commit aa630b17 authored by Floreal Cabanettes's avatar Floreal Cabanettes
Browse files

Start working on summary

parent 5c7c754f
......@@ -502,3 +502,18 @@ class Paf:
if c_name in contigs_list:
contigs_list.remove(c_name)
return "\n".join(contigs_list) + "\n"
def get_summary_stats(self):
"""
Get summary of identity
:return: table with percents by category
"""
self.parse_paf(False, False)
percents = {}
total = 0
for cat in self.lines:
nb_lines = len(self.lines[cat])
percents[cat] = nb_lines
total += nb_lines
for cat in self.lines:
percents[cat] /= total
......@@ -414,6 +414,11 @@ def no_assoc(id_res):
abort(404)
@app.route('/summary/<id_res>', methods=['POST'])
def summary(id_res):
pass
@app.route("/ask-upload", methods=['POST'])
def ask_upload():
try:
......
......@@ -68,6 +68,7 @@
<input type="range" min="0" max="5" value="2" step="1" id="chroms-limits"/></label></p>
<p><input type="button" id="sort-contigs" value="Sort contigs"/></p>
<p><input type="button" id="hide-noise" value="Hide noise"/></p>
<p><input type="button" id="summary" value="Summary"/></p>
</form>
</div>
</div>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment