How to save statistics in the function - image processing

2 ビュー (過去 30 日間)
SS
SS 2021 年 5 月 18 日
編集済み: SS 2021 年 5 月 20 日
Hi, I am running a code on a set of binary images to calculate the positions and angles of some line elements. I have some issues saving the statistics and results in the error : index exceeds bounds. Can someone please help me resolving this issue.

採用された回答

KSSV
KSSV 2021 年 5 月 18 日
The given error is very clear and simple. The error says, you are trying to extract more number of elements then present from the array.
Example:
A = rand(1,10) ; % array of size 1x10
A(1) % first element
A(end) % last element
A(10) % last element
A(12) % error, as there is no 12th element
In your case, check the dimensions of array and run the loop properly. Learn about debugging the code, this will help you to rectify your error easily.

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeMatrix Indexing についてさらに検索

タグ

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by