title: Findpeaks expected X to be increasing valued
body: <p>I'm starting out with matlab to analyse some data. I want to find the peaks in a gyroscope signal, but for some reason I'm getting an error saying "Expected X to be increasing valued".</p>
  
  <p>The full code for this is the following:</p>
  
  <pre><code>load logfile_6_2
  
  figure;
  axes;
  hold on;
  
  rate = inertia.node_137.data(inertia.node_137.data(:,1)&gt;1161 &amp; inertia.node_137.data(:,1)&lt;1221, :);
  gyro = rate(:,inertia.node_137.fields.gyro);
  taxis = rate(:,inertia.node_137.fields.time);
  
  plot(taxis, gyro(:,1), 'r')
  findpeaks(gyro(:,1), taxis, 'MinPeakDistance', 2);
  </code></pre>
  
  <p>The gyro variable contains 3 directions, and I want the x in this case, which is why i use gyro(:,1).
  The X that the error seems to be speaking of is the taxis, which is simply the timestamps of the data. This is increasing, so I do not understand why I get this error. Does anyone have an idea how this could happen? Thanks in advance!</p>
  
  <p>Edit:
  This is an example of the taxis data</p>
  
  <pre><code>830.5100
  830.5110
  830.5120
  830.5130
  830.5140
  830.5150
  830.5160
  830.5170
  830.5180
  830.5190
  830.5200
  </code></pre>