Hi,
I'd like to open matlabpool with a variable number of cores, to use the maximum number of cores available. So n would equal features('numCores') here.
But matlabpool open n, matlabpool open features('numCores'), matlabpool open maxNumCompThreads don't work here. matlabpool open seems to accept only numbers and not variables.
I could do something stupid like
if features('numCores') == 4matlabpool open 4;elseif features('numCores') == 2matlabpool open 2;end
but I'd like to know if something more elegant exists.
Thanks!
Best Answer