'cast' 'computer' 'error' 'factorial' 'isequal' 'length' 'message' 'numel'īuilt-in (C:\Program Files\MATLAB\R2016b\toolbox\matlab\datatypes\cast)īuilt-in (C:\Program Files\MATLAB\R2016b\toolbox\matlab\general\computer)īuilt-in (C:\Program Files\MATLAB\R2016b\toolbox\matlab\lang\error)Ĭ:\Program Files\MATLAB\R2016b\toolbox\matlab\specfun\factorial. Note, however, that the functions that which sees may not be the same as seen by your file, depending on search paths.Īs an example, the built-in file perms.m gives: > g = getcallinfo('perms.m') Where unique is used to remove duplicate function names. ![]() You can then locate those functions using which: which(x), unique(f)) f has an entry for each call (the lines where those calls occurr are g(1).). g(1) refers to the main function in the file, and f is a cell array with the names of the functions it calls. In general, the file may have subfunctions, and g is a non-scalar struct array. You can get the names of functions called by a file using the semi-documented function getcallinfo: g = getcallinfo('filename.m') For instance a gui file has many local callback functions. Note: I need this to include toolbox dependencies in all local and nested functions, as well as function used inside those functions (full dependency tree). Is there an easy way to know which functions are used from that particular toolbox in my script file? For example, how can I know which function of the 'Model-Based Calibration Toolbox' is used in my code? Or which line of code that toolbox is used at? This way I can try to implement the function myself and avoid using the toolbox. 'Statistics and Machine Learning Toolbox' Is there a way to find out what are the toolboxes that are not installed but needed to execute a given script fList, pList (files) also returns a list of the MathWorks products possibly required to run the program files specified by files. ![]() I get the following result 'Image Processing Toolbox' Within my code, I'd like to check if the end-users have fsolve in their installation and if not, use fzero. For instance, I have a large script file that uses several toolboxes. how to test if toolbox exists Follow 127 views (last 30 days) Show older comments C Lira on Vote 3 Link Commented: Farid on I am writings some code that I wish to distribute open source. ![]() I am migrating my code and need to reduce the amount of used toolboxes as much as possible.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |