I have a massive Dataset from an Experiment with stationary and dynamic points in it. I would like to segment this Data set into Stationary and non-stationary points (or Dynamic points)
The Idea behind this is to create seperate files for the stationary and non-stationary points.
I have tried a few things, including the mean/std etc.
Could anyone of you, point me into the right direction or library that would help me achieve this?
The red lines depic a change of the Blue line of 0.5. However this doesnt seem to capture all pts as seen in a zoomed image here (cannot upload more than one picture.) :
Suppose your raw “blue” data are in a column named “blue” in the DataFramedf:
df["blue_delta"] = df["blue"].diff()
then the dynamic points are where df["blue_delta"] != 0. You can also
do a compare on a whole series, eg:
df["blue_delta"] == 0
which would match the staionary data points. And since the above is a Series of Boolean values (true/false) you can use it as an index to
select the “stationary” points and save them in their own column: