Unless it is rabid, most wild yotes if they see you they will not come to you. Most are 40-60 lbs, you are much bigger, they want to eat, but they want to live another day, so they don't want to take a chance to hurt themselve. So if you see one from a comfortable distance, just throw some rocks at it. If you miss, it will probably run away, if you hit it, even better, reinforces them to stay away from humans.
OTH, if it sneaks up on you to try to attack you/your dog, as others have said, a stick might be much more effective.
A rabid one is a whole different story.