Measure the magnification (size of image of subject on the screen / size of the subject in real life); add 1 to the result; square the result of that; and multiply the shutterspeed (the actual time) by that.
If you want to have a compensation not as a shutterspeed factor, but in stops, take the log of that factor and divide it by the log of 2.