R Code for Regression-Discontinuity Designs