[~,ant_est] = max(abs(z));
1 次查看(过去 30 天)
显示 更早的评论
When i used this above code in my matlab version 2009a it is showing an error Expression or statement is incorrect--possibly unbalanced (, {, or [.
help me to correct it
2 个评论
Massimo Zanetti
2017-1-26
编辑:Massimo Zanetti
2017-1-26
Most probably the error is not related to this line of code. Please, post more details (e.g., the piece of code and the whole matlab error message, including the line at which the error is found).
James Tursa
2017-1-26
编辑:James Tursa
2017-1-26
I.e., several lines above and below the offending line.
采纳的回答
Walter Roberson
2017-1-26
The ~ operator was not implemented until R2009b. You can replace that code with
[UnUsEdVaRiAbLe_To_IgNoRe, ant_est] = max(abs(z));
clear UnUsEdVaRiAbLe_To_IgNoRe
6 个评论
Adam
2017-1-26
Don't clear the variable if time is more of an issue than memory. clear instructions take a lot of time, relatively.
Walter Roberson
2017-1-26
I would be unlikely to clear the junk variable myself, unless I was short on memory. The "clear" I showed is the logical equivalent, not the practical equivalent.
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Numeric Types 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!