Skip to content

Commit

Permalink
Merge branch 'impute-historical-condition-set' into combined-rodap-stuff
Browse files Browse the repository at this point in the history
  • Loading branch information
scottbell committed Oct 17, 2024
2 parents a8a1ade + 6ca6a4c commit 707bdbe
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions src/plugins/condition/HistoricalTelemetryProvider.js
Original file line number Diff line number Diff line change
Expand Up @@ -134,13 +134,7 @@ export default class HistoricalTelemetryProvider {
const referenceTelemetryKeyString = Object.keys(dataFrame)[0];
const referenceTelemetryCollection = this.#telemetryCollections[referenceTelemetryKeyString];
const referenceTelemetryData = referenceTelemetryCollection.getAll();
const maxDataPointsToCompute = this.#telemetryOptions.size || referenceTelemetryData.length;
for (
let i = 0;
i < referenceTelemetryData.length && historicalData.length < maxDataPointsToCompute;
i++
) {
const datum = referenceTelemetryData[i];
referenceTelemetryData.forEach((datum) => {
const timestamp = datum[referenceTelemetryCollection.timeKey];
const historicalDatum = this.#computeHistoricalDatum(
timestamp,
Expand All @@ -150,7 +144,7 @@ export default class HistoricalTelemetryProvider {
if (historicalDatum) {
historicalData.push(historicalDatum);
}
}
});
return historicalData;
}

Expand Down

0 comments on commit 707bdbe

Please sign in to comment.