def run_matlab_job(job):
 log('Running matlab job.')
 job_file = job_file_for(job)
 function_call = ("matlab_wrapper('%s'),quit;" % job_file)
 matlab_cmd = ('matlab -nosplash -nodesktop -r "%s"' % function_call)
 log(matlab_cmd)
 sh(matlab_cmd)

def run_matlab_job ( job ) : log ( 'Running matlab job.' ) job_file = job_file_for ( job ) function_call = ( "matlab_wrapper('%s'),quit;" % job_file ) matlab_cmd = ( 'matlab -nosplash -nodesktop -r "%s"' % function_call ) log ( matlab_cmd ) sh ( matlab_cmd )
run it as a matlab function .