MCPcopy Create free account
hub / github.com/chartjs/Chart.js / decimatedConfig

Function decimatedConfig

test/specs/plugin.decimation.spec.js:217–240  ·  view source on GitHub ↗
(dataset)

Source from the content-addressed store, hash-verified

215 });
216
217 function decimatedConfig(dataset) {
218 return {
219 type: 'line',
220 data: {
221 datasets: [dataset]
222 },
223 options: {
224 parsing: false,
225 scales: {
226 x: {
227 type: 'linear'
228 }
229 },
230 plugins: {
231 decimation: {
232 enabled: true,
233 algorithm: 'lttb',
234 samples: 5,
235 threshold: 7
236 }
237 }
238 }
239 };
240 }
241
242 it('should leave a frozen dataset undecimated', function() {
243 const dataset = Object.freeze({data: originalData, label: 'dataset1'});

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected