R Code for Oly Analysis