Question about toolbox dependencies
이전 댓글 표시
Hello
I am working on getting a program ready for distribution and wanted to check on the required toolboxes. I noticed that when I run:
[fList,pList] = matlab.codetools.requiredFilesAndProducts('myprog.m');
It says that I need the Statistics and Machine Learning Toolbox. I have the toolbox installed, but do not want/need to require its use in the program. I did some digging and it seems that the iqr function is saying it requires this toolbox. However it seems as if although there is a iqr function in the statistics and machine learning toolbox, regular Matlab has a standard iqr function as well, which is the function I am using.
To illustrate this if I make a file test.m that has this code:
x = [1 2 3 4 5 6];
d = iqr(x);
and then I run
[fList,pList] = matlab.codetools.requiredFilesAndProducts('test.m');
{pList.Name}'
ans =
2×1 cell array
{'MATLAB' }
{'Statistics and Machine Learning Toolbox'}
Why does this happen?
Similarly, ive notived that 'Polyspace Bug Finder' is showing up as a required product. Ive never used this and have no idea why it would be required (although if I check pList.Certain for this it is 0). Can someone explain why this is being listed as a required product for my program?
thanks!
채택된 답변
추가 답변 (1개)
Fangjun Jiang
2023년 2월 2일
I think you've found a bug. Report it to the Mathworks or see if they already reported this.
I tried your example in R2020b and R2022b. Both versions have "Statistics and Machine Learning Toolbox" installed and licensed.
In R2020b, it showed
>> {pList.Name}'
ans =
2×1 cell array
{'MATLAB' }
{'Statistics and Machine Learning Toolbox'}
In R2022b, it showed
>> {pList.Name}'
ans =
1×1 cell array
{'MATLAB'}
카테고리
도움말 센터 및 File Exchange에서 Introduction to Installation and Licensing에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!