R Scripts for data analysis for ALEM