This is not a good measurement of input lag.
- processing time that delays the output beep is unknown
- OS event for mouse may not be as the button is clicked, its when the OS gets to it, which will be variable
- process to produce beep, if software related may be delays as cpu processing is not continuous, its framed
- scripts are interpreted code (not compiled) so there is a delay by the interpreter
- the snap may not actually be the switch toggling to fire the click event
- are you sure that the program running is not at the normal 60hz refresh rate of a lot of applications? Essentially, did the mouse fire happen in a 16.7ms time frame and then the next frame is producing audio?
At best, the value you are getting is the variance in the timing for the os to produce a beep and click sound of a mouse. The irregularity of the times given lead to this conclusion. Basically, the difference in min/max time values of creating audio based on a click.