This allows them to perceive ultraviolet light, which is involved in courtship