#!/bin/bash -l #$ -j y # For 12 combinations of parameters, run a job array with # 12 tasks using "-t" option (e.g. #$ -t 1-12). #$ -t 1-12 # Load the R module you'd like to use module load R/4.1.2 # Each job launched will have a unique task id assigned (1,2,...,12) # which is also saved as environment variable called $SGE_TASK_ID. # $SGE_TASK_ID can be passed into the R Script as an argument. # Within the R script, the task id value is used as a row index # value to extract a row of parameters, in a dataframe, to be used in # the run. # (See "param_sweep.R"" for more details). # Run the script and pass $SGE_TASK_ID as an argument Rscript param_sweep.R $SGE_TASK_ID