Adorable sheep-sized dinosaurs probably evolved their fancy neck frills to attract mates or show off their dominance. 

Protoceratops — a dinosaur that looked a bit like a mini-Triceratops without horns — had elaborate and varied neck frills. Paleontologists have debated what they were used for: Defense? Temperature regulation? Or perhaps, like modern birds with colorful tail feathers, the dinosaurs evolved the frills to show off their fitness to potential mates and competitors, a process of sexual selection. In sexual selection, an animal with a certain trait that appeals to potential mates or otherwise allows them to reproduce more will get passed down to the next generation and become more common.