The attached file shows how you can produce a summary table of the durations for zero and one. I've used column D as a helper column (coloured blue) with this formula in D1:
and this formula in D2:
which is then copied down to the bottom of your data. The idea is that transitions from 0 to 1 are shown with an increasing number which ends with 0.5, and transitions from 1 to 0 are shown with an increasing integer.
Then I've put some headings in G1:H2 and the number 1 in F3 with this formula in F4:
This formula is in G3:
so that if your first value in B2 is a 1 this cell shows blank. A slightly different formula is used in G4:
Both cells are formatted as hh:mm:ss, and return the time differences for the zero values by looking for the time values between 0 and 0.5 (row 3) and between 1 and 1.5 (row 4). A similar formula is used for the 1's in H3:
which is copied into H4, with both cells formatted as hh:mm:ss. You need to copy the formulae in F4:H4 down, and to assist you I've put another little formula in I4 to tell you how far, depending on your data.
Hope this helps.
Pete
Bookmarks