To do a high level test of GGIR I need an example data file. Real life data files are at least 100MB in size, so not something we want to store inside the software. To address this I wrote the _create_test_acccsv function that creates a dummy data file with simulated data. The simulations are simple, but just enough to trigger the main functionalities.
Description of what create_test_acc_csv does:
The function generates 3 time series corresponding to the 3 sensor channels. The sensor are positioned orthogonally,
which means that there is a well defined geometric relation between their values in a non-movement scenario. I start by positioning simulated sensor with x-axis upright, and y- and z- axis horizontal.
Further, I add some degree of sensor offset and scaling error (code reference).
When we simulate movement I need to make sure that the rolling average of the 3 time series complies with the geometric relation between the three sensor axes. So, simply adding random patterns to the data is not enough. To address this I rotate the three axis with a rotation matrix.
Finally, I add random numbers on top of this to simulate the actual movement (code reference).
The result is a file where I know exactly the sensor calibration error and how many hours per day the person slept and moved around.
As you can see this procedure involves quite a lot of domain knowledge. From the perspective of the time_series_generator, I imagine it would be useful to be able to do the following:
Suggested functionality for time_series_generator:
Ability to assemble a time series based on serially appending and/or summing multiple different time series types. At the moment the user can already do this by writing some complementary code, but it could be valuable if the software facilitates this process. The more this is facilitated the more a user can focus on the process of designing the overall signal.
Ability to incorporate a mathematical relation between multiple channels. In the GGIR example, this would be: Given xyz(time), calculate a new xyz(time) based on xyz(time), rotationmatrix, rotationangle(time).
Following on from #20 here is my second use-case:
To do a high level test of GGIR I need an example data file. Real life data files are at least 100MB in size, so not something we want to store inside the software. To address this I wrote the _create_test_acccsv function that creates a dummy data file with simulated data. The simulations are simple, but just enough to trigger the main functionalities.
Description of what create_test_acc_csv does:
The result is a file where I know exactly the sensor calibration error and how many hours per day the person slept and moved around.
As you can see this procedure involves quite a lot of domain knowledge. From the perspective of the
time_series_generator
, I imagine it would be useful to be able to do the following:Suggested functionality for time_series_generator: