Finding peak in the Gaussian like function which Value is unknown.

조회 수: 4 (최근 30일)
Jae-Hee Park
Jae-Hee Park 2022년 9월 21일
댓글: Jae-Hee Park 2022년 9월 22일
Hi!
I want to find the peak in the Gaussian form of value.
But the difficulty is that the data is not given.
My pseudo code is below.
for i=1:n
Value = Somefunction(); %it takes long time.(ex:1min)
Values(i) = Value;
end
So, that code makes variable Values like gaussian(we know answer must be like gaussian).
But it takes too much time so I want to make the code like this.
while(1)
Value = Somefunction(); %it takes long time.(ex:1min)
if (the Value is the peak)
break;
end
end
Purpose is to reduce the iteration of the code.
Is that possible?
Thank your help.
Jae-Hee Park

답변 (1개)

Sam Chak
Sam Chak 2022년 9월 22일
Can you try if the findpeaks function works for your application?
You can also find some examples here:
  댓글 수: 1
Jae-Hee Park
Jae-Hee Park 2022년 9월 22일
@Sam Chak I checked this function but this function needs all data. My data is iterally generated.

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Descriptive Statistics에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by