They allow for quick, easy location and alignment of the rear wheel after you've removed it. Initally, you back the screws all the way out, then place the wheel in the desired spot along the dropouts, align the wheel between the chainstays and tighten the nuts or skewer. Then you tighten the screws so they contact the axle. Next time you remove the wheel you simply put it in the dropouts, pull the wheel until the axle contacts the screws and everything should be perfect alignment.
It provides limited tailoring of wheelbase length and can be used to compensate for unequal length chainstays. Obviously, it's greateset advantage in races, when quick wheel changes are required. Set screws and horizontal dropouts have largely disappeared in the last couple of decades due to vertical dropouts which establish the fixed axle placement necessary for optimal operation of indexed shifting systems.