Pheromones seem likely, but I don't know of any conclusive studies. Both menstruation and menarche can be affected by close association with men and women.
Many postulations about the effect are centered on survival and reproduction, even competitive reproduction.
Personally, I would think reproduction and competitive reproduction are the most likely. I couldn't figure how survival would come into play, unless it was something like schools of fish: It's thought that small fish who travel in schools make harder targets; their movement causes flashing, which draws attention in different directions, supposedly so a predator couldn't follow one target. Similarly, when menstrual cycles sync, all the women in the group get bitchy at the same time, making it nearly impossible for a man to single out one of them for retaliation. The man becomes confused, stymied, gives up and either swims off into the abyss to contemplate his existence, or beaches on a sand bar until dawn with his guy friends.