How to use "nan"
1 view (last 30 days)
Show older comments
Commented: gyeonggeun kim on 26 Mar 2021
I want to get rid of the color by using "nan" ,marked on the map.
The code is as follows.
Veronica Taurino on 26 Mar 2021
KSSV on 26 Mar 2021
Edited: KSSV on 26 Mar 2021
LEt's say you want to change the values beyond a given value val (a number) into NaN. Use:
u(u>val) = NaN ;
isnan is afunction used to check whether a value is nan or not. You can check after replacing values with NaN using:
Find more on Logical in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!Start Hunting!