When working in India with street dogs, dog fights between entire dogs were common and desexing was beneficial at reducing the incidence of aggression in dogs and dog fighting. In that environment, desexing certainly helped because there was regular competition for females in season and females coming into season were often harassed by packs of male dogs that readily fought each other. In season female dogs give lots of signals both through smell, pheromones (hormones in the air that are detected by a specific organ that humans do not possess) and with visual cues as they get closer to allowing a male to mate with them. Aggression for mating rights can occur and it is beneficial for the species that the strongest dog who can detect correctly the right time to mate with a female should pass on his genes to the next generation.
In the western world, there are not so many entire male and female dogs. Because we know that sexual aggression can occur, it is often assumed that a dog needs desexing if it is entire and shows aggressive behaviour. If the aggression occurred between two entire male dogs in the presence of an entire female who was coming into heat, this assumption may be correct. However, often the behaviour is seen with no competition evident and the pet is not running off in search of an in season female.
Some studies have shown that entire male dogs are more likely to display aggressive behaviour than their desexed counterparts, while desexed females are more likely to display aggressive responses than entire female dogs. From this simple statement, we could jump to the conclusion that desexing will reduce aggression in male dogs and leaving a female entire would reduce the risk of aggression in a female dog. Unfortunately the story is a lot more complicated than that. Hormones can increase or decrease the threshold for an aggressive response in a situation, but we really need to consider WHY the aggressive response may be happening in the first place.
Aggressive responses from many animals in situations where such a response is not benefitting the animal can often be due to an underlying problem that needs addressing. The behaviour is a sign of a deeper problem and often that problem can be related to fear or anxiety. Although desexing or not desexing could alter the threshold for an aggressive response, the behaviour itself could have developed due to another problem. To desex an entire male who is showing aggression can sometimes be like putting a band-aid on a festering sore. Initially there may be some benefit, but as the underlying problem continues without appropriate treatment, further behaviour problems can develop, and ultimately we have not treated the underlying illness.
The earlier behaviour problems are treated appropriately, the better.