I have a table like this:
Time Indicator Value
"2017-05-22 13:52:10" 1 10
"2017-05-22 13:52:12" 1 11
"2017-05-22 13:52:14" 1 9
"2017-05-22 13:52:16" 0 4
"2017-05-22 13:52:18" 0 10
"2017-05-22 13:52:20" 1 7
"2017-05-22 13:52:22" 1 9
"2017-05-22 13:52:24" 1 7
And I would like to compute three Values: The Means for all Rows, where Indicator is constant.
So I would like to do a group by Indicator for three Bins: The first Bin with Indicator=1, the second Bin with Indicator=0 and the third bin with Indicator=1. The basic idea is, that I want to create bins by the change of one variable. How can I do that?
Thanks for your Help!