Can I make the max value in a plot 1 and the rest zero with kronecker delta?

1 回表示 (過去 30 日間)
onamaewa
onamaewa 2019 年 2 月 22 日
回答済み: Munish Raj 2019 年 2 月 25 日
The spot of intensity at -11 to -12 meters on the y-axis, I'd like to use kronecker delta to make the pixel with the greatest intensity shown while the others are blue (or zero).
tea_PP.jpg

回答 (1 件)

Munish Raj
Munish Raj 2019 年 2 月 25 日
There is no direct method to implement the kroneckel delta function, but the algorithm can be coded.
The following is a sample code to implement this.
% Find the max value.
maxValue = max(imageArray(:))
imageArray(imageArray==maxValue)=1; %Make all pixels with maximum intensity =1
imageArray(imageArray~=maxValue)=0; %Make all other pixels =0

カテゴリ

Help Center および File ExchangeStartup and Shutdown についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by