MATLAB启动后,自动执行的代码为
C:\Program Files\MATLAB\R2017b\toolbox\local\matlabrc.m
MATLAB对这个脚本的描述:
%MATLABRC Master startup MATLAB script. % MATLABRC is automatically executed by MATLAB during startup. % It establishes the MATLAB path, sets the default figure size, % and sets a few uicontrol defaults. % % On multi-user or networked systems, the system manager can put % any messages, definitions, etc. that apply to all users here. % % MATLABRC also invokes a STARTUP command if the file ‘startup.m‘ % exists on the MATLAB path.
要想改变默认工作目录,给这个脚本追加一个cd操作:
cd C:\Users\think\Documents\MATLAB
原文地址:https://www.cnblogs.com/YangGuangPu/p/12625298.html
时间: 2024-10-12 12:14:12