Fortunately, coyotes rarely attack humans, and are generally very afraid of them (though this isn't always true, especially if the coyote has grown acclimated to humans).
If a coyote attacks your dog when you're around, you can often scare it off by making loud noises or spraying it with a hose. Beware, though.