#/!bin/bash
# This script launch R programs to test the difference between two experiments.

module load R

./config.sh

makedir -p $OUTDIR

exp1=$1
exp2=$2
year1=$3
year2=$4
nmemb=$5

# Comparing Reichler & Kim indices
Rscript R_scripts/KS_index.R $OUTDIR $exp1 $exp2 $year1 $year2

# Mapping the differences between the two experiments
rep=$MAINDIR/EC-Earth_diags
Rscript R_scripts/ $rep $exp1 $exp2 $year1 $year2 $nmemb
