MATLAB: How to change the default working folder

general preferenciesMATLAB

I'm running matlab R2017a on Debian 9, every time I start MATLAB it creates the ~/Documents/MATLAB folder and assumes that it is the main working folder. I would like the default folder to be ~/Documents/prog/matlab, how should I do that ?
Thank you !

Best Answer

Open MATLAB preferences: Click on the top bar or type preferences in a command window. Go to General > Initial working folder. Specify the required folder you want to have at MATLAB startup.