diff --git a/README.md b/README.md
index 6ea6371..1bfcb8d 100644
--- a/README.md
+++ b/README.md
@@ -94,10 +94,10 @@ The most important components of CROW are:
The source data are time series of vertical profiles (`vpts`)generated by [vol2bird](https://github.com/adokter/vol2bird). These are stored on a public file server. The text files contain fixed-width separated values of **variables related to the presence of birds** (density, speed, reflectivity, ...), grouped by date (first column), time (second column) and height (third column). The structure in the source data files is therefore a flat table. See for example the [data file for the radar at site Helchteren](https://opendata.meteo.be/ftp/observations/radar/vbird/behel/2020/behel_vpts_20201101.txt) on November 1st, 2020.
-However for performance reasons, the `Home` compoment holds these data in a `radarVtps` variable organized as a tree of objects:
+However for performance reasons, the `Home` compoment holds these data in a `radarVpts` variable organized as a tree of objects:
```
-radarVtps (Object)
+radarVpts (Object)
├── 1604185200000 (Object - timestamp)
│ ├── heightData (Object - vertical profile of birds for this timestamp, per altitude)
│ │ ├── 0 (Object)
@@ -113,10 +113,10 @@ radarVtps (Object)
└── ...
```
-1. the `radarVtps` object is initialized according to the selected time range and radar. Sun altitudes at site are also computed and set.
-2. data file(s) are loaded via AJAX, and their content is used to populate `radarVtps` (more specifically, the various properties in each timestamp -> heightdata entries).
+1. the `radarVpts` object is initialized according to the selected time range and radar. Sun altitudes at site are also computed and set.
+2. data file(s) are loaded via AJAX, and their content is used to populate `radarVpts` (more specifically, the various properties in each timestamp -> heightdata entries).
3. these data are transformed via computed properties and passed to the child components (that are in charge of the visulization):
- - `VPChart` receives a flattened version of `radarVtps` (`radarVtpsAsArray`, similar to the structure of the initial data files)
+ - `VPChart` receives a flattened version of `radarVpts` (`radarVptsAsArray`, similar to the structure of the initial data files)
- `VPIChart` receives vertically integrated profiles (see `integrateProfile` function in `helpers.ts`).
- `TimelineChart` receives a simple array with the sun altitude for each shown time period.
@@ -128,7 +128,7 @@ It makes use of a few more child components for modularity reasons: `SiteSelecto
### VPChart
-`VPChart` visualizes the raw VTPS data as a heatmap (bird density in function of the time and altitude) with D3. It uses the `DailyLines` component to show vertical lines on the chart each day at midnight and `ColorLegend` to show a legend for the 3 availables colour scales.
+`VPChart` visualizes the raw VPTS data as a heatmap (bird density in function of the time and altitude) with D3. It uses the `DailyLines` component to show vertical lines on the chart each day at midnight and `ColorLegend` to show a legend for the 3 availables colour scales.
## License
diff --git a/src/CrowTypes.ts b/src/CrowTypes.ts
index 94fe297..9a391f9 100644
--- a/src/CrowTypes.ts
+++ b/src/CrowTypes.ts
@@ -51,11 +51,11 @@ export interface RadarInterface {
longitude: number;
timezone: string;
endpoint: string; // URL template, some variables are interpolated. Example: 'https://opendata.meteo.be/ftp/observations/radar/vbird/{odimCode}/{yyyy}/{odimCode}_vpts_{yyyymmdd}.txt'
- vtpsFileFormat: VTPSFileFormat;
+ vptsFileFormat: VPTSFileFormat;
heights: number[]; // Data is available at the following heights
}
-export type VTPSFileFormat = "VOL2BIRD" | "CSV"; // VOL2BIRD: fixed width column. CSV: Follow BioRad's output (see https://github.com/inbo/crow/issues/135)
+export type VPTSFileFormat = "VOL2BIRD" | "CSV"; // VOL2BIRD: fixed width column. CSV: Follow BioRad's output (see https://github.com/inbo/crow/issues/135)
export interface GroupedRadarInterface {
label: string;
@@ -72,7 +72,7 @@ export interface TimeIntervalForRadioGroup {
value: number;
}
-export interface VTPSDataRowFromFile {
+export interface VPTSDataRowFromFile {
datetime: number;
height: number;
dd: number;
@@ -82,7 +82,7 @@ export interface VTPSDataRowFromFile {
eta: number;
}
-export interface VTPSDataRow {
+export interface VPTSDataRow {
datetime?: number;
height?: number;
dd?: number;
@@ -92,7 +92,7 @@ export interface VTPSDataRow {
noData?: boolean; // Field not in original data, but used to know if we have data loaded for the given datetime/height combination
}
-export interface VTPSEntry { // TODO: check: is it a duplicate of VTPSDataRow?
+export interface VPTSEntry { // TODO: check: is it a duplicate of VPTSDataRow?
dd: number;
dens: number;
ff: number;
diff --git a/src/components/Home.vue b/src/components/Home.vue
index 6426bee..df7a98c 100644
--- a/src/components/Home.vue
+++ b/src/components/Home.vue
@@ -137,7 +137,7 @@
{
heightObj[height] = { noData: true };
});
@@ -558,7 +558,7 @@ export default Vue.extend({
};
this.$set(
- this.radarVtps,
+ this.radarVpts,
currentMoment.toDate().getTime(),
metadataObj
);
@@ -595,19 +595,19 @@ export default Vue.extend({
});
},
- /* Store a Vtps data row originating in a file into vtpsData */
- storeDataRow(vtpsDataRow: VTPSDataRowFromFile): void {
- const objToStore = { ...vtpsDataRow, ...{ noData: false } };
+ /* Store a Vpts data row originating in a file into vptsData */
+ storeDataRow(vptsDataRow: VPTSDataRowFromFile): void {
+ const objToStore = { ...vptsDataRow, ...{ noData: false } };
if ( // no (datetime) slot = data not copied. Allow automatic downsampling.
Object.prototype.hasOwnProperty.call(
- this.radarVtps,
- vtpsDataRow.datetime
+ this.radarVpts,
+ vptsDataRow.datetime
)
) {
this.$set(
- this.radarVtps[vtpsDataRow.datetime].heightData,
- vtpsDataRow.height,
+ this.radarVpts[vptsDataRow.datetime].heightData,
+ vptsDataRow.height,
objToStore
);
}
@@ -640,7 +640,7 @@ export default Vue.extend({
for (let currentDate of this.getDatesForData(startMoment, endMoment)) {
const url = helpers.buildVpTsDataUrl(radar, moment(currentDate, "YYYY-MM-DD"));
axios.get(url).then(response => {
- const dayData = helpers.filterVtps(helpers.parseVtps(response.data, radar.vtpsFileFormat));
+ const dayData = helpers.filterVpts(helpers.parseVpts(response.data, radar.vptsFileFormat));
for (const val of dayData) {
this.storeDataRow(val);
diff --git a/src/components/VPChart.vue b/src/components/VPChart.vue
index 7192767..2f289ef 100644
--- a/src/components/VPChart.vue
+++ b/src/components/VPChart.vue
@@ -42,7 +42,7 @@
-
+
VTPSEntry[],
+ vptsData: Array as () => VPTSEntry[],
styleConfig: Object,
scheme: String as () => ColorSchemeIdentifier,
showTimeAs: String, // "UTC" or a TZ database entry (such as "Europe/Brussels")
@@ -299,19 +299,19 @@ export default Vue.extend({
return durationInMs / 1000 / this.dataTemporalResolution + 1;
},
minTimestamp: function (): number {
- const minVal = d3.min(this.vtpsData, function (d: VTPSEntry) {
+ const minVal = d3.min(this.vptsData, function (d: VPTSEntry) {
return d.timestamp;
});
return minVal || 0;
},
maxTimestamp: function (): number {
- const maxVal = d3.max(this.vtpsData, function (d: VTPSEntry) {
+ const maxVal = d3.max(this.vptsData, function (d: VPTSEntry) {
return d.timestamp;
});
return maxVal || 0;
},
maxColorLegendValue: function(): number {
- // We need a prop for this so it gets updated when data is added to vtpsData (and maxDensity is subsequently changed)
+ // We need a prop for this so it gets updated when data is added to vptsData (and maxDensity is subsequently changed)
if (this.selectedColorSchemeConfig.dynamicDomain === true) {
return this.maxDensity
} else {
@@ -319,19 +319,19 @@ export default Vue.extend({
}
},
maxDensity: function (): number {
- const maxVal = d3.max(this.vtpsData, function (d) {
+ const maxVal = d3.max(this.vptsData, function (d) {
return d.dens;
});
return maxVal || 0;
},
dataTemporalResolution: function (): number {
- return (this.vtpsData[this.distinctHeightsMeters.length + 1].timestamp - this.vtpsData[0].timestamp) / 1000;
+ return (this.vptsData[this.distinctHeightsMeters.length + 1].timestamp - this.vptsData[0].timestamp) / 1000;
},
dataVerticalResolutionMeters: function(): number {
return this.distinctHeightsMeters[1] - this.distinctHeightsMeters[0];
},
distinctHeightsMeters: function (): number[] {
- const heightsSet = new Set(this.vtpsData.map((row) => row.height));
+ const heightsSet = new Set(this.vptsData.map((row) => row.height));
return Array.from(heightsSet.values());
},
distinctHeightsMetersPlusOne: function (): number[] {
@@ -369,8 +369,8 @@ export default Vue.extend({
.range([this.innerHeight, 0])
.domain([0, this.maxHeightFeet]);
},
- vtpsDataPrepared: function (): VTPSEntryPrepared[] {
- return this.vtpsData.map((data) => ({
+ vptsDataPrepared: function (): VPTSEntryPrepared[] {
+ return this.vptsData.map((data) => ({
...data,
x: Math.round(Math.round(this.xScale(data.timestamp)) + 1),
@@ -428,7 +428,7 @@ export default Vue.extend({
return 0;
}
},
- getRectColor: function (data: VTPSEntry): string {
+ getRectColor: function (data: VPTSEntry): string {
let color;
const config = this.selectedColorSchemeConfig;
diff --git a/src/config.ts b/src/config.ts
index 64963cd..8edc649 100644
--- a/src/config.ts
+++ b/src/config.ts
@@ -23,31 +23,31 @@ export default {
{
label: "Belgium",
options: [
- { odimCode: "behel", text: "Helchteren", latitude: 51.069199, longitude: 5.406138, timezone: "Europe/Brussels", endpoint: meteoBeUrlTemplate, heights: availableHeights, vtpsFileFormat: 'VOL2BIRD' },
- { odimCode: "bejab", text: "Jabbeke", latitude: 51.1919, longitude: 3.0641, timezone: "Europe/Brussels", endpoint: meteoBeUrlTemplate, heights: availableHeights, vtpsFileFormat: 'VOL2BIRD' },
- { odimCode: "bewid", text: "Wideumont", latitude: 49.9135, longitude: 5.5044, timezone: "Europe/Brussels", endpoint: meteoBeUrlTemplate, heights: availableHeights, vtpsFileFormat: 'VOL2BIRD' },
- { odimCode: "bezav", text: "Zaventem", latitude: 50.9054, longitude: 4.4579, timezone: "Europe/Brussels", endpoint: meteoBeUrlTemplate, heights: availableHeights, vtpsFileFormat: 'VOL2BIRD' },
+ { odimCode: "behel", text: "Helchteren", latitude: 51.069199, longitude: 5.406138, timezone: "Europe/Brussels", endpoint: meteoBeUrlTemplate, heights: availableHeights, vptsFileFormat: 'VOL2BIRD' },
+ { odimCode: "bejab", text: "Jabbeke", latitude: 51.1919, longitude: 3.0641, timezone: "Europe/Brussels", endpoint: meteoBeUrlTemplate, heights: availableHeights, vptsFileFormat: 'VOL2BIRD' },
+ { odimCode: "bewid", text: "Wideumont", latitude: 49.9135, longitude: 5.5044, timezone: "Europe/Brussels", endpoint: meteoBeUrlTemplate, heights: availableHeights, vptsFileFormat: 'VOL2BIRD' },
+ { odimCode: "bezav", text: "Zaventem", latitude: 50.9054, longitude: 4.4579, timezone: "Europe/Brussels", endpoint: meteoBeUrlTemplate, heights: availableHeights, vptsFileFormat: 'VOL2BIRD' },
]
},
{
label: "France",
options: [
- { odimCode: "frabb", text: "Abbeville", latitude: 50.1360, longitude: 1.8347, timezone: "Europe/Paris", endpoint: meteoBeUrlTemplate, heights: availableHeights, vtpsFileFormat: 'VOL2BIRD' },
- { odimCode: "frave", text: "Avesnes", latitude: 50.1283, longitude: 3.8118, timezone: "Europe/Paris", endpoint: meteoBeUrlTemplate, heights: availableHeights, vtpsFileFormat: 'VOL2BIRD' },
+ { odimCode: "frabb", text: "Abbeville", latitude: 50.1360, longitude: 1.8347, timezone: "Europe/Paris", endpoint: meteoBeUrlTemplate, heights: availableHeights, vptsFileFormat: 'VOL2BIRD' },
+ { odimCode: "frave", text: "Avesnes", latitude: 50.1283, longitude: 3.8118, timezone: "Europe/Paris", endpoint: meteoBeUrlTemplate, heights: availableHeights, vptsFileFormat: 'VOL2BIRD' },
]
},
{
label: "Germany",
options: [
- { odimCode: "deess", text: "Essen", latitude: 51.4055, longitude: 6.9669, timezone: "Europe/Berlin", endpoint: meteoBeUrlTemplate, heights: availableHeights, vtpsFileFormat: 'VOL2BIRD' },
- { odimCode: "denhb", text: "Neuheilenbach", latitude: 50.1097, longitude: 6.5483, timezone: "Europe/Berlin", endpoint: meteoBeUrlTemplate, heights: availableHeights, vtpsFileFormat: 'VOL2BIRD' }
+ { odimCode: "deess", text: "Essen", latitude: 51.4055, longitude: 6.9669, timezone: "Europe/Berlin", endpoint: meteoBeUrlTemplate, heights: availableHeights, vptsFileFormat: 'VOL2BIRD' },
+ { odimCode: "denhb", text: "Neuheilenbach", latitude: 50.1097, longitude: 6.5483, timezone: "Europe/Berlin", endpoint: meteoBeUrlTemplate, heights: availableHeights, vptsFileFormat: 'VOL2BIRD' }
]
},
{
label: "Netherlands",
options: [
- { odimCode: "nldhl", text: "Den Helder", latitude: 52.9533, longitude: 4.7899, timezone: "Europe/Amsterdam", endpoint: meteoBeUrlTemplate, heights: availableHeights, vtpsFileFormat: 'VOL2BIRD' },
- { odimCode: "nlhrw", text: "Herwijnen", latitude: 51.83708, longitude: 5.13797, timezone: "Europe/Amsterdam", endpoint: meteoBeUrlTemplate, heights: availableHeights, vtpsFileFormat: 'VOL2BIRD' },
+ { odimCode: "nldhl", text: "Den Helder", latitude: 52.9533, longitude: 4.7899, timezone: "Europe/Amsterdam", endpoint: meteoBeUrlTemplate, heights: availableHeights, vptsFileFormat: 'VOL2BIRD' },
+ { odimCode: "nlhrw", text: "Herwijnen", latitude: 51.83708, longitude: 5.13797, timezone: "Europe/Amsterdam", endpoint: meteoBeUrlTemplate, heights: availableHeights, vptsFileFormat: 'VOL2BIRD' },
]
},
{
@@ -61,7 +61,7 @@ export default {
endpoint: 'https://opendata.vogelwarte.ch/ftp/observations/radar/wr/bird.vpts/{odimCode}/{yyyy}/{odimCode}_vpts_{yyyymmdd}.csv',
//endpoint: 'http://localhost:8000/{odimCode}/{yyyy}/{odimCode}_vpts_{yyyymmdd}.csv',
heights: [0, 200, 400, 600, 800, 1000, 1200, 1400, 1600, 1800, 2000, 2200, 2400, 2600, 2800, 3000, 3200, 3400, 3600, 3800, 4000, 4200, 4400, 4600, 4800, 5000, 5200, 5400, 5600, 5800],
- vtpsFileFormat: 'CSV'
+ vptsFileFormat: 'CSV'
}
]
}
@@ -80,7 +80,7 @@ export default {
initialTimeDisplay: "radarLocal" as TimeDisplayedAsValue,
- appTemporalResolution: 10 * 60, // seconds (this is the resolution we use for calculation and display) Should be a multiple of the data (vtps file) temporal resolution for downsampling, or equal if we want to show data at the highest resolution
+ appTemporalResolution: 10 * 60, // seconds (this is the resolution we use for calculation and display) Should be a multiple of the data (vpts file) temporal resolution for downsampling, or equal if we want to show data at the highest resolution
VPChartStyle: {
margin: { top: 20, right: globalChartMarginRight, bottom: 30, left: globalChartMarginLeft },
diff --git a/src/helpers.ts b/src/helpers.ts
index c45f710..edcb510 100644
--- a/src/helpers.ts
+++ b/src/helpers.ts
@@ -1,11 +1,11 @@
// TODO: move field position (hardcoded constants) to config.js
import * as d3 from "d3";
import moment from "moment-timezone";
-import { LangCode, MultilanguageStringContainer, Profiles, RadarInterface, VTPSDataRowFromFile, VTPSFileFormat } from "./CrowTypes";
+import { LangCode, MultilanguageStringContainer, Profiles, RadarInterface, VPTSDataRowFromFile, VPTSFileFormat } from "./CrowTypes";
import { rgb, RGBColor } from "d3-color";
-const SD_VVP_THRESHOLD = 2; // VTPS data with sd_vvp < sdVpp_treshold are considered NOT birds (insects or rain)
+const SD_VVP_THRESHOLD = 2; // VPTS data with sd_vvp < sdVpp_treshold are considered NOT birds (insects or rain)
function interpolateStdGammaII(val: number): RGBColor {
// Num: between 0 and 1
@@ -23,7 +23,7 @@ function interpolateStdGammaII(val: number): RGBColor {
}
function densityToBirdtam(density: number): number {
- // Takes a density (from VTPS data) and turn it to a BIRDTAM code.
+ // Takes a density (from VPTS data) and turn it to a BIRDTAM code.
// Implementation based on the following explanation from Hans van Gasteren (Dutch Air Force)
/*
RGB codes van 0-4 in licht groen. BIRDTAM 5 is 100% groen en daarna 6 en hoger. Ik heb ook BIRDTAM 9 geintroduceerd om de extremen (en regen) weer te geven. Zo staan ze althans op dit moment op de FlySafe-pagina en in ons artikel
@@ -79,7 +79,7 @@ function parseFloatOrZero(str: string): number {
}
}
-function filterVtps(rows: VTPSDataRowFromFile[], sd_vvpThresh = SD_VVP_THRESHOLD): VTPSDataRowFromFile[] {
+function filterVpts(rows: VPTSDataRowFromFile[], sd_vvpThresh = SD_VVP_THRESHOLD): VPTSDataRowFromFile[] {
// Filter out data rows that are likely not birds, based on sd_vvp (https://github.com/inbo/crow/issues/122)
return rows.filter(function (row) {
return !isNaN(row.sd_vvp) && row.sd_vvp >= sd_vvpThresh
@@ -111,7 +111,7 @@ function csvStringToObjs(csvString: string, lineSeparator='\n', fieldSeparator='
return r
}
-function parseCSVVtps(responseString: string): VTPSDataRowFromFile[] {
+function parseCSVVpts(responseString: string): VPTSDataRowFromFile[] {
// Data file sample: https://github.com/inbo/crow/issues/135#issuecomment-823844454
const lineSeparator = '\n';
const fieldSeparator = ',';
@@ -148,7 +148,7 @@ function buildVpTsDataUrl(radar: RadarInterface, selectedDate: moment.Moment): s
.replaceAll('{yyyymmdd}', selectedDate.format("YYYYMMDD"))
}
-function parseVol2birdVtps(responseString: string): VTPSDataRowFromFile[] {
+function parseVol2birdVpts(responseString: string): VPTSDataRowFromFile[] {
const numHeaderLines = 4;
let d = responseString.split("\n");
@@ -174,15 +174,15 @@ function parseVol2birdVtps(responseString: string): VTPSDataRowFromFile[] {
return r;
}
-function parseVtps(responseString: string, format: VTPSFileFormat): VTPSDataRowFromFile[] {
+function parseVpts(responseString: string, format: VPTSFileFormat): VPTSDataRowFromFile[] {
if (format === 'VOL2BIRD') {
- return parseVol2birdVtps(responseString);
+ return parseVol2birdVpts(responseString);
} else {
- return parseCSVVtps(responseString);
+ return parseCSVVpts(responseString);
}
}
-function integrateProfile(data: VTPSDataRowFromFile[], altMin = 0, altMax = Infinity, interval = 200, sd_vvpThresh = SD_VVP_THRESHOLD, alpha = NaN): Profiles {
+function integrateProfile(data: VPTSDataRowFromFile[], altMin = 0, altMax = Infinity, interval = 200, sd_vvpThresh = SD_VVP_THRESHOLD, alpha = NaN): Profiles {
// TODO: interval and vvpThresh should actually be derived from data/metadata itself
// TODO: extract the data - could be improved by using data itself as input
@@ -277,4 +277,4 @@ function getBrowserFirstLangCode(): string | undefined {
}
-export default { parseVtps, integrateProfile, metersToFeet, makeSafeForCSS, formatTimestamp, formatMoment, uuidv4, densityToBirdtam, interpolateStdGammaII, translateString, filterVtps, getBrowserFirstLangCode, buildVpTsDataUrl }
+export default { parseVpts, integrateProfile, metersToFeet, makeSafeForCSS, formatTimestamp, formatMoment, uuidv4, densityToBirdtam, interpolateStdGammaII, translateString, filterVpts, getBrowserFirstLangCode, buildVpTsDataUrl }
diff --git a/tests/unit/VPChart.spec.ts b/tests/unit/VPChart.spec.ts
index fe2b130..b4d4105 100644
--- a/tests/unit/VPChart.spec.ts
+++ b/tests/unit/VPChart.spec.ts
@@ -5,7 +5,7 @@ import { createLocalVue } from "@vue/test-utils"
import { BootstrapVue } from "bootstrap-vue"
// TODO: move test data to other file?
-const vtpsData = [ // 1 hr of Helchteren data (Feb 9, 2020, centered around noon local time)
+const vptsData = [ // 1 hr of Helchteren data (Feb 9, 2020, centered around noon local time)
{
"timestamp": 1581244200000,
"height": 0,
@@ -2744,7 +2744,7 @@ test("General Chart component rendering & behaviour", () => {
const wrapper = mount(VPChart, {
localVue,
propsData: {
- vtpsData: vtpsData,
+ vptsData: vptsData,
showTimeAs: "Europe/Brussels",
styleConfig: styleConfig
}
diff --git a/tests/unit/crow.spec.ts b/tests/unit/crow.spec.ts
index 7fa7090..1364291 100644
--- a/tests/unit/crow.spec.ts
+++ b/tests/unit/crow.spec.ts
@@ -1,7 +1,7 @@
import { createLocalVue } from "@vue/test-utils"
import { BootstrapVue } from "bootstrap-vue"
import helpers from "../../src/helpers"
-import { VTPSDataRowFromFile } from "@/CrowTypes";
+import { VPTSDataRowFromFile } from "@/CrowTypes";
import * as Papa from "papaparse";
const fs = require("fs");
const path = require("path");
@@ -22,9 +22,9 @@ function round3decimals(num: number): number {
test("Profile integration code (compare to bioRad output)", () => {
// 1. Load and parse the data
- // 1.1 From VTPS file
+ // 1.1 From VPTS file
const sourceData = fs.readFileSync(path.resolve(__dirname, "./data/behel_vpts_20200129.truncated.txt"), "utf-8");
- const VtpsData = helpers.parseVtps(sourceData, 'VOL2BIRD');
+ const VptsData = helpers.parseVpts(sourceData, 'VOL2BIRD');
// 1.2 bioRad's output for comparison (behel_vpi_20200129.truncated.csv)
interface BioRadProfile {
mtr: number;
@@ -39,11 +39,11 @@ test("Profile integration code (compare to bioRad output)", () => {
}).data as BioRadProfile[];
// 2. Group data by datetime (preparation for integrateProfile)
- let lastTimestamp = VtpsData[0].datetime;
- let tempDataToIntegrate = [] as VTPSDataRowFromFile[];
- const groupedDataToIntegrate = [] as VTPSDataRowFromFile[][];
+ let lastTimestamp = VptsData[0].datetime;
+ let tempDataToIntegrate = [] as VPTSDataRowFromFile[];
+ const groupedDataToIntegrate = [] as VPTSDataRowFromFile[][];
- VtpsData.forEach((element) => {
+ VptsData.forEach((element) => {
if (element.datetime != lastTimestamp) {
groupedDataToIntegrate.push(tempDataToIntegrate);
tempDataToIntegrate = []; // If needed, we create a new array for the new timestamp