I'm encountering a problem with my data analysis and hope to find some solution. I already gave a look at other threads to see if anyone had the same problem and resolved it, but no one aimed to do what I intend to.
In short, I have these data in csv (or txt) format that can be graphically represented here :
I would like to index these data into 4 different arrays, one for each period.
I can identify where the 0s are and then manually index the data, but as I have a lot of files I would like to automate it. I could put thresholds but I have 2 criteria for them :
For stop threshold :
- value contained in cell 1 > cell2
- cell 2 = 0
For start threshold :
- value contained in cell 1 < cell 2
- cell 1 = 0
As you can see, thresholds can't be a fixed value, and I have more than one period to identify, hence I'm having difficulty. I'm far from a Matlab expert so maybe I'm missing something easy, in that case I would gladly appreciate your help.
Thank you in advance !