Info

이 질문은 마감되었습니다. 편집하거나 답변을 올리려면 질문을 다시 여십시오.

how to find a point in a dynamic array

조회 수: 2 (최근 30일)
Sukumar Palo
Sukumar Palo 2011년 3월 14일
마감: MATLAB Answer Bot 2021년 8월 20일
Hi,
I am working on a project. In the project i am stuck in a place to find a point. My receiver is getting two data in one packet[strength,time] one by one.My job is to design an algorithm which can tell me two points before the maximum strength is received.
e.g: my array is [0.1 0.25 0.4 0.5 0.2 0.6 0.7 0.9 0.6 0.5 0.34 0.22]
i am getting to my system 1 by 1 data i.e 0.1 0.25 0.4 0.5 0.2 0.6 0.7 0.9 0.6 0.5 0.34 0.22
I have to find a solution in which it will return me a point two points before max value is arrived.
thanx in advance

답변 (1개)

Oleg Komarov
Oleg Komarov 2011년 3월 14일
Look at the second output of max:
[m,idx] = max(array);
idx-2
Oleg

이 질문은 마감되었습니다.

태그

Community Treasure Hunt

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

Start Hunting!

Translated by