Communication, either visual or audible, can be contagious. We do this too. For example, when someone -- even your dog -- yawns, you will likely yawn too. In that case, yawning is thought to be a reflex-type action that cools the brain during hot conditions or provides the body with more oxygen when necessary. Similarly, if someone starts yelling at us or cries tears in front of us, we may react in the same way. All mammals -- and other animals too -- are driven to learn from, and respond to, others.
Therefore, when a dog barks after hearing another canine vocalize, it’s not necessarily a competition. Alexandra Horowitz, author of the book Inside of a Dog: What Dogs See, Smell and Know, points out that “barking together with others may be a form of social cohesion.” She further adds that “barks might be used to affirm a dog’s identity, or reveal an association with a group.” Studies show such barks can reveal emotions and intentions, such as playfulness, excitement and fear. The barking can get out of hand at places like shelters, where many dogs in close proximity start to bark. (A contagious infection, however, is behind the illness known as “kennel cough.”)
Most owners make the mistake of yelling at their dogs during such noisy times. This is actually amusing to consider because, from your dog’s perspective, you are just another barker. Your pet will probably then bark more, depending on how you’ve trained him or her.
If your attempt to chat with your neighbor about the new noisy dog fails, I suggest rewarding your dog for silence. You will need to call your pet to you, say “Sit!” followed by “Stay!” and then offer a food treat when your dog is still and quiet. The commands should be familiar to your dog, and will provide a mini time-out transition to peace and silence.