def rate(hit, num):
    return "%.4g" % (float(hit) / (num or 1.0))
Return the fraction of `hit`/`num`, as a string.
dataset/ETHPy150Open RoseOu/flasky/venv/lib/python2.7/site-packages/coverage/xmlreport.py/rate