Complex sentence: These shoals are created because of a cost and benefit analysis, and shoaling will only occur if the benefit outweighs the cost of creating the group.
Split into simpler sentences: These shoals are created because of a cost and benefit analysis. Shoaling will only occur if the benefit outweighs the cost of creating the group.