Using students instead of grades as treshold

Closes #435