Minor changes to make type references more regular in the stats code