From b15fcbe359759b66005903dd74cf1ee64ad9d1ab Mon Sep 17 00:00:00 2001 From: Tim Van Baak Date: Wed, 21 Nov 2018 11:42:39 -0800 Subject: [PATCH] Add undercited articles statistic --- src/build.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/build.py b/src/build.py index 8408c21..758ef38 100644 --- a/src/build.py +++ b/src/build.py @@ -270,6 +270,14 @@ def build_statistics_page(page, articles): content += "
\n".join(bot_ranked_items) content += "\n" + # Undercited articles + undercited = {a.title: len(a.citedby) for a in articles if len(a.citedby) <= 1} + undercited_items = itemize(reverse_statistics_dict(undercited)) + content += "
\n" + content += "Undercited articles:
\n" + content += "
\n".join(undercited_items) + content += "
\n" + # Fill in the entry skeleton return page.format(title="Statistics", content=content)