Added R code to repository, adapted from the MATLAB by Jie Hao and Nicolas Durrande.
Remove nuisance files.