MATLAB: Is the current folder different when I start MATLAB R2017a

defaultfolderMATLABr2017astartupuserpathworking

Up to R2016b, MATLAB would start with C:\Users\myUser\Documents\MATLAB as the working folder. However, when I start MATLAB R2017a, the working folder is different. Why is that?

Best Answer

There has been a change in MATLAB R2017a which affects the MATLAB startup folder.
Up to R2016b, the default startup folder is set to the "userpath" variable, which is C:\Users\...\Documents\MATLAB for Windows. Starting with R2017a, the default startup folder will be the last folder you were working in.
If you wish to change this setting, you can do so by clicking on "Preferences" in the "HOME" tab of the top ribbon, going to MATLAB\General, and changing the "Initial Working Folder" value from "Last working folder from previous MATLAB session" to "C:\Users\...\Documents\MATLAB"
According to the new default setting, if you closed MATLAB while working in C:\windows\system32, then that is the folder MATLAB will start in when you start it again.
Alternatively, you might be getting this behavior because of the configuration for the icon you use to start MATLAB. Please right-click on the icon and select Preferences, and make sure that the option for "Start In:" is blank. If this option is set to a directory, MATLAB will ignore your startup folder preferences and start in the directory specified in the shortcut icon.