Hello everyone.
I have a grid excel file with 300x300 pixels (cell). Each pixel represents different intensity value range from 0 to 0.1. I would like to threshold this grid so that any pixel value lower than 0.04 will be equal to 0. Does anyone know how to do that.
Thank you.

 採用された回答

Cris LaPierre
Cris LaPierre 2020 年 8 月 13 日

0 投票

I'm assuming you've loaded the file into MATLAB. Use logical indexing to set any value less than 0.04 equal to zero.
Data(Data<0.04)=0;

1 件のコメント

Amira Ramli
Amira Ramli 2020 年 8 月 22 日
thank you very much!

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

その他の回答 (0 件)

カテゴリ

ヘルプ センター および File ExchangeData Import from MATLAB についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by