advanced R programming: Notes