Courtship is ubiquitous in nature, sometimes to the point that we often do not connect specific behaviors to courtship. Few people wake up in the morning and think of the morning choir of birds as a desperate signal for persuading female birds to mate, and few divers would consider the darting to and from by Anthias as a more brutal and direct way of saying the same thing: Choose me!
According to the big answer in the sky (Wikipedia) courtship is the behavior by which different species select their partners for reproduction. As such it seems pretty straightforward and even self-evident; one needs to court before committing. But, think it over again. Why? Courtship costs a lot of energy, it takes a lot of time and it can be very dangerous, as courting behaviors often are pretty intense, leading to courting individuals loose control over their surroundings and can easily fall prey to a predator. So why care? Wouldn´t it be just as good to meet a mate of the opposite sex and get the mating over with no further ado. Some animals (and I guess most plants) do just that. There are a number of reasons why many animals still indulge in such a dangerous activity.
Earlier views on courtship was that the purpose of courtship was to coordinate the reproductive phase of the two participants. This is highly likely not a reasonable explanation, as most of you likely will know. After all, does an eighteen year old human male need any coordination of reproductive phasing? The answer is the same for most all animal males. In general, males are ready when the females are, negating the need for reproductive coordination within a pair.
Well then, why do we see so much courtship going on? I will treat a number of reasons in blogs to come, and restrict myself to the most obvious in this blog post. It is highly likely that the pair might want to check out the quality of each other. In order not to be stuck with a bozo´s gene, females may force males to do the most acrobatic, dangerous and costly displays in order to allow mating. Obviously birds are the prime example of this, with peacocks and birds of paradise being close to unfit for living a normal bird life due to the female pressure on males to prove themselves.
There are a number of fish with similar behaviors. From colder areas sticklebacks are known to have elaborate courtships. On reefs Anthias constantly show at least short bouts of courtship interspersed with a lot of male fighting, and on the sandy areas here in Lembeh, we see sand diver males doing all they can to persuade a female to choose just him to fertilize the expensive batch of eggs she carries. Good males, with no diseases, good combination of genes, that are able to feed themselves well, will be able to show more elaborate courtship behaviors of longer duration, and will then be favored by females and thus selection.