Cannot open MATLAB in desired initial working directory on Linux.

조회 수: 6 (최근 30일)
Soren Smith
Soren Smith 2019년 11월 16일
이동: Walter Roberson 2024년 1월 7일
Using Linux Mint 19.2. MATLAB version R2019a. I want MATLAB to open to either the last directory used, or a directory of my choice. I have not been able to achieve this.
I have tried:
  • Setting the MATLAB_USE_USERWORK environment variable to 1
  • Setting the -useStartupFolderPref flag in the launcher
  • Changing the initial working directory settings in the preferences
  • Installing matlab-support
Any changes made to preferences seem to be reset when MATLAB closes.
The combined use of these has had an effect on the starting directory, but it is never what is desired. It is currently opening in /. When opened as root, it opens in the userpath directory. It is beyond frustrating that something seemingly simple is proving to be so difficult. Any assistance would be greatly appreciated.

답변 (1개)

Swastik Sanjay Chaudhury
Swastik Sanjay Chaudhury 2019년 12월 4일
You can set the initial working folder in MATLAB through the following Preference settings:
1. Open the Preferences window
2. Navigate to the General options
3. Select the option to specify a path to a folder under the Initial working folder options, and enter the desired directory
4. Press Apply and/or OK to save your changes
5. Restart MATLAB to verify the new location is set as expected.
Additional information can be found in the MATLAB documentation:
MATLAB Startup Folder
  댓글 수: 3
Andrew Gibbs
Andrew Gibbs 2023년 3월 9일
I tried this, on linux ubuntu, and it doesn't work for me either. Neither the specified folder, nor the previous folder, will appear on startup.
Ryne
Ryne 2024년 1월 7일
I an having the same issue with MATLAB running on elementaryOS. Were you ever able to get the Current Folder Window to start in a specific folder location?

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Startup and Shutdown에 대해 자세히 알아보기

태그

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by