1

I need help approaching a proof which deals with inequalities:

If p and r are the precision and recall of a test, then the F1 measure of the test is defined to be $$F(p, r) = \frac{2pr}{p+r}$$

Prove that, for all positive reals p, r, and t, if t ≥ r then F(p, t) ≥ F(p, r)

What's the first step to approaching this problem? Do I need to look at this with different cases?

3 Answers3

1

A standard way is to look at $F(p,t)-F(p,r)$, which is $$\frac{2pt}{p+t}-\frac{2pr}{p+r}.$$ Bring to a common denominator and simplify. We get $$\frac{2pt(p+r)-2pr(p+t)}{(p+t)(p+r)},$$ which simplifies to $$\frac{2p^2(t-r)}{(p+t)(p+r)}.$$ This is clearly $\ge 0$.

André Nicolas
  • 507,029
0

Hint: $F(p,r) = \dfrac{2pr}{p+r} = \dfrac{2p^2+2pr-2p^2}{p+r} = \dfrac{2p(p+r)-2p^2}{p+r} = 2p - \dfrac{2p^2}{p+r}$.

Can you show that this is an increasing function in $r$?

JimmyK4542
  • 54,331
-1

$$\frac{1}{p}+\frac{1}{r}=\frac{p+r}{pr}\\so\\ f(p,r)=2 \frac{1}{\frac{1}{p}+\frac{1}{r}}\\\frac{1}{\frac{1}{p}+\frac{1}{r}}\\\\is -harmonic-mean$$

Khosrotash
  • 24,922
  • Would you mind elaborating a bit? The OP might not see your idea from what you wrote, although writing the function as a harmonic mean is a good idea. – Joonas Ilmavirta Sep 18 '14 at 07:55