My machine: ubuntu 18.04, run with python 3.7.1 and matlab 18b, in python it is:
import os
os.system('matlab -nojvm -nodisplay -nosplash -r "Mymat;quit;"')
and in Mymat.m it is
function X2 = TFOCS_LS()
a = 1; b = 2;
X2 = a+b;
end
Even I set that -nodisplay
flag, in the terminal it will still print something like below in the command line. How to suppress this information printout?
< M A T L A B (R) >
Copyright 1984-2018 The MathWorks, Inc.
R2018b Update 2 (9.5.0.1033004) 64-bit (glnxa64)
January 5, 2019
For online documentation, see https://www.mathworks.com/support
For product information, visit www.mathworks.com.