R scripts for model EOF analysis