Hi there,
I need to find a way to make a matlab command for the following: I have an array with 2500×1 doubles. And I need to find the doubles that are at least 150 and when there are more than 4 values >150 next to each other.
For example [125 165 150 124 126 154 103 99 160 198 *140] should return [0 0 0 0 0 0 0 0 0 0 0] and [149 *156 158 159 168 *149 120 *150 160 140 125] should return [0 1 1 1 1 0 0 0 0 0 0]
I have the following: x = array > 150 & ????
I don't know how to do the at least 4 following values in a simple way, I can only think of an if loop…
Does anyone know if there is a command for that?
Thanks in advance!
Best Answer