collectAll.R script