필터 지우기
필터 지우기

Replace value that are associated to a location by nan

조회 수: 1 (최근 30일)
Ricardo Duarte
Ricardo Duarte 2021년 10월 20일
편집: Matt J 2021년 10월 20일
Dear all,
I have a question that I hope you can help me.
I have a map of sound pressure levels (spl) in which I patched a white band using countour command as you may see in this figure.
Brifelly, I used surf(longitude,latitude,SPL_dB) to plot the spl levels and then I used c2=contourf(longitude,latitude,elevation', [100 100],'facecolor',[1 1 1]) to create the white band, where elevation is the bathymetry of the area.
However, now I would like to delete or replace by NaN all the values in my spl matrix that are covered by that white band.
How can I do it?
Thank you very much

채택된 답변

Matt J
Matt J 2021년 10월 20일
편집: Matt J 2021년 10월 20일
spl(0<= elevation & elevation<=100)=nan;

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Simulation, Tuning, and Visualization에 대해 자세히 알아보기

제품

Community Treasure Hunt

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

Start Hunting!

Translated by