some changes to event study code