]> git.donarmstrong.com Git - neurodebian.git/blobdiff - survey/makestats
Various fixes and additions based on current submissions.
[neurodebian.git] / survey / makestats
index a15b5f7dca214304306e0a7385098508dc7d81f5..af91aa19b2ee7e35aa6da04228df9f09f01d5d7c 100755 (executable)
@@ -44,7 +44,7 @@ resource_categories = {
     'pypi': 'PyPi',
     'pythonbundles': 'Python bundles',
     'sourceforge': 'Sourceforge',
-    'other': 'Other resource'
+    'otherres': 'Other resource'
     }
 # software categories
 sw_categories = {
@@ -65,7 +65,7 @@ redhat_family = ["rhel", "centos", "fedora", "scilinux"]
 debian_family = ["debian", "ubuntu", "biolinux"]
 suse_family = ["suse", "slel"]
 other_linux_family = ["gentoo", "mandriva", "arch", "slackware", "otherlinux"]
-other_family = ["starbsd", "unix", "qnx", "beos", "solaris", "other"]
+other_family = ["starbsd", "unix", "qnx", "beos", "solaris", "other", "dontknow"]
 
 os_cat_names = {
         'win': 'Windows',
@@ -213,7 +213,7 @@ def mkpic_os_per_env(db, destdir):
         pl.barh(x, stat, left=bottoms, color=os_colors[i],
                label=db.get_nice_name(os), height=0.8)
         bottoms += stat
-    pl.legend(loc='lower left')
+    pl.legend(loc='center left')
     pl.yticks(x + 0.4,  env_names[::-1])
     pl.ylim(-0.25, len(envs))
     pl.title("Operating system preference by environment")
@@ -293,7 +293,7 @@ def mkpic_software(db, destdir):
         mkpic_submissions_per_key(
             db, destdir, 'sw_%s' % typ,
             title="Software popularity: %s" % db.get_nice_name(typ),
-            sortby='name')
+            sortby='count')
 
 def mkpic_rating_by_os(db, env, items, destdir, title):
     pl.figure(figsize=(6.4, 4.8))
@@ -405,7 +405,7 @@ def main(srcdir, destdir):
         os.makedirs(destdir)
 
     mkpic_submissions_per_key(
-        db, destdir, 'virt_prod', sortby='name',
+        db, destdir, 'virt_prod', sortby='count',
         title='Virtualization product popularity\n(multiple choices per submission possible)')
 
     mkpic_submissions_per_key(
@@ -430,7 +430,7 @@ def main(srcdir, destdir):
                        "Personal environment", "I prefer this particular scientific software environment because ...")
     mkpic_rating_by_os_hor_joined(db, 'man_os', ['man_r%i' % i for i in range(1, 5)], destdir,
                        "Managed environment")
-    mkpic_rating_by_os_hor_joined(db, 'virt_host_os', ['man_r%i' % i for i in range(1, 4)], destdir,
+    mkpic_rating_by_os_hor_joined(db, 'virt_host_os', ['virt_r%i' % i for i in range(1, 4)], destdir,
                        "Virtual environment (by host OS)")
 
     # submission stats: this is RST