Trying my script in another MATLAB release
古いコメントを表示
Hi, I have MATLAB R2015b, and I have a script I would like to test in another MATLAB release, to see if it still works. I would like my script to be able to run in any release, or at least in as many releases as possible.
If you run it, can you tell me the error message that appears and how I can solve it?
5 件のコメント
per isakson
2017 年 1 月 12 日
On R2016a x1 produces a series of figures. Seems to work; no messages indicated otherwise. However, I interrupted the execution after fourteen figures
Image Analyst
2017 年 1 月 12 日
Ricardo, please give all the inputs necessary to reproduce the error you see. And give us the actual error message - ALL the red text not just part of it, because we don't seem to have the error you did.
Walter Roberson
2017 年 1 月 13 日
I read this as asking people to run it in other releases to determine whether the other releases are compatible -- that is, that the user wants to make the code portable and is wondering what changes to make to ensure portability.
Image Analyst
2017 年 1 月 13 日
Well I thought that too. It's a little unclear though if "the error message" also appears in his R2015a version or not. If there's no error message the only reason I think it wouldn't run in a later version is if he used a deprecated function that has since been removed. And it wouldn't run in an older version if he used a new function that didn't exist in the old version. The help documentation tells whether functions are deprecated and when they were first introduced so that may help him determine compatibility.
Ricardo Boza Villar
2017 年 1 月 13 日
採用された回答
その他の回答 (2 件)
Image Analyst
2017 年 1 月 11 日
You didn't say what to enter for inputs. I'm running R2016b and I put in 1 for all the inputs and it ran for a while and then crashed with this error message:
To use 'local2globalcoord', the following product must be both licensed and installed:
Phased Array System Toolbox
I don't have that toolbox. I've added it to the Products section above.
3 件のコメント
Ricardo Boza Villar
2017 年 1 月 12 日
Image Analyst
2017 年 1 月 12 日
You should unaccept this since I really didn't solve anything.
Ricardo Boza Villar
2017 年 1 月 12 日
Walter Roberson
2017 年 1 月 12 日
R2014a:
Error using contour3 (line 65)
Too many input arguments.
Error in x1 (line 185)
contour3(x,y,z,30,'-','linewidth',1), title(string_3,'interpreter','latex','FontSize',13), axis equal, pause(2) % pause(0.1)
3 件のコメント
Ricardo Boza Villar
2017 年 1 月 12 日
Walter Roberson
2017 年 1 月 12 日
The work-around is probably
[~, h] = contour3(x,y,z,30,'-');
set(h, 'LineWidth', 1);
This should work for both R2014a and before, and for R2014b and later. In R2014b and later, h would be a contour object, which has a LineWidth property directly. In R2014a and earlier, in the special case that you specified a linespec (which you did) then the h returned would be a vector of line objects, and those have LineWidth properties too.
If you had not specified '-' then in R2014a and earlier then h would be patch objects -- and they happen to have LineWidth properties as well.
Ricardo Boza Villar
2017 年 1 月 13 日
カテゴリ
ヘルプ センター および File Exchange で Performance and Memory についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!