フィルターのクリア

how to obtain the last index of a column vector containg a set of given values?

3 ビュー (過去 30 日間)
Abin Krishnan
Abin Krishnan 2014 年 2 月 15 日
コメント済み: Image Analyst 2014 年 2 月 15 日
I have a column vector which shows time. I'm trying to find out the index using the find command. My input command was. >> s=find(time==0.1000); >> s
s =
Empty matrix: 0-by-1
The vector contains three values of 0.1000.I want the index of the last value. But it shows the above error message.

回答 (1 件)

Image Analyst
Image Analyst 2014 年 2 月 15 日
The index of the last element of "time" or of any 1-D array is "end" or length(time).
  3 件のコメント
Abin Krishnan
Abin Krishnan 2014 年 2 月 15 日
I want the index of not the last element.i have used find command but still <= expression is not working
Image Analyst
Image Analyst 2014 年 2 月 15 日
Make it easy for us to help you. Read this. http://www.mathworks.com/matlabcentral/answers/6200-tutorial-how-to-ask-a-question-on-answers-and-get-a-fast-answer As of now, I can't do anything to help you.

サインインしてコメントする。

カテゴリ

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