In order to replicate the analyses N study, open StudyN.R and execute it. When prompted to select a file, select the corresponding data, which I recommend to be stored in the same folder as the script, otherwise you will end up working on two different directories and change the code accordingly.
The other script are functions or batches to compute the scale means.