R scripts for SIMS data analysis