File:IPhO-2015 average scores by country.svg

Summary

Description
English: Unofficial bar diagram of average student marks by country at the 46. International Physics Olympiad 2015 in Mumbai, India. Only the 50 best performing teams out of 83 are shown. The cutoff marks were 42.2 for gold, 33 for silver, 24 for bronze and 18 for a honourable mention (out of 50).
Date
Source Own work, http://www.ipho2015.in/ipho2015/results
Author Geek1337
SVG development
InfoField
Source code
InfoField

Python code

# -*- coding: utf-8 -*-
import matplotlib.pyplot as plt
from scipy import array, interpolate

# Average score of students at the IPhO 2015 by country, out of 50 points maximum
averages = [
['China', 46.86], ['Korea', 45.86], ['Taiwan', 44.42], ['USA', 43.58], ['Russia', 43.52],
['Hong Kong', 42.18], ['Singapore', 41.82], ['Iran', 41.5], ['Vietnam', 41.44], ['Thailand', 39.26],
['Romania', 39.1], ['Hungary', 36.38], ['India', 35.7], ['Indonesia', 34.14], ['Ukraine', 33.98],
['Japan', 33.64], ['Germany', 33.62], ['Armenia', 32.78], ['Israel', 32.42], ['Belarus', 31.88],
['Bulgaria', 31.66], ['Czech Republic', 31.54], ['Turkey', 31.52], ['United Kingdom', 31.14], ['France', 31.02],
['Italy', 30.5], ['Poland', 30.44], ['Cuba', 28.4], ['Australia', 27.06], ['Canada', 26.9],
['Slovakia', 26.86], ['Slovenia', 26.6], ['Estonia', 26.1], ['Kazakhstan', 25.8], ['Serbia', 24.9],
['Finland', 24.7], ['Bosnia and Herzegovina', 23.8], ['Brazil', 23.78], ['Croatia', 23.1], ['Lithuania', 22.5], ['Switzerland', 22.06], ['Netherlands', 21.94], ['Spain', 21.7], ['Puerto Rico', 20.2], ['Moldova', 20],
['Belgium', 19.9], ['Austria', 18.9], ['Portugal', 18.4], ['Macao', 18.3], ['Saudi Arabia', 18.3]
# ranks 51 to 83 not listed.
]

colors = array([(1,1,1), (.4,.6,1), (.87,.54,.25), (.7,.7,.7), (1,.8,0)])
cutoffs = array([0, 18, 24, 33, 42.2])
colorfun = interpolate.interp1d(cutoffs, colors.T,
    bounds_error=False, fill_value=tuple(colors[[0,-1]]))
bcolors = [colorfun(d[1]) for d in averages]

fig = plt.figure(figsize=(720 / 90.0, 480 / 90.0), dpi=72)
ax = plt.gca()

bars = plt.bar(range(1, len(averages)+1), [d[1] for d in averages],
               edgecolor='k', color=bcolors)

for i, bar in enumerate(bars):
    ax.annotate(averages[i][0],
                xy=(bar.get_x() + bar.get_width() * 0.65, bar.get_height()),
                xytext=(0, 5),
                textcoords="offset points",
                ha='center', va='bottom', rotation='vertical')

plt.xlim(0.3, 50.7)
plt.ylim(0, 50)
plt.xticks([1] + list(range(5, 51, 5)))
plt.xlabel('country')
plt.ylabel('student average score')
plt.title('46. IPhO 2015 results by country')
plt.tight_layout()
plt.savefig('IPhO-2015_average_scores_by_country.svg')

Licensing

I, the copyright holder of this work, hereby publish it under the following license:
w:en:Creative Commons
attribution share alike
This file is licensed under the Creative Commons Attribution-Share Alike 4.0 International license.
You are free:
  • to share – to copy, distribute and transmit the work
  • to remix – to adapt the work
Under the following conditions:
  • attribution – You must give appropriate credit, provide a link to the license, and indicate if changes were made. You may do so in any reasonable manner, but not in any way that suggests the licensor endorses you or your use.
  • share alike – If you remix, transform, or build upon the material, you must distribute your contributions under the same or compatible license as the original.
Category:CC-BY-SA-4.0#IPhO-2015%20average%20scores%20by%20country.svg
Category:Self-published work
Category:International Physics Olympiad Category:SVG bar charts
Category:CC-BY-SA-4.0 Category:International Physics Olympiad Category:SVG bar charts Category:Self-published work Category:Valid SVG created with Matplotlib code