Post-Correction Analysis

8.1 μs
"/home/gml/Proyects/Personal/Dextrose.jl/src"
12.3 μs
70.9 μs
201 ms
19.9 s
data_dir
"../data/"
1.6 μs
data_entries
71.6 ms
11.7 s
51.6 ms

Extract useful information

5.1 μs
489 ms
51.8 ms
8.1 μs
11.4 ms
833 ms
6.4 s
698 ms
2.1 s
3.8 ms

Define some useful parameters with Constant naming convention

5.5 μs
150
1.5 μs

Define some utility functions :

5 μs
Main.workspace2888.rebound
68.4 ms
Main.workspace2888.plot_intervals
125 μs
Main.workspace2888.plot_intervals
93.3 μs
Main.workspace2888.create_intervals
86.5 μs
Main.workspace2888.mean_time
116 μs
20.8 ms
99.3 ms
53.4 ms
49.1 ms

To do

benchmark both approaches :

7.2 μs
71.7 ms
60.2 ms

Note that they do produce identical results, as expected :

4.5 μs
true
280 ms
143 ms
57.1 ms
569 ns
601 ns
463 ns
50.3 ms
936 μs
26.3 ms

Visualise all post correction intervals

5.5 μs
260 ms
979 ns

This is sub-optimal, not only do we have different behaviours, we have too many lines to actually understand the trends. This is why we will have to perform clustering.

4.9 μs
212:1:392
3.2 μs
40.1 ms
8.9 μs
pglc
36 ms
3.9 μs
29.8 ms
209 ms
304 ms
2.4 s
373 ms
106 ms
128 ms

Variable selection rationale

Adding other parameters for the grouping could introduce some artifacts, which is obviously undefined behaviour. Wanting to evaluate the homogeneity of correction curves as a function of time, this are the only parameters that should be taken into account.

The selected variables are :x and :y, which are defined as follows : x(t)=cos(2×π×tT) y(t)=sin(2×π×tT)

Where t is the total amount of minutes since midnight (i.e. when that day started). t[0,1440[

9.7 μs
"Definition of parametric time functions "
18.4 ms
995 μs
1.6 ms

Hour slider :

32.7 ms

Clustering

4.5 μs
5.6 s
74.6 ms

Are our clusters what we expected ?

4.3 μs
56 ms
4 μs

yes

5 μs
471 ns
00:26:00
11.6 ms
hour_by_group
480 ms
idx_by_group
347 ms
intervals_by_group
322 ms
glycaemiae_by_group
315 ms
1.2 s
8.1 ms
5.9 ms
2×3 Array{Float64,2}:
 -0.7785798124408909   0.8576076213926156    0.28581369995861017
  0.20596893623295562  0.25317697866235817  -0.8357671753585296
3.2 μs