Separate values in a matrix greater than 0

8 Ansichten (letzte 30 Tage)
Miguel andres
Miguel andres am 23 Mai 2020
Beantwortet: Rik am 23 Mai 2020
Hi all,
I'm pretty new on Matlab and I would like to separate a time series of tide between flood and ebb for all the poinst of my grid.
Values greater than 0 meters correspond to flood and opposity for ebb. I would like to create a mask (that I can use it for other time series), so flood gets the value 1 and ebb 0.
I tried with if condiction but it didn´t work, hope you can help.
Thank you in advance.

Akzeptierte Antwort

Rik
Rik am 23 Mai 2020
So like this?
isFlood=water_height>0;

Weitere Antworten (0)

Kategorien

Mehr zu Oceanography and Hydrology finden Sie in Help Center und File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by