I agree with Tony, first step is to change the sensor and lead. Secondly, make sure that the RPM wire and the water temp lead are not wound around one another or zip tied together. I have seen this happen before and it seems to be a result of the frequency. Sometimes it works fine, sometimes it is mind boggling. Since it changes with RPM, I will bet that is your problem.
Thanks,
MM