Published
Edited
Apr 17, 2021
1 fork
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
durMonth = luxon.Duration.fromISO('P1M');
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
myAnnualEnergyByMonth = {
let energy = new my.Energy();
let monthlyenergy = [];
energy._token = 'resource_test';
await energy.load();
monthBoundaries.forEach((interval) => {
let e = energy.range({from: interval.s.toISO(), to: interval.e.toISO() , interval: 1800000 });
monthlyenergy.push({ source: e, count: e.count(), sum: e.sum(), min: e.min(), max: e.max(), mean: e.mean() });
});

return monthlyenergy;
}
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
costs = {
listOfProducts.tariffs.forEach((tariff) => {
let cost = new my.Cost();
cost.init({ energy: listOfProducts.predictedEnergy, tariff: tariff});
console.log(cost);
});
}
Insert cell
luxon.DateTime.fromISO('2021-03-27T23:00:00Z')
Insert cell
myAnnualEnergy = {
let energy = new my.Energy();
energy._token = 'resource_test';
await energy.load();
return energy.range({from: '2020-02-01T00:00:00.000+00:00', to: '2021-03-01T00:00:00.000+00:00' , interval: 1800000 });
}
Insert cell
import {serialize} from '@palewire/saving-csv'
Insert cell
my = require('https://bundle.run/stsc-tsc@1.0.13');
Insert cell
import {table} from '@tmcw/tables/2'
Insert cell
luxon = require("luxon/build/amd/luxon.js")
Insert cell
import {slider} from "@jashkenas/inputs"
Insert cell

Purpose-built for displays of data

Observable is your go-to platform for exploring data and creating expressive data visualizations. Use reactive JavaScript notebooks for prototyping and a collaborative canvas for visual data exploration and dashboard creation.
Learn more