#!/bin/bash
###########################
#
#PBS -l nodes=1:ppn=12
#PBS -l walltime=00:30:00
XXXXXXXXXx and below is my script details about running matlab I want to save the results from the trial.m however it does not work.
export JOBID=`echo "${PBS_JOBID}" | cut -d'.' -f1`
cd ${PBS_O_WORKDIR}
module load matlab/R2017b
matlab
trial.m
My script name: trial.m How to save the results from trial.m to my environment? In my trial.m matlab file, I have the following codes to display my results, does this work? betas and values are two vector of numbers
disp(betas);
disp(values);
save('parameters.mat','betas','values');
In addition, trial.m needs to call external functions that I saved in the same file, can it call automatically?