Skip to content

Commit 87b1c44

Browse files
committed
add funnel test - mocks and baselines
1 parent cad13aa commit 87b1c44

36 files changed

+1296
-0
lines changed
Loading
Loading
28.1 KB
Loading

test/image/baselines/funnel_11.png

26.3 KB
Loading
22.2 KB
Loading
13.6 KB
Loading
25 KB
Loading

test/image/baselines/funnel_attrs.png

39.3 KB
Loading
Loading
23.6 KB
Loading

test/image/baselines/funnel_gap0.png

15.8 KB
Loading
Loading
Loading
Loading

test/image/baselines/funnel_line.png

18.8 KB
Loading
23.6 KB
Loading
Loading
Loading
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
{
2+
"data": [
3+
{
4+
"type": "bar",
5+
"orientation": "h",
6+
"y": [ "textposition:outside" ],
7+
"x": [ 0 ],
8+
"text": [ "Text" ],
9+
"textposition": [ "outside" ]
10+
},
11+
{
12+
"type": "bar",
13+
"orientation": "h",
14+
"y": [ "textpostion:auto" ],
15+
"x": [ 0 ],
16+
"text": [ "should not see" ],
17+
"textposition": [ "auto" ]
18+
},
19+
{
20+
"type": "bar",
21+
"orientation": "h",
22+
"y": [ "textpostion:inside" ],
23+
"x": [ 0 ],
24+
"text": [ "should not see" ],
25+
"textposition": [ "inside" ]
26+
}
27+
],
28+
"layout": {
29+
"margin": { "l": 150 },
30+
"showlegend": false,
31+
"width": 600
32+
}
33+
}
Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
{
2+
"data": [
3+
{
4+
"type": "funnel", "opacity": 0.8,
5+
"y": [ 3, 2, 1 ],
6+
"yaxis": "y2"
7+
},
8+
{
9+
"type": "funnel", "opacity": 0.8,
10+
"y": [ 5, 3, 2 ]
11+
},
12+
{
13+
"type": "funnel", "opacity": 0.8,
14+
"y": [ 4, 1, 0 ]
15+
},
16+
{
17+
"type": "funnel", "opacity": 0.8,
18+
"y": [ 3, 2, 1 ],
19+
"alignmentgroup": "top",
20+
"hovertext": "alignmentgroup: top",
21+
"xaxis": "x2",
22+
"yaxis": "y2"
23+
},
24+
{
25+
"type": "funnel", "opacity": 0.8,
26+
"y": [ 5, 3, 2 ],
27+
"hovertext": "alignmentgroup: top<br>offsetgroup: 1",
28+
"alignmentgroup": "bottom",
29+
"offsetgroup": "1",
30+
"xaxis": "x2"
31+
},
32+
{
33+
"type": "funnel", "opacity": 0.8,
34+
"y": [ 4, 1, 0 ],
35+
"hovertext": "alignmentgroup: top<br>offsetgroup: 2",
36+
"alignmentgroup": "bottom",
37+
"offsetgroup": "2",
38+
"xaxis": "x2"
39+
}
40+
],
41+
"layout": {
42+
"funnelmode": "group",
43+
"showlegend": false,
44+
"grid": {
45+
"rows": 2,
46+
"columns": 2,
47+
"roworder": "bottom to top"
48+
},
49+
"colorway": [ "blue", "orange", "green" ],
50+
"margin": { "t": 20 },
51+
"xaxis": {
52+
"title": {
53+
"text": "no alignmentgroup<br>no offsetgroup"
54+
}
55+
},
56+
"xaxis2": {
57+
"title": {
58+
"text": "with alignmentgroup<br>with offsetgroup"
59+
}
60+
}
61+
}
62+
}
Lines changed: 89 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,89 @@
1+
{
2+
"data": [
3+
{
4+
"type": "funnel", "opacity": 0.8,
5+
"x": [ "A", "B", "C", "D" ],
6+
"y": [ 4, 3, 2, 1 ],
7+
"offsetgroup": 1,
8+
"hovertext": "offsetgroup: 1"
9+
},
10+
{
11+
"type": "funnel", "opacity": 0.8,
12+
"x": [ "A", "B", "C", "D" ],
13+
"y": [ 3, 2, 1, 0 ],
14+
"offsetgroup": 2,
15+
"hovertext": "offsetgroup: 2"
16+
},
17+
{
18+
"type": "funnel", "opacity": 0.8,
19+
"x": [ "A", "B", "C", "D" ],
20+
"y": [ 4, 3, 2, 1 ],
21+
"yaxis": "y2",
22+
"offsetgroup": 1,
23+
"hovertext": "offsetgroup: 1"
24+
},
25+
{
26+
"type": "funnel", "opacity": 0.8,
27+
"x": [ "A", "B", "C", "D" ],
28+
"y": [ 3, 2, 1, 0 ],
29+
"yaxis": "y2",
30+
"offsetgroup": 2,
31+
"hovertext": "offsetgroup: 2"
32+
},
33+
{
34+
"type": "funnel", "opacity": 0.8,
35+
"x": [ "A", "B", "C", "D" ],
36+
"y": [ 4, 3, 2, 1 ],
37+
"offsetgroup": 1,
38+
"hovertext": "offsetgroup: 1",
39+
"xaxis": "x2"
40+
},
41+
{
42+
"type": "funnel", "opacity": 0.8,
43+
"x": [ "A", "B", "C", "D" ],
44+
"y": [ 3, 2, 1, 0 ],
45+
"offsetgroup": 2,
46+
"hovertext": "offsetgroup: 2",
47+
"xaxis": "x2"
48+
},
49+
{
50+
"type": "funnel", "opacity": 0.8,
51+
"x": [ "A", "B", "C", "D" ],
52+
"y": [ 4, 3, 2, 1 ],
53+
"yaxis": "y2",
54+
"offsetgroup": 3,
55+
"hovertext": "offsetgroup: 3",
56+
"xaxis": "x2"
57+
},
58+
{
59+
"type": "funnel", "opacity": 0.8,
60+
"x": [ "A", "B", "C", "D" ],
61+
"y": [ 3, 2, 1, 0 ],
62+
"yaxis": "y2",
63+
"offsetgroup": 4,
64+
"hovertext": "offsetgroup: 4",
65+
"xaxis": "x2"
66+
}
67+
],
68+
"layout": {
69+
"funnelmode": "group",
70+
"showlegend": false,
71+
"grid": {
72+
"rows": 2,
73+
"columns": 2
74+
},
75+
"title": {
76+
"text": "funnel offset groups"
77+
},
78+
"xaxis": {
79+
"title": {
80+
"text": "two distinct offset groups"
81+
}
82+
},
83+
"xaxis2": {
84+
"title": {
85+
"text": "four distinct offset groups"
86+
}
87+
}
88+
}
89+
}

0 commit comments

Comments
 (0)