MATLAB爱好者论坛-LabFans.com

MATLAB爱好者论坛-LabFans.com (https://www.labfans.com/bbs/index.php)
-   资料存档 (https://www.labfans.com/bbs/forumdisplay.php?f=72)
-   -   索引必须是正整数或逻辑值:但是它是 (https://www.labfans.com/bbs/showthread.php?t=24234)

poster 2019-12-10 20:48

索引必须是正整数或逻辑值:但是它是
 
因此,我试图访问一个长度为165888的数组。我正在遍历,随即计算索引。某一时刻,我到达110689,由于某种原因,这引发了以下错误:

Attempted to access buf(110689); index must be a positive integer or logical.

有任何想法吗?



[B]回答:[/B]

这是一个四舍五入的事情。我正在计算,却忘了四舍五入。



[url=https://stackoverflow.com/questions/4458474]更多&回答...[/url]


所有时间均为北京时间。现在的时间是 01:06

Powered by vBulletin
版权所有 ©2000 - 2025,Jelsoft Enterprises Ltd.