I just noticed something curious. During the day I keep my phone connected via usb cable to my laptop (Thinkpad T410) most of the time while I am working. Today I responded to an email on the phone while it was still connected and the keyboard accuracy was TERRIBLE. It also seemed really slow in keeping up with me.
I unplugged the phone and tried again and all was fine and dandy. Hmmmmm..
I've seen this on my ur-Focus and my Nexus One. On the Focus it depended on what it was plugged into. It would do this on the wall charger or my desktop, but not my laptop, for example.
I think that somehow the external power source is altering the charge on the screen, even a slight static charge would be enough to screw up the touch screen sensitivity. Maybe a slight voltage leak out through the plug, or it could even be the magnetic field coming off the power cable as the phone is charging.
Did you have wifi trying to switch on in the background?
I can only reproduce your lag if I keep wifi one. Then wake up my phone from deep sleep. While the radio tries to re-connect, if I am immediately replying a text or specifically an email, then keyboard appears to lag. However as soon as the wifi is connected, if I switch off the screen, immediately switch it back on, then continue typing everything comes back to normal.