The study of the glands and hormones they produce, their regulation, and how they affect bodily functions.