__2018-01-17 如一模式识别研究

如一模式识别研究

matlab>>在matlab中加入文件夹搜索路径和去除文件夹搜索路径

转自:http://blog.csdn.net/tina_lulu_21/article/details/6936694

加入文件夹搜索路径 -- addpath (Add folders to search path)

ddpath('folderName1','folderName2','folderName3' ...)

addpath('folderName1','folderName2','folderName3' ... flag)

addpath folderName1 folderName2 folderName3 ... -flag)

previous_path = addpath(...)

这里的flag为

'-begin' :Add specified folders to the top of the search path.

'-end' :Add specified folders to the bottom of the search path.

'-frozen' :Disables change detection for folders you add to the path, which conserves Windows change notification resources (Windows only). Typehelp changenotification in the Command Window for more information.

例子:

Add c:/matlab/myfiles to the top of the search path:

addpath('c:/matlab/myfiles')

Add c:/matlab/myfiles to the end of the search path:

addpath c:/matlab/myfiles -end

Add myfiles and its subfolders to the search path:

addpath(genpath('c:/matlab/myfiles'))

On Windows, Add myfiles to the top of the search path, disable folder change notification, and display the search path before adding myfiles:

previous = addpath('c:/matlab/myfiles', '-frozen')

去除文件夹搜索路径 rmpath (Remove folders from search path)

rmpath('folderName') removes the specified folder from the search path . Use the full path forfolderName.

rmpath folderName is the command form of the syntax.

如果想把该目录下的所有子目录都添加到路径中去,也不用把所有的子目录逐一addpath,用genpath函数就可以啦:

Use genpath in conjunction with addpath to add a folder and its subfolders to the search path. Add myfiles and its subfolders to the search path:

addpath(genpath('c:/matlab/myfiles'))

评论留言区

:
  

作者: 游客 ; *
评论内容: *
带*号为必填项目

如一模式识别更新提示

matlab在图像处理方面的应用有更新

如一模式识别 友情链接

关于本站作者     chinaw3c     mozilla