added R code for association tests