It depends on the camera. With the Digital CamTrakker (pricey, but worth it), I like to set it up about 8-10 yds. from the intended target. It has a very fast trigger speed, great sensing range, and is awesome with rechargeable long-lasting batteries.
It really helps with any camera to have the deer want to pause in the frame. Whether a scrape, a fence crossing, food or water source, putting down some deer scent, or simply lay a cedar bough on the trail or scuff the ground just off the trail to get the deer to pause. Like I said, with the CamTrakker I've not had a problem but with others trying to do something to delay them does help.