|
2 | 2 | "data":[{
|
3 | 3 | "mode": "markers",
|
4 | 4 | "x": ["a", "b", "c"],
|
5 |
| - "y": ["X", "Y", "Z"] |
| 5 | + "y": ["X", "Y", "Z"], |
| 6 | + "xaxis": "x", |
| 7 | + "yaxis": "y" |
6 | 8 | }, {
|
7 | 9 | "mode": "markers",
|
8 | 10 | "x": ["a", "b", "c"],
|
9 | 11 | "y": ["X", "Y", "Z"],
|
10 | 12 | "xaxis": "x2",
|
11 | 13 | "yaxis": "y2"
|
| 14 | + }, { |
| 15 | + "mode": "markers", |
| 16 | + "x": ["a", "b", "c"], |
| 17 | + "y": ["X", "Y", "Z"], |
| 18 | + "xaxis": "x3", |
| 19 | + "yaxis": "y3" |
| 20 | + }, { |
| 21 | + "mode": "markers", |
| 22 | + "x": ["a", "b", "c"], |
| 23 | + "y": ["X", "Y", "Z"], |
| 24 | + "xaxis": "x4", |
| 25 | + "yaxis": "y4" |
12 | 26 | }],
|
13 | 27 | "layout":{
|
14 |
| - "autosize":false, |
15 | 28 | "xaxis":{
|
| 29 | + "categoryarray": ["a", "b", "c", "d"], |
| 30 | + "anchor": "x", |
16 | 31 | "domain": [0, 0.48],
|
17 | 32 | "ticks": "outside",
|
18 | 33 | "mirror":"allticks",
|
19 | 34 | "zeroline":false,
|
20 | 35 | "showline":true
|
21 | 36 | },
|
22 | 37 | "xaxis2":{
|
| 38 | + "categoryarray": ["a", "b", "c", "d"], |
23 | 39 | "anchor": "y2",
|
24 | 40 | "domain": [0.52, 1],
|
25 | 41 | "ticks": "outside",
|
|
28 | 44 | "showline":true,
|
29 | 45 | "range": [-0.5, 2.5]
|
30 | 46 | },
|
| 47 | + "xaxis3":{ |
| 48 | + "categoryarray": ["a", "b", "c", "d"], |
| 49 | + "side": "top", |
| 50 | + "anchor": "y3", |
| 51 | + "domain": [0, 0.48], |
| 52 | + "ticks": "outside", |
| 53 | + "mirror":"allticks", |
| 54 | + "zeroline":false, |
| 55 | + "showline":true |
| 56 | + }, |
| 57 | + "xaxis4":{ |
| 58 | + "categoryarray": ["a", "b", "c", "d"], |
| 59 | + "side": "top", |
| 60 | + "anchor": "y4", |
| 61 | + "domain": [0.52, 1], |
| 62 | + "ticks": "outside", |
| 63 | + "mirror":"allticks", |
| 64 | + "zeroline":false, |
| 65 | + "showline":true, |
| 66 | + "range": [-0.5, 2.5] |
| 67 | + }, |
31 | 68 | "yaxis":{
|
| 69 | + "categoryarray": ["W", "X", "Y", "Z"], |
| 70 | + "anchor": "y", |
| 71 | + "title": "letter refs", |
| 72 | + "domain": [0, 0.48], |
32 | 73 | "ticks": "outside",
|
33 | 74 | "mirror":"allticks",
|
34 | 75 | "zeroline":false,
|
35 | 76 | "showline":true
|
36 | 77 | },
|
37 | 78 | "yaxis2":{
|
| 79 | + "categoryarray": ["W", "X", "Y", "Z"], |
| 80 | + "domain": [0, 0.48], |
38 | 81 | "anchor": "x2",
|
39 | 82 | "side": "right",
|
40 | 83 | "ticks": "outside",
|
|
43 | 86 | "showline":true,
|
44 | 87 | "range": [-0.5, 2.5]
|
45 | 88 | },
|
46 |
| - "height":360, |
47 |
| - "width":600, |
| 89 | + "yaxis3":{ |
| 90 | + "categoryarray": ["W", "X", "Y", "Z"], |
| 91 | + "title": "number refs", |
| 92 | + "domain": [0.52, 1], |
| 93 | + "anchor": "x3", |
| 94 | + "ticks": "outside", |
| 95 | + "mirror":"allticks", |
| 96 | + "zeroline":false, |
| 97 | + "showline":true |
| 98 | + }, |
| 99 | + "yaxis4":{ |
| 100 | + "categoryarray": ["W", "X", "Y", "Z"], |
| 101 | + "domain": [0.52, 1], |
| 102 | + "anchor": "x4", |
| 103 | + "side": "right", |
| 104 | + "ticks": "outside", |
| 105 | + "mirror":"allticks", |
| 106 | + "zeroline":false, |
| 107 | + "showline":true, |
| 108 | + "range": [-0.5, 2.5] |
| 109 | + }, |
| 110 | + "height": 500, |
| 111 | + "width": 500, |
48 | 112 | "showlegend": false,
|
49 |
| - "margin":{"r":40,"b":40,"l":40,"t":40}, |
| 113 | + "margin":{"r":40,"b":25,"l":40,"t":55}, |
50 | 114 | "title": "left: auto range || right: set range",
|
51 |
| - "titlefont": {"size": 12}, |
| 115 | + "font": {"size": 10}, |
52 | 116 | "annotations":[{
|
53 |
| - "axref": "x", "ayref": "y", |
54 |
| - "text": "bump yrange up", |
55 |
| - "x": "a", "y": 3, |
56 |
| - "ax": "c", "ay": "3.5", |
57 |
| - "xanchor": "left", |
58 |
| - "borderpad": 10 |
| 117 | + "xref": "x", "yref": "y", "axref": "x", "ayref": "y", |
| 118 | + "text": "yrange bump", |
| 119 | + "x": "a", "y": "X", "ax": "c", "ay": "Z", |
| 120 | + "xanchor": "left", "yanchor": "bottom", "borderpad": 10 |
59 | 121 | }, {
|
60 |
| - "axref": "x", "ayref": "y", |
61 |
| - "text": "bump xrange<br>to the left", |
62 |
| - "x": "-1", "y": "Y", |
63 |
| - "ax": 0, "ay": "X" |
| 122 | + "xref": "x", "yref": "y", "showarrow": false, |
| 123 | + "text": "xrange bump", |
| 124 | + "x": "a", "y": "X", |
| 125 | + "xanchor": "right", "borderpad": 10 |
| 126 | + }, |
| 127 | + |
| 128 | + { |
| 129 | + "xref": "x2", "yref": "y2", "showarrow": false, |
| 130 | + "text": "should not see this", |
| 131 | + "x": "b", "y": "Z" |
64 | 132 | }, {
|
65 |
| - "xref": "x2", "yref": "y2", |
| 133 | + "xref": "x2", "yref": "y2", "showarrow": false, |
66 | 134 | "text": "should not see this",
|
67 |
| - "x": "a", "y": 3 |
| 135 | + "x": "d", "y": "X", |
| 136 | + "xanchor": "right", "borderpad": 10 |
68 | 137 | }, {
|
69 |
| - "xref": "x2", "yref": "y2", |
| 138 | + "xref": "x2", "yref": "y2", "showarrow": false, |
| 139 | + "text": "invalid category coords<br>should appear in center of graph", |
| 140 | + "x": "wrong", "y": "not-gonna-work" |
| 141 | + }, |
| 142 | + |
| 143 | + { |
| 144 | + "xref": "x3", "yref": "y3", "axref": "x3", "ayref": "y3", |
| 145 | + "text": "yrange bump", |
| 146 | + "x": 1, "y": 2, "ax": 2, "ay": 4.5, |
| 147 | + "xanchor": "left", "yanchor": "top", "borderpad": 10 |
| 148 | + }, { |
| 149 | + "xref": "x3", "yref": "y3", "showarrow": false, |
| 150 | + "text": "xrange bump", |
| 151 | + "x": -2, "y": 2, |
| 152 | + "xanchor": "left", "borderpad": 10 |
| 153 | + }, |
| 154 | + |
| 155 | + { |
| 156 | + "xref": "x4", "yref": "y4", "showarrow": false, |
70 | 157 | "text": "should not see this",
|
71 |
| - "x": "-1", "y": "Y" |
| 158 | + "x": -2, "y": 2 |
| 159 | + }, { |
| 160 | + "xref": "x4", "yref": "y4", "showarrow": false, |
| 161 | + "text": "should not see this", |
| 162 | + "x": 2, "y": 4.5 |
72 | 163 | }],
|
73 | 164 | "shapes": [{
|
74 | 165 | "type": "rectangle",
|
75 | 166 | "line": {"color": "purple"},
|
76 |
| - "x0": "b", "x1": 4.5, |
77 |
| - "y0": -1, "y1": "Z" |
78 |
| - }, { |
| 167 | + "x0": "b", "x1": "d", |
| 168 | + "y0": "W", "y1": "Z" |
| 169 | + }, |
| 170 | + |
| 171 | + { |
79 | 172 | "xref": "x2", "yref": "y2",
|
80 | 173 | "type": "rectangle",
|
81 | 174 | "line": {"color": "purple"},
|
82 |
| - "x0": "b", "x1": 4.5, |
83 |
| - "y0": -1, "y1": "Z" |
| 175 | + "x0": "---", "x1": "d", |
| 176 | + "y0": "wrong", "y1": "Z" |
| 177 | + }, |
| 178 | + |
| 179 | + { |
| 180 | + "xref": "x3", "yref": "y3", |
| 181 | + "type": "rectangle", |
| 182 | + "line": {"color": "purple"}, |
| 183 | + "x0": 0.25, "x1": 6, |
| 184 | + "y0": 1, "y1": 2.75 |
| 185 | + }, |
| 186 | + |
| 187 | + { |
| 188 | + "xref": "x4", "yref": "y4", |
| 189 | + "type": "rectangle", |
| 190 | + "line": {"color": "purple"}, |
| 191 | + "x0": 0.25, "x1": 6, |
| 192 | + "y0": 1, "y1": 2.75 |
84 | 193 | }]
|
85 | 194 | }
|
86 | 195 | }
|
0 commit comments