Update and replace Gmacs.R script.