I am new to coding and I am currently looking at an R code that I found online. The full code can be found at this link: http://epirecip.es/epicookbook/chapters/kr08/3_4/r_desol