Allow user-specified grade functions