pass average parameter in precision() and recall()
minor update