Add support to calculate average/median marks when doing ol.py index