-
-
Notifications
You must be signed in to change notification settings - Fork 23
/
datastructures.ts
52 lines (49 loc) · 1023 Bytes
/
datastructures.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
import type { ChartConfiguration } from 'chart.js';
import type {} from '../../src';
// #region data
const data: ChartConfiguration<'boxplot'>['data'] = {
labels: ['array', '{boxplot values}', 'with items', 'as outliers'],
datasets: [
{
label: 'Dataset 1',
borderWidth: 1,
itemRadius: 2,
itemStyle: 'circle',
itemBackgroundColor: '#000',
outlierBackgroundColor: '#000',
data: [
[1, 2, 3, 4, 5, 11],
{
min: 1,
q1: 2,
median: 3,
q3: 4,
max: 5,
},
{
min: 1,
q1: 2,
median: 3,
q3: 4,
max: 5,
items: [1, 2, 3, 4, 5],
},
{
min: 1,
q1: 2,
median: 3,
q3: 4,
max: 5,
outliers: [11],
},
],
},
],
};
// #endregion data
// #region config
export const config: ChartConfiguration<'boxplot'> = {
type: 'boxplot',
data,
};
// #endregion config