Canine aggression comes about due to any of a number of causes. Some dogs just have bad temperaments. Some have medical problems that cause behavioral changes. Aggression can be directed at people, at other animals, or both. An aggressive dog—one that threatens to bite, tries to bite, or does bite—is dangerous. If your dog behaves aggressively, you need to get qualified professional help immediately.
Start with a physical exam by your veterinarian. Be sure she knows about the aggression problem. Have a full thyroid panel run (not just a thyroid screening), as low thyroid sometimes causes aggressive behavior. Ask your vet about other tests you may want to have run. Be aware that even if a physical cause is found, it may be difficult or impossible to control your dog's aggressive behavior reliably enough to make him a safe pet. Altering cuts down on aggression if it's done before sexual maturity. It may help an older dog in some cases, but not all.
Here's the bottom line on aggression: No matter what the cause, and no matter how much you love your dog, if you cannot manage your dog's aggression so that he will never pose a threat to any child, to your neighbors or visitors to your home, or to anyone else's pet, then you should seriously consider having him humanely euthanized. It's a terribly sad and difficult decision to have to make, but sometimes it is the responsible and loving choice. How would you feel if your dog attacked and maimed a child or killed your neighbor's dog? A single dog bite is painful and can cause a lot of damage. An attack by an aggressive dog is devastating. Get help and do what you can to fix the problem, but if it can't be fixed, release your dog from the demons that provoke him, and keep everyone safe.