latest version
This commit is contained in:
@@ -255,8 +255,8 @@ console.log(` History: [${allValues.values.join(', ')}]\n`);
|
|||||||
console.log('--- Lagged sample comparison ---');
|
console.log('--- Lagged sample comparison ---');
|
||||||
|
|
||||||
const latest = stats.getCurrentValue(); // existing helper
|
const latest = stats.getCurrentValue(); // existing helper
|
||||||
const prevSample = stats.getLaggedValue(1); // new helper
|
const prevSample = stats.getLaggedValue(2); // new helper
|
||||||
const prevPrevSample = stats.getLaggedValue(2); // optional
|
const prevPrevSample = stats.getLaggedValue(3); // optional
|
||||||
|
|
||||||
if (prevSample) {
|
if (prevSample) {
|
||||||
const delta = latest - prevSample.value;
|
const delta = latest - prevSample.value;
|
||||||
|
|||||||
Reference in New Issue
Block a user