フィルターのクリア

how i can thresholding a signal

15 ビュー (過去 30 日間)
RESHMA
RESHMA 2016 年 4 月 1 日
コメント済み: Image Analyst 2020 年 2 月 21 日
i want to threshold a signal please help me
  2 件のコメント
Walter Roberson
Walter Roberson 2016 年 4 月 1 日
How do you want to compute the threshold level?
RESHMA
RESHMA 2016 年 4 月 4 日
i have a received signal in my matlab project , i want to just threshold that signal to a value of 5

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

採用された回答

Image Analyst
Image Analyst 2016 年 4 月 1 日
Try this:
thresholdedSignal = yourSignal < someThresholdLevel; % Or can use > if you want.
  3 件のコメント
Giorgio
Giorgio 2020 年 2 月 21 日
He is asking how to threshold a signal and you answered x < T. Which T?
What he is asking is "how to find T." If you know please let us know. Of course we want that but the problem is how to find the someThresholdLevel....
I can recommend to use something like this:
nbins = 128;
counts = hist(signal, nbins);
T = otsuthresh(counts);
press help otsuthresh
It computes a global threshold from histogram counts COUNTS that minimizes the intraclass variance for a bimodal histogram. T is a normalized intensity value that lies in the range [0,1]
You can use thr as theshold:
thr = round(T * nbins)
you can use the values associated to bins over/below the thr ...
Image Analyst
Image Analyst 2020 年 2 月 21 日
The T depends on the image. Sometimes the Otsu method works, and sometimes it doesn't. You can try imbinarize(). It works well for nice, bimodal histograms that you get with high contrast images. It doesn't work so well with mono-modal skewed histograms.
Usually I find I have skewed histogram and what I find works best is a triangle threshold, like in my attached function.

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

その他の回答 (0 件)

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by