The \1 should refer to the second matched block, so the -2 or 0. The bit i'm not sure about is whether the -2 needs to be in brackets of some kind. The script i borrowed the sed command from was changing a single char in the prboom config file and i don't remember sed syntax very well now.
The gui thing would be nice but might as well make things tidy as possible in the absence of one. I had planned to make the frontend for accelemymote a nice gui to change the settings and calibrate but it's the same thing: might be more effort than it's worth with an already functional alternative.
It all depends how the joystick implementation works in mupen64. Prboom "dead zone" is controlled by setting the maximum pitch and roll in the accelemymote config file, but its joystick implementation is known to be poor. Other apps might take some intermediate position as "on". Is the N64 joystick analog?