Fix bug in sub indicator averaging