One explanation for the great size of the tail is that if females prefer mating with males with large tails, those males will have greater reproductive success. Thus, there will be selection for the large spectacular tails that peacocks have.
This paper is getting a fair amount of attention (e.g., a mention on the latest Science podcast) because it counter intuitively argues that females do not prefer males with larger tails.
There's something important to know about this paper: The authors didn't do any experiments. That is, they never actually changed the tails of males in any way to see if this changed their courtship or mating success.
Instead, they watched peacocks and peahens mating in a free-ranging population in Japan (268 matings, if you're curious), and measured the peacocks' tails in various ways from photographs. Then, they looked to see if there were any correlations between tail shape and mating success.
No correlation between the length of the tail and mating success.
No correlation between the number of eyespots on the tail and mating success.
And this is where this being a study rather than an experiment makes the interpretation difficult. The authors worked simply with what they found in their field setting. And there was very little variation in peacock tails. If there's no variation, it's very difficult to make any conclusions about choice.
Image a situation where you have to pick between numerous $1 bills. You pick a $1 bill more or less at random, and the researcher concludes that value plays little role in your decision making process. The peahens may not have had much to distinguish the peacocks here, so other factors may become more important.
Indeed, the authors found correlations between behaviour called "shivering" and mating success. When the authors put all these factors to try to explain mating success in a single year, however, not much is explained.
They also found a correlation between tail length and predation -- although few peacocks were preyed upon. Although many individuals were identified using leg bands, the authors say very little about the age of the individuals they were studying. One could image a situation where the oldest mails have the longest tails, but because they are old, they are the most vulnerable to predators.
The authors propose that the peacock's tail is a relic. That is, it was important once, but is mostly unimportant now. This is an interesting idea, as are several others that they float in the discussion. But ultimately, I wish they had done some experiments.
TAKAHASHI, M., ARITA, H., HIRAIWAHASEGAWA, M., HASEGAWA, T. (2008). Peahens do not prefer peacocks with more elaborate trains. Animal Behaviour, 75(4), 1209-1219. DOI: 10.1016/j.anbehav.2007.10.004