From 57b04b2017183f9bf4b35627a1a99d12b90c4cba Mon Sep 17 00:00:00 2001 From: Kenneth Shaw Date: Sat, 20 Jan 2024 10:34:27 +0700 Subject: [PATCH] Initial commit --- .github/workflows/test.yml | 14 + .gitignore | 6 + LICENSE | 21 + README.md | 90 + echarts.min.js | 45 + echartsgoja.go | 289 + echartsgoja.js | 26 + echartsgoja_test.go | 110 + example_test.go | 203 + gen.sh | 66 + go.mod | 15 + go.sum | 62 + missing.sh | 13 + testdata/area-basic.js | 24 + testdata/area-basic.js.svg | 61 + testdata/area-pieces.js | 63 + testdata/area-pieces.js.svg | 72 + testdata/area-rainfall.js | 144 + testdata/area-rainfall.js.svg | 168 + testdata/area-simple.js | 81 + testdata/area-simple.js.svg | 108 + testdata/area-stack-gradient.js | 189 + testdata/area-stack-gradient.js.svg | 176 + testdata/area-stack.js | 103 + testdata/area-stack.js.svg | 200 + testdata/area-time-axis.js | 64 + testdata/area-time-axis.js.svg | 81 + testdata/bar-animation-delay.js | 71 + testdata/bar-animation-delay.js.svg | 2465 + testdata/bar-background.js | 26 + testdata/bar-background.js.svg | 124 + testdata/bar-brush.js | 106 + testdata/bar-data-color.js | 35 + testdata/bar-data-color.js.svg | 117 + testdata/bar-drilldown.js | 107 + testdata/bar-gradient.js | 85 + testdata/bar-histogram.js | 145 + testdata/bar-label-rotation.js | 173 + testdata/bar-label-rotation.js.svg | 319 + testdata/bar-large.js | 89 + testdata/bar-large.js.svg | 91 + testdata/bar-negative.js | 77 + testdata/bar-negative.js.svg | 313 + testdata/bar-negative2.js | 76 + testdata/bar-negative2.js.svg | 151 + testdata/bar-polar-label-radial.js | 37 + testdata/bar-polar-label-radial.js.svg | 31 + testdata/bar-polar-label-tangential.js | 36 + testdata/bar-polar-label-tangential.js.svg | 40 + testdata/bar-polar-real-estate.js | 111 + testdata/bar-polar-real-estate.js.svg | 544 + testdata/bar-polar-stack-radial.js | 51 + testdata/bar-polar-stack-radial.js.svg | 214 + testdata/bar-polar-stack.js | 52 + testdata/bar-polar-stack.js.svg | 51 + testdata/bar-race-country.js | 153 + testdata/bar-race.js | 70 + testdata/bar-race.js.svg | 34 + testdata/bar-rich-text.js | 148 + testdata/bar-simple.js | 22 + testdata/bar-simple.js.svg | 117 + testdata/bar-stack-borderRadius.js | 88 + testdata/bar-stack-borderRadius.js.svg | 140 + .../bar-stack-normalization-and-variation.js | 100 + testdata/bar-stack-normalization.js | 62 + testdata/bar-stack-normalization.js.svg | 501 + testdata/bar-stack.js | 121 + testdata/bar-stack.js.svg | 816 + testdata/bar-tick-align.js | 43 + testdata/bar-tick-align.js.svg | 116 + testdata/bar-waterfall.js | 65 + testdata/bar-waterfall.js.svg | 166 + testdata/bar-waterfall2.js | 89 + testdata/bar-waterfall2.js.svg | 318 + testdata/bar-y-category-stack.js | 92 + testdata/bar-y-category-stack.js.svg | 503 + testdata/bar-y-category.js | 45 + testdata/bar-y-category.js.svg | 188 + testdata/bar1.js | 75 + testdata/bar1.js.svg | 367 + testdata/boxplot-light-velocity.js | 89 + testdata/boxplot-light-velocity.js.svg | 135 + testdata/boxplot-light-velocity2.js | 92 + testdata/boxplot-light-velocity2.js.svg | 134 + testdata/boxplot-multi.js | 117 + testdata/boxplot-multi.js.svg | 59 + testdata/bubble-gradient.js | 160 + testdata/bubble-gradient.js.svg | 613 + testdata/bump-chart.js | 113 + testdata/bump-chart.js.svg | 266 + testdata/calendar-charts.js | 173 + testdata/calendar-charts.js.svg | 3809 ++ testdata/calendar-effectscatter.js | 164 + testdata/calendar-effectscatter.js.svg | 6300 ++ testdata/calendar-graph.js | 101 + testdata/calendar-graph.js.svg | 572 + testdata/calendar-heatmap.js | 52 + testdata/calendar-heatmap.js.svg | 782 + testdata/calendar-horizontal.js | 71 + testdata/calendar-horizontal.js.svg | 2520 + testdata/calendar-lunar.js | 462 + testdata/calendar-lunar.js.svg | 1220 + testdata/calendar-pie.js | 86 + testdata/calendar-pie.js.svg | 1509 + testdata/calendar-simple.js | 35 + testdata/calendar-simple.js.svg | 768 + testdata/calendar-vertical.js | 79 + testdata/calendar-vertical.js.svg | 2520 + testdata/candlestick-brush.js | 249 + testdata/candlestick-large.js | 199 + testdata/candlestick-large.js.svg | 103 + testdata/candlestick-sh-2015.js | 134 + testdata/candlestick-sh-2015.js.svg | 397 + testdata/candlestick-sh.js | 310 + testdata/candlestick-sh.js.svg | 400 + testdata/candlestick-simple.js | 24 + testdata/candlestick-simple.js.svg | 29 + testdata/candlestick-touch.js | 267 + testdata/candlestick-touch.js.svg | 171 + testdata/circle-packing-with-d3.js | 193 + testdata/confidence-band.js | 118 + testdata/custom-bar-trend.js | 113 + testdata/custom-bar-trend.js.svg | 125 + testdata/custom-calendar-icon.js | 121 + testdata/custom-calendar-icon.js.svg | 45 + testdata/custom-cartesian-polygon.js | 64 + testdata/custom-cartesian-polygon.js.svg | 47 + testdata/custom-error-bar.js | 122 + testdata/custom-error-bar.js.svg | 321 + testdata/custom-error-scatter.js | 131 + testdata/custom-error-scatter.js.svg | 329 + testdata/custom-gantt-flight.js | 523 + testdata/custom-gauge.js | 163 + testdata/custom-hexbin.js | 231 + testdata/custom-ohlc.js | 160 + testdata/custom-polar-heatmap.js | 81 + testdata/custom-polar-heatmap.js.svg | 260 + testdata/custom-profile.js | 113 + testdata/custom-profile.js.svg | 35 + testdata/custom-profit.js | 77 + testdata/custom-profit.js.svg | 46 + testdata/custom-spiral-race.js | 222 + testdata/custom-spiral-race.js.svg | 30 + testdata/custom-wind.js | 117 + testdata/cycle-plot.js | 138 + testdata/cycle-plot.js.svg | 57 + testdata/data-transform-aggregate.js | 136 + testdata/data-transform-filter.js | 84 + testdata/data-transform-multiple-pie.js | 96 + testdata/data-transform-multiple-pie.js.svg | 215 + testdata/data-transform-sort-bar.js | 41 + testdata/data-transform-sort-bar.js.svg | 133 + testdata/dataset-default.js | 55 + testdata/dataset-default.js.svg | 240 + testdata/dataset-encode0.js | 49 + testdata/dataset-encode0.js.svg | 368 + testdata/dataset-encode1.js | 117 + testdata/dataset-link.js | 90 + testdata/dataset-series-layout-by.js | 36 + testdata/dataset-series-layout-by.js.svg | 352 + testdata/dataset-simple0.js | 25 + testdata/dataset-simple0.js.svg | 180 + testdata/dataset-simple1.js | 25 + testdata/dataset-simple1.js.svg | 180 + testdata/doc-example/aria-decal-newspaper.js | 92 + testdata/doc-example/aria-decal-simple.js | 26 + testdata/doc-example/aria-decal.js | 121 + testdata/doc-example/aria-pie.js | 23 + .../doc-example/axisPointer-handle-image.js | 505 + .../axisPointer-handle-image.js.svg | 978 + .../doc-example/bar-dataZoom-filterMode.js | 78 + testdata/doc-example/bar-large.js | 57 + testdata/doc-example/bar-large.js.svg | 48043 ++++++++++++++++ testdata/doc-example/bar-media-timeline.js | 339 + testdata/doc-example/barGrid-barGap.js | 47 + testdata/doc-example/barGrid-barGap.js.svg | 115 + .../doc-example/candlestick-axisPointer.js | 235 + testdata/doc-example/canvas-vs-svg-en.js | 118 + testdata/doc-example/canvas-vs-svg-en.js.svg | 212 + testdata/doc-example/canvas-vs-svg.js | 118 + testdata/doc-example/canvas-vs-svg.js.svg | 212 + .../doc-example/custom-transition-simple.js | 92 + .../custom-transition-simple.js.svg | 41 + .../data-transform-multiple-sort-bar.js | 51 + .../data-transform-multiple-sort-bar.js.svg | 141 + .../doc-example/dataset-encode-simple0.js | 31 + .../doc-example/dataset-encode-simple0.js.svg | 149 + testdata/doc-example/geo-svg-label-basic.js | 41 + testdata/doc-example/geo-svg-layout-basic.js | 131 + testdata/doc-example/geo-svg-named-basic.js | 13 + testdata/doc-example/getting-started.js | 21 + testdata/doc-example/getting-started.js.svg | 108 + testdata/doc-example/graphic-bounding.js | 98 + testdata/doc-example/graphic-bounding.js.svg | 16 + testdata/doc-example/label-position.js | 81 + testdata/doc-example/label-position.js.svg | 60 + testdata/doc-example/line-stack-tiled.js | 46 + testdata/doc-example/line-stack-tiled.js.svg | 124 + testdata/doc-example/map-example.js | 144 + .../map-visualMap-continuous-text.js | 90 + .../doc-example/map-visualMap-continuous.js | 230 + testdata/doc-example/map-visualMap-pieces.js | 76 + .../map-visualMap-piecewise-text.js | 90 + testdata/doc-example/mix-timeline-all.js | 355 + testdata/doc-example/mix-timeline-all.js.svg | 1280 + testdata/doc-example/parallel-all.js | 174 + testdata/doc-example/parallel-all.js.svg | 280 + testdata/doc-example/pictorialBar-clip.js | 94 + testdata/doc-example/pictorialBar-clip.js.svg | 142 + .../doc-example/pictorialBar-graphicType.js | 60 + .../doc-example/pictorialBar-patternSize.js | 44 + testdata/doc-example/pictorialBar-position.js | 52 + .../doc-example/pictorialBar-position.js.svg | 126 + testdata/doc-example/pictorialBar-repeat.js | 25 + .../doc-example/pictorialBar-repeat.js.svg | 131 + .../pictorialBar-repeatDirection.js | 52 + .../pictorialBar-repeatDirection.js.svg | 855 + .../doc-example/pictorialBar-repeatLayout.js | 200 + .../pictorialBar-repeatLayout.js.svg | 787 + .../pictorialBar-symbolBoundingDataArray.js | 82 + ...ictorialBar-symbolBoundingDataArray.js.svg | 1259 + .../doc-example/pictorialBar-symbolSize.js | 110 + .../pictorialBar-symbolSize.js.svg | 158 + testdata/doc-example/pie-highlight.js | 61 + testdata/doc-example/pie-highlight.js.svg | 90 + testdata/doc-example/pie-label-bleedMargin.js | 69 + .../doc-example/pie-label-bleedMargin.js.svg | 51 + .../pie-label-distanceToLabelLine.js | 69 + .../pie-label-distanceToLabelLine.js.svg | 51 + testdata/doc-example/pie-label-margin.js | 69 + testdata/doc-example/pie-label-margin.js.svg | 51 + testdata/doc-example/pie-media.js | 175 + testdata/doc-example/polar-anticlockwise.js | 16 + .../doc-example/polar-anticlockwise.js.svg | 32 + testdata/doc-example/polar-start-angle.js | 16 + testdata/doc-example/polar-start-angle.js.svg | 32 + testdata/doc-example/radar.js | 50 + testdata/doc-example/radar.js.svg | 18 + testdata/doc-example/scatter-dataZoom-all.js | 105 + .../doc-example/scatter-dataZoom-all.js.svg | 167 + .../scatter-tutorial-dataZoom-1.js | 31 + .../scatter-tutorial-dataZoom-1.js.svg | 139 + .../scatter-tutorial-dataZoom-2.js | 36 + .../scatter-tutorial-dataZoom-2.js.svg | 139 + .../scatter-tutorial-dataZoom-3.js | 50 + .../scatter-tutorial-dataZoom-3.js.svg | 143 + .../scatter-visualMap-categories.js | 228 + .../scatter-visualMap-categories.js.svg | 1368 + .../scatter-visualMap-piecewise.js | 467 + testdata/doc-example/sunburst-color.js | 45 + testdata/doc-example/sunburst-color.js.svg | 65 + .../sunburst-highlight-ancestor.js | 71 + .../sunburst-highlight-ancestor.js.svg | 128 + .../sunburst-highlight-descendant.js | 71 + .../sunburst-highlight-descendant.js.svg | 128 + testdata/doc-example/sunburst-label-align.js | 33 + .../doc-example/sunburst-label-align.js.svg | 215 + testdata/doc-example/sunburst-simple.js | 29 + testdata/doc-example/sunburst-simple.js.svg | 65 + testdata/doc-example/text-block-fragment.js | 65 + .../doc-example/text-block-fragment.js.svg | 37 + testdata/doc-example/text-fregment-align.js | 119 + .../doc-example/text-fregment-align.js.svg | 49 + testdata/doc-example/text-options.js | 91 + testdata/doc-example/text-options.js.svg | 42 + .../doc-example/timeline-dynamic-series.js | 71 + .../timeline-dynamic-series.js.svg | 151 + testdata/doc-example/title-block.js | 126 + testdata/doc-example/treemap-borderColor.js | 80 + testdata/doc-example/tutorial-async.js | 41 + testdata/doc-example/tutorial-async.js.svg | 9 + testdata/doc-example/tutorial-dynamic-data.js | 55 + .../doc-example/tutorial-dynamic-data.js.svg | 54 + testdata/doc-example/tutorial-loading.js | 43 + .../doc-example/tutorial-styling-step0.js | 17 + .../doc-example/tutorial-styling-step0.js.svg | 77 + .../doc-example/tutorial-styling-step1.js | 18 + .../doc-example/tutorial-styling-step1.js.svg | 77 + .../doc-example/tutorial-styling-step2.js | 24 + .../doc-example/tutorial-styling-step2.js.svg | 82 + .../doc-example/tutorial-styling-step3.js | 39 + .../doc-example/tutorial-styling-step3.js.svg | 82 + .../doc-example/tutorial-styling-step4.js | 40 + .../doc-example/tutorial-styling-step4.js.svg | 82 + .../doc-example/tutorial-styling-step5.js | 48 + .../doc-example/tutorial-styling-step5.js.svg | 82 + .../doc-example/value-animation-simple.js | 58 + .../doc-example/value-animation-simple.js.svg | 53 + testdata/dynamic-data.js | 144 + testdata/dynamic-data.js.svg | 242 + testdata/dynamic-data2.js | 81 + testdata/dynamic-data2.js.svg | 55 + testdata/effectScatter-bmap.js | 594 + testdata/effectScatter-bmap.js.svg | 6 + testdata/effectScatter-map.js | 505 + testdata/flame-graph.js | 202 + testdata/funnel-align.js | 101 + testdata/funnel-align.js.svg | 305 + testdata/funnel-customize.js | 87 + testdata/funnel-customize.js.svg | 159 + testdata/funnel-mutiple.js | 101 + testdata/funnel-mutiple.js.svg | 304 + testdata/funnel.js | 68 + testdata/funnel.js.svg | 94 + testdata/gauge-barometer.js | 131 + testdata/gauge-barometer.js.svg | 158 + testdata/gauge-car.js | 519 + testdata/gauge-car.js.svg | 223 + testdata/gauge-clock.js | 227 + testdata/gauge-clock.js.svg | 119 + testdata/gauge-grade.js | 96 + testdata/gauge-grade.js.svg | 92 + testdata/gauge-multi-title.js | 93 + testdata/gauge-multi-title.js.svg | 172 + testdata/gauge-progress.js | 97 + testdata/gauge-progress.js.svg | 101 + testdata/gauge-ring.js | 112 + testdata/gauge-ring.js.svg | 53 + testdata/gauge-simple.js | 33 + testdata/gauge-simple.js.svg | 106 + testdata/gauge-speed.js | 59 + testdata/gauge-speed.js.svg | 46 + testdata/gauge-stage.js | 73 + testdata/gauge-stage.js.svg | 106 + testdata/gauge-temperature.js | 139 + testdata/gauge-temperature.js.svg | 106 + testdata/gauge.js | 27 + testdata/gauge.js.svg | 105 + testdata/geo-beef-cuts.js | 71 + testdata/geo-lines.js | 292 + testdata/geo-map-scatter.js | 343 + testdata/geo-organ.js | 82 + testdata/geo-seatmap-flight.js | 83 + testdata/geo-svg-custom-effect.js | 122 + testdata/geo-svg-lines.js | 83 + testdata/geo-svg-map.js | 204 + testdata/geo-svg-scatter-simple.js | 47 + testdata/geo-svg-traffic.js | 167 + testdata/graph-circular-layout.js | 58 + testdata/graph-force-dynamic.js | 59 + testdata/graph-force.js | 49 + testdata/graph-force2.js | 59 + testdata/graph-force2.js.svg | 306 + testdata/graph-grid.js | 50 + testdata/graph-grid.js.svg | 151 + testdata/graph-label-overlap.js | 49 + testdata/graph-life-expectancy.js | 98 + testdata/graph-npm.js | 56 + testdata/graph-simple.js | 99 + testdata/graph-simple.js.svg | 89 + testdata/graph-webkit-dep.js | 42 + testdata/graph.js | 61 + testdata/graphic-loading.js | 51 + testdata/graphic-loading.js.svg | 10 + testdata/graphic-stroke-animation.js | 57 + testdata/graphic-stroke-animation.js.svg | 4 + testdata/graphic-wave-animation.js | 198 + testdata/grid-multiple.js | 178 + testdata/grid-multiple.js.svg | 180 + testdata/heatmap-bmap.js | 46 + testdata/heatmap-cartesian.js | 71 + testdata/heatmap-cartesian.js.svg | 532 + testdata/heatmap-large-piecewise.js | 191 + testdata/heatmap-large-piecewise.js.svg | 1117 + testdata/heatmap-large.js | 183 + testdata/heatmap-large.js.svg | 1320 + testdata/heatmap-map.js | 447 + testdata/line-aqi.js | 115 + testdata/line-draggable.js | 140 + testdata/line-easing.js | 285 + testdata/line-easing.js.svg | 634 + testdata/line-function.js | 73 + testdata/line-function.js.svg | 109 + testdata/line-gradient.js | 86 + testdata/line-gradient.js.svg | 530 + testdata/line-graphic.js | 120 + testdata/line-graphic.js.svg | 79 + .../line-in-cartesian-coordinate-system.js | 21 + ...line-in-cartesian-coordinate-system.js.svg | 67 + testdata/line-log.js | 66 + testdata/line-log.js.svg | 165 + testdata/line-marker.js | 84 + testdata/line-marker.js.svg | 120 + testdata/line-markline.js | 86 + testdata/line-markline.js.svg | 135 + testdata/line-pen.js | 73 + testdata/line-polar.js | 41 + testdata/line-polar.js.svg | 145 + testdata/line-polar2.js | 47 + testdata/line-polar2.js.svg | 46 + testdata/line-race.js | 97 + testdata/line-sections.js | 103 + testdata/line-sections.js.svg | 96 + testdata/line-simple.js | 22 + testdata/line-simple.js.svg | 63 + testdata/line-smooth.js | 23 + testdata/line-smooth.js.svg | 61 + testdata/line-stack.js | 69 + testdata/line-stack.js.svg | 178 + testdata/line-step.js | 56 + testdata/line-step.js.svg | 125 + testdata/line-style.js | 34 + testdata/line-style.js.svg | 59 + testdata/line-tooltip-touch.js | 153 + testdata/line-tooltip-touch.js.svg | 112 + testdata/line-y-category.js | 53 + testdata/line-y-category.js.svg | 73 + testdata/lines-airline.js | 58 + testdata/lines-bmap-bus.js | 163 + testdata/lines-bmap-effect.js | 194 + testdata/lines-bmap.js | 152 + testdata/lines-ny.js | 77 + testdata/map-HK.js | 94 + testdata/map-bar-morph.js | 141 + testdata/map-bin.js | 234 + testdata/map-bin.js.svg | 16 + testdata/map-polygon.js | 655 + testdata/map-polygon.js.svg | 6 + testdata/map-usa-pie.js | 76 + testdata/map-usa-projection.js | 134 + testdata/map-usa.js | 141 + testdata/mix-line-bar.js | 97 + testdata/mix-line-bar.js.svg | 257 + testdata/mix-timeline-finance.js | 434 + testdata/mix-timeline-finance.js.svg | 1288 + testdata/mix-zoom-on-value.js | 95 + testdata/multiple-x-axis.js | 100 + testdata/multiple-x-axis.js.svg | 112 + testdata/multiple-y-axis.js | 111 + testdata/multiple-y-axis.js.svg | 411 + testdata/parallel-aqi.js | 222 + testdata/parallel-aqi.js.svg | 494 + testdata/parallel-nutrients.js | 172 + testdata/parallel-simple.js | 31 + testdata/parallel-simple.js.svg | 81 + testdata/pictorialBar-bar-transition.js | 152 + testdata/pictorialBar-bar-transition.js.svg | 1335 + testdata/pictorialBar-body-fill.js | 164 + testdata/pictorialBar-body-fill.js.svg | 129 + testdata/pictorialBar-dotted.js | 103 + testdata/pictorialBar-dotted.js.svg | 10838 ++++ testdata/pictorialBar-forest.js | 107 + testdata/pictorialBar-forest.js.svg | 124 + testdata/pictorialBar-hill.js | 128 + testdata/pictorialBar-spirit.js | 115 + testdata/pictorialBar-spirit.js.svg | 264 + testdata/pictorialBar-vehicle.js | 121 + testdata/pictorialBar-vehicle.js.svg | 1335 + testdata/pictorialBar-velocity.js | 111 + testdata/pictorialBar-velocity.js.svg | 223 + testdata/pie-alignTo.js | 110 + testdata/pie-alignTo.js.svg | 309 + testdata/pie-borderRadius.js | 50 + testdata/pie-borderRadius.js.svg | 78 + testdata/pie-custom.js | 68 + testdata/pie-custom.js.svg | 84 + testdata/pie-doughnut.js | 45 + testdata/pie-doughnut.js.svg | 78 + testdata/pie-half-donut.js | 56 + testdata/pie-half-donut.js.svg | 111 + testdata/pie-labelLine-adjust.js | 92 + testdata/pie-labelLine-adjust.js.svg | 297 + testdata/pie-legend.js | 73 + testdata/pie-legend.js.svg | 821 + testdata/pie-nest.js | 97 + testdata/pie-nest.js.svg | 259 + testdata/pie-parliament-transition.js | 118 + testdata/pie-parliament-transition.js.svg | 79 + testdata/pie-pattern.js | 60 + testdata/pie-rich-text.js | 134 + testdata/pie-roseType-simple.js | 44 + testdata/pie-roseType-simple.js.svg | 140 + testdata/pie-roseType.js | 91 + testdata/pie-roseType.js.svg | 223 + testdata/pie-simple.js | 42 + testdata/pie-simple.js.svg | 91 + testdata/polar-roundCap.js | 51 + testdata/polar-roundCap.js.svg | 57 + testdata/radar-aqi.js | 208 + testdata/radar-aqi.js.svg | 92 + testdata/radar-custom.js | 129 + testdata/radar-custom.js.svg | 93 + testdata/radar-multiple.js | 107 + testdata/radar-multiple.js.svg | 115 + testdata/radar.js | 42 + testdata/radar.js.svg | 39 + testdata/radar2.js | 74 + testdata/radar2.js.svg | 332 + testdata/sankey-energy.js | 34 + testdata/sankey-itemstyle.js | 1281 + testdata/sankey-itemstyle.js.svg | 334 + testdata/sankey-levels.js | 75 + testdata/sankey-nodeAlign-left.js | 35 + testdata/sankey-nodeAlign-right.js | 36 + testdata/sankey-simple.js | 68 + testdata/sankey-simple.js.svg | 43 + testdata/sankey-vertical.js | 47 + testdata/sankey-vertical.js.svg | 21 + testdata/scatter-aggregate-bar.js | 191 + testdata/scatter-aggregate-bar.js.svg | 7155 +++ testdata/scatter-anscombe-quartet.js | 148 + testdata/scatter-anscombe-quartet.js.svg | 773 + testdata/scatter-aqi-color.js | 253 + testdata/scatter-aqi-color.js.svg | 1878 + testdata/scatter-clustering-process.js | 231 + testdata/scatter-clustering.js | 135 + testdata/scatter-effect.js | 82 + testdata/scatter-effect.js.svg | 3815 ++ testdata/scatter-exponential-regression.js | 89 + testdata/scatter-label-align-right.js | 59 + testdata/scatter-label-align-right.js.svg | 337 + testdata/scatter-label-align-top.js | 52 + testdata/scatter-label-align-top.js.svg | 349 + testdata/scatter-large.js | 73 + testdata/scatter-large.js.svg | 52 + testdata/scatter-life-expectancy-timeline.js | 166 + testdata/scatter-linear-regression.js | 270 + testdata/scatter-logarithmic-regression.js | 140 + testdata/scatter-map-brush.js | 818 + testdata/scatter-map.js | 470 + testdata/scatter-matrix.js | 300 + testdata/scatter-matrix.js.svg | 1795 + testdata/scatter-nebula.js | 75 + testdata/scatter-nutrients-matrix.js | 438 + testdata/scatter-nutrients.js | 167 + testdata/scatter-painter-choice.js | 60 + testdata/scatter-polar-punchCard.js | 75 + testdata/scatter-polar-punchCard.js.svg | 2405 + testdata/scatter-polynomial-regression.js | 88 + testdata/scatter-punchCard.js | 80 + testdata/scatter-punchCard.js.svg | 2451 + testdata/scatter-simple.js | 41 + testdata/scatter-simple.js.svg | 353 + testdata/scatter-single-axis.js | 62 + testdata/scatter-single-axis.js.svg | 2499 + testdata/scatter-stream-visual.js | 57 + testdata/scatter-symbol-morph.js | 137 + testdata/scatter-symbol-morph.js.svg | 1407 + testdata/scatter-weibo.js | 103 + testdata/scatter-weight.js | 275 + testdata/scatter-weight.js.svg | 7181 +++ testdata/scatter-world-population.js | 517 + testdata/sunburst-book.js | 436 + testdata/sunburst-book.js.svg | 871 + testdata/sunburst-borderRadius.js | 84 + testdata/sunburst-borderRadius.js.svg | 16 + testdata/sunburst-drink.js | 860 + testdata/sunburst-drink.js.svg | 1445 + testdata/sunburst-label-rotate.js | 128 + testdata/sunburst-label-rotate.js.svg | 199 + testdata/sunburst-monochrome.js | 242 + testdata/sunburst-monochrome.js.svg | 559 + testdata/sunburst-simple.js | 83 + testdata/sunburst-simple.js.svg | 154 + testdata/sunburst-visualMap.js | 124 + testdata/sunburst-visualMap.js.svg | 450 + testdata/themeRiver-basic.js | 181 + testdata/themeRiver-basic.js.svg | 164 + testdata/themeRiver-lastfm.js | 76 + testdata/tree-basic.js | 49 + testdata/tree-legend.js | 234 + testdata/tree-orient-bottom-top.js | 47 + testdata/tree-orient-right-left.js | 49 + testdata/tree-polyline.js | 168 + testdata/tree-polyline.js.svg | 1375 + testdata/tree-radial.js | 32 + testdata/tree-vertical.js | 45 + testdata/treemap-disk.js | 71 + testdata/treemap-drill-down.js | 81 + testdata/treemap-obama.js | 196 + testdata/treemap-show-parent.js | 86 + testdata/treemap-simple.js | 45 + testdata/treemap-simple.js.svg | 23 + testdata/treemap-sunburst-transition.js | 57 + testdata/treemap-visual.js | 117 + testdata/watermark.js | 235 + testdata/wind-barb.js | 294 + 577 files changed, 203828 insertions(+) create mode 100644 .github/workflows/test.yml create mode 100644 .gitignore create mode 100644 LICENSE create mode 100644 README.md create mode 100644 echarts.min.js create mode 100644 echartsgoja.go create mode 100644 echartsgoja.js create mode 100644 echartsgoja_test.go create mode 100644 example_test.go create mode 100755 gen.sh create mode 100644 go.mod create mode 100644 go.sum create mode 100755 missing.sh create mode 100644 testdata/area-basic.js create mode 100644 testdata/area-basic.js.svg create mode 100644 testdata/area-pieces.js create mode 100644 testdata/area-pieces.js.svg create mode 100644 testdata/area-rainfall.js create mode 100644 testdata/area-rainfall.js.svg create mode 100644 testdata/area-simple.js create mode 100644 testdata/area-simple.js.svg create mode 100644 testdata/area-stack-gradient.js create mode 100644 testdata/area-stack-gradient.js.svg create mode 100644 testdata/area-stack.js create mode 100644 testdata/area-stack.js.svg create mode 100644 testdata/area-time-axis.js create mode 100644 testdata/area-time-axis.js.svg create mode 100644 testdata/bar-animation-delay.js create mode 100644 testdata/bar-animation-delay.js.svg create mode 100644 testdata/bar-background.js create mode 100644 testdata/bar-background.js.svg create mode 100644 testdata/bar-brush.js create mode 100644 testdata/bar-data-color.js create mode 100644 testdata/bar-data-color.js.svg create mode 100644 testdata/bar-drilldown.js create mode 100644 testdata/bar-gradient.js create mode 100644 testdata/bar-histogram.js create mode 100644 testdata/bar-label-rotation.js create mode 100644 testdata/bar-label-rotation.js.svg create mode 100644 testdata/bar-large.js create mode 100644 testdata/bar-large.js.svg create mode 100644 testdata/bar-negative.js create mode 100644 testdata/bar-negative.js.svg create mode 100644 testdata/bar-negative2.js create mode 100644 testdata/bar-negative2.js.svg create mode 100644 testdata/bar-polar-label-radial.js create mode 100644 testdata/bar-polar-label-radial.js.svg create mode 100644 testdata/bar-polar-label-tangential.js create mode 100644 testdata/bar-polar-label-tangential.js.svg create mode 100644 testdata/bar-polar-real-estate.js create mode 100644 testdata/bar-polar-real-estate.js.svg create mode 100644 testdata/bar-polar-stack-radial.js create mode 100644 testdata/bar-polar-stack-radial.js.svg create mode 100644 testdata/bar-polar-stack.js create mode 100644 testdata/bar-polar-stack.js.svg create mode 100644 testdata/bar-race-country.js create mode 100644 testdata/bar-race.js create mode 100644 testdata/bar-race.js.svg create mode 100644 testdata/bar-rich-text.js create mode 100644 testdata/bar-simple.js create mode 100644 testdata/bar-simple.js.svg create mode 100644 testdata/bar-stack-borderRadius.js create mode 100644 testdata/bar-stack-borderRadius.js.svg create mode 100644 testdata/bar-stack-normalization-and-variation.js create mode 100644 testdata/bar-stack-normalization.js create mode 100644 testdata/bar-stack-normalization.js.svg create mode 100644 testdata/bar-stack.js create mode 100644 testdata/bar-stack.js.svg create mode 100644 testdata/bar-tick-align.js create mode 100644 testdata/bar-tick-align.js.svg create mode 100644 testdata/bar-waterfall.js create mode 100644 testdata/bar-waterfall.js.svg create mode 100644 testdata/bar-waterfall2.js create mode 100644 testdata/bar-waterfall2.js.svg create mode 100644 testdata/bar-y-category-stack.js create mode 100644 testdata/bar-y-category-stack.js.svg create mode 100644 testdata/bar-y-category.js create mode 100644 testdata/bar-y-category.js.svg create mode 100644 testdata/bar1.js create mode 100644 testdata/bar1.js.svg create mode 100644 testdata/boxplot-light-velocity.js create mode 100644 testdata/boxplot-light-velocity.js.svg create mode 100644 testdata/boxplot-light-velocity2.js create mode 100644 testdata/boxplot-light-velocity2.js.svg create mode 100644 testdata/boxplot-multi.js create mode 100644 testdata/boxplot-multi.js.svg create mode 100644 testdata/bubble-gradient.js create mode 100644 testdata/bubble-gradient.js.svg create mode 100644 testdata/bump-chart.js create mode 100644 testdata/bump-chart.js.svg create mode 100644 testdata/calendar-charts.js create mode 100644 testdata/calendar-charts.js.svg create mode 100644 testdata/calendar-effectscatter.js create mode 100644 testdata/calendar-effectscatter.js.svg create mode 100644 testdata/calendar-graph.js create mode 100644 testdata/calendar-graph.js.svg create mode 100644 testdata/calendar-heatmap.js create mode 100644 testdata/calendar-heatmap.js.svg create mode 100644 testdata/calendar-horizontal.js create mode 100644 testdata/calendar-horizontal.js.svg create mode 100644 testdata/calendar-lunar.js create mode 100644 testdata/calendar-lunar.js.svg create mode 100644 testdata/calendar-pie.js create mode 100644 testdata/calendar-pie.js.svg create mode 100644 testdata/calendar-simple.js create mode 100644 testdata/calendar-simple.js.svg create mode 100644 testdata/calendar-vertical.js create mode 100644 testdata/calendar-vertical.js.svg create mode 100644 testdata/candlestick-brush.js create mode 100644 testdata/candlestick-large.js create mode 100644 testdata/candlestick-large.js.svg create mode 100644 testdata/candlestick-sh-2015.js create mode 100644 testdata/candlestick-sh-2015.js.svg create mode 100644 testdata/candlestick-sh.js create mode 100644 testdata/candlestick-sh.js.svg create mode 100644 testdata/candlestick-simple.js create mode 100644 testdata/candlestick-simple.js.svg create mode 100644 testdata/candlestick-touch.js create mode 100644 testdata/candlestick-touch.js.svg create mode 100644 testdata/circle-packing-with-d3.js create mode 100644 testdata/confidence-band.js create mode 100644 testdata/custom-bar-trend.js create mode 100644 testdata/custom-bar-trend.js.svg create mode 100644 testdata/custom-calendar-icon.js create mode 100644 testdata/custom-calendar-icon.js.svg create mode 100644 testdata/custom-cartesian-polygon.js create mode 100644 testdata/custom-cartesian-polygon.js.svg create mode 100644 testdata/custom-error-bar.js create mode 100644 testdata/custom-error-bar.js.svg create mode 100644 testdata/custom-error-scatter.js create mode 100644 testdata/custom-error-scatter.js.svg create mode 100644 testdata/custom-gantt-flight.js create mode 100644 testdata/custom-gauge.js create mode 100644 testdata/custom-hexbin.js create mode 100644 testdata/custom-ohlc.js create mode 100644 testdata/custom-polar-heatmap.js create mode 100644 testdata/custom-polar-heatmap.js.svg create mode 100644 testdata/custom-profile.js create mode 100644 testdata/custom-profile.js.svg create mode 100644 testdata/custom-profit.js create mode 100644 testdata/custom-profit.js.svg create mode 100644 testdata/custom-spiral-race.js create mode 100644 testdata/custom-spiral-race.js.svg create mode 100644 testdata/custom-wind.js create mode 100644 testdata/cycle-plot.js create mode 100644 testdata/cycle-plot.js.svg create mode 100644 testdata/data-transform-aggregate.js create mode 100644 testdata/data-transform-filter.js create mode 100644 testdata/data-transform-multiple-pie.js create mode 100644 testdata/data-transform-multiple-pie.js.svg create mode 100644 testdata/data-transform-sort-bar.js create mode 100644 testdata/data-transform-sort-bar.js.svg create mode 100644 testdata/dataset-default.js create mode 100644 testdata/dataset-default.js.svg create mode 100644 testdata/dataset-encode0.js create mode 100644 testdata/dataset-encode0.js.svg create mode 100644 testdata/dataset-encode1.js create mode 100644 testdata/dataset-link.js create mode 100644 testdata/dataset-series-layout-by.js create mode 100644 testdata/dataset-series-layout-by.js.svg create mode 100644 testdata/dataset-simple0.js create mode 100644 testdata/dataset-simple0.js.svg create mode 100644 testdata/dataset-simple1.js create mode 100644 testdata/dataset-simple1.js.svg create mode 100644 testdata/doc-example/aria-decal-newspaper.js create mode 100644 testdata/doc-example/aria-decal-simple.js create mode 100644 testdata/doc-example/aria-decal.js create mode 100644 testdata/doc-example/aria-pie.js create mode 100644 testdata/doc-example/axisPointer-handle-image.js create mode 100644 testdata/doc-example/axisPointer-handle-image.js.svg create mode 100644 testdata/doc-example/bar-dataZoom-filterMode.js create mode 100644 testdata/doc-example/bar-large.js create mode 100644 testdata/doc-example/bar-large.js.svg create mode 100644 testdata/doc-example/bar-media-timeline.js create mode 100644 testdata/doc-example/barGrid-barGap.js create mode 100644 testdata/doc-example/barGrid-barGap.js.svg create mode 100644 testdata/doc-example/candlestick-axisPointer.js create mode 100644 testdata/doc-example/canvas-vs-svg-en.js create mode 100644 testdata/doc-example/canvas-vs-svg-en.js.svg create mode 100644 testdata/doc-example/canvas-vs-svg.js create mode 100644 testdata/doc-example/canvas-vs-svg.js.svg create mode 100644 testdata/doc-example/custom-transition-simple.js create mode 100644 testdata/doc-example/custom-transition-simple.js.svg create mode 100644 testdata/doc-example/data-transform-multiple-sort-bar.js create mode 100644 testdata/doc-example/data-transform-multiple-sort-bar.js.svg create mode 100644 testdata/doc-example/dataset-encode-simple0.js create mode 100644 testdata/doc-example/dataset-encode-simple0.js.svg create mode 100644 testdata/doc-example/geo-svg-label-basic.js create mode 100644 testdata/doc-example/geo-svg-layout-basic.js create mode 100644 testdata/doc-example/geo-svg-named-basic.js create mode 100644 testdata/doc-example/getting-started.js create mode 100644 testdata/doc-example/getting-started.js.svg create mode 100644 testdata/doc-example/graphic-bounding.js create mode 100644 testdata/doc-example/graphic-bounding.js.svg create mode 100644 testdata/doc-example/label-position.js create mode 100644 testdata/doc-example/label-position.js.svg create mode 100644 testdata/doc-example/line-stack-tiled.js create mode 100644 testdata/doc-example/line-stack-tiled.js.svg create mode 100644 testdata/doc-example/map-example.js create mode 100644 testdata/doc-example/map-visualMap-continuous-text.js create mode 100644 testdata/doc-example/map-visualMap-continuous.js create mode 100644 testdata/doc-example/map-visualMap-pieces.js create mode 100644 testdata/doc-example/map-visualMap-piecewise-text.js create mode 100644 testdata/doc-example/mix-timeline-all.js create mode 100644 testdata/doc-example/mix-timeline-all.js.svg create mode 100644 testdata/doc-example/parallel-all.js create mode 100644 testdata/doc-example/parallel-all.js.svg create mode 100644 testdata/doc-example/pictorialBar-clip.js create mode 100644 testdata/doc-example/pictorialBar-clip.js.svg create mode 100644 testdata/doc-example/pictorialBar-graphicType.js create mode 100644 testdata/doc-example/pictorialBar-patternSize.js create mode 100644 testdata/doc-example/pictorialBar-position.js create mode 100644 testdata/doc-example/pictorialBar-position.js.svg create mode 100644 testdata/doc-example/pictorialBar-repeat.js create mode 100644 testdata/doc-example/pictorialBar-repeat.js.svg create mode 100644 testdata/doc-example/pictorialBar-repeatDirection.js create mode 100644 testdata/doc-example/pictorialBar-repeatDirection.js.svg create mode 100644 testdata/doc-example/pictorialBar-repeatLayout.js create mode 100644 testdata/doc-example/pictorialBar-repeatLayout.js.svg create mode 100644 testdata/doc-example/pictorialBar-symbolBoundingDataArray.js create mode 100644 testdata/doc-example/pictorialBar-symbolBoundingDataArray.js.svg create mode 100644 testdata/doc-example/pictorialBar-symbolSize.js create mode 100644 testdata/doc-example/pictorialBar-symbolSize.js.svg create mode 100644 testdata/doc-example/pie-highlight.js create mode 100644 testdata/doc-example/pie-highlight.js.svg create mode 100644 testdata/doc-example/pie-label-bleedMargin.js create mode 100644 testdata/doc-example/pie-label-bleedMargin.js.svg create mode 100644 testdata/doc-example/pie-label-distanceToLabelLine.js create mode 100644 testdata/doc-example/pie-label-distanceToLabelLine.js.svg create mode 100644 testdata/doc-example/pie-label-margin.js create mode 100644 testdata/doc-example/pie-label-margin.js.svg create mode 100644 testdata/doc-example/pie-media.js create mode 100644 testdata/doc-example/polar-anticlockwise.js create mode 100644 testdata/doc-example/polar-anticlockwise.js.svg create mode 100644 testdata/doc-example/polar-start-angle.js create mode 100644 testdata/doc-example/polar-start-angle.js.svg create mode 100644 testdata/doc-example/radar.js create mode 100644 testdata/doc-example/radar.js.svg create mode 100644 testdata/doc-example/scatter-dataZoom-all.js create mode 100644 testdata/doc-example/scatter-dataZoom-all.js.svg create mode 100644 testdata/doc-example/scatter-tutorial-dataZoom-1.js create mode 100644 testdata/doc-example/scatter-tutorial-dataZoom-1.js.svg create mode 100644 testdata/doc-example/scatter-tutorial-dataZoom-2.js create mode 100644 testdata/doc-example/scatter-tutorial-dataZoom-2.js.svg create mode 100644 testdata/doc-example/scatter-tutorial-dataZoom-3.js create mode 100644 testdata/doc-example/scatter-tutorial-dataZoom-3.js.svg create mode 100644 testdata/doc-example/scatter-visualMap-categories.js create mode 100644 testdata/doc-example/scatter-visualMap-categories.js.svg create mode 100644 testdata/doc-example/scatter-visualMap-piecewise.js create mode 100644 testdata/doc-example/sunburst-color.js create mode 100644 testdata/doc-example/sunburst-color.js.svg create mode 100644 testdata/doc-example/sunburst-highlight-ancestor.js create mode 100644 testdata/doc-example/sunburst-highlight-ancestor.js.svg create mode 100644 testdata/doc-example/sunburst-highlight-descendant.js create mode 100644 testdata/doc-example/sunburst-highlight-descendant.js.svg create mode 100644 testdata/doc-example/sunburst-label-align.js create mode 100644 testdata/doc-example/sunburst-label-align.js.svg create mode 100644 testdata/doc-example/sunburst-simple.js create mode 100644 testdata/doc-example/sunburst-simple.js.svg create mode 100644 testdata/doc-example/text-block-fragment.js create mode 100644 testdata/doc-example/text-block-fragment.js.svg create mode 100644 testdata/doc-example/text-fregment-align.js create mode 100644 testdata/doc-example/text-fregment-align.js.svg create mode 100644 testdata/doc-example/text-options.js create mode 100644 testdata/doc-example/text-options.js.svg create mode 100644 testdata/doc-example/timeline-dynamic-series.js create mode 100644 testdata/doc-example/timeline-dynamic-series.js.svg create mode 100644 testdata/doc-example/title-block.js create mode 100644 testdata/doc-example/treemap-borderColor.js create mode 100644 testdata/doc-example/tutorial-async.js create mode 100644 testdata/doc-example/tutorial-async.js.svg create mode 100644 testdata/doc-example/tutorial-dynamic-data.js create mode 100644 testdata/doc-example/tutorial-dynamic-data.js.svg create mode 100644 testdata/doc-example/tutorial-loading.js create mode 100644 testdata/doc-example/tutorial-styling-step0.js create mode 100644 testdata/doc-example/tutorial-styling-step0.js.svg create mode 100644 testdata/doc-example/tutorial-styling-step1.js create mode 100644 testdata/doc-example/tutorial-styling-step1.js.svg create mode 100644 testdata/doc-example/tutorial-styling-step2.js create mode 100644 testdata/doc-example/tutorial-styling-step2.js.svg create mode 100644 testdata/doc-example/tutorial-styling-step3.js create mode 100644 testdata/doc-example/tutorial-styling-step3.js.svg create mode 100644 testdata/doc-example/tutorial-styling-step4.js create mode 100644 testdata/doc-example/tutorial-styling-step4.js.svg create mode 100644 testdata/doc-example/tutorial-styling-step5.js create mode 100644 testdata/doc-example/tutorial-styling-step5.js.svg create mode 100644 testdata/doc-example/value-animation-simple.js create mode 100644 testdata/doc-example/value-animation-simple.js.svg create mode 100644 testdata/dynamic-data.js create mode 100644 testdata/dynamic-data.js.svg create mode 100644 testdata/dynamic-data2.js create mode 100644 testdata/dynamic-data2.js.svg create mode 100644 testdata/effectScatter-bmap.js create mode 100644 testdata/effectScatter-bmap.js.svg create mode 100644 testdata/effectScatter-map.js create mode 100644 testdata/flame-graph.js create mode 100644 testdata/funnel-align.js create mode 100644 testdata/funnel-align.js.svg create mode 100644 testdata/funnel-customize.js create mode 100644 testdata/funnel-customize.js.svg create mode 100644 testdata/funnel-mutiple.js create mode 100644 testdata/funnel-mutiple.js.svg create mode 100644 testdata/funnel.js create mode 100644 testdata/funnel.js.svg create mode 100644 testdata/gauge-barometer.js create mode 100644 testdata/gauge-barometer.js.svg create mode 100644 testdata/gauge-car.js create mode 100644 testdata/gauge-car.js.svg create mode 100644 testdata/gauge-clock.js create mode 100644 testdata/gauge-clock.js.svg create mode 100644 testdata/gauge-grade.js create mode 100644 testdata/gauge-grade.js.svg create mode 100644 testdata/gauge-multi-title.js create mode 100644 testdata/gauge-multi-title.js.svg create mode 100644 testdata/gauge-progress.js create mode 100644 testdata/gauge-progress.js.svg create mode 100644 testdata/gauge-ring.js create mode 100644 testdata/gauge-ring.js.svg create mode 100644 testdata/gauge-simple.js create mode 100644 testdata/gauge-simple.js.svg create mode 100644 testdata/gauge-speed.js create mode 100644 testdata/gauge-speed.js.svg create mode 100644 testdata/gauge-stage.js create mode 100644 testdata/gauge-stage.js.svg create mode 100644 testdata/gauge-temperature.js create mode 100644 testdata/gauge-temperature.js.svg create mode 100644 testdata/gauge.js create mode 100644 testdata/gauge.js.svg create mode 100644 testdata/geo-beef-cuts.js create mode 100644 testdata/geo-lines.js create mode 100644 testdata/geo-map-scatter.js create mode 100644 testdata/geo-organ.js create mode 100644 testdata/geo-seatmap-flight.js create mode 100644 testdata/geo-svg-custom-effect.js create mode 100644 testdata/geo-svg-lines.js create mode 100644 testdata/geo-svg-map.js create mode 100644 testdata/geo-svg-scatter-simple.js create mode 100644 testdata/geo-svg-traffic.js create mode 100644 testdata/graph-circular-layout.js create mode 100644 testdata/graph-force-dynamic.js create mode 100644 testdata/graph-force.js create mode 100644 testdata/graph-force2.js create mode 100644 testdata/graph-force2.js.svg create mode 100644 testdata/graph-grid.js create mode 100644 testdata/graph-grid.js.svg create mode 100644 testdata/graph-label-overlap.js create mode 100644 testdata/graph-life-expectancy.js create mode 100644 testdata/graph-npm.js create mode 100644 testdata/graph-simple.js create mode 100644 testdata/graph-simple.js.svg create mode 100644 testdata/graph-webkit-dep.js create mode 100644 testdata/graph.js create mode 100644 testdata/graphic-loading.js create mode 100644 testdata/graphic-loading.js.svg create mode 100644 testdata/graphic-stroke-animation.js create mode 100644 testdata/graphic-stroke-animation.js.svg create mode 100644 testdata/graphic-wave-animation.js create mode 100644 testdata/grid-multiple.js create mode 100644 testdata/grid-multiple.js.svg create mode 100644 testdata/heatmap-bmap.js create mode 100644 testdata/heatmap-cartesian.js create mode 100644 testdata/heatmap-cartesian.js.svg create mode 100644 testdata/heatmap-large-piecewise.js create mode 100644 testdata/heatmap-large-piecewise.js.svg create mode 100644 testdata/heatmap-large.js create mode 100644 testdata/heatmap-large.js.svg create mode 100644 testdata/heatmap-map.js create mode 100644 testdata/line-aqi.js create mode 100644 testdata/line-draggable.js create mode 100644 testdata/line-easing.js create mode 100644 testdata/line-easing.js.svg create mode 100644 testdata/line-function.js create mode 100644 testdata/line-function.js.svg create mode 100644 testdata/line-gradient.js create mode 100644 testdata/line-gradient.js.svg create mode 100644 testdata/line-graphic.js create mode 100644 testdata/line-graphic.js.svg create mode 100644 testdata/line-in-cartesian-coordinate-system.js create mode 100644 testdata/line-in-cartesian-coordinate-system.js.svg create mode 100644 testdata/line-log.js create mode 100644 testdata/line-log.js.svg create mode 100644 testdata/line-marker.js create mode 100644 testdata/line-marker.js.svg create mode 100644 testdata/line-markline.js create mode 100644 testdata/line-markline.js.svg create mode 100644 testdata/line-pen.js create mode 100644 testdata/line-polar.js create mode 100644 testdata/line-polar.js.svg create mode 100644 testdata/line-polar2.js create mode 100644 testdata/line-polar2.js.svg create mode 100644 testdata/line-race.js create mode 100644 testdata/line-sections.js create mode 100644 testdata/line-sections.js.svg create mode 100644 testdata/line-simple.js create mode 100644 testdata/line-simple.js.svg create mode 100644 testdata/line-smooth.js create mode 100644 testdata/line-smooth.js.svg create mode 100644 testdata/line-stack.js create mode 100644 testdata/line-stack.js.svg create mode 100644 testdata/line-step.js create mode 100644 testdata/line-step.js.svg create mode 100644 testdata/line-style.js create mode 100644 testdata/line-style.js.svg create mode 100644 testdata/line-tooltip-touch.js create mode 100644 testdata/line-tooltip-touch.js.svg create mode 100644 testdata/line-y-category.js create mode 100644 testdata/line-y-category.js.svg create mode 100644 testdata/lines-airline.js create mode 100644 testdata/lines-bmap-bus.js create mode 100644 testdata/lines-bmap-effect.js create mode 100644 testdata/lines-bmap.js create mode 100644 testdata/lines-ny.js create mode 100644 testdata/map-HK.js create mode 100644 testdata/map-bar-morph.js create mode 100644 testdata/map-bin.js create mode 100644 testdata/map-bin.js.svg create mode 100644 testdata/map-polygon.js create mode 100644 testdata/map-polygon.js.svg create mode 100644 testdata/map-usa-pie.js create mode 100644 testdata/map-usa-projection.js create mode 100644 testdata/map-usa.js create mode 100644 testdata/mix-line-bar.js create mode 100644 testdata/mix-line-bar.js.svg create mode 100644 testdata/mix-timeline-finance.js create mode 100644 testdata/mix-timeline-finance.js.svg create mode 100644 testdata/mix-zoom-on-value.js create mode 100644 testdata/multiple-x-axis.js create mode 100644 testdata/multiple-x-axis.js.svg create mode 100644 testdata/multiple-y-axis.js create mode 100644 testdata/multiple-y-axis.js.svg create mode 100644 testdata/parallel-aqi.js create mode 100644 testdata/parallel-aqi.js.svg create mode 100644 testdata/parallel-nutrients.js create mode 100644 testdata/parallel-simple.js create mode 100644 testdata/parallel-simple.js.svg create mode 100644 testdata/pictorialBar-bar-transition.js create mode 100644 testdata/pictorialBar-bar-transition.js.svg create mode 100644 testdata/pictorialBar-body-fill.js create mode 100644 testdata/pictorialBar-body-fill.js.svg create mode 100644 testdata/pictorialBar-dotted.js create mode 100644 testdata/pictorialBar-dotted.js.svg create mode 100644 testdata/pictorialBar-forest.js create mode 100644 testdata/pictorialBar-forest.js.svg create mode 100644 testdata/pictorialBar-hill.js create mode 100644 testdata/pictorialBar-spirit.js create mode 100644 testdata/pictorialBar-spirit.js.svg create mode 100644 testdata/pictorialBar-vehicle.js create mode 100644 testdata/pictorialBar-vehicle.js.svg create mode 100644 testdata/pictorialBar-velocity.js create mode 100644 testdata/pictorialBar-velocity.js.svg create mode 100644 testdata/pie-alignTo.js create mode 100644 testdata/pie-alignTo.js.svg create mode 100644 testdata/pie-borderRadius.js create mode 100644 testdata/pie-borderRadius.js.svg create mode 100644 testdata/pie-custom.js create mode 100644 testdata/pie-custom.js.svg create mode 100644 testdata/pie-doughnut.js create mode 100644 testdata/pie-doughnut.js.svg create mode 100644 testdata/pie-half-donut.js create mode 100644 testdata/pie-half-donut.js.svg create mode 100644 testdata/pie-labelLine-adjust.js create mode 100644 testdata/pie-labelLine-adjust.js.svg create mode 100644 testdata/pie-legend.js create mode 100644 testdata/pie-legend.js.svg create mode 100644 testdata/pie-nest.js create mode 100644 testdata/pie-nest.js.svg create mode 100644 testdata/pie-parliament-transition.js create mode 100644 testdata/pie-parliament-transition.js.svg create mode 100644 testdata/pie-pattern.js create mode 100644 testdata/pie-rich-text.js create mode 100644 testdata/pie-roseType-simple.js create mode 100644 testdata/pie-roseType-simple.js.svg create mode 100644 testdata/pie-roseType.js create mode 100644 testdata/pie-roseType.js.svg create mode 100644 testdata/pie-simple.js create mode 100644 testdata/pie-simple.js.svg create mode 100644 testdata/polar-roundCap.js create mode 100644 testdata/polar-roundCap.js.svg create mode 100644 testdata/radar-aqi.js create mode 100644 testdata/radar-aqi.js.svg create mode 100644 testdata/radar-custom.js create mode 100644 testdata/radar-custom.js.svg create mode 100644 testdata/radar-multiple.js create mode 100644 testdata/radar-multiple.js.svg create mode 100644 testdata/radar.js create mode 100644 testdata/radar.js.svg create mode 100644 testdata/radar2.js create mode 100644 testdata/radar2.js.svg create mode 100644 testdata/sankey-energy.js create mode 100644 testdata/sankey-itemstyle.js create mode 100644 testdata/sankey-itemstyle.js.svg create mode 100644 testdata/sankey-levels.js create mode 100644 testdata/sankey-nodeAlign-left.js create mode 100644 testdata/sankey-nodeAlign-right.js create mode 100644 testdata/sankey-simple.js create mode 100644 testdata/sankey-simple.js.svg create mode 100644 testdata/sankey-vertical.js create mode 100644 testdata/sankey-vertical.js.svg create mode 100644 testdata/scatter-aggregate-bar.js create mode 100644 testdata/scatter-aggregate-bar.js.svg create mode 100644 testdata/scatter-anscombe-quartet.js create mode 100644 testdata/scatter-anscombe-quartet.js.svg create mode 100644 testdata/scatter-aqi-color.js create mode 100644 testdata/scatter-aqi-color.js.svg create mode 100644 testdata/scatter-clustering-process.js create mode 100644 testdata/scatter-clustering.js create mode 100644 testdata/scatter-effect.js create mode 100644 testdata/scatter-effect.js.svg create mode 100644 testdata/scatter-exponential-regression.js create mode 100644 testdata/scatter-label-align-right.js create mode 100644 testdata/scatter-label-align-right.js.svg create mode 100644 testdata/scatter-label-align-top.js create mode 100644 testdata/scatter-label-align-top.js.svg create mode 100644 testdata/scatter-large.js create mode 100644 testdata/scatter-large.js.svg create mode 100644 testdata/scatter-life-expectancy-timeline.js create mode 100644 testdata/scatter-linear-regression.js create mode 100644 testdata/scatter-logarithmic-regression.js create mode 100644 testdata/scatter-map-brush.js create mode 100644 testdata/scatter-map.js create mode 100644 testdata/scatter-matrix.js create mode 100644 testdata/scatter-matrix.js.svg create mode 100644 testdata/scatter-nebula.js create mode 100644 testdata/scatter-nutrients-matrix.js create mode 100644 testdata/scatter-nutrients.js create mode 100644 testdata/scatter-painter-choice.js create mode 100644 testdata/scatter-polar-punchCard.js create mode 100644 testdata/scatter-polar-punchCard.js.svg create mode 100644 testdata/scatter-polynomial-regression.js create mode 100644 testdata/scatter-punchCard.js create mode 100644 testdata/scatter-punchCard.js.svg create mode 100644 testdata/scatter-simple.js create mode 100644 testdata/scatter-simple.js.svg create mode 100644 testdata/scatter-single-axis.js create mode 100644 testdata/scatter-single-axis.js.svg create mode 100644 testdata/scatter-stream-visual.js create mode 100644 testdata/scatter-symbol-morph.js create mode 100644 testdata/scatter-symbol-morph.js.svg create mode 100644 testdata/scatter-weibo.js create mode 100644 testdata/scatter-weight.js create mode 100644 testdata/scatter-weight.js.svg create mode 100644 testdata/scatter-world-population.js create mode 100644 testdata/sunburst-book.js create mode 100644 testdata/sunburst-book.js.svg create mode 100644 testdata/sunburst-borderRadius.js create mode 100644 testdata/sunburst-borderRadius.js.svg create mode 100644 testdata/sunburst-drink.js create mode 100644 testdata/sunburst-drink.js.svg create mode 100644 testdata/sunburst-label-rotate.js create mode 100644 testdata/sunburst-label-rotate.js.svg create mode 100644 testdata/sunburst-monochrome.js create mode 100644 testdata/sunburst-monochrome.js.svg create mode 100644 testdata/sunburst-simple.js create mode 100644 testdata/sunburst-simple.js.svg create mode 100644 testdata/sunburst-visualMap.js create mode 100644 testdata/sunburst-visualMap.js.svg create mode 100644 testdata/themeRiver-basic.js create mode 100644 testdata/themeRiver-basic.js.svg create mode 100644 testdata/themeRiver-lastfm.js create mode 100644 testdata/tree-basic.js create mode 100644 testdata/tree-legend.js create mode 100644 testdata/tree-orient-bottom-top.js create mode 100644 testdata/tree-orient-right-left.js create mode 100644 testdata/tree-polyline.js create mode 100644 testdata/tree-polyline.js.svg create mode 100644 testdata/tree-radial.js create mode 100644 testdata/tree-vertical.js create mode 100644 testdata/treemap-disk.js create mode 100644 testdata/treemap-drill-down.js create mode 100644 testdata/treemap-obama.js create mode 100644 testdata/treemap-show-parent.js create mode 100644 testdata/treemap-simple.js create mode 100644 testdata/treemap-simple.js.svg create mode 100644 testdata/treemap-sunburst-transition.js create mode 100644 testdata/treemap-visual.js create mode 100644 testdata/watermark.js create mode 100644 testdata/wind-barb.js diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml new file mode 100644 index 0000000..244b428 --- /dev/null +++ b/.github/workflows/test.yml @@ -0,0 +1,14 @@ +name: Test +on: [push, pull_request] +jobs: + test: + name: Test + runs-on: ubuntu-latest + steps: + - name: Install Go + uses: actions/setup-go@v4 + - name: Checkout code + uses: actions/checkout@v3 + - name: Test + run: | + CGO_ENABLED=0 TIMEOUT=10m go test -v -timeout=2h ./... diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..be2a736 --- /dev/null +++ b/.gitignore @@ -0,0 +1,6 @@ +/*.svg + +*-orig.svg +*.png +*.jpg +*.txt diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..ae5ae84 --- /dev/null +++ b/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2015-2024 Kenneth Shaw + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/README.md b/README.md new file mode 100644 index 0000000..1fc7127 --- /dev/null +++ b/README.md @@ -0,0 +1,90 @@ +# echartsgoja + +`echartsgoja` renders [Apache ECharts][echarts-examples] as SVGs using the +[`goja`][goja] JavaScript runtime. Developed for use by [`usql`][usql] for +rendering charts. + +[Overview][] | [TODO][] | [About][] + +[Overview]: #overview "Overview" +[TODO]: #todo "TODO" +[About]: #about "About" + +[![Unit Tests][echartsgoja-ci-status]][echartsgoja-ci] +[![Go Reference][goref-echartsgoja-status]][goref-echartsgoja] +[![Discord Discussion][discord-status]][discord] + +[echartsgoja-ci]: https://github.com/xo/echartsgoja/actions/workflows/test.yml +[echartsgoja-ci-status]: https://github.com/xo/echartsgoja/actions/workflows/test.yml/badge.svg +[goref-echartsgoja]: https://pkg.go.dev/github.com/xo/echartsgoja +[goref-echartsgoja-status]: https://pkg.go.dev/badge/github.com/xo/echartsgoja.svg +[discord]: https://discord.gg/yJKEzc7prt "Discord Discussion" +[discord-status]: https://img.shields.io/discord/829150509658013727.svg?label=Discord&logo=Discord&colorB=7289da&style=flat-square "Discord Discussion" + +## Overview + +Install in the usual Go fashion: + +```sh +$ go get github.com/xo/echartsgoja@latest +``` + +Then use like the following: + +```go +package echartsgoja_test + +import ( + "context" + "log" + "os" + + "github.com/xo/echartsgoja" +) + +func Example() { + echarts := echartsgoja.New() + svg, err := echarts.RenderOptions(context.Background(), simpleOpts) + if err != nil { + log.Fatal(err) + } + if err := os.WriteFile("simple.svg", []byte(svg), 0o644); err != nil { + log.Fatal(err) + } + // Output: +} + +const simpleOpts = `{ + "xAxis": { + "type": "category", + "boundaryGap": false, + "data": ["Mon", "Tue", "Wed", "Thu", "Fri", "Sat", "Sun"] + }, + "yAxis": { + "type": "value" + }, + "series": [{ + "data": [820, 932, 901, 934, 1290, 1330, 1320], + "type": "line", + "areaStyle": {} + }] +}` +``` + +## TODO + +- Rewrite as native Go + +## About + +`echartsgoja` was written primarily to support these projects: + +- [usql][usql] - a universal command-line interface for SQL databases + +Users of this package may find the [`github.com/xo/resvg`][resvg] package +helpful in rendering generated SVGs. + +[echarts-examples]: https://echarts.apache.org/examples/en/index.html +[usql]: https://github.com/xo/usql +[resvg]: https://github.com/xo/resvg +[goja]: https://github.com/dop251/goja diff --git a/echarts.min.js b/echarts.min.js new file mode 100644 index 0000000..3e09d31 --- /dev/null +++ b/echarts.min.js @@ -0,0 +1,45 @@ + +/* +* Licensed to the Apache Software Foundation (ASF) under one +* or more contributor license agreements. See the NOTICE file +* distributed with this work for additional information +* regarding copyright ownership. The ASF licenses this file +* to you under the Apache License, Version 2.0 (the +* "License"); you may not use this file except in compliance +* with the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, +* software distributed under the License is distributed on an +* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +* KIND, either express or implied. See the License for the +* specific language governing permissions and limitations +* under the License. +*/ + +!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e((t="undefined"!=typeof globalThis?globalThis:t||self).echarts={})}(this,(function(t){"use strict"; +/*! ***************************************************************************** + Copyright (c) Microsoft Corporation. + + Permission to use, copy, modify, and/or distribute this software for any + purpose with or without fee is hereby granted. + + THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH + REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY + AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, + INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM + LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR + OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR + PERFORMANCE OF THIS SOFTWARE. + ***************************************************************************** */var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])},e(t,n)};function n(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function i(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(i.prototype=n.prototype,new i)}var i=function(){this.firefox=!1,this.ie=!1,this.edge=!1,this.newEdge=!1,this.weChat=!1},r=new function(){this.browser=new i,this.node=!1,this.wxa=!1,this.worker=!1,this.svgSupported=!1,this.touchEventsSupported=!1,this.pointerEventsSupported=!1,this.domSupported=!1,this.transformSupported=!1,this.transform3dSupported=!1,this.hasGlobalWindow="undefined"!=typeof window};"object"==typeof wx&&"function"==typeof wx.getSystemInfoSync?(r.wxa=!0,r.touchEventsSupported=!0):"undefined"==typeof document&&"undefined"!=typeof self?r.worker=!0:"undefined"==typeof navigator?(r.node=!0,r.svgSupported=!0):function(t,e){var n=e.browser,i=t.match(/Firefox\/([\d.]+)/),r=t.match(/MSIE\s([\d.]+)/)||t.match(/Trident\/.+?rv:(([\d.]+))/),o=t.match(/Edge?\/([\d.]+)/),a=/micromessenger/i.test(t);i&&(n.firefox=!0,n.version=i[1]);r&&(n.ie=!0,n.version=r[1]);o&&(n.edge=!0,n.version=o[1],n.newEdge=+o[1].split(".")[0]>18);a&&(n.weChat=!0);e.svgSupported="undefined"!=typeof SVGRect,e.touchEventsSupported="ontouchstart"in window&&!n.ie&&!n.edge,e.pointerEventsSupported="onpointerdown"in window&&(n.edge||n.ie&&+n.version>=11),e.domSupported="undefined"!=typeof document;var s=document.documentElement.style;e.transform3dSupported=(n.ie&&"transition"in s||n.edge||"WebKitCSSMatrix"in window&&"m11"in new WebKitCSSMatrix||"MozPerspective"in s)&&!("OTransition"in s),e.transformSupported=e.transform3dSupported||n.ie&&+n.version>=9}(navigator.userAgent,r);var o="sans-serif",a="12px "+o;var s,l,u=function(t){var e={};if("undefined"==typeof JSON)return e;for(var n=0;n=0)o=r*t.length;else for(var c=0;c>1)%2;a.style.cssText=["position: absolute","visibility: hidden","padding: 0","margin: 0","border-width: 0","user-select: none","width:0","height:0",i[s]+":0",r[l]+":0",i[1-s]+":auto",r[1-l]+":auto",""].join("!important;"),t.appendChild(a),n.push(a)}return n}(e,a),l=function(t,e,n){for(var i=n?"invTrans":"trans",r=e[i],o=e.srcCoords,a=[],s=[],l=!0,u=0;u<4;u++){var h=t[u].getBoundingClientRect(),c=2*u,p=h.left,d=h.top;a.push(p,d),l=l&&o&&p===o[c]&&d===o[c+1],s.push(t[u].offsetLeft,t[u].offsetTop)}return l&&r?r:(e.srcCoords=a,e[i]=n?$t(s,a):$t(a,s))}(s,a,o);if(l)return l(t,n,i),!0}return!1}function ee(t){return"CANVAS"===t.nodeName.toUpperCase()}var ne=/([&<>"'])/g,ie={"&":"&","<":"<",">":">",'"':""","'":"'"};function re(t){return null==t?"":(t+"").replace(ne,(function(t,e){return ie[e]}))}var oe=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,ae=[],se=r.browser.firefox&&+r.browser.version.split(".")[0]<39;function le(t,e,n,i){return n=n||{},i?ue(t,e,n):se&&null!=e.layerX&&e.layerX!==e.offsetX?(n.zrX=e.layerX,n.zrY=e.layerY):null!=e.offsetX?(n.zrX=e.offsetX,n.zrY=e.offsetY):ue(t,e,n),n}function ue(t,e,n){if(r.domSupported&&t.getBoundingClientRect){var i=e.clientX,o=e.clientY;if(ee(t)){var a=t.getBoundingClientRect();return n.zrX=i-a.left,void(n.zrY=o-a.top)}if(te(ae,t,i,o))return n.zrX=ae[0],void(n.zrY=ae[1])}n.zrX=n.zrY=0}function he(t){return t||window.event}function ce(t,e,n){if(null!=(e=he(e)).zrX)return e;var i=e.type;if(i&&i.indexOf("touch")>=0){var r="touchend"!==i?e.targetTouches[0]:e.changedTouches[0];r&&le(t,r,e,n)}else{le(t,e,e,n);var o=function(t){var e=t.wheelDelta;if(e)return e;var n=t.deltaX,i=t.deltaY;if(null==n||null==i)return e;return 3*(0!==i?Math.abs(i):Math.abs(n))*(i>0?-1:i<0?1:n>0?-1:1)}(e);e.zrDelta=o?o/120:-(e.detail||0)/3}var a=e.button;return null==e.which&&void 0!==a&&oe.test(e.type)&&(e.which=1&a?1:2&a?3:4&a?2:0),e}function pe(t,e,n,i){t.addEventListener(e,n,i)}var de=function(t){t.preventDefault(),t.stopPropagation(),t.cancelBubble=!0};function fe(t){return 2===t.which||3===t.which}var ge=function(){function t(){this._track=[]}return t.prototype.recognize=function(t,e,n){return this._doTrack(t,e,n),this._recognize(t)},t.prototype.clear=function(){return this._track.length=0,this},t.prototype._doTrack=function(t,e,n){var i=t.touches;if(i){for(var r={points:[],touches:[],target:e,event:t},o=0,a=i.length;o1&&r&&r.length>1){var a=ye(r)/ye(o);!isFinite(a)&&(a=1),e.pinchScale=a;var s=[((i=r)[0][0]+i[1][0])/2,(i[0][1]+i[1][1])/2];return e.pinchX=s[0],e.pinchY=s[1],{type:"pinch",target:t[0].target,event:e}}}}};function me(){return[1,0,0,1,0,0]}function xe(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=1,t[4]=0,t[5]=0,t}function _e(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[4]=e[4],t[5]=e[5],t}function be(t,e,n){var i=e[0]*n[0]+e[2]*n[1],r=e[1]*n[0]+e[3]*n[1],o=e[0]*n[2]+e[2]*n[3],a=e[1]*n[2]+e[3]*n[3],s=e[0]*n[4]+e[2]*n[5]+e[4],l=e[1]*n[4]+e[3]*n[5]+e[5];return t[0]=i,t[1]=r,t[2]=o,t[3]=a,t[4]=s,t[5]=l,t}function we(t,e,n){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[4]=e[4]+n[0],t[5]=e[5]+n[1],t}function Se(t,e,n){var i=e[0],r=e[2],o=e[4],a=e[1],s=e[3],l=e[5],u=Math.sin(n),h=Math.cos(n);return t[0]=i*h+a*u,t[1]=-i*u+a*h,t[2]=r*h+s*u,t[3]=-r*u+h*s,t[4]=h*o+u*l,t[5]=h*l-u*o,t}function Me(t,e,n){var i=n[0],r=n[1];return t[0]=e[0]*i,t[1]=e[1]*r,t[2]=e[2]*i,t[3]=e[3]*r,t[4]=e[4]*i,t[5]=e[5]*r,t}function Ie(t,e){var n=e[0],i=e[2],r=e[4],o=e[1],a=e[3],s=e[5],l=n*a-o*i;return l?(l=1/l,t[0]=a*l,t[1]=-o*l,t[2]=-i*l,t[3]=n*l,t[4]=(i*s-a*r)*l,t[5]=(o*r-n*s)*l,t):null}function Te(t){var e=[1,0,0,1,0,0];return _e(e,t),e}var Ce=Object.freeze({__proto__:null,create:me,identity:xe,copy:_e,mul:be,translate:we,rotate:Se,scale:Me,invert:Ie,clone:Te}),De=function(){function t(t,e){this.x=t||0,this.y=e||0}return t.prototype.copy=function(t){return this.x=t.x,this.y=t.y,this},t.prototype.clone=function(){return new t(this.x,this.y)},t.prototype.set=function(t,e){return this.x=t,this.y=e,this},t.prototype.equal=function(t){return t.x===this.x&&t.y===this.y},t.prototype.add=function(t){return this.x+=t.x,this.y+=t.y,this},t.prototype.scale=function(t){this.x*=t,this.y*=t},t.prototype.scaleAndAdd=function(t,e){this.x+=t.x*e,this.y+=t.y*e},t.prototype.sub=function(t){return this.x-=t.x,this.y-=t.y,this},t.prototype.dot=function(t){return this.x*t.x+this.y*t.y},t.prototype.len=function(){return Math.sqrt(this.x*this.x+this.y*this.y)},t.prototype.lenSquare=function(){return this.x*this.x+this.y*this.y},t.prototype.normalize=function(){var t=this.len();return this.x/=t,this.y/=t,this},t.prototype.distance=function(t){var e=this.x-t.x,n=this.y-t.y;return Math.sqrt(e*e+n*n)},t.prototype.distanceSquare=function(t){var e=this.x-t.x,n=this.y-t.y;return e*e+n*n},t.prototype.negate=function(){return this.x=-this.x,this.y=-this.y,this},t.prototype.transform=function(t){if(t){var e=this.x,n=this.y;return this.x=t[0]*e+t[2]*n+t[4],this.y=t[1]*e+t[3]*n+t[5],this}},t.prototype.toArray=function(t){return t[0]=this.x,t[1]=this.y,t},t.prototype.fromArray=function(t){this.x=t[0],this.y=t[1]},t.set=function(t,e,n){t.x=e,t.y=n},t.copy=function(t,e){t.x=e.x,t.y=e.y},t.len=function(t){return Math.sqrt(t.x*t.x+t.y*t.y)},t.lenSquare=function(t){return t.x*t.x+t.y*t.y},t.dot=function(t,e){return t.x*e.x+t.y*e.y},t.add=function(t,e,n){t.x=e.x+n.x,t.y=e.y+n.y},t.sub=function(t,e,n){t.x=e.x-n.x,t.y=e.y-n.y},t.scale=function(t,e,n){t.x=e.x*n,t.y=e.y*n},t.scaleAndAdd=function(t,e,n,i){t.x=e.x+n.x*i,t.y=e.y+n.y*i},t.lerp=function(t,e,n,i){var r=1-i;t.x=r*e.x+i*n.x,t.y=r*e.y+i*n.y},t}(),Ae=Math.min,ke=Math.max,Le=new De,Pe=new De,Oe=new De,Re=new De,Ne=new De,Ee=new De,ze=function(){function t(t,e,n,i){n<0&&(t+=n,n=-n),i<0&&(e+=i,i=-i),this.x=t,this.y=e,this.width=n,this.height=i}return t.prototype.union=function(t){var e=Ae(t.x,this.x),n=Ae(t.y,this.y);isFinite(this.x)&&isFinite(this.width)?this.width=ke(t.x+t.width,this.x+this.width)-e:this.width=t.width,isFinite(this.y)&&isFinite(this.height)?this.height=ke(t.y+t.height,this.y+this.height)-n:this.height=t.height,this.x=e,this.y=n},t.prototype.applyTransform=function(e){t.applyTransform(this,this,e)},t.prototype.calculateTransform=function(t){var e=this,n=t.width/e.width,i=t.height/e.height,r=[1,0,0,1,0,0];return we(r,r,[-e.x,-e.y]),Me(r,r,[n,i]),we(r,r,[t.x,t.y]),r},t.prototype.intersect=function(e,n){if(!e)return!1;e instanceof t||(e=t.create(e));var i=this,r=i.x,o=i.x+i.width,a=i.y,s=i.y+i.height,l=e.x,u=e.x+e.width,h=e.y,c=e.y+e.height,p=!(of&&(f=x,gf&&(f=_,v=n.x&&t<=n.x+n.width&&e>=n.y&&e<=n.y+n.height},t.prototype.clone=function(){return new t(this.x,this.y,this.width,this.height)},t.prototype.copy=function(e){t.copy(this,e)},t.prototype.plain=function(){return{x:this.x,y:this.y,width:this.width,height:this.height}},t.prototype.isFinite=function(){return isFinite(this.x)&&isFinite(this.y)&&isFinite(this.width)&&isFinite(this.height)},t.prototype.isZero=function(){return 0===this.width||0===this.height},t.create=function(e){return new t(e.x,e.y,e.width,e.height)},t.copy=function(t,e){t.x=e.x,t.y=e.y,t.width=e.width,t.height=e.height},t.applyTransform=function(e,n,i){if(i){if(i[1]<1e-5&&i[1]>-1e-5&&i[2]<1e-5&&i[2]>-1e-5){var r=i[0],o=i[3],a=i[4],s=i[5];return e.x=n.x*r+a,e.y=n.y*o+s,e.width=n.width*r,e.height=n.height*o,e.width<0&&(e.x+=e.width,e.width=-e.width),void(e.height<0&&(e.y+=e.height,e.height=-e.height))}Le.x=Oe.x=n.x,Le.y=Re.y=n.y,Pe.x=Re.x=n.x+n.width,Pe.y=Oe.y=n.y+n.height,Le.transform(i),Re.transform(i),Pe.transform(i),Oe.transform(i),e.x=Ae(Le.x,Pe.x,Oe.x,Re.x),e.y=Ae(Le.y,Pe.y,Oe.y,Re.y);var l=ke(Le.x,Pe.x,Oe.x,Re.x),u=ke(Le.y,Pe.y,Oe.y,Re.y);e.width=l-e.x,e.height=u-e.y}else e!==n&&t.copy(e,n)},t}(),Ve="silent";function Be(){de(this.event)}var Fe=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.handler=null,e}return n(e,t),e.prototype.dispose=function(){},e.prototype.setCursor=function(){},e}(jt),Ge=function(t,e){this.x=t,this.y=e},We=["click","dblclick","mousewheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],He=new ze(0,0,0,0),Ye=function(t){function e(e,n,i,r,o){var a=t.call(this)||this;return a._hovered=new Ge(0,0),a.storage=e,a.painter=n,a.painterRoot=r,a._pointerSize=o,i=i||new Fe,a.proxy=null,a.setHandlerProxy(i),a._draggingMgr=new Zt(a),a}return n(e,t),e.prototype.setHandlerProxy=function(t){this.proxy&&this.proxy.dispose(),t&&(E(We,(function(e){t.on&&t.on(e,this[e],this)}),this),t.handler=this),this.proxy=t},e.prototype.mousemove=function(t){var e=t.zrX,n=t.zrY,i=Ze(this,e,n),r=this._hovered,o=r.target;o&&!o.__zr&&(o=(r=this.findHover(r.x,r.y)).target);var a=this._hovered=i?new Ge(e,n):this.findHover(e,n),s=a.target,l=this.proxy;l.setCursor&&l.setCursor(s?s.cursor:"default"),o&&s!==o&&this.dispatchToElement(r,"mouseout",t),this.dispatchToElement(a,"mousemove",t),s&&s!==o&&this.dispatchToElement(a,"mouseover",t)},e.prototype.mouseout=function(t){var e=t.zrEventControl;"only_globalout"!==e&&this.dispatchToElement(this._hovered,"mouseout",t),"no_globalout"!==e&&this.trigger("globalout",{type:"globalout",event:t})},e.prototype.resize=function(){this._hovered=new Ge(0,0)},e.prototype.dispatch=function(t,e){var n=this[t];n&&n.call(this,e)},e.prototype.dispose=function(){this.proxy.dispose(),this.storage=null,this.proxy=null,this.painter=null},e.prototype.setCursorStyle=function(t){var e=this.proxy;e.setCursor&&e.setCursor(t)},e.prototype.dispatchToElement=function(t,e,n){var i=(t=t||{}).target;if(!i||!i.silent){for(var r="on"+e,o=function(t,e,n){return{type:t,event:n,target:e.target,topTarget:e.topTarget,cancelBubble:!1,offsetX:n.zrX,offsetY:n.zrY,gestureEvent:n.gestureEvent,pinchX:n.pinchX,pinchY:n.pinchY,pinchScale:n.pinchScale,wheelDelta:n.zrDelta,zrByTouch:n.zrByTouch,which:n.which,stop:Be}}(e,t,n);i&&(i[r]&&(o.cancelBubble=!!i[r].call(i,o)),i.trigger(e,o),i=i.__hostTarget?i.__hostTarget:i.parent,!o.cancelBubble););o.cancelBubble||(this.trigger(e,o),this.painter&&this.painter.eachOtherLayer&&this.painter.eachOtherLayer((function(t){"function"==typeof t[r]&&t[r].call(t,o),t.trigger&&t.trigger(e,o)})))}},e.prototype.findHover=function(t,e,n){var i=this.storage.getDisplayList(),r=new Ge(t,e);if(Ue(i,r,t,e,n),this._pointerSize&&!r.target){for(var o=[],a=this._pointerSize,s=a/2,l=new ze(t-s,e-s,a,a),u=i.length-1;u>=0;u--){var h=i[u];h===n||h.ignore||h.ignoreCoarsePointer||h.parent&&h.parent.ignoreCoarsePointer||(He.copy(h.getBoundingRect()),h.transform&&He.applyTransform(h.transform),He.intersect(l)&&o.push(h))}if(o.length)for(var c=Math.PI/12,p=2*Math.PI,d=0;d=0;o--){var a=t[o],s=void 0;if(a!==r&&!a.ignore&&(s=Xe(a,n,i))&&(!e.topTarget&&(e.topTarget=a),s!==Ve)){e.target=a;break}}}function Ze(t,e,n){var i=t.painter;return e<0||e>i.getWidth()||n<0||n>i.getHeight()}E(["click","mousedown","mouseup","mousewheel","dblclick","contextmenu"],(function(t){Ye.prototype[t]=function(e){var n,i,r=e.zrX,o=e.zrY,a=Ze(this,r,o);if("mouseup"===t&&a||(i=(n=this.findHover(r,o)).target),"mousedown"===t)this._downEl=i,this._downPoint=[e.zrX,e.zrY],this._upEl=i;else if("mouseup"===t)this._upEl=i;else if("click"===t){if(this._downEl!==this._upEl||!this._downPoint||Vt(this._downPoint,[e.zrX,e.zrY])>4)return;this._downPoint=null}this.dispatchToElement(n,t,e)}}));function je(t,e,n,i){var r=e+1;if(r===n)return 1;if(i(t[r++],t[e])<0){for(;r=0;)r++;return r-e}function qe(t,e,n,i,r){for(i===e&&i++;i>>1])<0?l=o:s=o+1;var u=i-s;switch(u){case 3:t[s+3]=t[s+2];case 2:t[s+2]=t[s+1];case 1:t[s+1]=t[s];break;default:for(;u>0;)t[s+u]=t[s+u-1],u--}t[s]=a}}function Ke(t,e,n,i,r,o){var a=0,s=0,l=1;if(o(t,e[n+r])>0){for(s=i-r;l0;)a=l,(l=1+(l<<1))<=0&&(l=s);l>s&&(l=s),a+=r,l+=r}else{for(s=r+1;ls&&(l=s);var u=a;a=r-l,l=r-u}for(a++;a>>1);o(t,e[n+h])>0?a=h+1:l=h}return l}function $e(t,e,n,i,r,o){var a=0,s=0,l=1;if(o(t,e[n+r])<0){for(s=r+1;ls&&(l=s);var u=a;a=r-l,l=r-u}else{for(s=i-r;l=0;)a=l,(l=1+(l<<1))<=0&&(l=s);l>s&&(l=s),a+=r,l+=r}for(a++;a>>1);o(t,e[n+h])<0?l=h:a=h+1}return l}function Je(t,e){var n,i,r=7,o=0;t.length;var a=[];function s(s){var l=n[s],u=i[s],h=n[s+1],c=i[s+1];i[s]=u+c,s===o-3&&(n[s+1]=n[s+2],i[s+1]=i[s+2]),o--;var p=$e(t[h],t,l,u,0,e);l+=p,0!==(u-=p)&&0!==(c=Ke(t[l+u-1],t,h,c,c-1,e))&&(u<=c?function(n,i,o,s){var l=0;for(l=0;l=7||d>=7);if(f)break;g<0&&(g=0),g+=2}if((r=g)<1&&(r=1),1===i){for(l=0;l=0;l--)t[d+l]=t[p+l];return void(t[c]=a[h])}var f=r;for(;;){var g=0,y=0,v=!1;do{if(e(a[h],t[u])<0){if(t[c--]=t[u--],g++,y=0,0==--i){v=!0;break}}else if(t[c--]=a[h--],y++,g=0,1==--s){v=!0;break}}while((g|y)=0;l--)t[d+l]=t[p+l];if(0===i){v=!0;break}}if(t[c--]=a[h--],1==--s){v=!0;break}if(0!==(y=s-Ke(t[u],a,0,s,s-1,e))){for(s-=y,d=(c-=y)+1,p=(h-=y)+1,l=0;l=7||y>=7);if(v)break;f<0&&(f=0),f+=2}(r=f)<1&&(r=1);if(1===s){for(d=(c-=i)+1,p=(u-=i)+1,l=i-1;l>=0;l--)t[d+l]=t[p+l];t[c]=a[h]}else{if(0===s)throw new Error;for(p=c-(s-1),l=0;l1;){var t=o-2;if(t>=1&&i[t-1]<=i[t]+i[t+1]||t>=2&&i[t-2]<=i[t]+i[t-1])i[t-1]i[t+1])break;s(t)}},forceMergeRuns:function(){for(;o>1;){var t=o-2;t>0&&i[t-1]=32;)e|=1&t,t>>=1;return t+e}(r);do{if((o=je(t,n,i,e))s&&(l=s),qe(t,n,n+l,n+o,e),o=l}a.pushRun(n,o),a.mergeRuns(),r-=o,n+=o}while(0!==r);a.forceMergeRuns()}}}var tn=!1;function en(){tn||(tn=!0,console.warn("z / z2 / zlevel of displayable is invalid, which may cause unexpected errors"))}function nn(t,e){return t.zlevel===e.zlevel?t.z===e.z?t.z2-e.z2:t.z-e.z:t.zlevel-e.zlevel}var rn=function(){function t(){this._roots=[],this._displayList=[],this._displayListLen=0,this.displayableSortFunc=nn}return t.prototype.traverse=function(t,e){for(var n=0;n0&&(u.__clipPaths=[]),isNaN(u.z)&&(en(),u.z=0),isNaN(u.z2)&&(en(),u.z2=0),isNaN(u.zlevel)&&(en(),u.zlevel=0),this._displayList[this._displayListLen++]=u}var h=t.getDecalElement&&t.getDecalElement();h&&this._updateAndAddDisplayable(h,e,n);var c=t.getTextGuideLine();c&&this._updateAndAddDisplayable(c,e,n);var p=t.getTextContent();p&&this._updateAndAddDisplayable(p,e,n)}},t.prototype.addRoot=function(t){t.__zr&&t.__zr.storage===this||this._roots.push(t)},t.prototype.delRoot=function(t){if(t instanceof Array)for(var e=0,n=t.length;e=0&&this._roots.splice(i,1)}},t.prototype.delAllRoots=function(){this._roots=[],this._displayList=[],this._displayListLen=0},t.prototype.getRoots=function(){return this._roots},t.prototype.dispose=function(){this._displayList=null,this._roots=null},t}(),on=r.hasGlobalWindow&&(window.requestAnimationFrame&&window.requestAnimationFrame.bind(window)||window.msRequestAnimationFrame&&window.msRequestAnimationFrame.bind(window)||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame)||function(t){return setTimeout(t,16)},an={linear:function(t){return t},quadraticIn:function(t){return t*t},quadraticOut:function(t){return t*(2-t)},quadraticInOut:function(t){return(t*=2)<1?.5*t*t:-.5*(--t*(t-2)-1)},cubicIn:function(t){return t*t*t},cubicOut:function(t){return--t*t*t+1},cubicInOut:function(t){return(t*=2)<1?.5*t*t*t:.5*((t-=2)*t*t+2)},quarticIn:function(t){return t*t*t*t},quarticOut:function(t){return 1- --t*t*t*t},quarticInOut:function(t){return(t*=2)<1?.5*t*t*t*t:-.5*((t-=2)*t*t*t-2)},quinticIn:function(t){return t*t*t*t*t},quinticOut:function(t){return--t*t*t*t*t+1},quinticInOut:function(t){return(t*=2)<1?.5*t*t*t*t*t:.5*((t-=2)*t*t*t*t+2)},sinusoidalIn:function(t){return 1-Math.cos(t*Math.PI/2)},sinusoidalOut:function(t){return Math.sin(t*Math.PI/2)},sinusoidalInOut:function(t){return.5*(1-Math.cos(Math.PI*t))},exponentialIn:function(t){return 0===t?0:Math.pow(1024,t-1)},exponentialOut:function(t){return 1===t?1:1-Math.pow(2,-10*t)},exponentialInOut:function(t){return 0===t?0:1===t?1:(t*=2)<1?.5*Math.pow(1024,t-1):.5*(2-Math.pow(2,-10*(t-1)))},circularIn:function(t){return 1-Math.sqrt(1-t*t)},circularOut:function(t){return Math.sqrt(1- --t*t)},circularInOut:function(t){return(t*=2)<1?-.5*(Math.sqrt(1-t*t)-1):.5*(Math.sqrt(1-(t-=2)*t)+1)},elasticIn:function(t){var e,n=.1;return 0===t?0:1===t?1:(!n||n<1?(n=1,e=.1):e=.4*Math.asin(1/n)/(2*Math.PI),-n*Math.pow(2,10*(t-=1))*Math.sin((t-e)*(2*Math.PI)/.4))},elasticOut:function(t){var e,n=.1;return 0===t?0:1===t?1:(!n||n<1?(n=1,e=.1):e=.4*Math.asin(1/n)/(2*Math.PI),n*Math.pow(2,-10*t)*Math.sin((t-e)*(2*Math.PI)/.4)+1)},elasticInOut:function(t){var e,n=.1,i=.4;return 0===t?0:1===t?1:(!n||n<1?(n=1,e=.1):e=i*Math.asin(1/n)/(2*Math.PI),(t*=2)<1?n*Math.pow(2,10*(t-=1))*Math.sin((t-e)*(2*Math.PI)/i)*-.5:n*Math.pow(2,-10*(t-=1))*Math.sin((t-e)*(2*Math.PI)/i)*.5+1)},backIn:function(t){var e=1.70158;return t*t*((e+1)*t-e)},backOut:function(t){var e=1.70158;return--t*t*((e+1)*t+e)+1},backInOut:function(t){var e=2.5949095;return(t*=2)<1?t*t*((e+1)*t-e)*.5:.5*((t-=2)*t*((e+1)*t+e)+2)},bounceIn:function(t){return 1-an.bounceOut(1-t)},bounceOut:function(t){return t<1/2.75?7.5625*t*t:t<2/2.75?7.5625*(t-=1.5/2.75)*t+.75:t<2.5/2.75?7.5625*(t-=2.25/2.75)*t+.9375:7.5625*(t-=2.625/2.75)*t+.984375},bounceInOut:function(t){return t<.5?.5*an.bounceIn(2*t):.5*an.bounceOut(2*t-1)+.5}},sn=Math.pow,ln=Math.sqrt,un=1e-8,hn=1e-4,cn=ln(3),pn=1/3,dn=Mt(),fn=Mt(),gn=Mt();function yn(t){return t>-1e-8&&tun||t<-1e-8}function mn(t,e,n,i,r){var o=1-r;return o*o*(o*t+3*r*e)+r*r*(r*i+3*o*n)}function xn(t,e,n,i,r){var o=1-r;return 3*(((e-t)*o+2*(n-e)*r)*o+(i-n)*r*r)}function _n(t,e,n,i,r,o){var a=i+3*(e-n)-t,s=3*(n-2*e+t),l=3*(e-t),u=t-r,h=s*s-3*a*l,c=s*l-9*a*u,p=l*l-3*s*u,d=0;if(yn(h)&&yn(c)){if(yn(s))o[0]=0;else(M=-l/s)>=0&&M<=1&&(o[d++]=M)}else{var f=c*c-4*h*p;if(yn(f)){var g=c/h,y=-g/2;(M=-s/a+g)>=0&&M<=1&&(o[d++]=M),y>=0&&y<=1&&(o[d++]=y)}else if(f>0){var v=ln(f),m=h*s+1.5*a*(-c+v),x=h*s+1.5*a*(-c-v);(M=(-s-((m=m<0?-sn(-m,pn):sn(m,pn))+(x=x<0?-sn(-x,pn):sn(x,pn))))/(3*a))>=0&&M<=1&&(o[d++]=M)}else{var _=(2*h*s-3*a*c)/(2*ln(h*h*h)),b=Math.acos(_)/3,w=ln(h),S=Math.cos(b),M=(-s-2*w*S)/(3*a),I=(y=(-s+w*(S+cn*Math.sin(b)))/(3*a),(-s+w*(S-cn*Math.sin(b)))/(3*a));M>=0&&M<=1&&(o[d++]=M),y>=0&&y<=1&&(o[d++]=y),I>=0&&I<=1&&(o[d++]=I)}}return d}function bn(t,e,n,i,r){var o=6*n-12*e+6*t,a=9*e+3*i-3*t-9*n,s=3*e-3*t,l=0;if(yn(a)){if(vn(o))(h=-s/o)>=0&&h<=1&&(r[l++]=h)}else{var u=o*o-4*a*s;if(yn(u))r[0]=-o/(2*a);else if(u>0){var h,c=ln(u),p=(-o-c)/(2*a);(h=(-o+c)/(2*a))>=0&&h<=1&&(r[l++]=h),p>=0&&p<=1&&(r[l++]=p)}}return l}function wn(t,e,n,i,r,o){var a=(e-t)*r+t,s=(n-e)*r+e,l=(i-n)*r+n,u=(s-a)*r+a,h=(l-s)*r+s,c=(h-u)*r+u;o[0]=t,o[1]=a,o[2]=u,o[3]=c,o[4]=c,o[5]=h,o[6]=l,o[7]=i}function Sn(t,e,n,i,r,o,a,s,l,u,h){var c,p,d,f,g,y=.005,v=1/0;dn[0]=l,dn[1]=u;for(var m=0;m<1;m+=.05)fn[0]=mn(t,n,r,a,m),fn[1]=mn(e,i,o,s,m),(f=Ft(dn,fn))=0&&f=0&&y=1?1:_n(0,i,o,1,t,s)&&mn(0,r,a,1,s[0])}}}var On=function(){function t(t){this._inited=!1,this._startTime=0,this._pausedTime=0,this._paused=!1,this._life=t.life||1e3,this._delay=t.delay||0,this.loop=t.loop||!1,this.onframe=t.onframe||bt,this.ondestroy=t.ondestroy||bt,this.onrestart=t.onrestart||bt,t.easing&&this.setEasing(t.easing)}return t.prototype.step=function(t,e){if(this._inited||(this._startTime=t+this._delay,this._inited=!0),!this._paused){var n=this._life,i=t-this._startTime-this._pausedTime,r=i/n;r<0&&(r=0),r=Math.min(r,1);var o=this.easingFunc,a=o?o(r):r;if(this.onframe(a),1===r){if(!this.loop)return!0;var s=i%n;this._startTime=t-s,this._pausedTime=0,this.onrestart()}return!1}this._pausedTime+=e},t.prototype.pause=function(){this._paused=!0},t.prototype.resume=function(){this._paused=!1},t.prototype.setEasing=function(t){this.easing=t,this.easingFunc=X(t)?t:an[t]||Pn(t)},t}(),Rn=function(t){this.value=t},Nn=function(){function t(){this._len=0}return t.prototype.insert=function(t){var e=new Rn(t);return this.insertEntry(e),e},t.prototype.insertEntry=function(t){this.head?(this.tail.next=t,t.prev=this.tail,t.next=null,this.tail=t):this.head=this.tail=t,this._len++},t.prototype.remove=function(t){var e=t.prev,n=t.next;e?e.next=n:this.head=n,n?n.prev=e:this.tail=e,t.next=t.prev=null,this._len--},t.prototype.len=function(){return this._len},t.prototype.clear=function(){this.head=this.tail=null,this._len=0},t}(),En=function(){function t(t){this._list=new Nn,this._maxSize=10,this._map={},this._maxSize=t}return t.prototype.put=function(t,e){var n=this._list,i=this._map,r=null;if(null==i[t]){var o=n.len(),a=this._lastRemovedEntry;if(o>=this._maxSize&&o>0){var s=n.head;n.remove(s),delete i[s.key],r=s.value,this._lastRemovedEntry=s}a?a.value=e:a=new Rn(e),a.key=t,n.insertEntry(a),i[t]=a}return r},t.prototype.get=function(t){var e=this._map[t],n=this._list;if(null!=e)return e!==n.tail&&(n.remove(e),n.insertEntry(e)),e.value},t.prototype.clear=function(){this._list.clear(),this._map={}},t.prototype.len=function(){return this._list.len()},t}(),zn={transparent:[0,0,0,0],aliceblue:[240,248,255,1],antiquewhite:[250,235,215,1],aqua:[0,255,255,1],aquamarine:[127,255,212,1],azure:[240,255,255,1],beige:[245,245,220,1],bisque:[255,228,196,1],black:[0,0,0,1],blanchedalmond:[255,235,205,1],blue:[0,0,255,1],blueviolet:[138,43,226,1],brown:[165,42,42,1],burlywood:[222,184,135,1],cadetblue:[95,158,160,1],chartreuse:[127,255,0,1],chocolate:[210,105,30,1],coral:[255,127,80,1],cornflowerblue:[100,149,237,1],cornsilk:[255,248,220,1],crimson:[220,20,60,1],cyan:[0,255,255,1],darkblue:[0,0,139,1],darkcyan:[0,139,139,1],darkgoldenrod:[184,134,11,1],darkgray:[169,169,169,1],darkgreen:[0,100,0,1],darkgrey:[169,169,169,1],darkkhaki:[189,183,107,1],darkmagenta:[139,0,139,1],darkolivegreen:[85,107,47,1],darkorange:[255,140,0,1],darkorchid:[153,50,204,1],darkred:[139,0,0,1],darksalmon:[233,150,122,1],darkseagreen:[143,188,143,1],darkslateblue:[72,61,139,1],darkslategray:[47,79,79,1],darkslategrey:[47,79,79,1],darkturquoise:[0,206,209,1],darkviolet:[148,0,211,1],deeppink:[255,20,147,1],deepskyblue:[0,191,255,1],dimgray:[105,105,105,1],dimgrey:[105,105,105,1],dodgerblue:[30,144,255,1],firebrick:[178,34,34,1],floralwhite:[255,250,240,1],forestgreen:[34,139,34,1],fuchsia:[255,0,255,1],gainsboro:[220,220,220,1],ghostwhite:[248,248,255,1],gold:[255,215,0,1],goldenrod:[218,165,32,1],gray:[128,128,128,1],green:[0,128,0,1],greenyellow:[173,255,47,1],grey:[128,128,128,1],honeydew:[240,255,240,1],hotpink:[255,105,180,1],indianred:[205,92,92,1],indigo:[75,0,130,1],ivory:[255,255,240,1],khaki:[240,230,140,1],lavender:[230,230,250,1],lavenderblush:[255,240,245,1],lawngreen:[124,252,0,1],lemonchiffon:[255,250,205,1],lightblue:[173,216,230,1],lightcoral:[240,128,128,1],lightcyan:[224,255,255,1],lightgoldenrodyellow:[250,250,210,1],lightgray:[211,211,211,1],lightgreen:[144,238,144,1],lightgrey:[211,211,211,1],lightpink:[255,182,193,1],lightsalmon:[255,160,122,1],lightseagreen:[32,178,170,1],lightskyblue:[135,206,250,1],lightslategray:[119,136,153,1],lightslategrey:[119,136,153,1],lightsteelblue:[176,196,222,1],lightyellow:[255,255,224,1],lime:[0,255,0,1],limegreen:[50,205,50,1],linen:[250,240,230,1],magenta:[255,0,255,1],maroon:[128,0,0,1],mediumaquamarine:[102,205,170,1],mediumblue:[0,0,205,1],mediumorchid:[186,85,211,1],mediumpurple:[147,112,219,1],mediumseagreen:[60,179,113,1],mediumslateblue:[123,104,238,1],mediumspringgreen:[0,250,154,1],mediumturquoise:[72,209,204,1],mediumvioletred:[199,21,133,1],midnightblue:[25,25,112,1],mintcream:[245,255,250,1],mistyrose:[255,228,225,1],moccasin:[255,228,181,1],navajowhite:[255,222,173,1],navy:[0,0,128,1],oldlace:[253,245,230,1],olive:[128,128,0,1],olivedrab:[107,142,35,1],orange:[255,165,0,1],orangered:[255,69,0,1],orchid:[218,112,214,1],palegoldenrod:[238,232,170,1],palegreen:[152,251,152,1],paleturquoise:[175,238,238,1],palevioletred:[219,112,147,1],papayawhip:[255,239,213,1],peachpuff:[255,218,185,1],peru:[205,133,63,1],pink:[255,192,203,1],plum:[221,160,221,1],powderblue:[176,224,230,1],purple:[128,0,128,1],red:[255,0,0,1],rosybrown:[188,143,143,1],royalblue:[65,105,225,1],saddlebrown:[139,69,19,1],salmon:[250,128,114,1],sandybrown:[244,164,96,1],seagreen:[46,139,87,1],seashell:[255,245,238,1],sienna:[160,82,45,1],silver:[192,192,192,1],skyblue:[135,206,235,1],slateblue:[106,90,205,1],slategray:[112,128,144,1],slategrey:[112,128,144,1],snow:[255,250,250,1],springgreen:[0,255,127,1],steelblue:[70,130,180,1],tan:[210,180,140,1],teal:[0,128,128,1],thistle:[216,191,216,1],tomato:[255,99,71,1],turquoise:[64,224,208,1],violet:[238,130,238,1],wheat:[245,222,179,1],white:[255,255,255,1],whitesmoke:[245,245,245,1],yellow:[255,255,0,1],yellowgreen:[154,205,50,1]};function Vn(t){return(t=Math.round(t))<0?0:t>255?255:t}function Bn(t){return t<0?0:t>1?1:t}function Fn(t){var e=t;return e.length&&"%"===e.charAt(e.length-1)?Vn(parseFloat(e)/100*255):Vn(parseInt(e,10))}function Gn(t){var e=t;return e.length&&"%"===e.charAt(e.length-1)?Bn(parseFloat(e)/100):Bn(parseFloat(e))}function Wn(t,e,n){return n<0?n+=1:n>1&&(n-=1),6*n<1?t+(e-t)*n*6:2*n<1?e:3*n<2?t+(e-t)*(2/3-n)*6:t}function Hn(t,e,n){return t+(e-t)*n}function Yn(t,e,n,i,r){return t[0]=e,t[1]=n,t[2]=i,t[3]=r,t}function Xn(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t}var Un=new En(20),Zn=null;function jn(t,e){Zn&&Xn(Zn,e),Zn=Un.put(t,Zn||e.slice())}function qn(t,e){if(t){e=e||[];var n=Un.get(t);if(n)return Xn(e,n);var i=(t+="").replace(/ /g,"").toLowerCase();if(i in zn)return Xn(e,zn[i]),jn(t,e),e;var r,o=i.length;if("#"===i.charAt(0))return 4===o||5===o?(r=parseInt(i.slice(1,4),16))>=0&&r<=4095?(Yn(e,(3840&r)>>4|(3840&r)>>8,240&r|(240&r)>>4,15&r|(15&r)<<4,5===o?parseInt(i.slice(4),16)/15:1),jn(t,e),e):void Yn(e,0,0,0,1):7===o||9===o?(r=parseInt(i.slice(1,7),16))>=0&&r<=16777215?(Yn(e,(16711680&r)>>16,(65280&r)>>8,255&r,9===o?parseInt(i.slice(7),16)/255:1),jn(t,e),e):void Yn(e,0,0,0,1):void 0;var a=i.indexOf("("),s=i.indexOf(")");if(-1!==a&&s+1===o){var l=i.substr(0,a),u=i.substr(a+1,s-(a+1)).split(","),h=1;switch(l){case"rgba":if(4!==u.length)return 3===u.length?Yn(e,+u[0],+u[1],+u[2],1):Yn(e,0,0,0,1);h=Gn(u.pop());case"rgb":return u.length>=3?(Yn(e,Fn(u[0]),Fn(u[1]),Fn(u[2]),3===u.length?h:Gn(u[3])),jn(t,e),e):void Yn(e,0,0,0,1);case"hsla":return 4!==u.length?void Yn(e,0,0,0,1):(u[3]=Gn(u[3]),Kn(u,e),jn(t,e),e);case"hsl":return 3!==u.length?void Yn(e,0,0,0,1):(Kn(u,e),jn(t,e),e);default:return}}Yn(e,0,0,0,1)}}function Kn(t,e){var n=(parseFloat(t[0])%360+360)%360/360,i=Gn(t[1]),r=Gn(t[2]),o=r<=.5?r*(i+1):r+i-r*i,a=2*r-o;return Yn(e=e||[],Vn(255*Wn(a,o,n+1/3)),Vn(255*Wn(a,o,n)),Vn(255*Wn(a,o,n-1/3)),1),4===t.length&&(e[3]=t[3]),e}function $n(t,e){var n=qn(t);if(n){for(var i=0;i<3;i++)n[i]=e<0?n[i]*(1-e)|0:(255-n[i])*e+n[i]|0,n[i]>255?n[i]=255:n[i]<0&&(n[i]=0);return ri(n,4===n.length?"rgba":"rgb")}}function Jn(t,e,n){if(e&&e.length&&t>=0&&t<=1){n=n||[];var i=t*(e.length-1),r=Math.floor(i),o=Math.ceil(i),a=e[r],s=e[o],l=i-r;return n[0]=Vn(Hn(a[0],s[0],l)),n[1]=Vn(Hn(a[1],s[1],l)),n[2]=Vn(Hn(a[2],s[2],l)),n[3]=Bn(Hn(a[3],s[3],l)),n}}var Qn=Jn;function ti(t,e,n){if(e&&e.length&&t>=0&&t<=1){var i=t*(e.length-1),r=Math.floor(i),o=Math.ceil(i),a=qn(e[r]),s=qn(e[o]),l=i-r,u=ri([Vn(Hn(a[0],s[0],l)),Vn(Hn(a[1],s[1],l)),Vn(Hn(a[2],s[2],l)),Bn(Hn(a[3],s[3],l))],"rgba");return n?{color:u,leftIndex:r,rightIndex:o,value:i}:u}}var ei=ti;function ni(t,e,n,i){var r=qn(t);if(t)return r=function(t){if(t){var e,n,i=t[0]/255,r=t[1]/255,o=t[2]/255,a=Math.min(i,r,o),s=Math.max(i,r,o),l=s-a,u=(s+a)/2;if(0===l)e=0,n=0;else{n=u<.5?l/(s+a):l/(2-s-a);var h=((s-i)/6+l/2)/l,c=((s-r)/6+l/2)/l,p=((s-o)/6+l/2)/l;i===s?e=p-c:r===s?e=1/3+h-p:o===s&&(e=2/3+c-h),e<0&&(e+=1),e>1&&(e-=1)}var d=[360*e,n,u];return null!=t[3]&&d.push(t[3]),d}}(r),null!=e&&(r[0]=function(t){return(t=Math.round(t))<0?0:t>360?360:t}(e)),null!=n&&(r[1]=Gn(n)),null!=i&&(r[2]=Gn(i)),ri(Kn(r),"rgba")}function ii(t,e){var n=qn(t);if(n&&null!=e)return n[3]=Bn(e),ri(n,"rgba")}function ri(t,e){if(t&&t.length){var n=t[0]+","+t[1]+","+t[2];return"rgba"!==e&&"hsva"!==e&&"hsla"!==e||(n+=","+t[3]),e+"("+n+")"}}function oi(t,e){var n=qn(t);return n?(.299*n[0]+.587*n[1]+.114*n[2])*n[3]/255+(1-n[3])*e:0}var ai=Object.freeze({__proto__:null,parse:qn,lift:$n,toHex:function(t){var e=qn(t);if(e)return((1<<24)+(e[0]<<16)+(e[1]<<8)+ +e[2]).toString(16).slice(1)},fastLerp:Jn,fastMapToColor:Qn,lerp:ti,mapToColor:ei,modifyHSL:ni,modifyAlpha:ii,stringify:ri,lum:oi,random:function(){return ri([Math.round(255*Math.random()),Math.round(255*Math.random()),Math.round(255*Math.random())],"rgb")}}),si=Math.round;function li(t){var e;if(t&&"transparent"!==t){if("string"==typeof t&&t.indexOf("rgba")>-1){var n=qn(t);n&&(t="rgb("+n[0]+","+n[1]+","+n[2]+")",e=n[3])}}else t="none";return{color:t,opacity:null==e?1:e}}var ui=1e-4;function hi(t){return t-1e-4}function ci(t){return si(1e3*t)/1e3}function pi(t){return si(1e4*t)/1e4}var di={left:"start",right:"end",center:"middle",middle:"middle"};function fi(t){return t&&!!t.image}function gi(t){return fi(t)||function(t){return t&&!!t.svgElement}(t)}function yi(t){return"linear"===t.type}function vi(t){return"radial"===t.type}function mi(t){return t&&("linear"===t.type||"radial"===t.type)}function xi(t){return"url(#"+t+")"}function _i(t){var e=t.getGlobalScale(),n=Math.max(e[0],e[1]);return Math.max(Math.ceil(Math.log(n)/Math.log(10)),1)}function bi(t){var e=t.x||0,n=t.y||0,i=(t.rotation||0)*wt,r=rt(t.scaleX,1),o=rt(t.scaleY,1),a=t.skewX||0,s=t.skewY||0,l=[];return(e||n)&&l.push("translate("+e+"px,"+n+"px)"),i&&l.push("rotate("+i+")"),1===r&&1===o||l.push("scale("+r+","+o+")"),(a||s)&&l.push("skew("+si(a*wt)+"deg, "+si(s*wt)+"deg)"),l.join(" ")}var wi=r.hasGlobalWindow&&X(window.btoa)?function(t){return window.btoa(unescape(encodeURIComponent(t)))}:"undefined"!=typeof Buffer?function(t){return Buffer.from(t).toString("base64")}:function(t){return null},Si=Array.prototype.slice;function Mi(t,e,n){return(e-t)*n+t}function Ii(t,e,n,i){for(var r=e.length,o=0;oi?e:t,o=Math.min(n,i),a=r[o-1]||{color:[0,0,0,0],offset:0},s=o;sa)i.length=a;else for(var s=o;s=1},t.prototype.getAdditiveTrack=function(){return this._additiveTrack},t.prototype.addKeyframe=function(t,e,n){this._needsSort=!0;var i=this.keyframes,r=i.length,o=!1,a=6,s=e;if(N(e)){var l=function(t){return N(t&&t[0])?2:1}(e);a=l,(1===l&&!j(e[0])||2===l&&!j(e[0][0]))&&(o=!0)}else if(j(e)&&!nt(e))a=0;else if(U(e))if(isNaN(+e)){var u=qn(e);u&&(s=u,a=3)}else a=0;else if(Q(e)){var h=A({},s);h.colorStops=z(e.colorStops,(function(t){return{offset:t.offset,color:qn(t.color)}})),yi(e)?a=4:vi(e)&&(a=5),s=h}0===r?this.valType=a:a===this.valType&&6!==a||(o=!0),this.discrete=this.discrete||o;var c={time:t,value:s,rawValue:e,percent:0};return n&&(c.easing=n,c.easingFunc=X(n)?n:an[n]||Pn(n)),i.push(c),c},t.prototype.prepare=function(t,e){var n=this.keyframes;this._needsSort&&n.sort((function(t,e){return t.time-e.time}));for(var i=this.valType,r=n.length,o=n[r-1],a=this.discrete,s=Oi(i),l=Pi(i),u=0;u=0&&!(l[n].percent<=e);n--);n=d(n,u-2)}else{for(n=p;ne);n++);n=d(n-1,u-2)}r=l[n+1],i=l[n]}if(i&&r){this._lastFr=n,this._lastFrP=e;var f=r.percent-i.percent,g=0===f?1:d((e-i.percent)/f,1);r.easingFunc&&(g=r.easingFunc(g));var y=o?this._additiveValue:c?Ri:t[h];if(!Oi(s)&&!c||y||(y=this._additiveValue=[]),this.discrete)t[h]=g<1?i.rawValue:r.rawValue;else if(Oi(s))1===s?Ii(y,i[a],r[a],g):function(t,e,n,i){for(var r=e.length,o=r&&e[0].length,a=0;a0&&s.addKeyframe(0,ki(l),i),this._trackKeys.push(a)}s.addKeyframe(t,ki(e[a]),i)}return this._maxTime=Math.max(this._maxTime,t),this},t.prototype.pause=function(){this._clip.pause(),this._paused=!0},t.prototype.resume=function(){this._clip.resume(),this._paused=!1},t.prototype.isPaused=function(){return!!this._paused},t.prototype.duration=function(t){return this._maxTime=t,this._force=!0,this},t.prototype._doneCallback=function(){this._setTracksFinished(),this._clip=null;var t=this._doneCbs;if(t)for(var e=t.length,n=0;n0)){this._started=1;for(var e=this,n=[],i=this._maxTime||0,r=0;r1){var a=o.pop();r.addKeyframe(a.time,t[i]),r.prepare(this._maxTime,r.getAdditiveTrack())}}}},t}();function zi(){return(new Date).getTime()}var Vi,Bi,Fi=function(t){function e(e){var n=t.call(this)||this;return n._running=!1,n._time=0,n._pausedTime=0,n._pauseStart=0,n._paused=!1,e=e||{},n.stage=e.stage||{},n}return n(e,t),e.prototype.addClip=function(t){t.animation&&this.removeClip(t),this._head?(this._tail.next=t,t.prev=this._tail,t.next=null,this._tail=t):this._head=this._tail=t,t.animation=this},e.prototype.addAnimator=function(t){t.animation=this;var e=t.getClip();e&&this.addClip(e)},e.prototype.removeClip=function(t){if(t.animation){var e=t.prev,n=t.next;e?e.next=n:this._head=n,n?n.prev=e:this._tail=e,t.next=t.prev=t.animation=null}},e.prototype.removeAnimator=function(t){var e=t.getClip();e&&this.removeClip(e),t.animation=null},e.prototype.update=function(t){for(var e=zi()-this._pausedTime,n=e-this._time,i=this._head;i;){var r=i.next;i.step(e,n)?(i.ondestroy(),this.removeClip(i),i=r):i=r}this._time=e,t||(this.trigger("frame",n),this.stage.update&&this.stage.update())},e.prototype._startLoop=function(){var t=this;this._running=!0,on((function e(){t._running&&(on(e),!t._paused&&t.update())}))},e.prototype.start=function(){this._running||(this._time=zi(),this._pausedTime=0,this._startLoop())},e.prototype.stop=function(){this._running=!1},e.prototype.pause=function(){this._paused||(this._pauseStart=zi(),this._paused=!0)},e.prototype.resume=function(){this._paused&&(this._pausedTime+=zi()-this._pauseStart,this._paused=!1)},e.prototype.clear=function(){for(var t=this._head;t;){var e=t.next;t.prev=t.next=t.animation=null,t=e}this._head=this._tail=null},e.prototype.isFinished=function(){return null==this._head},e.prototype.animate=function(t,e){e=e||{},this.start();var n=new Ei(t,e.loop);return this.addAnimator(n),n},e}(jt),Gi=r.domSupported,Wi=(Bi={pointerdown:1,pointerup:1,pointermove:1,pointerout:1},{mouse:Vi=["click","dblclick","mousewheel","wheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],touch:["touchstart","touchend","touchmove"],pointer:z(Vi,(function(t){var e=t.replace("mouse","pointer");return Bi.hasOwnProperty(e)?e:t}))}),Hi=["mousemove","mouseup"],Yi=["pointermove","pointerup"],Xi=!1;function Ui(t){var e=t.pointerType;return"pen"===e||"touch"===e}function Zi(t){t&&(t.zrByTouch=!0)}function ji(t,e){for(var n=e,i=!1;n&&9!==n.nodeType&&!(i=n.domBelongToZr||n!==e&&n===t.painterRoot);)n=n.parentNode;return i}var qi=function(t,e){this.stopPropagation=bt,this.stopImmediatePropagation=bt,this.preventDefault=bt,this.type=e.type,this.target=this.currentTarget=t.dom,this.pointerType=e.pointerType,this.clientX=e.clientX,this.clientY=e.clientY},Ki={mousedown:function(t){t=ce(this.dom,t),this.__mayPointerCapture=[t.zrX,t.zrY],this.trigger("mousedown",t)},mousemove:function(t){t=ce(this.dom,t);var e=this.__mayPointerCapture;!e||t.zrX===e[0]&&t.zrY===e[1]||this.__togglePointerCapture(!0),this.trigger("mousemove",t)},mouseup:function(t){t=ce(this.dom,t),this.__togglePointerCapture(!1),this.trigger("mouseup",t)},mouseout:function(t){ji(this,(t=ce(this.dom,t)).toElement||t.relatedTarget)||(this.__pointerCapturing&&(t.zrEventControl="no_globalout"),this.trigger("mouseout",t))},wheel:function(t){Xi=!0,t=ce(this.dom,t),this.trigger("mousewheel",t)},mousewheel:function(t){Xi||(t=ce(this.dom,t),this.trigger("mousewheel",t))},touchstart:function(t){Zi(t=ce(this.dom,t)),this.__lastTouchMoment=new Date,this.handler.processGesture(t,"start"),Ki.mousemove.call(this,t),Ki.mousedown.call(this,t)},touchmove:function(t){Zi(t=ce(this.dom,t)),this.handler.processGesture(t,"change"),Ki.mousemove.call(this,t)},touchend:function(t){Zi(t=ce(this.dom,t)),this.handler.processGesture(t,"end"),Ki.mouseup.call(this,t),+new Date-+this.__lastTouchMoment<300&&Ki.click.call(this,t)},pointerdown:function(t){Ki.mousedown.call(this,t)},pointermove:function(t){Ui(t)||Ki.mousemove.call(this,t)},pointerup:function(t){Ki.mouseup.call(this,t)},pointerout:function(t){Ui(t)||Ki.mouseout.call(this,t)}};E(["click","dblclick","contextmenu"],(function(t){Ki[t]=function(e){e=ce(this.dom,e),this.trigger(t,e)}}));var $i={pointermove:function(t){Ui(t)||$i.mousemove.call(this,t)},pointerup:function(t){$i.mouseup.call(this,t)},mousemove:function(t){this.trigger("mousemove",t)},mouseup:function(t){var e=this.__pointerCapturing;this.__togglePointerCapture(!1),this.trigger("mouseup",t),e&&(t.zrEventControl="only_globalout",this.trigger("mouseout",t))}};function Ji(t,e){var n=e.domHandlers;r.pointerEventsSupported?E(Wi.pointer,(function(i){tr(e,i,(function(e){n[i].call(t,e)}))})):(r.touchEventsSupported&&E(Wi.touch,(function(i){tr(e,i,(function(r){n[i].call(t,r),function(t){t.touching=!0,null!=t.touchTimer&&(clearTimeout(t.touchTimer),t.touchTimer=null),t.touchTimer=setTimeout((function(){t.touching=!1,t.touchTimer=null}),700)}(e)}))})),E(Wi.mouse,(function(i){tr(e,i,(function(r){r=he(r),e.touching||n[i].call(t,r)}))})))}function Qi(t,e){function n(n){tr(e,n,(function(i){i=he(i),ji(t,i.target)||(i=function(t,e){return ce(t.dom,new qi(t,e),!0)}(t,i),e.domHandlers[n].call(t,i))}),{capture:!0})}r.pointerEventsSupported?E(Yi,n):r.touchEventsSupported||E(Hi,n)}function tr(t,e,n,i){t.mounted[e]=n,t.listenerOpts[e]=i,pe(t.domTarget,e,n,i)}function er(t){var e,n,i,r,o=t.mounted;for(var a in o)o.hasOwnProperty(a)&&(e=t.domTarget,n=a,i=o[a],r=t.listenerOpts[a],e.removeEventListener(n,i,r));t.mounted={}}var nr=function(t,e){this.mounted={},this.listenerOpts={},this.touching=!1,this.domTarget=t,this.domHandlers=e},ir=function(t){function e(e,n){var i=t.call(this)||this;return i.__pointerCapturing=!1,i.dom=e,i.painterRoot=n,i._localHandlerScope=new nr(e,Ki),Gi&&(i._globalHandlerScope=new nr(document,$i)),Ji(i,i._localHandlerScope),i}return n(e,t),e.prototype.dispose=function(){er(this._localHandlerScope),Gi&&er(this._globalHandlerScope)},e.prototype.setCursor=function(t){this.dom.style&&(this.dom.style.cursor=t||"default")},e.prototype.__togglePointerCapture=function(t){if(this.__mayPointerCapture=null,Gi&&+this.__pointerCapturing^+t){this.__pointerCapturing=t;var e=this._globalHandlerScope;t?Qi(this,e):er(e)}},e}(jt),rr=1;r.hasGlobalWindow&&(rr=Math.max(window.devicePixelRatio||window.screen&&window.screen.deviceXDPI/window.screen.logicalXDPI||1,1));var or=rr,ar="#333",sr="#ccc",lr=xe,ur=5e-5;function hr(t){return t>ur||t<-5e-5}var cr=[],pr=[],dr=[1,0,0,1,0,0],fr=Math.abs,gr=function(){function t(){}return t.prototype.getLocalTransform=function(e){return t.getLocalTransform(this,e)},t.prototype.setPosition=function(t){this.x=t[0],this.y=t[1]},t.prototype.setScale=function(t){this.scaleX=t[0],this.scaleY=t[1]},t.prototype.setSkew=function(t){this.skewX=t[0],this.skewY=t[1]},t.prototype.setOrigin=function(t){this.originX=t[0],this.originY=t[1]},t.prototype.needLocalTransform=function(){return hr(this.rotation)||hr(this.x)||hr(this.y)||hr(this.scaleX-1)||hr(this.scaleY-1)||hr(this.skewX)||hr(this.skewY)},t.prototype.updateTransform=function(){var t=this.parent&&this.parent.transform,e=this.needLocalTransform(),n=this.transform;e||t?(n=n||[1,0,0,1,0,0],e?this.getLocalTransform(n):lr(n),t&&(e?be(n,t,n):_e(n,t)),this.transform=n,this._resolveGlobalScaleRatio(n)):n&&(lr(n),this.invTransform=null)},t.prototype._resolveGlobalScaleRatio=function(t){var e=this.globalScaleRatio;if(null!=e&&1!==e){this.getGlobalScale(cr);var n=cr[0]<0?-1:1,i=cr[1]<0?-1:1,r=((cr[0]-n)*e+n)/cr[0]||0,o=((cr[1]-i)*e+i)/cr[1]||0;t[0]*=r,t[1]*=r,t[2]*=o,t[3]*=o}this.invTransform=this.invTransform||[1,0,0,1,0,0],Ie(this.invTransform,t)},t.prototype.getComputedTransform=function(){for(var t=this,e=[];t;)e.push(t),t=t.parent;for(;t=e.pop();)t.updateTransform();return this.transform},t.prototype.setLocalTransform=function(t){if(t){var e=t[0]*t[0]+t[1]*t[1],n=t[2]*t[2]+t[3]*t[3],i=Math.atan2(t[1],t[0]),r=Math.PI/2+i-Math.atan2(t[3],t[2]);n=Math.sqrt(n)*Math.cos(r),e=Math.sqrt(e),this.skewX=r,this.skewY=0,this.rotation=-i,this.x=+t[4],this.y=+t[5],this.scaleX=e,this.scaleY=n,this.originX=0,this.originY=0}},t.prototype.decomposeTransform=function(){if(this.transform){var t=this.parent,e=this.transform;t&&t.transform&&(be(pr,t.invTransform,e),e=pr);var n=this.originX,i=this.originY;(n||i)&&(dr[4]=n,dr[5]=i,be(pr,e,dr),pr[4]-=n,pr[5]-=i,e=pr),this.setLocalTransform(e)}},t.prototype.getGlobalScale=function(t){var e=this.transform;return t=t||[],e?(t[0]=Math.sqrt(e[0]*e[0]+e[1]*e[1]),t[1]=Math.sqrt(e[2]*e[2]+e[3]*e[3]),e[0]<0&&(t[0]=-t[0]),e[3]<0&&(t[1]=-t[1]),t):(t[0]=1,t[1]=1,t)},t.prototype.transformCoordToLocal=function(t,e){var n=[t,e],i=this.invTransform;return i&&Wt(n,n,i),n},t.prototype.transformCoordToGlobal=function(t,e){var n=[t,e],i=this.transform;return i&&Wt(n,n,i),n},t.prototype.getLineScale=function(){var t=this.transform;return t&&fr(t[0]-1)>1e-10&&fr(t[3]-1)>1e-10?Math.sqrt(fr(t[0]*t[3]-t[2]*t[1])):1},t.prototype.copyTransform=function(t){vr(this,t)},t.getLocalTransform=function(t,e){e=e||[];var n=t.originX||0,i=t.originY||0,r=t.scaleX,o=t.scaleY,a=t.anchorX,s=t.anchorY,l=t.rotation||0,u=t.x,h=t.y,c=t.skewX?Math.tan(t.skewX):0,p=t.skewY?Math.tan(-t.skewY):0;if(n||i||a||s){var d=n+a,f=i+s;e[4]=-d*r-c*f*o,e[5]=-f*o-p*d*r}else e[4]=e[5]=0;return e[0]=r,e[3]=o,e[1]=p*r,e[2]=c*o,l&&Se(e,e,l),e[4]+=n+u,e[5]+=i+h,e},t.initDefaultProps=function(){var e=t.prototype;e.scaleX=e.scaleY=e.globalScaleRatio=1,e.x=e.y=e.originX=e.originY=e.skewX=e.skewY=e.rotation=e.anchorX=e.anchorY=0}(),t}(),yr=["x","y","originX","originY","anchorX","anchorY","rotation","scaleX","scaleY","skewX","skewY"];function vr(t,e){for(var n=0;n=0?parseFloat(t)/100*e:parseFloat(t):t}function Tr(t,e,n){var i=e.position||"inside",r=null!=e.distance?e.distance:5,o=n.height,a=n.width,s=o/2,l=n.x,u=n.y,h="left",c="top";if(i instanceof Array)l+=Ir(i[0],n.width),u+=Ir(i[1],n.height),h=null,c=null;else switch(i){case"left":l-=r,u+=s,h="right",c="middle";break;case"right":l+=r+a,u+=s,c="middle";break;case"top":l+=a/2,u-=r,h="center",c="bottom";break;case"bottom":l+=a/2,u+=o+r,h="center";break;case"inside":l+=a/2,u+=s,h="center",c="middle";break;case"insideLeft":l+=r,u+=s,c="middle";break;case"insideRight":l+=a-r,u+=s,h="right",c="middle";break;case"insideTop":l+=a/2,u+=r,h="center";break;case"insideBottom":l+=a/2,u+=o-r,h="center",c="bottom";break;case"insideTopLeft":l+=r,u+=r;break;case"insideTopRight":l+=a-r,u+=r,h="right";break;case"insideBottomLeft":l+=r,u+=o-r,c="bottom";break;case"insideBottomRight":l+=a-r,u+=o-r,h="right",c="bottom"}return(t=t||{}).x=l,t.y=u,t.align=h,t.verticalAlign=c,t}var Cr="__zr_normal__",Dr=yr.concat(["ignore"]),Ar=V(yr,(function(t,e){return t[e]=!0,t}),{ignore:!1}),kr={},Lr=new ze(0,0,0,0),Pr=function(){function t(t){this.id=M(),this.animators=[],this.currentStates=[],this.states={},this._init(t)}return t.prototype._init=function(t){this.attr(t)},t.prototype.drift=function(t,e,n){switch(this.draggable){case"horizontal":e=0;break;case"vertical":t=0}var i=this.transform;i||(i=this.transform=[1,0,0,1,0,0]),i[4]+=t,i[5]+=e,this.decomposeTransform(),this.markRedraw()},t.prototype.beforeUpdate=function(){},t.prototype.afterUpdate=function(){},t.prototype.update=function(){this.updateTransform(),this.__dirty&&this.updateInnerText()},t.prototype.updateInnerText=function(t){var e=this._textContent;if(e&&(!e.ignore||t)){this.textConfig||(this.textConfig={});var n=this.textConfig,i=n.local,r=e.innerTransformable,o=void 0,a=void 0,s=!1;r.parent=i?this:null;var l=!1;if(r.copyTransform(e),null!=n.position){var u=Lr;n.layoutRect?u.copy(n.layoutRect):u.copy(this.getBoundingRect()),i||u.applyTransform(this.transform),this.calculateTextPosition?this.calculateTextPosition(kr,n,u):Tr(kr,n,u),r.x=kr.x,r.y=kr.y,o=kr.align,a=kr.verticalAlign;var h=n.origin;if(h&&null!=n.rotation){var c=void 0,p=void 0;"center"===h?(c=.5*u.width,p=.5*u.height):(c=Ir(h[0],u.width),p=Ir(h[1],u.height)),l=!0,r.originX=-r.x+c+(i?0:u.x),r.originY=-r.y+p+(i?0:u.y)}}null!=n.rotation&&(r.rotation=n.rotation);var d=n.offset;d&&(r.x+=d[0],r.y+=d[1],l||(r.originX=-d[0],r.originY=-d[1]));var f=null==n.inside?"string"==typeof n.position&&n.position.indexOf("inside")>=0:n.inside,g=this._innerTextDefaultStyle||(this._innerTextDefaultStyle={}),y=void 0,v=void 0,m=void 0;f&&this.canBeInsideText()?(y=n.insideFill,v=n.insideStroke,null!=y&&"auto"!==y||(y=this.getInsideTextFill()),null!=v&&"auto"!==v||(v=this.getInsideTextStroke(y),m=!0)):(y=n.outsideFill,v=n.outsideStroke,null!=y&&"auto"!==y||(y=this.getOutsideFill()),null!=v&&"auto"!==v||(v=this.getOutsideStroke(y),m=!0)),(y=y||"#000")===g.fill&&v===g.stroke&&m===g.autoStroke&&o===g.align&&a===g.verticalAlign||(s=!0,g.fill=y,g.stroke=v,g.autoStroke=m,g.align=o,g.verticalAlign=a,e.setDefaultTextStyle(g)),e.__dirty|=1,s&&e.dirtyStyle(!0)}},t.prototype.canBeInsideText=function(){return!0},t.prototype.getInsideTextFill=function(){return"#fff"},t.prototype.getInsideTextStroke=function(t){return"#000"},t.prototype.getOutsideFill=function(){return this.__zr&&this.__zr.isDarkMode()?sr:ar},t.prototype.getOutsideStroke=function(t){var e=this.__zr&&this.__zr.getBackgroundColor(),n="string"==typeof e&&qn(e);n||(n=[255,255,255,1]);for(var i=n[3],r=this.__zr.isDarkMode(),o=0;o<3;o++)n[o]=n[o]*i+(r?0:255)*(1-i);return n[3]=1,ri(n,"rgba")},t.prototype.traverse=function(t,e){},t.prototype.attrKV=function(t,e){"textConfig"===t?this.setTextConfig(e):"textContent"===t?this.setTextContent(e):"clipPath"===t?this.setClipPath(e):"extra"===t?(this.extra=this.extra||{},A(this.extra,e)):this[t]=e},t.prototype.hide=function(){this.ignore=!0,this.markRedraw()},t.prototype.show=function(){this.ignore=!1,this.markRedraw()},t.prototype.attr=function(t,e){if("string"==typeof t)this.attrKV(t,e);else if(q(t))for(var n=G(t),i=0;i0},t.prototype.getState=function(t){return this.states[t]},t.prototype.ensureState=function(t){var e=this.states;return e[t]||(e[t]={}),e[t]},t.prototype.clearStates=function(t){this.useState(Cr,!1,t)},t.prototype.useState=function(t,e,n,i){var r=t===Cr;if(this.hasState()||!r){var o=this.currentStates,a=this.stateTransition;if(!(P(o,t)>=0)||!e&&1!==o.length){var s;if(this.stateProxy&&!r&&(s=this.stateProxy(t)),s||(s=this.states&&this.states[t]),s||r){r||this.saveCurrentToNormalState(s);var l=!!(s&&s.hoverLayer||i);l&&this._toggleHoverLayerFlag(!0),this._applyStateObj(t,s,this._normalState,e,!n&&!this.__inHover&&a&&a.duration>0,a);var u=this._textContent,h=this._textGuide;return u&&u.useState(t,e,n,l),h&&h.useState(t,e,n,l),r?(this.currentStates=[],this._normalState={}):e?this.currentStates.push(t):this.currentStates=[t],this._updateAnimationTargets(),this.markRedraw(),!l&&this.__inHover&&(this._toggleHoverLayerFlag(!1),this.__dirty&=-2),s}I("State "+t+" not exists.")}}},t.prototype.useStates=function(t,e,n){if(t.length){var i=[],r=this.currentStates,o=t.length,a=o===r.length;if(a)for(var s=0;s0,d);var f=this._textContent,g=this._textGuide;f&&f.useStates(t,e,c),g&&g.useStates(t,e,c),this._updateAnimationTargets(),this.currentStates=t.slice(),this.markRedraw(),!c&&this.__inHover&&(this._toggleHoverLayerFlag(!1),this.__dirty&=-2)}else this.clearStates()},t.prototype._updateAnimationTargets=function(){for(var t=0;t=0){var n=this.currentStates.slice();n.splice(e,1),this.useStates(n)}},t.prototype.replaceState=function(t,e,n){var i=this.currentStates.slice(),r=P(i,t),o=P(i,e)>=0;r>=0?o?i.splice(r,1):i[r]=e:n&&!o&&i.push(e),this.useStates(i)},t.prototype.toggleState=function(t,e){e?this.useState(t,!0):this.removeState(t)},t.prototype._mergeStates=function(t){for(var e,n={},i=0;i=0&&e.splice(n,1)})),this.animators.push(t),n&&n.animation.addAnimator(t),n&&n.wakeUp()},t.prototype.updateDuringAnimation=function(t){this.markRedraw()},t.prototype.stopAnimation=function(t,e){for(var n=this.animators,i=n.length,r=[],o=0;o0&&n.during&&o[0].during((function(t,e){n.during(e)}));for(var p=0;p0||r.force&&!a.length){var w,S=void 0,M=void 0,I=void 0;if(s){M={},p&&(S={});for(_=0;_=0&&(n.splice(i,0,t),this._doAdd(t))}return this},e.prototype.replace=function(t,e){var n=P(this._children,t);return n>=0&&this.replaceAt(e,n),this},e.prototype.replaceAt=function(t,e){var n=this._children,i=n[e];if(t&&t!==this&&t.parent!==this&&t!==i){n[e]=t,i.parent=null;var r=this.__zr;r&&i.removeSelfFromZr(r),this._doAdd(t)}return this},e.prototype._doAdd=function(t){t.parent&&t.parent.remove(t),t.parent=this;var e=this.__zr;e&&e!==t.__zr&&t.addSelfToZr(e),e&&e.refresh()},e.prototype.remove=function(t){var e=this.__zr,n=this._children,i=P(n,t);return i<0||(n.splice(i,1),t.parent=null,e&&t.removeSelfFromZr(e),e&&e.refresh()),this},e.prototype.removeAll=function(){for(var t=this._children,e=this.__zr,n=0;n0&&(this._stillFrameAccum++,this._stillFrameAccum>this._sleepAfterStill&&this.animation.stop())},t.prototype.setSleepAfterStill=function(t){this._sleepAfterStill=t},t.prototype.wakeUp=function(){this.animation.start(),this._stillFrameAccum=0},t.prototype.refreshHover=function(){this._needsRefreshHover=!0},t.prototype.refreshHoverImmediately=function(){this._needsRefreshHover=!1,this.painter.refreshHover&&"canvas"===this.painter.getType()&&this.painter.refreshHover()},t.prototype.resize=function(t){t=t||{},this.painter.resize(t.width,t.height),this.handler.resize()},t.prototype.clearAnimation=function(){this.animation.clear()},t.prototype.getWidth=function(){return this.painter.getWidth()},t.prototype.getHeight=function(){return this.painter.getHeight()},t.prototype.setCursorStyle=function(t){this.handler.setCursorStyle(t)},t.prototype.findHover=function(t,e){return this.handler.findHover(t,e)},t.prototype.on=function(t,e,n){return this.handler.on(t,e,n),this},t.prototype.off=function(t,e){this.handler.off(t,e)},t.prototype.trigger=function(t,e){this.handler.trigger(t,e)},t.prototype.clear=function(){for(var t=this.storage.getRoots(),e=0;e0){if(t<=r)return a;if(t>=o)return s}else{if(t>=r)return a;if(t<=o)return s}else{if(t===r)return a;if(t===o)return s}return(t-r)/l*u+a}function Ur(t,e){switch(t){case"center":case"middle":t="50%";break;case"left":case"top":t="0%";break;case"right":case"bottom":t="100%"}return U(t)?(n=t,n.replace(/^\s+|\s+$/g,"")).match(/%$/)?parseFloat(t)/100*e:parseFloat(t):null==t?NaN:+t;var n}function Zr(t,e,n){return null==e&&(e=10),e=Math.min(Math.max(0,e),20),t=(+t).toFixed(e),n?t:+t}function jr(t){return t.sort((function(t,e){return t-e})),t}function qr(t){if(t=+t,isNaN(t))return 0;if(t>1e-14)for(var e=1,n=0;n<15;n++,e*=10)if(Math.round(t*e)/e===t)return n;return Kr(t)}function Kr(t){var e=t.toString().toLowerCase(),n=e.indexOf("e"),i=n>0?+e.slice(n+1):0,r=n>0?n:e.length,o=e.indexOf("."),a=o<0?0:r-1-o;return Math.max(0,a-i)}function $r(t,e){var n=Math.log,i=Math.LN10,r=Math.floor(n(t[1]-t[0])/i),o=Math.round(n(Math.abs(e[1]-e[0]))/i),a=Math.min(Math.max(-r+o,0),20);return isFinite(a)?a:20}function Jr(t,e){var n=V(t,(function(t,e){return t+(isNaN(e)?0:e)}),0);if(0===n)return[];for(var i=Math.pow(10,e),r=z(t,(function(t){return(isNaN(t)?0:t)/n*i*100})),o=100*i,a=z(r,(function(t){return Math.floor(t)})),s=V(a,(function(t,e){return t+e}),0),l=z(r,(function(t,e){return t-a[e]}));su&&(u=l[c],h=c);++a[h],l[h]=0,++s}return z(a,(function(t){return t/i}))}function Qr(t,e){var n=Math.max(qr(t),qr(e)),i=t+e;return n>20?i:Zr(i,n)}var to=9007199254740991;function eo(t){var e=2*Math.PI;return(t%e+e)%e}function no(t){return t>-1e-4&&t=10&&e++,e}function so(t,e){var n=ao(t),i=Math.pow(10,n),r=t/i;return t=(e?r<1.5?1:r<2.5?2:r<4?3:r<7?5:10:r<1?1:r<2?2:r<3?3:r<5?5:10)*i,n>=-20?+t.toFixed(n<0?-n:0):t}function lo(t,e){var n=(t.length-1)*e+1,i=Math.floor(n),r=+t[i-1],o=n-i;return o?r+o*(t[i]-r):r}function uo(t){t.sort((function(t,e){return s(t,e,0)?-1:1}));for(var e=-1/0,n=1,i=0;i=0||r&&P(r,s)<0)){var l=n.getShallow(s,e);null!=l&&(o[t[a][0]]=l)}}return o}}var Qo=Jo([["fill","color"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["opacity"],["shadowColor"]]),ta=function(){function t(){}return t.prototype.getAreaStyle=function(t,e){return Qo(this,t,e)},t}(),ea=new En(50);function na(t){if("string"==typeof t){var e=ea.get(t);return e&&e.image}return t}function ia(t,e,n,i,r){if(t){if("string"==typeof t){if(e&&e.__zrImageSrc===t||!n)return e;var o=ea.get(t),a={hostEl:n,cb:i,cbPayload:r};return o?!oa(e=o.image)&&o.pending.push(a):((e=h.loadImage(t,ra,ra)).__zrImageSrc=t,ea.put(t,e.__cachedImgObj={image:e,pending:[a]})),e}return t}return e}function ra(){var t=this.__cachedImgObj;this.onload=this.onerror=this.__cachedImgObj=null;for(var e=0;e=a;l++)s-=a;var u=xr(n,e);return u>s&&(n="",u=0),s=t-u,r.ellipsis=n,r.ellipsisWidth=u,r.contentWidth=s,r.containerWidth=t,r}function ua(t,e){var n=e.containerWidth,i=e.font,r=e.contentWidth;if(!n)return"";var o=xr(t,i);if(o<=n)return t;for(var a=0;;a++){if(o<=r||a>=e.maxIterations){t+=e.ellipsis;break}var s=0===a?ha(t,r,e.ascCharWidth,e.cnCharWidth):o>0?Math.floor(t.length*r/o):0;o=xr(t=t.substr(0,s),i)}return""===t&&(t=e.placeholder),t}function ha(t,e,n,i){for(var r=0,o=0,a=t.length;o0&&f+i.accumWidth>i.width&&(o=e.split("\n"),c=!0),i.accumWidth=f}else{var g=va(e,h,i.width,i.breakAll,i.accumWidth);i.accumWidth=g.accumWidth+d,a=g.linesWidths,o=g.lines}}else o=e.split("\n");for(var y=0;y=32&&e<=591||e>=880&&e<=4351||e>=4608&&e<=5119||e>=7680&&e<=8303}(t)||!!ga[t]}function va(t,e,n,i,r){for(var o=[],a=[],s="",l="",u=0,h=0,c=0;cn:r+h+d>n)?h?(s||l)&&(f?(s||(s=l,l="",h=u=0),o.push(s),a.push(h-u),l+=p,s="",h=u+=d):(l&&(s+=l,l="",u=0),o.push(s),a.push(h),s=p,h=d)):f?(o.push(l),a.push(u),l=p,u=d):(o.push(p),a.push(d)):(h+=d,f?(l+=p,u+=d):(l&&(s+=l,l="",u=0),s+=p))}else l&&(s+=l,h+=u),o.push(s),a.push(h),s="",l="",u=0,h=0}return o.length||s||(s=t,l="",u=0),l&&(s+=l),s&&(o.push(s),a.push(h)),1===o.length&&(h+=r),{accumWidth:h,lines:o,linesWidths:a}}var ma="__zr_style_"+Math.round(10*Math.random()),xa={shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,shadowColor:"#000",opacity:1,blend:"source-over"},_a={style:{shadowBlur:!0,shadowOffsetX:!0,shadowOffsetY:!0,shadowColor:!0,opacity:!0}};xa[ma]=!0;var ba=["z","z2","invisible"],wa=["invisible"],Sa=function(t){function e(e){return t.call(this,e)||this}var i;return n(e,t),e.prototype._init=function(e){for(var n=G(e),i=0;i1e-4)return s[0]=t-n,s[1]=e-i,l[0]=t+n,void(l[1]=e+i);if(La[0]=Aa(r)*n+t,La[1]=Da(r)*i+e,Pa[0]=Aa(o)*n+t,Pa[1]=Da(o)*i+e,u(s,La,Pa),h(l,La,Pa),(r%=ka)<0&&(r+=ka),(o%=ka)<0&&(o+=ka),r>o&&!a?o+=ka:rr&&(Oa[0]=Aa(d)*n+t,Oa[1]=Da(d)*i+e,u(s,Oa,s),h(l,Oa,l))}var Ga={M:1,L:2,C:3,Q:4,A:5,Z:6,R:7},Wa=[],Ha=[],Ya=[],Xa=[],Ua=[],Za=[],ja=Math.min,qa=Math.max,Ka=Math.cos,$a=Math.sin,Ja=Math.abs,Qa=Math.PI,ts=2*Qa,es="undefined"!=typeof Float32Array,ns=[];function is(t){return Math.round(t/Qa*1e8)/1e8%2*Qa}function rs(t,e){var n=is(t[0]);n<0&&(n+=ts);var i=n-t[0],r=t[1];r+=i,!e&&r-n>=ts?r=n+ts:e&&n-r>=ts?r=n-ts:!e&&n>r?r=n+(ts-is(n-r)):e&&n0&&(this._ux=Ja(n/or/t)||0,this._uy=Ja(n/or/e)||0)},t.prototype.setDPR=function(t){this.dpr=t},t.prototype.setContext=function(t){this._ctx=t},t.prototype.getContext=function(){return this._ctx},t.prototype.beginPath=function(){return this._ctx&&this._ctx.beginPath(),this.reset(),this},t.prototype.reset=function(){this._saveData&&(this._len=0),this._pathSegLen&&(this._pathSegLen=null,this._pathLen=0),this._version++},t.prototype.moveTo=function(t,e){return this._drawPendingPt(),this.addData(Ga.M,t,e),this._ctx&&this._ctx.moveTo(t,e),this._x0=t,this._y0=e,this._xi=t,this._yi=e,this},t.prototype.lineTo=function(t,e){var n=Ja(t-this._xi),i=Ja(e-this._yi),r=n>this._ux||i>this._uy;if(this.addData(Ga.L,t,e),this._ctx&&r&&this._ctx.lineTo(t,e),r)this._xi=t,this._yi=e,this._pendingPtDist=0;else{var o=n*n+i*i;o>this._pendingPtDist&&(this._pendingPtX=t,this._pendingPtY=e,this._pendingPtDist=o)}return this},t.prototype.bezierCurveTo=function(t,e,n,i,r,o){return this._drawPendingPt(),this.addData(Ga.C,t,e,n,i,r,o),this._ctx&&this._ctx.bezierCurveTo(t,e,n,i,r,o),this._xi=r,this._yi=o,this},t.prototype.quadraticCurveTo=function(t,e,n,i){return this._drawPendingPt(),this.addData(Ga.Q,t,e,n,i),this._ctx&&this._ctx.quadraticCurveTo(t,e,n,i),this._xi=n,this._yi=i,this},t.prototype.arc=function(t,e,n,i,r,o){this._drawPendingPt(),ns[0]=i,ns[1]=r,rs(ns,o),i=ns[0];var a=(r=ns[1])-i;return this.addData(Ga.A,t,e,n,n,i,a,0,o?0:1),this._ctx&&this._ctx.arc(t,e,n,i,r,o),this._xi=Ka(r)*n+t,this._yi=$a(r)*n+e,this},t.prototype.arcTo=function(t,e,n,i,r){return this._drawPendingPt(),this._ctx&&this._ctx.arcTo(t,e,n,i,r),this},t.prototype.rect=function(t,e,n,i){return this._drawPendingPt(),this._ctx&&this._ctx.rect(t,e,n,i),this.addData(Ga.R,t,e,n,i),this},t.prototype.closePath=function(){this._drawPendingPt(),this.addData(Ga.Z);var t=this._ctx,e=this._x0,n=this._y0;return t&&t.closePath(),this._xi=e,this._yi=n,this},t.prototype.fill=function(t){t&&t.fill(),this.toStatic()},t.prototype.stroke=function(t){t&&t.stroke(),this.toStatic()},t.prototype.len=function(){return this._len},t.prototype.setData=function(t){var e=t.length;this.data&&this.data.length===e||!es||(this.data=new Float32Array(e));for(var n=0;nu.length&&(this._expandData(),u=this.data);for(var h=0;h0&&(this._ctx&&this._ctx.lineTo(this._pendingPtX,this._pendingPtY),this._pendingPtDist=0)},t.prototype._expandData=function(){if(!(this.data instanceof Array)){for(var t=[],e=0;e11&&(this.data=new Float32Array(t)))}},t.prototype.getBoundingRect=function(){Ya[0]=Ya[1]=Ua[0]=Ua[1]=Number.MAX_VALUE,Xa[0]=Xa[1]=Za[0]=Za[1]=-Number.MAX_VALUE;var t,e=this.data,n=0,i=0,r=0,o=0;for(t=0;tn||Ja(y)>i||c===e-1)&&(f=Math.sqrt(A*A+y*y),r=g,o=x);break;case Ga.C:var v=t[c++],m=t[c++],x=(g=t[c++],t[c++]),_=t[c++],b=t[c++];f=Mn(r,o,v,m,g,x,_,b,10),r=_,o=b;break;case Ga.Q:f=kn(r,o,v=t[c++],m=t[c++],g=t[c++],x=t[c++],10),r=g,o=x;break;case Ga.A:var w=t[c++],S=t[c++],M=t[c++],I=t[c++],T=t[c++],C=t[c++],D=C+T;c+=1;t[c++];d&&(a=Ka(T)*M+w,s=$a(T)*I+S),f=qa(M,I)*ja(ts,Math.abs(C)),r=Ka(D)*M+w,o=$a(D)*I+S;break;case Ga.R:a=r=t[c++],s=o=t[c++],f=2*t[c++]+2*t[c++];break;case Ga.Z:var A=a-r;y=s-o;f=Math.sqrt(A*A+y*y),r=a,o=s}f>=0&&(l[h++]=f,u+=f)}return this._pathLen=u,u},t.prototype.rebuildPath=function(t,e){var n,i,r,o,a,s,l,u,h,c,p=this.data,d=this._ux,f=this._uy,g=this._len,y=e<1,v=0,m=0,x=0;if(!y||(this._pathSegLen||this._calculateLength(),l=this._pathSegLen,u=e*this._pathLen))t:for(var _=0;_0&&(t.lineTo(h,c),x=0),b){case Ga.M:n=r=p[_++],i=o=p[_++],t.moveTo(r,o);break;case Ga.L:a=p[_++],s=p[_++];var S=Ja(a-r),M=Ja(s-o);if(S>d||M>f){if(y){if(v+(j=l[m++])>u){var I=(u-v)/j;t.lineTo(r*(1-I)+a*I,o*(1-I)+s*I);break t}v+=j}t.lineTo(a,s),r=a,o=s,x=0}else{var T=S*S+M*M;T>x&&(h=a,c=s,x=T)}break;case Ga.C:var C=p[_++],D=p[_++],A=p[_++],k=p[_++],L=p[_++],P=p[_++];if(y){if(v+(j=l[m++])>u){wn(r,C,A,L,I=(u-v)/j,Wa),wn(o,D,k,P,I,Ha),t.bezierCurveTo(Wa[1],Ha[1],Wa[2],Ha[2],Wa[3],Ha[3]);break t}v+=j}t.bezierCurveTo(C,D,A,k,L,P),r=L,o=P;break;case Ga.Q:C=p[_++],D=p[_++],A=p[_++],k=p[_++];if(y){if(v+(j=l[m++])>u){Dn(r,C,A,I=(u-v)/j,Wa),Dn(o,D,k,I,Ha),t.quadraticCurveTo(Wa[1],Ha[1],Wa[2],Ha[2]);break t}v+=j}t.quadraticCurveTo(C,D,A,k),r=A,o=k;break;case Ga.A:var O=p[_++],R=p[_++],N=p[_++],E=p[_++],z=p[_++],V=p[_++],B=p[_++],F=!p[_++],G=N>E?N:E,W=Ja(N-E)>.001,H=z+V,Y=!1;if(y)v+(j=l[m++])>u&&(H=z+V*(u-v)/j,Y=!0),v+=j;if(W&&t.ellipse?t.ellipse(O,R,N,E,B,z,H,F):t.arc(O,R,G,z,H,F),Y)break t;w&&(n=Ka(z)*N+O,i=$a(z)*E+R),r=Ka(H)*N+O,o=$a(H)*E+R;break;case Ga.R:n=r=p[_],i=o=p[_+1],a=p[_++],s=p[_++];var X=p[_++],U=p[_++];if(y){if(v+(j=l[m++])>u){var Z=u-v;t.moveTo(a,s),t.lineTo(a+ja(Z,X),s),(Z-=X)>0&&t.lineTo(a+X,s+ja(Z,U)),(Z-=U)>0&&t.lineTo(a+qa(X-Z,0),s+U),(Z-=X)>0&&t.lineTo(a,s+qa(U-Z,0));break t}v+=j}t.rect(a,s,X,U);break;case Ga.Z:if(y){var j;if(v+(j=l[m++])>u){I=(u-v)/j;t.lineTo(r*(1-I)+n*I,o*(1-I)+i*I);break t}v+=j}t.closePath(),r=n,o=i}}},t.prototype.clone=function(){var e=new t,n=this.data;return e.data=n.slice?n.slice():Array.prototype.slice.call(n),e._len=this._len,e},t.CMD=Ga,t.initDefaultProps=function(){var e=t.prototype;e._saveData=!0,e._ux=0,e._uy=0,e._pendingPtDist=0,e._version=0}(),t}();function as(t,e,n,i,r,o,a){if(0===r)return!1;var s=r,l=0;if(a>e+s&&a>i+s||at+s&&o>n+s||oe+c&&h>i+c&&h>o+c&&h>s+c||ht+c&&u>n+c&&u>r+c&&u>a+c||ue+u&&l>i+u&&l>o+u||lt+u&&s>n+u&&s>r+u||sn||h+ur&&(r+=cs);var p=Math.atan2(l,s);return p<0&&(p+=cs),p>=i&&p<=r||p+cs>=i&&p+cs<=r}function ds(t,e,n,i,r,o){if(o>e&&o>i||or?s:0}var fs=os.CMD,gs=2*Math.PI;var ys=[-1,-1,-1],vs=[-1,-1];function ms(t,e,n,i,r,o,a,s,l,u){if(u>e&&u>i&&u>o&&u>s||u1&&(h=void 0,h=vs[0],vs[0]=vs[1],vs[1]=h),f=mn(e,i,o,s,vs[0]),d>1&&(g=mn(e,i,o,s,vs[1]))),2===d?ve&&s>i&&s>o||s=0&&h<=1&&(r[l++]=h);else{var u=a*a-4*o*s;if(yn(u))(h=-a/(2*o))>=0&&h<=1&&(r[l++]=h);else if(u>0){var h,c=ln(u),p=(-a-c)/(2*o);(h=(-a+c)/(2*o))>=0&&h<=1&&(r[l++]=h),p>=0&&p<=1&&(r[l++]=p)}}return l}(e,i,o,s,ys);if(0===l)return 0;var u=Cn(e,i,o);if(u>=0&&u<=1){for(var h=0,c=In(e,i,o,u),p=0;pn||s<-n)return 0;var l=Math.sqrt(n*n-s*s);ys[0]=-l,ys[1]=l;var u=Math.abs(i-r);if(u<1e-4)return 0;if(u>=gs-1e-4){i=0,r=gs;var h=o?1:-1;return a>=ys[0]+t&&a<=ys[1]+t?h:0}if(i>r){var c=i;i=r,r=c}i<0&&(i+=gs,r+=gs);for(var p=0,d=0;d<2;d++){var f=ys[d];if(f+t>a){var g=Math.atan2(s,f);h=o?1:-1;g<0&&(g=gs+g),(g>=i&&g<=r||g+gs>=i&&g+gs<=r)&&(g>Math.PI/2&&g<1.5*Math.PI&&(h=-h),p+=h)}}return p}function bs(t,e,n,i,r){for(var o,a,s,l,u=t.data,h=t.len(),c=0,p=0,d=0,f=0,g=0,y=0;y1&&(n||(c+=ds(p,d,f,g,i,r))),m&&(f=p=u[y],g=d=u[y+1]),v){case fs.M:p=f=u[y++],d=g=u[y++];break;case fs.L:if(n){if(as(p,d,u[y],u[y+1],e,i,r))return!0}else c+=ds(p,d,u[y],u[y+1],i,r)||0;p=u[y++],d=u[y++];break;case fs.C:if(n){if(ss(p,d,u[y++],u[y++],u[y++],u[y++],u[y],u[y+1],e,i,r))return!0}else c+=ms(p,d,u[y++],u[y++],u[y++],u[y++],u[y],u[y+1],i,r)||0;p=u[y++],d=u[y++];break;case fs.Q:if(n){if(ls(p,d,u[y++],u[y++],u[y],u[y+1],e,i,r))return!0}else c+=xs(p,d,u[y++],u[y++],u[y],u[y+1],i,r)||0;p=u[y++],d=u[y++];break;case fs.A:var x=u[y++],_=u[y++],b=u[y++],w=u[y++],S=u[y++],M=u[y++];y+=1;var I=!!(1-u[y++]);o=Math.cos(S)*b+x,a=Math.sin(S)*w+_,m?(f=o,g=a):c+=ds(p,d,o,a,i,r);var T=(i-x)*w/b+x;if(n){if(ps(x,_,w,S,S+M,I,e,T,r))return!0}else c+=_s(x,_,w,S,S+M,I,T,r);p=Math.cos(S+M)*b+x,d=Math.sin(S+M)*w+_;break;case fs.R:if(f=p=u[y++],g=d=u[y++],o=f+u[y++],a=g+u[y++],n){if(as(f,g,o,g,e,i,r)||as(o,g,o,a,e,i,r)||as(o,a,f,a,e,i,r)||as(f,a,f,g,e,i,r))return!0}else c+=ds(o,g,o,a,i,r),c+=ds(f,a,f,g,i,r);break;case fs.Z:if(n){if(as(p,d,f,g,e,i,r))return!0}else c+=ds(p,d,f,g,i,r);p=f,d=g}}return n||(s=d,l=g,Math.abs(s-l)<1e-4)||(c+=ds(p,d,f,g,i,r)||0),0!==c}var ws=k({fill:"#000",stroke:null,strokePercent:1,fillOpacity:1,strokeOpacity:1,lineDashOffset:0,lineWidth:1,lineCap:"butt",miterLimit:10,strokeNoScale:!1,strokeFirst:!1},xa),Ss={style:k({fill:!0,stroke:!0,strokePercent:!0,fillOpacity:!0,strokeOpacity:!0,lineDashOffset:!0,lineWidth:!0,miterLimit:!0},_a.style)},Ms=yr.concat(["invisible","culling","z","z2","zlevel","parent"]),Is=function(t){function e(e){return t.call(this,e)||this}var i;return n(e,t),e.prototype.update=function(){var n=this;t.prototype.update.call(this);var i=this.style;if(i.decal){var r=this._decalEl=this._decalEl||new e;r.buildPath===e.prototype.buildPath&&(r.buildPath=function(t){n.buildPath(t,n.shape)}),r.silent=!0;var o=r.style;for(var a in i)o[a]!==i[a]&&(o[a]=i[a]);o.fill=i.fill?i.decal:null,o.decal=null,o.shadowColor=null,i.strokeFirst&&(o.stroke=null);for(var s=0;s.5?ar:e>.2?"#eee":sr}if(t)return sr}return ar},e.prototype.getInsideTextStroke=function(t){var e=this.style.fill;if(U(e)){var n=this.__zr;if(!(!n||!n.isDarkMode())===oi(t,0)<.4)return e}},e.prototype.buildPath=function(t,e,n){},e.prototype.pathUpdated=function(){this.__dirty&=-5},e.prototype.getUpdatedPathProxy=function(t){return!this.path&&this.createPathProxy(),this.path.beginPath(),this.buildPath(this.path,this.shape,t),this.path},e.prototype.createPathProxy=function(){this.path=new os(!1)},e.prototype.hasStroke=function(){var t=this.style,e=t.stroke;return!(null==e||"none"===e||!(t.lineWidth>0))},e.prototype.hasFill=function(){var t=this.style.fill;return null!=t&&"none"!==t},e.prototype.getBoundingRect=function(){var t=this._rect,e=this.style,n=!t;if(n){var i=!1;this.path||(i=!0,this.createPathProxy());var r=this.path;(i||4&this.__dirty)&&(r.beginPath(),this.buildPath(r,this.shape,!1),this.pathUpdated()),t=r.getBoundingRect()}if(this._rect=t,this.hasStroke()&&this.path&&this.path.len()>0){var o=this._rectStroke||(this._rectStroke=t.clone());if(this.__dirty||n){o.copy(t);var a=e.strokeNoScale?this.getLineScale():1,s=e.lineWidth;if(!this.hasFill()){var l=this.strokeContainThreshold;s=Math.max(s,null==l?4:l)}a>1e-10&&(o.width+=s/a,o.height+=s/a,o.x-=s/a/2,o.y-=s/a/2)}return o}return t},e.prototype.contain=function(t,e){var n=this.transformCoordToLocal(t,e),i=this.getBoundingRect(),r=this.style;if(t=n[0],e=n[1],i.contain(t,e)){var o=this.path;if(this.hasStroke()){var a=r.lineWidth,s=r.strokeNoScale?this.getLineScale():1;if(s>1e-10&&(this.hasFill()||(a=Math.max(a,this.strokeContainThreshold)),function(t,e,n,i){return bs(t,e,!0,n,i)}(o,a/s,t,e)))return!0}if(this.hasFill())return function(t,e,n){return bs(t,0,!1,e,n)}(o,t,e)}return!1},e.prototype.dirtyShape=function(){this.__dirty|=4,this._rect&&(this._rect=null),this._decalEl&&this._decalEl.dirtyShape(),this.markRedraw()},e.prototype.dirty=function(){this.dirtyStyle(),this.dirtyShape()},e.prototype.animateShape=function(t){return this.animate("shape",t)},e.prototype.updateDuringAnimation=function(t){"style"===t?this.dirtyStyle():"shape"===t?this.dirtyShape():this.markRedraw()},e.prototype.attrKV=function(e,n){"shape"===e?this.setShape(n):t.prototype.attrKV.call(this,e,n)},e.prototype.setShape=function(t,e){var n=this.shape;return n||(n=this.shape={}),"string"==typeof t?n[t]=e:A(n,t),this.dirtyShape(),this},e.prototype.shapeChanged=function(){return!!(4&this.__dirty)},e.prototype.createStyle=function(t){return mt(ws,t)},e.prototype._innerSaveToNormal=function(e){t.prototype._innerSaveToNormal.call(this,e);var n=this._normalState;e.shape&&!n.shape&&(n.shape=A({},this.shape))},e.prototype._applyStateObj=function(e,n,i,r,o,a){t.prototype._applyStateObj.call(this,e,n,i,r,o,a);var s,l=!(n&&r);if(n&&n.shape?o?r?s=n.shape:(s=A({},i.shape),A(s,n.shape)):(s=A({},r?this.shape:i.shape),A(s,n.shape)):l&&(s=i.shape),s)if(o){this.shape=A({},this.shape);for(var u={},h=G(s),c=0;c0},e.prototype.hasFill=function(){var t=this.style.fill;return null!=t&&"none"!==t},e.prototype.createStyle=function(t){return mt(Ts,t)},e.prototype.setBoundingRect=function(t){this._rect=t},e.prototype.getBoundingRect=function(){var t=this.style;if(!this._rect){var e=t.text;null!=e?e+="":e="";var n=br(e,t.font,t.textAlign,t.textBaseline);if(n.x+=t.x||0,n.y+=t.y||0,this.hasStroke()){var i=t.lineWidth;n.x-=i/2,n.y-=i/2,n.width+=i,n.height+=i}this._rect=n}return this._rect},e.initDefaultProps=void(e.prototype.dirtyRectTolerance=10),e}(Sa);Cs.prototype.type="tspan";var Ds=k({x:0,y:0},xa),As={style:k({x:!0,y:!0,width:!0,height:!0,sx:!0,sy:!0,sWidth:!0,sHeight:!0},_a.style)};var ks=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return n(e,t),e.prototype.createStyle=function(t){return mt(Ds,t)},e.prototype._getSize=function(t){var e=this.style,n=e[t];if(null!=n)return n;var i,r=(i=e.image)&&"string"!=typeof i&&i.width&&i.height?e.image:this.__image;if(!r)return 0;var o="width"===t?"height":"width",a=e[o];return null==a?r[t]:r[t]/r[o]*a},e.prototype.getWidth=function(){return this._getSize("width")},e.prototype.getHeight=function(){return this._getSize("height")},e.prototype.getAnimationStyleProps=function(){return As},e.prototype.getBoundingRect=function(){var t=this.style;return this._rect||(this._rect=new ze(t.x||0,t.y||0,this.getWidth(),this.getHeight())),this._rect},e}(Sa);ks.prototype.type="image";var Ls=Math.round;function Ps(t,e,n){if(e){var i=e.x1,r=e.x2,o=e.y1,a=e.y2;t.x1=i,t.x2=r,t.y1=o,t.y2=a;var s=n&&n.lineWidth;return s?(Ls(2*i)===Ls(2*r)&&(t.x1=t.x2=Rs(i,s,!0)),Ls(2*o)===Ls(2*a)&&(t.y1=t.y2=Rs(o,s,!0)),t):t}}function Os(t,e,n){if(e){var i=e.x,r=e.y,o=e.width,a=e.height;t.x=i,t.y=r,t.width=o,t.height=a;var s=n&&n.lineWidth;return s?(t.x=Rs(i,s,!0),t.y=Rs(r,s,!0),t.width=Math.max(Rs(i+o,s,!1)-t.x,0===o?0:1),t.height=Math.max(Rs(r+a,s,!1)-t.y,0===a?0:1),t):t}}function Rs(t,e,n){if(!e)return t;var i=Ls(2*t);return(i+Ls(e))%2==0?i/2:(i+(n?1:-1))/2}var Ns=function(){this.x=0,this.y=0,this.width=0,this.height=0},Es={},zs=function(t){function e(e){return t.call(this,e)||this}return n(e,t),e.prototype.getDefaultShape=function(){return new Ns},e.prototype.buildPath=function(t,e){var n,i,r,o;if(this.subPixelOptimize){var a=Os(Es,e,this.style);n=a.x,i=a.y,r=a.width,o=a.height,a.r=e.r,e=a}else n=e.x,i=e.y,r=e.width,o=e.height;e.r?function(t,e){var n,i,r,o,a,s=e.x,l=e.y,u=e.width,h=e.height,c=e.r;u<0&&(s+=u,u=-u),h<0&&(l+=h,h=-h),"number"==typeof c?n=i=r=o=c:c instanceof Array?1===c.length?n=i=r=o=c[0]:2===c.length?(n=r=c[0],i=o=c[1]):3===c.length?(n=c[0],i=o=c[1],r=c[2]):(n=c[0],i=c[1],r=c[2],o=c[3]):n=i=r=o=0,n+i>u&&(n*=u/(a=n+i),i*=u/a),r+o>u&&(r*=u/(a=r+o),o*=u/a),i+r>h&&(i*=h/(a=i+r),r*=h/a),n+o>h&&(n*=h/(a=n+o),o*=h/a),t.moveTo(s+n,l),t.lineTo(s+u-i,l),0!==i&&t.arc(s+u-i,l+i,i,-Math.PI/2,0),t.lineTo(s+u,l+h-r),0!==r&&t.arc(s+u-r,l+h-r,r,0,Math.PI/2),t.lineTo(s+o,l+h),0!==o&&t.arc(s+o,l+h-o,o,Math.PI/2,Math.PI),t.lineTo(s,l+n),0!==n&&t.arc(s+n,l+n,n,Math.PI,1.5*Math.PI)}(t,e):t.rect(n,i,r,o)},e.prototype.isZeroArea=function(){return!this.shape.width||!this.shape.height},e}(Is);zs.prototype.type="rect";var Vs={fill:"#000"},Bs={style:k({fill:!0,stroke:!0,fillOpacity:!0,strokeOpacity:!0,lineWidth:!0,fontSize:!0,lineHeight:!0,width:!0,height:!0,textShadowColor:!0,textShadowBlur:!0,textShadowOffsetX:!0,textShadowOffsetY:!0,backgroundColor:!0,padding:!0,borderColor:!0,borderWidth:!0,borderRadius:!0},_a.style)},Fs=function(t){function e(e){var n=t.call(this)||this;return n.type="text",n._children=[],n._defaultStyle=Vs,n.attr(e),n}return n(e,t),e.prototype.childrenRef=function(){return this._children},e.prototype.update=function(){t.prototype.update.call(this),this.styleChanged()&&this._updateSubTexts();for(var e=0;ed&&h){var f=Math.floor(d/l);n=n.slice(0,f)}if(t&&a&&null!=c)for(var g=la(c,o,e.ellipsis,{minChar:e.truncateMinChar,placeholder:e.placeholder}),y=0;y0,T=null!=t.width&&("truncate"===t.overflow||"break"===t.overflow||"breakAll"===t.overflow),C=i.calculatedLineHeight,D=0;Dl&&fa(n,t.substring(l,u),e,s),fa(n,i[2],e,s,i[1]),l=aa.lastIndex}lo){b>0?(m.tokens=m.tokens.slice(0,b),y(m,_,x),n.lines=n.lines.slice(0,v+1)):n.lines=n.lines.slice(0,v);break t}var C=w.width,D=null==C||"auto"===C;if("string"==typeof C&&"%"===C.charAt(C.length-1))P.percentWidth=C,h.push(P),P.contentWidth=xr(P.text,I);else{if(D){var A=w.backgroundColor,k=A&&A.image;k&&oa(k=na(k))&&(P.width=Math.max(P.width,k.width*T/k.height))}var L=f&&null!=r?r-_:null;null!=L&&L=0&&"right"===(C=x[T]).align;)this._placeToken(C,t,b,f,I,"right",y),w-=C.width,I-=C.width,T--;for(M+=(n-(M-d)-(g-I)-w)/2;S<=T;)C=x[S],this._placeToken(C,t,b,f,M+C.width/2,"center",y),M+=C.width,S++;f+=b}},e.prototype._placeToken=function(t,e,n,i,r,o,s){var l=e.rich[t.styleName]||{};l.text=t.text;var u=t.verticalAlign,h=i+n/2;"top"===u?h=i+t.height/2:"bottom"===u&&(h=i+n-t.height/2),!t.isLineHolder&&Js(l)&&this._renderBackground(l,e,"right"===o?r-t.width:"center"===o?r-t.width/2:r,h-t.height/2,t.width,t.height);var c=!!l.backgroundColor,p=t.textPadding;p&&(r=Ks(r,o,p),h-=t.height/2-p[0]-t.innerHeight/2);var d=this._getOrCreateChild(Cs),f=d.createStyle();d.useStyle(f);var g=this._defaultStyle,y=!1,v=0,m=qs("fill"in l?l.fill:"fill"in e?e.fill:(y=!0,g.fill)),x=js("stroke"in l?l.stroke:"stroke"in e?e.stroke:c||s||g.autoStroke&&!y?null:(v=2,g.stroke)),_=l.textShadowBlur>0||e.textShadowBlur>0;f.text=t.text,f.x=r,f.y=h,_&&(f.shadowBlur=l.textShadowBlur||e.textShadowBlur||0,f.shadowColor=l.textShadowColor||e.textShadowColor||"transparent",f.shadowOffsetX=l.textShadowOffsetX||e.textShadowOffsetX||0,f.shadowOffsetY=l.textShadowOffsetY||e.textShadowOffsetY||0),f.textAlign=o,f.textBaseline="middle",f.font=t.font||a,f.opacity=ot(l.opacity,e.opacity,1),Xs(f,l),x&&(f.lineWidth=ot(l.lineWidth,e.lineWidth,v),f.lineDash=rt(l.lineDash,e.lineDash),f.lineDashOffset=e.lineDashOffset||0,f.stroke=x),m&&(f.fill=m);var b=t.contentWidth,w=t.contentHeight;d.setBoundingRect(new ze(wr(f.x,b,f.textAlign),Sr(f.y,w,f.textBaseline),b,w))},e.prototype._renderBackground=function(t,e,n,i,r,o){var a,s,l,u=t.backgroundColor,h=t.borderWidth,c=t.borderColor,p=u&&u.image,d=u&&!p,f=t.borderRadius,g=this;if(d||t.lineHeight||h&&c){(a=this._getOrCreateChild(zs)).useStyle(a.createStyle()),a.style.fill=null;var y=a.shape;y.x=n,y.y=i,y.width=r,y.height=o,y.r=f,a.dirtyShape()}if(d)(l=a.style).fill=u||null,l.fillOpacity=rt(t.fillOpacity,1);else if(p){(s=this._getOrCreateChild(ks)).onload=function(){g.dirtyStyle()};var v=s.style;v.image=u.image,v.x=n,v.y=i,v.width=r,v.height=o}h&&c&&((l=a.style).lineWidth=h,l.stroke=c,l.strokeOpacity=rt(t.strokeOpacity,1),l.lineDash=t.borderDash,l.lineDashOffset=t.borderDashOffset||0,a.strokeContainThreshold=0,a.hasFill()&&a.hasStroke()&&(l.strokeFirst=!0,l.lineWidth*=2));var m=(a||s).style;m.shadowBlur=t.shadowBlur||0,m.shadowColor=t.shadowColor||"transparent",m.shadowOffsetX=t.shadowOffsetX||0,m.shadowOffsetY=t.shadowOffsetY||0,m.opacity=ot(t.opacity,e.opacity,1)},e.makeFont=function(t){var e="";return Us(t)&&(e=[t.fontStyle,t.fontWeight,Ys(t.fontSize),t.fontFamily||"sans-serif"].join(" ")),e&&ut(e)||t.textFont||t.font},e}(Sa),Gs={left:!0,right:1,center:1},Ws={top:1,bottom:1,middle:1},Hs=["fontStyle","fontWeight","fontSize","fontFamily"];function Ys(t){return"string"!=typeof t||-1===t.indexOf("px")&&-1===t.indexOf("rem")&&-1===t.indexOf("em")?isNaN(+t)?"12px":t+"px":t}function Xs(t,e){for(var n=0;n=0,o=!1;if(t instanceof Is){var a=il(t),s=r&&a.selectFill||a.normalFill,l=r&&a.selectStroke||a.normalStroke;if(dl(s)||dl(l)){var u=(i=i||{}).style||{};"inherit"===u.fill?(o=!0,i=A({},i),(u=A({},u)).fill=s):!dl(u.fill)&&dl(s)?(o=!0,i=A({},i),(u=A({},u)).fill=gl(s)):!dl(u.stroke)&&dl(l)&&(o||(i=A({},i),u=A({},u)),u.stroke=gl(l)),i.style=u}}if(i&&null==i.z2){o||(i=A({},i));var h=t.z2EmphasisLift;i.z2=t.z2+(null!=h?h:sl)}return i}(this,0,e,n);if("blur"===t)return function(t,e,n){var i=P(t.currentStates,e)>=0,r=t.style.opacity,o=i?null:function(t,e,n,i){for(var r=t.style,o={},a=0;a0){var o={dataIndex:r,seriesIndex:t.seriesIndex};null!=i&&(o.dataType=i),e.push(o)}}))})),e}function Hl(t,e,n){ql(t,!0),Ml(t,Cl),Xl(t,e,n)}function Yl(t,e,n,i){i?function(t){ql(t,!1)}(t):Hl(t,e,n)}function Xl(t,e,n){var i=Qs(t);null!=e?(i.focus=e,i.blurScope=n):i.focus&&(i.focus=null)}var Ul=["emphasis","blur","select"],Zl={itemStyle:"getItemStyle",lineStyle:"getLineStyle",areaStyle:"getAreaStyle"};function jl(t,e,n,i){n=n||"itemStyle";for(var r=0;r1&&(a*=ru(f),s*=ru(f));var g=(r===o?-1:1)*ru((a*a*(s*s)-a*a*(d*d)-s*s*(p*p))/(a*a*(d*d)+s*s*(p*p)))||0,y=g*a*d/s,v=g*-s*p/a,m=(t+n)/2+au(c)*y-ou(c)*v,x=(e+i)/2+ou(c)*y+au(c)*v,_=hu([1,0],[(p-y)/a,(d-v)/s]),b=[(p-y)/a,(d-v)/s],w=[(-1*p-y)/a,(-1*d-v)/s],S=hu(b,w);if(uu(b,w)<=-1&&(S=su),uu(b,w)>=1&&(S=0),S<0){var M=Math.round(S/su*1e6)/1e6;S=2*su+M%2*su}h.addData(u,m,x,a,s,_,S,c,o)}var pu=/([mlvhzcqtsa])([^mlvhzcqtsa]*)/gi,du=/-?([0-9]*\.)?[0-9]+([eE]-?[0-9]+)?/g;var fu=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return n(e,t),e.prototype.applyTransform=function(t){},e}(Is);function gu(t){return null!=t.setData}function yu(t,e){var n=function(t){var e=new os;if(!t)return e;var n,i=0,r=0,o=i,a=r,s=os.CMD,l=t.match(pu);if(!l)return e;for(var u=0;uk*k+L*L&&(M=T,I=C),{cx:M,cy:I,x0:-h,y0:-c,x1:M*(r/b-1),y1:I*(r/b-1)}}function Nu(t,e){var n,i=Lu(e.r,0),r=Lu(e.r0||0,0),o=i>0;if(o||r>0){if(o||(i=r,r=0),r>i){var a=i;i=r,r=a}var s=e.startAngle,l=e.endAngle;if(!isNaN(s)&&!isNaN(l)){var u=e.cx,h=e.cy,c=!!e.clockwise,p=Au(l-s),d=p>Mu&&p%Mu;if(d>Ou&&(p=d),i>Ou)if(p>Mu-Ou)t.moveTo(u+i*Tu(s),h+i*Iu(s)),t.arc(u,h,i,s,l,!c),r>Ou&&(t.moveTo(u+r*Tu(l),h+r*Iu(l)),t.arc(u,h,r,l,s,c));else{var f=void 0,g=void 0,y=void 0,v=void 0,m=void 0,x=void 0,_=void 0,b=void 0,w=void 0,S=void 0,M=void 0,I=void 0,T=void 0,C=void 0,D=void 0,A=void 0,k=i*Tu(s),L=i*Iu(s),P=r*Tu(l),O=r*Iu(l),R=p>Ou;if(R){var N=e.cornerRadius;N&&(n=function(t){var e;if(Y(t)){var n=t.length;if(!n)return t;e=1===n?[t[0],t[0],0,0]:2===n?[t[0],t[0],t[1],t[1]]:3===n?t.concat(t[2]):t}else e=[t,t,t,t];return e}(N),f=n[0],g=n[1],y=n[2],v=n[3]);var E=Au(i-r)/2;if(m=Pu(E,y),x=Pu(E,v),_=Pu(E,f),b=Pu(E,g),M=w=Lu(m,x),I=S=Lu(_,b),(w>Ou||S>Ou)&&(T=i*Tu(l),C=i*Iu(l),D=r*Tu(s),A=r*Iu(s),pOu){var X=Pu(y,M),U=Pu(v,M),Z=Ru(D,A,k,L,i,X,c),j=Ru(T,C,P,O,i,U,c);t.moveTo(u+Z.cx+Z.x0,h+Z.cy+Z.y0),M0&&t.arc(u+Z.cx,h+Z.cy,X,Du(Z.y0,Z.x0),Du(Z.y1,Z.x1),!c),t.arc(u,h,i,Du(Z.cy+Z.y1,Z.cx+Z.x1),Du(j.cy+j.y1,j.cx+j.x1),!c),U>0&&t.arc(u+j.cx,h+j.cy,U,Du(j.y1,j.x1),Du(j.y0,j.x0),!c))}else t.moveTo(u+k,h+L),t.arc(u,h,i,s,l,!c);else t.moveTo(u+k,h+L);if(r>Ou&&R)if(I>Ou){X=Pu(f,I),Z=Ru(P,O,T,C,r,-(U=Pu(g,I)),c),j=Ru(k,L,D,A,r,-X,c);t.lineTo(u+Z.cx+Z.x0,h+Z.cy+Z.y0),I0&&t.arc(u+Z.cx,h+Z.cy,U,Du(Z.y0,Z.x0),Du(Z.y1,Z.x1),!c),t.arc(u,h,r,Du(Z.cy+Z.y1,Z.cx+Z.x1),Du(j.cy+j.y1,j.cx+j.x1),c),X>0&&t.arc(u+j.cx,h+j.cy,X,Du(j.y1,j.x1),Du(j.y0,j.x0),!c))}else t.lineTo(u+P,h+O),t.arc(u,h,r,l,s,c);else t.lineTo(u+P,h+O)}else t.moveTo(u,h);t.closePath()}}}var Eu=function(){this.cx=0,this.cy=0,this.r0=0,this.r=0,this.startAngle=0,this.endAngle=2*Math.PI,this.clockwise=!0,this.cornerRadius=0},zu=function(t){function e(e){return t.call(this,e)||this}return n(e,t),e.prototype.getDefaultShape=function(){return new Eu},e.prototype.buildPath=function(t,e){Nu(t,e)},e.prototype.isZeroArea=function(){return this.shape.startAngle===this.shape.endAngle||this.shape.r===this.shape.r0},e}(Is);zu.prototype.type="sector";var Vu=function(){this.cx=0,this.cy=0,this.r=0,this.r0=0},Bu=function(t){function e(e){return t.call(this,e)||this}return n(e,t),e.prototype.getDefaultShape=function(){return new Vu},e.prototype.buildPath=function(t,e){var n=e.cx,i=e.cy,r=2*Math.PI;t.moveTo(n+e.r,i),t.arc(n,i,e.r,0,r,!1),t.moveTo(n+e.r0,i),t.arc(n,i,e.r0,0,r,!0)},e}(Is);function Fu(t,e,n){var i=e.smooth,r=e.points;if(r&&r.length>=2){if(i){var o=function(t,e,n,i){var r,o,a,s,l=[],u=[],h=[],c=[];if(i){a=[1/0,1/0],s=[-1/0,-1/0];for(var p=0,d=t.length;poh[1]){if(a=!1,r)return a;var u=Math.abs(oh[0]-rh[1]),h=Math.abs(rh[0]-oh[1]);Math.min(u,h)>i.len()&&(u0){var c={duration:h.duration,delay:h.delay||0,easing:h.easing,done:o,force:!!o||!!a,setToFinal:!u,scope:t,during:a};l?e.animateFrom(n,c):e.animateTo(n,c)}else e.stopAnimation(),!l&&e.attr(n),a&&a(1),o&&o()}function fh(t,e,n,i,r,o){dh("update",t,e,n,i,r,o)}function gh(t,e,n,i,r,o){dh("enter",t,e,n,i,r,o)}function yh(t){if(!t.__zr)return!0;for(var e=0;eMath.abs(o[1])?o[0]>0?"right":"left":o[1]>0?"bottom":"top"}function Bh(t){return!t.isGroup}function Fh(t,e,n){if(t&&e){var i,r=(i={},t.traverse((function(t){Bh(t)&&t.anid&&(i[t.anid]=t)})),i);e.traverse((function(t){if(Bh(t)&&t.anid){var e=r[t.anid];if(e){var i=o(t);t.attr(o(e)),fh(t,i,n,Qs(t).dataIndex)}}}))}function o(t){var e={x:t.x,y:t.y,rotation:t.rotation};return function(t){return null!=t.shape}(t)&&(e.shape=A({},t.shape)),e}}function Gh(t,e){return z(t,(function(t){var n=t[0];n=bh(n,e.x),n=wh(n,e.x+e.width);var i=t[1];return i=bh(i,e.y),[n,i=wh(i,e.y+e.height)]}))}function Wh(t,e){var n=bh(t.x,e.x),i=wh(t.x+t.width,e.x+e.width),r=bh(t.y,e.y),o=wh(t.y+t.height,e.y+e.height);if(i>=n&&o>=r)return{x:n,y:r,width:i-n,height:o-r}}function Hh(t,e,n){var i=A({rectHover:!0},e),r=i.style={strokeNoScale:!0};if(n=n||{x:-1,y:-1,width:2,height:2},t)return 0===t.indexOf("image://")?(r.image=t.slice(8),k(r,n),new ks(i)):Ah(t.replace("path://",""),i,n,"center")}function Yh(t,e,n,i,r){for(var o=0,a=r[r.length-1];o=-1e-6)return!1;var f=t-r,g=e-o,y=Uh(f,g,u,h)/d;if(y<0||y>1)return!1;var v=Uh(f,g,c,p)/d;return!(v<0||v>1)}function Uh(t,e,n,i){return t*i-n*e}function Zh(t){var e=t.itemTooltipOption,n=t.componentModel,i=t.itemName,r=U(e)?{formatter:e}:e,o=n.mainType,a=n.componentIndex,s={componentType:o,name:i,$vars:["name"]};s[o+"Index"]=a;var l=t.formatterParamsExtra;l&&E(G(l),(function(t){_t(s,t)||(s[t]=l[t],s.$vars.push(t))}));var u=Qs(t.el);u.componentMainType=o,u.componentIndex=a,u.tooltipConfig={name:i,option:k({content:i,formatterParams:s},r)}}function jh(t,e){var n;t.isGroup&&(n=e(t)),n||t.traverse(e)}function qh(t,e){if(t)if(Y(t))for(var n=0;n-1?Dc:kc;function Rc(t,e){t=t.toUpperCase(),Pc[t]=new Mc(e),Lc[t]=e}function Nc(t){return Pc[t]}Rc(Ac,{time:{month:["January","February","March","April","May","June","July","August","September","October","November","December"],monthAbbr:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],dayOfWeek:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayOfWeekAbbr:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"]},legend:{selector:{all:"All",inverse:"Inv"}},toolbox:{brush:{title:{rect:"Box Select",polygon:"Lasso Select",lineX:"Horizontally Select",lineY:"Vertically Select",keep:"Keep Selections",clear:"Clear Selections"}},dataView:{title:"Data View",lang:["Data View","Close","Refresh"]},dataZoom:{title:{zoom:"Zoom",back:"Zoom Reset"}},magicType:{title:{line:"Switch to Line Chart",bar:"Switch to Bar Chart",stack:"Stack",tiled:"Tile"}},restore:{title:"Restore"},saveAsImage:{title:"Save as Image",lang:["Right Click to Save Image"]}},series:{typeNames:{pie:"Pie chart",bar:"Bar chart",line:"Line chart",scatter:"Scatter plot",effectScatter:"Ripple scatter plot",radar:"Radar chart",tree:"Tree",treemap:"Treemap",boxplot:"Boxplot",candlestick:"Candlestick",k:"K line chart",heatmap:"Heat map",map:"Map",parallel:"Parallel coordinate map",lines:"Line graph",graph:"Relationship graph",sankey:"Sankey diagram",funnel:"Funnel chart",gauge:"Gauge",pictorialBar:"Pictorial bar",themeRiver:"Theme River Map",sunburst:"Sunburst"}},aria:{general:{withTitle:'This is a chart about "{title}"',withoutTitle:"This is a chart"},series:{single:{prefix:"",withName:" with type {seriesType} named {seriesName}.",withoutName:" with type {seriesType}."},multiple:{prefix:". It consists of {seriesCount} series count.",withName:" The {seriesId} series is a {seriesType} representing {seriesName}.",withoutName:" The {seriesId} series is a {seriesType}.",separator:{middle:"",end:""}}},data:{allData:"The data is as follows: ",partialData:"The first {displayCnt} items are: ",withName:"the data for {name} is {value}",withoutName:"{value}",separator:{middle:", ",end:". "}}}}),Rc(Dc,{time:{month:["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"],monthAbbr:["1月","2月","3月","4月","5月","6月","7月","8月","9月","10月","11月","12月"],dayOfWeek:["星期日","星期一","星期二","星期三","星期四","星期五","星期六"],dayOfWeekAbbr:["日","一","二","三","四","五","六"]},legend:{selector:{all:"全选",inverse:"反选"}},toolbox:{brush:{title:{rect:"矩形选择",polygon:"圈选",lineX:"横向选择",lineY:"纵向选择",keep:"保持选择",clear:"清除选择"}},dataView:{title:"数据视图",lang:["数据视图","关闭","刷新"]},dataZoom:{title:{zoom:"区域缩放",back:"区域缩放还原"}},magicType:{title:{line:"切换为折线图",bar:"切换为柱状图",stack:"切换为堆叠",tiled:"切换为平铺"}},restore:{title:"还原"},saveAsImage:{title:"保存为图片",lang:["右键另存为图片"]}},series:{typeNames:{pie:"饼图",bar:"柱状图",line:"折线图",scatter:"散点图",effectScatter:"涟漪散点图",radar:"雷达图",tree:"树图",treemap:"矩形树图",boxplot:"箱型图",candlestick:"K线图",k:"K线图",heatmap:"热力图",map:"地图",parallel:"平行坐标图",lines:"线图",graph:"关系图",sankey:"桑基图",funnel:"漏斗图",gauge:"仪表盘图",pictorialBar:"象形柱图",themeRiver:"主题河流图",sunburst:"旭日图"}},aria:{general:{withTitle:"这是一个关于“{title}”的图表。",withoutTitle:"这是一个图表,"},series:{single:{prefix:"",withName:"图表类型是{seriesType},表示{seriesName}。",withoutName:"图表类型是{seriesType}。"},multiple:{prefix:"它由{seriesCount}个图表系列组成。",withName:"第{seriesId}个系列是一个表示{seriesName}的{seriesType},",withoutName:"第{seriesId}个系列是一个{seriesType},",separator:{middle:";",end:"。"}}},data:{allData:"其数据是——",partialData:"其中,前{displayCnt}项是——",withName:"{name}的数据是{value}",withoutName:"{value}",separator:{middle:",",end:""}}}});var Ec=1e3,zc=6e4,Vc=36e5,Bc=864e5,Fc=31536e6,Gc={year:"{yyyy}",month:"{MMM}",day:"{d}",hour:"{HH}:{mm}",minute:"{HH}:{mm}",second:"{HH}:{mm}:{ss}",millisecond:"{HH}:{mm}:{ss} {SSS}",none:"{yyyy}-{MM}-{dd} {HH}:{mm}:{ss} {SSS}"},Wc="{yyyy}-{MM}-{dd}",Hc={year:"{yyyy}",month:"{yyyy}-{MM}",day:Wc,hour:Wc+" "+Gc.hour,minute:Wc+" "+Gc.minute,second:Wc+" "+Gc.second,millisecond:Gc.none},Yc=["year","month","day","hour","minute","second","millisecond"],Xc=["year","half-year","quarter","month","week","half-week","day","half-day","quarter-day","hour","minute","second","millisecond"];function Uc(t,e){return"0000".substr(0,e-(t+="").length)+t}function Zc(t){switch(t){case"half-year":case"quarter":return"month";case"week":case"half-week":return"day";case"half-day":case"quarter-day":return"hour";default:return t}}function jc(t){return t===Zc(t)}function qc(t,e,n,i){var r=ro(t),o=r[Jc(n)](),a=r[Qc(n)]()+1,s=Math.floor((a-1)/3)+1,l=r[tp(n)](),u=r["get"+(n?"UTC":"")+"Day"](),h=r[ep(n)](),c=(h-1)%12+1,p=r[np(n)](),d=r[ip(n)](),f=r[rp(n)](),g=(i instanceof Mc?i:Nc(i||Oc)||Pc[kc]).getModel("time"),y=g.get("month"),v=g.get("monthAbbr"),m=g.get("dayOfWeek"),x=g.get("dayOfWeekAbbr");return(e||"").replace(/{yyyy}/g,o+"").replace(/{yy}/g,Uc(o%100+"",2)).replace(/{Q}/g,s+"").replace(/{MMMM}/g,y[a-1]).replace(/{MMM}/g,v[a-1]).replace(/{MM}/g,Uc(a,2)).replace(/{M}/g,a+"").replace(/{dd}/g,Uc(l,2)).replace(/{d}/g,l+"").replace(/{eeee}/g,m[u]).replace(/{ee}/g,x[u]).replace(/{e}/g,u+"").replace(/{HH}/g,Uc(h,2)).replace(/{H}/g,h+"").replace(/{hh}/g,Uc(c+"",2)).replace(/{h}/g,c+"").replace(/{mm}/g,Uc(p,2)).replace(/{m}/g,p+"").replace(/{ss}/g,Uc(d,2)).replace(/{s}/g,d+"").replace(/{SSS}/g,Uc(f,3)).replace(/{S}/g,f+"")}function Kc(t,e){var n=ro(t),i=n[Qc(e)]()+1,r=n[tp(e)](),o=n[ep(e)](),a=n[np(e)](),s=n[ip(e)](),l=0===n[rp(e)](),u=l&&0===s,h=u&&0===a,c=h&&0===o,p=c&&1===r;return p&&1===i?"year":p?"month":c?"day":h?"hour":u?"minute":l?"second":"millisecond"}function $c(t,e,n){var i=j(t)?ro(t):t;switch(e=e||Kc(t,n)){case"year":return i[Jc(n)]();case"half-year":return i[Qc(n)]()>=6?1:0;case"quarter":return Math.floor((i[Qc(n)]()+1)/4);case"month":return i[Qc(n)]();case"day":return i[tp(n)]();case"half-day":return i[ep(n)]()/24;case"hour":return i[ep(n)]();case"minute":return i[np(n)]();case"second":return i[ip(n)]();case"millisecond":return i[rp(n)]()}}function Jc(t){return t?"getUTCFullYear":"getFullYear"}function Qc(t){return t?"getUTCMonth":"getMonth"}function tp(t){return t?"getUTCDate":"getDate"}function ep(t){return t?"getUTCHours":"getHours"}function np(t){return t?"getUTCMinutes":"getMinutes"}function ip(t){return t?"getUTCSeconds":"getSeconds"}function rp(t){return t?"getUTCMilliseconds":"getMilliseconds"}function op(t){return t?"setUTCFullYear":"setFullYear"}function ap(t){return t?"setUTCMonth":"setMonth"}function sp(t){return t?"setUTCDate":"setDate"}function lp(t){return t?"setUTCHours":"setHours"}function up(t){return t?"setUTCMinutes":"setMinutes"}function hp(t){return t?"setUTCSeconds":"setSeconds"}function cp(t){return t?"setUTCMilliseconds":"setMilliseconds"}function pp(t){if(!co(t))return U(t)?t:"-";var e=(t+"").split(".");return e[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,"$1,")+(e.length>1?"."+e[1]:"")}function dp(t,e){return t=(t||"").toLowerCase().replace(/-(.)/g,(function(t,e){return e.toUpperCase()})),e&&t&&(t=t.charAt(0).toUpperCase()+t.slice(1)),t}var fp=st;function gp(t,e,n){function i(t){return t&&ut(t)?t:"-"}function r(t){return!(null==t||isNaN(t)||!isFinite(t))}var o="time"===e,a=t instanceof Date;if(o||a){var s=o?ro(t):t;if(!isNaN(+s))return qc(s,"{yyyy}-{MM}-{dd} {HH}:{mm}:{ss}",n);if(a)return"-"}if("ordinal"===e)return Z(t)?i(t):j(t)&&r(t)?t+"":"-";var l=ho(t);return r(l)?pp(l):Z(t)?i(t):"boolean"==typeof t?t+"":"-"}var yp=["a","b","c","d","e","f","g"],vp=function(t,e){return"{"+t+(null==e?"":e)+"}"};function mp(t,e,n){Y(e)||(e=[e]);var i=e.length;if(!i)return"";for(var r=e[0].$vars||[],o=0;o':'':{renderMode:o,content:"{"+(n.markerId||"markerX")+"|} ",style:"subItem"===r?{width:4,height:4,borderRadius:2,backgroundColor:i}:{width:10,height:10,borderRadius:5,backgroundColor:i}}:""}function _p(t,e){return e=e||"transparent",U(t)?t:q(t)&&t.colorStops&&(t.colorStops[0]||{}).color||e}function bp(t,e){if("_blank"===e||"blank"===e){var n=window.open();n.opener=null,n.location.href=t}else window.open(t,e)}var wp=E,Sp=["left","right","top","bottom","width","height"],Mp=[["width","left","right"],["height","top","bottom"]];function Ip(t,e,n,i,r){var o=0,a=0;null==i&&(i=1/0),null==r&&(r=1/0);var s=0;e.eachChild((function(l,u){var h,c,p=l.getBoundingRect(),d=e.childAt(u+1),f=d&&d.getBoundingRect();if("horizontal"===t){var g=p.width+(f?-f.x+p.x:0);(h=o+g)>i||l.newline?(o=0,h=g,a+=s+n,s=p.height):s=Math.max(s,p.height)}else{var y=p.height+(f?-f.y+p.y:0);(c=a+y)>r||l.newline?(o+=s+n,a=0,c=y,s=p.width):s=Math.max(s,p.width)}l.newline||(l.x=o,l.y=a,l.markRedraw(),"horizontal"===t?o=h+n:a=c+n)}))}var Tp=Ip;H(Ip,"vertical"),H(Ip,"horizontal");function Cp(t,e,n){n=fp(n||0);var i=e.width,r=e.height,o=Ur(t.left,i),a=Ur(t.top,r),s=Ur(t.right,i),l=Ur(t.bottom,r),u=Ur(t.width,i),h=Ur(t.height,r),c=n[2]+n[0],p=n[1]+n[3],d=t.aspect;switch(isNaN(u)&&(u=i-s-p-o),isNaN(h)&&(h=r-l-c-a),null!=d&&(isNaN(u)&&isNaN(h)&&(d>i/r?u=.8*i:h=.8*r),isNaN(u)&&(u=d*h),isNaN(h)&&(h=u/d)),isNaN(o)&&(o=i-s-u-p),isNaN(a)&&(a=r-l-h-c),t.left||t.right){case"center":o=i/2-u/2-n[3];break;case"right":o=i-u-p}switch(t.top||t.bottom){case"middle":case"center":a=r/2-h/2-n[0];break;case"bottom":a=r-h-c}o=o||0,a=a||0,isNaN(u)&&(u=i-p-o-(s||0)),isNaN(h)&&(h=r-c-a-(l||0));var f=new ze(o+n[3],a+n[0],u,h);return f.margin=n,f}function Dp(t,e,n,i,r,o){var a,s=!r||!r.hv||r.hv[0],l=!r||!r.hv||r.hv[1],u=r&&r.boundingMode||"all";if((o=o||t).x=t.x,o.y=t.y,!s&&!l)return!1;if("raw"===u)a="group"===t.type?new ze(0,0,+e.width||0,+e.height||0):t.getBoundingRect();else if(a=t.getBoundingRect(),t.needLocalTransform()){var h=t.getLocalTransform();(a=a.clone()).applyTransform(h)}var c=Cp(k({width:a.width,height:a.height},e),n,i),p=s?c.x-a.x:0,d=l?c.y-a.y:0;return"raw"===u?(o.x=p,o.y=d):(o.x+=p,o.y+=d),o===t&&t.markRedraw(),!0}function Ap(t){var e=t.layoutMode||t.constructor.layoutMode;return q(e)?e:e?{type:e}:null}function kp(t,e,n){var i=n&&n.ignoreSize;!Y(i)&&(i=[i,i]);var r=a(Mp[0],0),o=a(Mp[1],1);function a(n,r){var o={},a=0,u={},h=0;if(wp(n,(function(e){u[e]=t[e]})),wp(n,(function(t){s(e,t)&&(o[t]=u[t]=e[t]),l(o,t)&&a++,l(u,t)&&h++})),i[r])return l(e,n[1])?u[n[2]]=null:l(e,n[2])&&(u[n[1]]=null),u;if(2!==h&&a){if(a>=2)return o;for(var c=0;c=0;a--)o=C(o,n[a],!0);e.defaultOption=o}return e.defaultOption},e.prototype.getReferringComponents=function(t,e){var n=t+"Index",i=t+"Id";return Bo(this.ecModel,t,{index:this.get(n,!0),id:this.get(i,!0)},e)},e.prototype.getBoxLayoutParams=function(){var t=this;return{left:t.get("left"),top:t.get("top"),right:t.get("right"),bottom:t.get("bottom"),width:t.get("width"),height:t.get("height")}},e.prototype.getZLevelKey=function(){return""},e.prototype.setZLevel=function(t){this.option.zlevel=t},e.protoInitialize=function(){var t=e.prototype;t.type="component",t.id="",t.name="",t.mainType="",t.subType="",t.componentIndex=0}(),e}(Mc);Zo(Rp,Mc),$o(Rp),function(t){var e={};t.registerSubTypeDefaulter=function(t,n){var i=Xo(t);e[i.main]=n},t.determineSubType=function(n,i){var r=i.type;if(!r){var o=Xo(n).main;t.hasSubTypes(n)&&e[o]&&(r=e[o](i))}return r}}(Rp),function(t,e){function n(t,e){return t[e]||(t[e]={predecessor:[],successor:[]}),t[e]}t.topologicalTravel=function(t,i,r,o){if(t.length){var a=function(t){var i={},r=[];return E(t,(function(o){var a=n(i,o),s=function(t,e){var n=[];return E(t,(function(t){P(e,t)>=0&&n.push(t)})),n}(a.originalDeps=e(o),t);a.entryCount=s.length,0===a.entryCount&&r.push(o),E(s,(function(t){P(a.predecessor,t)<0&&a.predecessor.push(t);var e=n(i,t);P(e.successor,t)<0&&e.successor.push(o)}))})),{graph:i,noEntryList:r}}(i),s=a.graph,l=a.noEntryList,u={};for(E(t,(function(t){u[t]=!0}));l.length;){var h=l.pop(),c=s[h],p=!!u[h];p&&(r.call(o,h,c.originalDeps.slice()),delete u[h]),E(c.successor,p?f:d)}E(u,(function(){var t="";throw new Error(t)}))}function d(t){s[t].entryCount--,0===s[t].entryCount&&l.push(t)}function f(t){u[t]=!0,d(t)}}}(Rp,(function(t){var e=[];E(Rp.getClassesByMainType(t),(function(t){e=e.concat(t.dependencies||t.prototype.dependencies||[])})),e=z(e,(function(t){return Xo(t).main})),"dataset"!==t&&P(e,"dataset")<=0&&e.unshift("dataset");return e}));var Np="";"undefined"!=typeof navigator&&(Np=navigator.platform||"");var Ep="rgba(0, 0, 0, 0.2)",zp={darkMode:"auto",colorBy:"series",color:["#5470c6","#91cc75","#fac858","#ee6666","#73c0de","#3ba272","#fc8452","#9a60b4","#ea7ccc"],gradientColor:["#f6efa6","#d88273","#bf444c"],aria:{decal:{decals:[{color:Ep,dashArrayX:[1,0],dashArrayY:[2,5],symbolSize:1,rotation:Math.PI/6},{color:Ep,symbol:"circle",dashArrayX:[[8,8],[0,8,8,0]],dashArrayY:[6,0],symbolSize:.8},{color:Ep,dashArrayX:[1,0],dashArrayY:[4,3],rotation:-Math.PI/4},{color:Ep,dashArrayX:[[6,6],[0,6,6,0]],dashArrayY:[6,0]},{color:Ep,dashArrayX:[[1,0],[1,6]],dashArrayY:[1,0,6,0],rotation:Math.PI/4},{color:Ep,symbol:"triangle",dashArrayX:[[9,9],[0,9,9,0]],dashArrayY:[7,2],symbolSize:.75}]}},textStyle:{fontFamily:Np.match(/^Win/)?"Microsoft YaHei":"sans-serif",fontSize:12,fontStyle:"normal",fontWeight:"normal"},blendMode:null,stateAnimation:{duration:300,easing:"cubicOut"},animation:"auto",animationDuration:1e3,animationDurationUpdate:500,animationEasing:"cubicInOut",animationEasingUpdate:"cubicInOut",animationThreshold:2e3,progressiveThreshold:3e3,progressive:400,hoverLayerThreshold:3e3,useUTC:!1},Vp=yt(["tooltip","label","itemName","itemId","itemGroupId","seriesName"]),Bp="original",Fp="arrayRows",Gp="objectRows",Wp="keyedColumns",Hp="typedArray",Yp="unknown",Xp="column",Up="row",Zp=1,jp=2,qp=3,Kp=Oo();function $p(t,e,n){var i={},r=Qp(e);if(!r||!t)return i;var o,a,s=[],l=[],u=e.ecModel,h=Kp(u).datasetMap,c=r.uid+"_"+n.seriesLayoutBy;E(t=t.slice(),(function(e,n){var r=q(e)?e:t[n]={name:e};"ordinal"===r.type&&null==o&&(o=n,a=f(r)),i[r.name]=[]}));var p=h.get(c)||h.set(c,{categoryWayDim:a,valueWayDim:0});function d(t,e,n){for(var i=0;ie)return t[i];return t[n-1]}(i,a):n;if((h=h||n)&&h.length){var c=h[l];return r&&(u[r]=c),s.paletteIdx=(l+1)%h.length,c}}var cd="\0_ec_inner";var pd=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return n(e,t),e.prototype.init=function(t,e,n,i,r,o){i=i||{},this.option=null,this._theme=new Mc(i),this._locale=new Mc(r),this._optionManager=o},e.prototype.setOption=function(t,e,n){var i=gd(e);this._optionManager.setOption(t,n,i),this._resetOption(null,i)},e.prototype.resetOption=function(t,e){return this._resetOption(t,gd(e))},e.prototype._resetOption=function(t,e){var n=!1,i=this._optionManager;if(!t||"recreate"===t){var r=i.mountOption("recreate"===t);0,this.option&&"recreate"!==t?(this.restoreData(),this._mergeOption(r,e)):od(this,r),n=!0}if("timeline"!==t&&"media"!==t||this.restoreData(),!t||"recreate"===t||"timeline"===t){var o=i.getTimelineOption(this);o&&(n=!0,this._mergeOption(o,e))}if(!t||"recreate"===t||"media"===t){var a=i.getMediaOption(this);a.length&&E(a,(function(t){n=!0,this._mergeOption(t,e)}),this)}return n},e.prototype.mergeOption=function(t){this._mergeOption(t,null)},e.prototype._mergeOption=function(t,e){var n=this.option,i=this._componentsMap,r=this._componentsCount,o=[],a=yt(),s=e&&e.replaceMergeMainTypeMap;Kp(this).datasetMap=yt(),E(t,(function(t,e){null!=t&&(Rp.hasClass(e)?e&&(o.push(e),a.set(e,!0)):n[e]=null==n[e]?T(t):C(n[e],t,!0))})),s&&s.each((function(t,e){Rp.hasClass(e)&&!a.get(e)&&(o.push(e),a.set(e,!0))})),Rp.topologicalTravel(o,Rp.getAllClassMainTypes(),(function(e){var o=function(t,e,n){var i=nd.get(e);if(!i)return n;var r=i(t);return r?n.concat(r):n}(this,e,bo(t[e])),a=i.get(e),l=a?s&&s.get(e)?"replaceMerge":"normalMerge":"replaceAll",u=To(a,o,l);(function(t,e,n){E(t,(function(t){var i=t.newOption;q(i)&&(t.keyInfo.mainType=e,t.keyInfo.subType=function(t,e,n,i){return e.type?e.type:n?n.subType:i.determineSubType(t,e)}(e,i,t.existing,n))}))})(u,e,Rp),n[e]=null,i.set(e,null),r.set(e,0);var h,c=[],p=[],d=0;E(u,(function(t,n){var i=t.existing,r=t.newOption;if(r){var o="series"===e,a=Rp.getClass(e,t.keyInfo.subType,!o);if(!a)return;if("tooltip"===e){if(h)return void 0;h=!0}if(i&&i.constructor===a)i.name=t.keyInfo.name,i.mergeOption(r,this),i.optionUpdated(r,!1);else{var s=A({componentIndex:n},t.keyInfo);A(i=new a(r,this,this,s),s),t.brandNew&&(i.__requireNewView=!0),i.init(r,this,this),i.optionUpdated(null,!0)}}else i&&(i.mergeOption({},this),i.optionUpdated({},!1));i?(c.push(i.option),p.push(i),d++):(c.push(void 0),p.push(void 0))}),this),n[e]=c,i.set(e,p),r.set(e,d),"series"===e&&id(this)}),this),this._seriesIndices||id(this)},e.prototype.getOption=function(){var t=T(this.option);return E(t,(function(e,n){if(Rp.hasClass(n)){for(var i=bo(e),r=i.length,o=!1,a=r-1;a>=0;a--)i[a]&&!Lo(i[a])?o=!0:(i[a]=null,!o&&r--);i.length=r,t[n]=i}})),delete t[cd],t},e.prototype.getTheme=function(){return this._theme},e.prototype.getLocaleModel=function(){return this._locale},e.prototype.setUpdatePayload=function(t){this._payload=t},e.prototype.getUpdatePayload=function(){return this._payload},e.prototype.getComponent=function(t,e){var n=this._componentsMap.get(t);if(n){var i=n[e||0];if(i)return i;if(null==e)for(var r=0;r=e:"max"===n?t<=e:t===e})(i[a],t,o)||(r=!1)}})),r}var Sd=E,Md=q,Id=["areaStyle","lineStyle","nodeStyle","linkStyle","chordStyle","label","labelLine"];function Td(t){var e=t&&t.itemStyle;if(e)for(var n=0,i=Id.length;n=0;g--){var y=t[g];if(s||(p=y.data.rawIndexOf(y.stackedByDimension,c)),p>=0){var v=y.data.getByRawIndex(y.stackResultDimension,p);if("all"===l||"positive"===l&&v>0||"negative"===l&&v<0||"samesign"===l&&d>=0&&v>0||"samesign"===l&&d<=0&&v<0){d=Qr(d,v),f=v;break}}}return i[0]=d,i[1]=f,i}))}))}var Yd,Xd,Ud,Zd,jd,qd=function(t){this.data=t.data||(t.sourceFormat===Wp?{}:[]),this.sourceFormat=t.sourceFormat||Yp,this.seriesLayoutBy=t.seriesLayoutBy||Xp,this.startIndex=t.startIndex||0,this.dimensionsDetectedCount=t.dimensionsDetectedCount,this.metaRawOption=t.metaRawOption;var e=this.dimensionsDefine=t.dimensionsDefine;if(e)for(var n=0;nu&&(u=d)}s[0]=l,s[1]=u}},i=function(){return this._data?this._data.length/this._dimSize:0};function r(t){for(var e=0;e=0&&(s=o.interpolatedValue[l])}return null!=s?s+"":""})):void 0},t.prototype.getRawValue=function(t,e){return gf(this.getData(e),t)},t.prototype.formatTooltip=function(t,e,n){},t}();function mf(t){var e,n;return q(t)?t.type&&(n=t):e=t,{text:e,frag:n}}function xf(t){return new _f(t)}var _f=function(){function t(t){t=t||{},this._reset=t.reset,this._plan=t.plan,this._count=t.count,this._onDirty=t.onDirty,this._dirty=!0}return t.prototype.perform=function(t){var e,n=this._upstream,i=t&&t.skip;if(this._dirty&&n){var r=this.context;r.data=r.outputData=n.context.outputData}this.__pipeline&&(this.__pipeline.currentTask=this),this._plan&&!i&&(e=this._plan(this.context));var o,a=h(this._modBy),s=this._modDataCount||0,l=h(t&&t.modBy),u=t&&t.modDataCount||0;function h(t){return!(t>=1)&&(t=1),t}a===l&&s===u||(e="reset"),(this._dirty||"reset"===e)&&(this._dirty=!1,o=this._doReset(i)),this._modBy=l,this._modDataCount=u;var c=t&&t.step;if(this._dueEnd=n?n._outputDueEnd:this._count?this._count(this.context):1/0,this._progress){var p=this._dueIndex,d=Math.min(null!=c?this._dueIndex+c:1/0,this._dueEnd);if(!i&&(o||p1&&i>0?s:a}};return o;function a(){return e=t?null:oe},gte:function(t,e){return t>=e}},Tf=function(){function t(t,e){if(!j(e)){var n="";0,vo(n)}this._opFn=If[t],this._rvalFloat=ho(e)}return t.prototype.evaluate=function(t){return j(t)?this._opFn(t,this._rvalFloat):this._opFn(ho(t),this._rvalFloat)},t}(),Cf=function(){function t(t,e){var n="desc"===t;this._resultLT=n?1:-1,null==e&&(e=n?"min":"max"),this._incomparable="min"===e?-1/0:1/0}return t.prototype.evaluate=function(t,e){var n=j(t)?t:ho(t),i=j(e)?e:ho(e),r=isNaN(n),o=isNaN(i);if(r&&(n=this._incomparable),o&&(i=this._incomparable),r&&o){var a=U(t),s=U(e);a&&(n=s?t:0),s&&(i=a?e:0)}return ni?-this._resultLT:0},t}(),Df=function(){function t(t,e){this._rval=e,this._isEQ=t,this._rvalTypeof=typeof e,this._rvalFloat=ho(e)}return t.prototype.evaluate=function(t){var e=t===this._rval;if(!e){var n=typeof t;n===this._rvalTypeof||"number"!==n&&"number"!==this._rvalTypeof||(e=ho(t)===this._rvalFloat)}return this._isEQ?e:!e},t}();function Af(t,e){return"eq"===t||"ne"===t?new Df("eq"===t,e):_t(If,t)?new Tf(t,e):null}var kf=function(){function t(){}return t.prototype.getRawData=function(){throw new Error("not supported")},t.prototype.getRawDataItem=function(t){throw new Error("not supported")},t.prototype.cloneRawData=function(){},t.prototype.getDimensionInfo=function(t){},t.prototype.cloneAllDimensionInfo=function(){},t.prototype.count=function(){},t.prototype.retrieveValue=function(t,e){},t.prototype.retrieveValueFromItem=function(t,e){},t.prototype.convertValue=function(t,e){return wf(t,e)},t}();function Lf(t){var e=t.sourceFormat;if(!zf(e)){var n="";0,vo(n)}return t.data}function Pf(t){var e=t.sourceFormat,n=t.data;if(!zf(e)){var i="";0,vo(i)}if(e===Fp){for(var r=[],o=0,a=n.length;o65535?Ff:Gf}function Uf(t,e,n,i,r){var o=Yf[n||"float"];if(r){var a=t[e],s=a&&a.length;if(s!==i){for(var l=new o(i),u=0;ug[1]&&(g[1]=f)}return this._rawCount=this._count=s,{start:a,end:s}},t.prototype._initDataFromProvider=function(t,e,n){for(var i=this._provider,r=this._chunks,o=this._dimensions,a=o.length,s=this._rawExtent,l=z(o,(function(t){return t.property})),u=0;uy[1]&&(y[1]=g)}}!i.persistent&&i.clean&&i.clean(),this._rawCount=this._count=e,this._extent=[]},t.prototype.count=function(){return this._count},t.prototype.get=function(t,e){if(!(e>=0&&e=0&&e=this._rawCount||t<0)return-1;if(!this._indices)return t;var e=this._indices,n=e[t];if(null!=n&&nt))return o;r=o-1}}return-1},t.prototype.indicesOfNearest=function(t,e,n){var i=this._chunks[t],r=[];if(!i)return r;null==n&&(n=1/0);for(var o=1/0,a=-1,s=0,l=0,u=this.count();l=0&&a<0)&&(o=c,a=h,s=0),h===a&&(r[s++]=l))}return r.length=s,r},t.prototype.getIndices=function(){var t,e=this._indices;if(e){var n=e.constructor,i=this._count;if(n===Array){t=new n(i);for(var r=0;r=u&&x<=h||isNaN(x))&&(a[s++]=d),d++}p=!0}else if(2===r){f=c[i[0]];var y=c[i[1]],v=t[i[1]][0],m=t[i[1]][1];for(g=0;g=u&&x<=h||isNaN(x))&&(_>=v&&_<=m||isNaN(_))&&(a[s++]=d),d++}p=!0}}if(!p)if(1===r)for(g=0;g=u&&x<=h||isNaN(x))&&(a[s++]=b)}else for(g=0;gt[M][1])&&(w=!1)}w&&(a[s++]=e.getRawIndex(g))}return sy[1]&&(y[1]=g)}}}},t.prototype.lttbDownSample=function(t,e){var n,i,r,o=this.clone([t],!0),a=o._chunks[t],s=this.count(),l=0,u=Math.floor(1/e),h=this.getRawIndex(0),c=new(Xf(this._rawCount))(Math.min(2*(Math.ceil(s/u)+2),s));c[l++]=h;for(var p=1;pn&&(n=i,r=I)}M>0&&M<_-x&&(c[l++]=Math.min(S,r),r=Math.max(S,r)),c[l++]=r,h=r}return c[l++]=this.getRawIndex(s-1),o._count=l,o._indices=c,o.getRawIndex=this._getRawIdx,o},t.prototype.downSample=function(t,e,n,i){for(var r=this.clone([t],!0),o=r._chunks,a=[],s=Math.floor(1/e),l=o[t],u=this.count(),h=r._rawExtent[t]=[1/0,-1/0],c=new(Xf(this._rawCount))(Math.ceil(u/s)),p=0,d=0;du-d&&(s=u-d,a.length=s);for(var f=0;fh[1]&&(h[1]=y),c[p++]=v}return r._count=p,r._indices=c,r._updateGetRawIdx(),r},t.prototype.each=function(t,e){if(this._count)for(var n=t.length,i=this._chunks,r=0,o=this.count();ra&&(a=l)}return i=[o,a],this._extent[t]=i,i},t.prototype.getRawDataItem=function(t){var e=this.getRawIndex(t);if(this._provider.persistent)return this._provider.getItem(e);for(var n=[],i=this._chunks,r=0;r=0?this._indices[t]:-1},t.prototype._updateGetRawIdx=function(){this.getRawIndex=this._indices?this._getRawIdx:this._getRawIdxIdentity},t.internalField=function(){function t(t,e,n,i){return wf(t[i],this._dimensions[i])}Vf={arrayRows:t,objectRows:function(t,e,n,i){return wf(t[e],this._dimensions[i])},keyedColumns:t,original:function(t,e,n,i){var r=t&&(null==t.value?t:t.value);return wf(r instanceof Array?r[i]:r,this._dimensions[i])},typedArray:function(t,e,n,i){return t[i]}}}(),t}(),jf=function(){function t(t){this._sourceList=[],this._storeList=[],this._upstreamSignList=[],this._versionSignBase=0,this._dirty=!0,this._sourceHost=t}return t.prototype.dirty=function(){this._setLocalSource([],[]),this._storeList=[],this._dirty=!0},t.prototype._setLocalSource=function(t,e){this._sourceList=t,this._upstreamSignList=e,this._versionSignBase++,this._versionSignBase>9e10&&(this._versionSignBase=0)},t.prototype._getVersionSign=function(){return this._sourceHost.uid+"_"+this._versionSignBase},t.prototype.prepareSource=function(){this._isDirty()&&(this._createSource(),this._dirty=!1)},t.prototype._createSource=function(){this._setLocalSource([],[]);var t,e,n=this._sourceHost,i=this._getUpstreamSourceManagers(),r=!!i.length;if(Kf(n)){var o=n,a=void 0,s=void 0,l=void 0;if(r){var u=i[0];u.prepareSource(),a=(l=u.getSource()).data,s=l.sourceFormat,e=[u._getVersionSign()]}else s=$(a=o.get("data",!0))?Hp:Bp,e=[];var h=this._getSourceMetaRawOption()||{},c=l&&l.metaRawOption||{},p=rt(h.seriesLayoutBy,c.seriesLayoutBy)||null,d=rt(h.sourceHeader,c.sourceHeader),f=rt(h.dimensions,c.dimensions);t=p!==c.seriesLayoutBy||!!d!=!!c.sourceHeader||f?[$d(a,{seriesLayoutBy:p,sourceHeader:d,dimensions:f},s)]:[]}else{var g=n;if(r){var y=this._applyTransform(i);t=y.sourceList,e=y.upstreamSignList}else{t=[$d(g.get("source",!0),this._getSourceMetaRawOption(),null)],e=[]}}this._setLocalSource(t,e)},t.prototype._applyTransform=function(t){var e,n=this._sourceHost,i=n.get("transform",!0),r=n.get("fromTransformResult",!0);if(null!=r){var o="";1!==t.length&&$f(o)}var a,s=[],l=[];return E(t,(function(t){t.prepareSource();var e=t.getSource(r||0),n="";null==r||e||$f(n),s.push(e),l.push(t._getVersionSign())})),i?e=function(t,e,n){var i=bo(t),r=i.length,o="";r||vo(o);for(var a=0,s=r;a1||n>0&&!t.noHeader;return E(t.blocks,(function(t){var n=og(t);n>=e&&(e=n+ +(i&&(!n||ig(t)&&!t.noHeader)))})),e}return 0}function ag(t,e,n,i){var r,o=e.noHeader,a=(r=og(e),{html:tg[r],richText:eg[r]}),s=[],l=e.blocks||[];lt(!l||Y(l)),l=l||[];var u=t.orderMode;if(e.sortBlocks&&u){l=l.slice();var h={valueAsc:"asc",valueDesc:"desc"};if(_t(h,u)){var c=new Cf(h[u],null);l.sort((function(t,e){return c.evaluate(t.sortParam,e.sortParam)}))}else"seriesDesc"===u&&l.reverse()}E(l,(function(n,r){var o=e.valueFormatter,l=rg(n)(o?A(A({},t),{valueFormatter:o}):t,n,r>0?a.html:0,i);null!=l&&s.push(l)}));var p="richText"===t.renderMode?s.join(a.richText):ug(s.join(""),o?n:a.html);if(o)return p;var d=gp(e.header,"ordinal",t.useUTC),f=Qf(i,t.renderMode).nameStyle;return"richText"===t.renderMode?hg(t,d,f)+a.richText+p:ug('
'+re(d)+"
"+p,n)}function sg(t,e,n,i){var r=t.renderMode,o=e.noName,a=e.noValue,s=!e.markerType,l=e.name,u=t.useUTC,h=e.valueFormatter||t.valueFormatter||function(t){return z(t=Y(t)?t:[t],(function(t,e){return gp(t,Y(d)?d[e]:d,u)}))};if(!o||!a){var c=s?"":t.markupStyleCreator.makeTooltipMarker(e.markerType,e.markerColor||"#333",r),p=o?"":gp(l,"ordinal",u),d=e.valueType,f=a?[]:h(e.value),g=!s||!o,y=!s&&o,v=Qf(i,r),m=v.nameStyle,x=v.valueStyle;return"richText"===r?(s?"":c)+(o?"":hg(t,p,m))+(a?"":function(t,e,n,i,r){var o=[r],a=i?10:20;return n&&o.push({padding:[0,0,0,a],align:"right"}),t.markupStyleCreator.wrapRichTextStyle(Y(e)?e.join(" "):e,o)}(t,f,g,y,x)):ug((s?"":c)+(o?"":function(t,e,n){return''+re(t)+""}(p,!s,m))+(a?"":function(t,e,n,i){var r=n?"10px":"20px",o=e?"float:right;margin-left:"+r:"";return t=Y(t)?t:[t],''+z(t,(function(t){return re(t)})).join("  ")+""}(f,g,y,x)),n)}}function lg(t,e,n,i,r,o){if(t)return rg(t)({useUTC:r,renderMode:n,orderMode:i,markupStyleCreator:e,valueFormatter:t.valueFormatter},t,0,o)}function ug(t,e){return'
'+t+'
'}function hg(t,e,n){return t.markupStyleCreator.wrapRichTextStyle(e,n)}function cg(t,e){return _p(t.getData().getItemVisual(e,"style")[t.visualDrawType])}function pg(t,e){var n=t.get("padding");return null!=n?n:"richText"===e?[8,10]:10}var dg=function(){function t(){this.richTextStyles={},this._nextStyleNameId=po()}return t.prototype._generateStyleName=function(){return"__EC_aUTo_"+this._nextStyleNameId++},t.prototype.makeTooltipMarker=function(t,e,n){var i="richText"===n?this._generateStyleName():null,r=xp({color:e,type:t,renderMode:n,markerId:i});return U(r)?r:(this.richTextStyles[i]=r.style,r.content)},t.prototype.wrapRichTextStyle=function(t,e){var n={};Y(e)?E(e,(function(t){return A(n,t)})):A(n,e);var i=this._generateStyleName();return this.richTextStyles[i]=n,"{"+i+"|"+t+"}"},t}();function fg(t){var e,n,i,r,o=t.series,a=t.dataIndex,s=t.multipleSeries,l=o.getData(),u=l.mapDimensionsAll("defaultedTooltip"),h=u.length,c=o.getRawValue(a),p=Y(c),d=cg(o,a);if(h>1||p&&!h){var f=function(t,e,n,i,r){var o=e.getData(),a=V(t,(function(t,e,n){var i=o.getDimensionInfo(n);return t||i&&!1!==i.tooltip&&null!=i.displayName}),!1),s=[],l=[],u=[];function h(t,e){var n=o.getDimensionInfo(e);n&&!1!==n.otherDims.tooltip&&(a?u.push(ng("nameValue",{markerType:"subItem",markerColor:r,name:n.displayName,value:t,valueType:n.type})):(s.push(t),l.push(n.type)))}return i.length?E(i,(function(t){h(gf(o,n,t),t)})):E(t,h),{inlineValues:s,inlineValueTypes:l,blocks:u}}(c,o,a,u,d);e=f.inlineValues,n=f.inlineValueTypes,i=f.blocks,r=f.inlineValues[0]}else if(h){var g=l.getDimensionInfo(u[0]);r=e=gf(l,a,u[0]),n=g.type}else r=e=p?c[0]:c;var y=ko(o),v=y&&o.name||"",m=l.getName(a),x=s?v:m;return ng("section",{header:v,noHeader:s||!y,sortParam:r,blocks:[ng("nameValue",{markerType:"item",markerColor:d,name:x,noName:!ut(x),value:e,valueType:n})].concat(i||[])})}var gg=Oo();function yg(t,e){return t.getName(e)||t.getId(e)}var vg="__universalTransitionEnabled",mg=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e._selectedDataIndicesMap={},e}return n(e,t),e.prototype.init=function(t,e,n){this.seriesIndex=this.componentIndex,this.dataTask=xf({count:_g,reset:bg}),this.dataTask.context={model:this},this.mergeDefaultAndTheme(t,n),(gg(this).sourceManager=new jf(this)).prepareSource();var i=this.getInitialData(t,n);Sg(i,this),this.dataTask.context.data=i,gg(this).dataBeforeProcessed=i,xg(this),this._initSelectedMapFromData(i)},e.prototype.mergeDefaultAndTheme=function(t,e){var n=Ap(this),i=n?Lp(t):{},r=this.subType;Rp.hasClass(r)&&(r+="Series"),C(t,e.getTheme().get(this.subType)),C(t,this.getDefaultOption()),wo(t,"label",["show"]),this.fillDataTextStyle(t.data),n&&kp(t,i,n)},e.prototype.mergeOption=function(t,e){t=C(this.option,t,!0),this.fillDataTextStyle(t.data);var n=Ap(this);n&&kp(this.option,t,n);var i=gg(this).sourceManager;i.dirty(),i.prepareSource();var r=this.getInitialData(t,e);Sg(r,this),this.dataTask.dirty(),this.dataTask.context.data=r,gg(this).dataBeforeProcessed=r,xg(this),this._initSelectedMapFromData(r)},e.prototype.fillDataTextStyle=function(t){if(t&&!$(t))for(var e=["show"],n=0;nthis.getShallow("animationThreshold")&&(e=!1),!!e},e.prototype.restoreData=function(){this.dataTask.dirty()},e.prototype.getColorFromPalette=function(t,e,n){var i=this.ecModel,r=ld.prototype.getColorFromPalette.call(this,t,e,n);return r||(r=i.getColorFromPalette(t,e,n)),r},e.prototype.coordDimToDataDim=function(t){return this.getRawData().mapDimensionsAll(t)},e.prototype.getProgressive=function(){return this.get("progressive")},e.prototype.getProgressiveThreshold=function(){return this.get("progressiveThreshold")},e.prototype.select=function(t,e){this._innerSelect(this.getData(e),t)},e.prototype.unselect=function(t,e){var n=this.option.selectedMap;if(n){var i=this.option.selectedMode,r=this.getData(e);if("series"===i||"all"===n)return this.option.selectedMap={},void(this._selectedDataIndicesMap={});for(var o=0;o=0&&n.push(r)}return n},e.prototype.isSelected=function(t,e){var n=this.option.selectedMap;if(!n)return!1;var i=this.getData(e);return("all"===n||n[yg(i,t)])&&!i.getItemModel(t).get(["select","disabled"])},e.prototype.isUniversalTransitionEnabled=function(){if(this[vg])return!0;var t=this.option.universalTransition;return!!t&&(!0===t||t&&t.enabled)},e.prototype._innerSelect=function(t,e){var n,i,r=this.option,o=r.selectedMode,a=e.length;if(o&&a)if("series"===o)r.selectedMap="all";else if("multiple"===o){q(r.selectedMap)||(r.selectedMap={});for(var s=r.selectedMap,l=0;l0&&this._innerSelect(t,e)}},e.registerClass=function(t){return Rp.registerClass(t)},e.protoInitialize=function(){var t=e.prototype;t.type="series.__base__",t.seriesIndex=0,t.ignoreStyleOnData=!1,t.hasSymbolVisual=!1,t.defaultSymbol="circle",t.visualStyleAccessPath="itemStyle",t.visualDrawType="fill"}(),e}(Rp);function xg(t){var e=t.name;ko(t)||(t.name=function(t){var e=t.getRawData(),n=e.mapDimensionsAll("seriesName"),i=[];return E(n,(function(t){var n=e.getDimensionInfo(t);n.displayName&&i.push(n.displayName)})),i.join(" ")}(t)||e)}function _g(t){return t.model.getRawData().count()}function bg(t){var e=t.model;return e.setData(e.getRawData().cloneShallow()),wg}function wg(t,e){e.outputData&&t.end>e.outputData.count()&&e.model.getRawData().cloneShallow(e.outputData)}function Sg(t,e){E(vt(t.CHANGABLE_METHODS,t.DOWNSAMPLE_METHODS),(function(n){t.wrapMethod(n,H(Mg,e))}))}function Mg(t,e){var n=Ig(t);return n&&n.setOutputEnd((e||this).count()),e}function Ig(t){var e=(t.ecModel||{}).scheduler,n=e&&e.getPipeline(t.uid);if(n){var i=n.currentTask;if(i){var r=i.agentStubMap;r&&(i=r.get(t.uid))}return i}}R(mg,vf),R(mg,ld),Zo(mg,Rp);var Tg=function(){function t(){this.group=new zr,this.uid=Tc("viewComponent")}return t.prototype.init=function(t,e){},t.prototype.render=function(t,e,n,i){},t.prototype.dispose=function(t,e){},t.prototype.updateView=function(t,e,n,i){},t.prototype.updateLayout=function(t,e,n,i){},t.prototype.updateVisual=function(t,e,n,i){},t.prototype.toggleBlurSeries=function(t,e,n){},t.prototype.eachRendered=function(t){var e=this.group;e&&e.traverse(t)},t}();function Cg(){var t=Oo();return function(e){var n=t(e),i=e.pipelineContext,r=!!n.large,o=!!n.progressiveRender,a=n.large=!(!i||!i.large),s=n.progressiveRender=!(!i||!i.progressiveRender);return!(r===a&&o===s)&&"reset"}}Uo(Tg),$o(Tg);var Dg=Oo(),Ag=Cg(),kg=function(){function t(){this.group=new zr,this.uid=Tc("viewChart"),this.renderTask=xf({plan:Og,reset:Rg}),this.renderTask.context={view:this}}return t.prototype.init=function(t,e){},t.prototype.render=function(t,e,n,i){0},t.prototype.highlight=function(t,e,n,i){var r=t.getData(i&&i.dataType);r&&Pg(r,i,"emphasis")},t.prototype.downplay=function(t,e,n,i){var r=t.getData(i&&i.dataType);r&&Pg(r,i,"normal")},t.prototype.remove=function(t,e){this.group.removeAll()},t.prototype.dispose=function(t,e){},t.prototype.updateView=function(t,e,n,i){this.render(t,e,n,i)},t.prototype.updateLayout=function(t,e,n,i){this.render(t,e,n,i)},t.prototype.updateVisual=function(t,e,n,i){this.render(t,e,n,i)},t.prototype.eachRendered=function(t){qh(this.group,t)},t.markUpdateMethod=function(t,e){Dg(t).updateMethod=e},t.protoInitialize=void(t.prototype.type="chart"),t}();function Lg(t,e,n){t&&Kl(t)&&("emphasis"===e?kl:Ll)(t,n)}function Pg(t,e,n){var i=Po(t,e),r=e&&null!=e.highlightKey?function(t){var e=nl[t];return null==e&&el<=32&&(e=nl[t]=el++),e}(e.highlightKey):null;null!=i?E(bo(i),(function(e){Lg(t.getItemGraphicEl(e),n,r)})):t.eachItemGraphicEl((function(t){Lg(t,n,r)}))}function Og(t){return Ag(t.model)}function Rg(t){var e=t.model,n=t.ecModel,i=t.api,r=t.payload,o=e.pipelineContext.progressiveRender,a=t.view,s=r&&Dg(r).updateMethod,l=o?"incrementalPrepareRender":s&&a[s]?s:"render";return"render"!==l&&a[l](e,n,i,r),Ng[l]}Uo(kg),$o(kg);var Ng={incrementalPrepareRender:{progress:function(t,e){e.view.incrementalRender(t,e.model,e.ecModel,e.api,e.payload)}},render:{forceFirstProgress:!0,progress:function(t,e){e.view.render(e.model,e.ecModel,e.api,e.payload)}}},Eg="\0__throttleOriginMethod",zg="\0__throttleRate",Vg="\0__throttleType";function Bg(t,e,n){var i,r,o,a,s,l=0,u=0,h=null;function c(){u=(new Date).getTime(),h=null,t.apply(o,a||[])}e=e||0;var p=function(){for(var t=[],p=0;p=0?c():h=setTimeout(c,-r),l=i};return p.clear=function(){h&&(clearTimeout(h),h=null)},p.debounceNextCall=function(t){s=t},p}function Fg(t,e,n,i){var r=t[e];if(r){var o=r[Eg]||r,a=r[Vg];if(r[zg]!==n||a!==i){if(null==n||!i)return t[e]=o;(r=t[e]=Bg(o,n,"debounce"===i))[Eg]=o,r[Vg]=i,r[zg]=n}return r}}function Gg(t,e){var n=t[e];n&&n[Eg]&&(n.clear&&n.clear(),t[e]=n[Eg])}var Wg=Oo(),Hg={itemStyle:Jo(bc,!0),lineStyle:Jo(mc,!0)},Yg={lineStyle:"stroke",itemStyle:"fill"};function Xg(t,e){var n=t.visualStyleMapper||Hg[e];return n||(console.warn("Unknown style type '"+e+"'."),Hg.itemStyle)}function Ug(t,e){var n=t.visualDrawType||Yg[e];return n||(console.warn("Unknown style type '"+e+"'."),"fill")}var Zg={createOnAllSeries:!0,performRawSeries:!0,reset:function(t,e){var n=t.getData(),i=t.visualStyleAccessPath||"itemStyle",r=t.getModel(i),o=Xg(t,i)(r),a=r.getShallow("decal");a&&(n.setVisual("decal",a),a.dirty=!0);var s=Ug(t,i),l=o[s],u=X(l)?l:null,h="auto"===o.fill||"auto"===o.stroke;if(!o[s]||u||h){var c=t.getColorFromPalette(t.name,null,e.getSeriesCount());o[s]||(o[s]=c,n.setVisual("colorFromPalette",!0)),o.fill="auto"===o.fill||X(o.fill)?c:o.fill,o.stroke="auto"===o.stroke||X(o.stroke)?c:o.stroke}if(n.setVisual("style",o),n.setVisual("drawType",s),!e.isSeriesFiltered(t)&&u)return n.setVisual("colorFromPalette",!1),{dataEach:function(e,n){var i=t.getDataParams(n),r=A({},o);r[s]=u(i),e.setItemVisual(n,"style",r)}}}},jg=new Mc,qg={createOnAllSeries:!0,performRawSeries:!0,reset:function(t,e){if(!t.ignoreStyleOnData&&!e.isSeriesFiltered(t)){var n=t.getData(),i=t.visualStyleAccessPath||"itemStyle",r=Xg(t,i),o=n.getVisual("drawType");return{dataEach:n.hasItemOption?function(t,e){var n=t.getRawDataItem(e);if(n&&n[i]){jg.option=n[i];var a=r(jg);A(t.ensureUniqueItemVisual(e,"style"),a),jg.option.decal&&(t.setItemVisual(e,"decal",jg.option.decal),jg.option.decal.dirty=!0),o in a&&t.setItemVisual(e,"colorFromPalette",!1)}}:null}}}},Kg={performRawSeries:!0,overallReset:function(t){var e=yt();t.eachSeries((function(t){var n=t.getColorBy();if(!t.isColorBySeries()){var i=t.type+"-"+n,r=e.get(i);r||(r={},e.set(i,r)),Wg(t).scope=r}})),t.eachSeries((function(e){if(!e.isColorBySeries()&&!t.isSeriesFiltered(e)){var n=e.getRawData(),i={},r=e.getData(),o=Wg(e).scope,a=e.visualStyleAccessPath||"itemStyle",s=Ug(e,a);r.each((function(t){var e=r.getRawIndex(t);i[e]=t})),n.each((function(t){var a=i[t];if(r.getItemVisual(a,"colorFromPalette")){var l=r.ensureUniqueItemVisual(a,"style"),u=n.getName(t)||t+"",h=n.count();l[s]=e.getColorFromPalette(u,o,h)}}))}}))}},$g=Math.PI;var Jg=function(){function t(t,e,n,i){this._stageTaskMap=yt(),this.ecInstance=t,this.api=e,n=this._dataProcessorHandlers=n.slice(),i=this._visualHandlers=i.slice(),this._allHandlers=n.concat(i)}return t.prototype.restoreData=function(t,e){t.restoreData(e),this._stageTaskMap.each((function(t){var e=t.overallTask;e&&e.dirty()}))},t.prototype.getPerformArgs=function(t,e){if(t.__pipeline){var n=this._pipelineMap.get(t.__pipeline.id),i=n.context,r=!e&&n.progressiveEnabled&&(!i||i.progressiveRender)&&t.__idxInPipeline>n.blockIndex?n.step:null,o=i&&i.modDataCount;return{step:r,modBy:null!=o?Math.ceil(o/r):null,modDataCount:o}}},t.prototype.getPipeline=function(t){return this._pipelineMap.get(t)},t.prototype.updateStreamModes=function(t,e){var n=this._pipelineMap.get(t.uid),i=t.getData().count(),r=n.progressiveEnabled&&e.incrementalPrepareRender&&i>=n.threshold,o=t.get("large")&&i>=t.get("largeThreshold"),a="mod"===t.get("progressiveChunkMode")?i:null;t.pipelineContext=n.context={progressiveRender:r,modDataCount:a,large:o}},t.prototype.restorePipelines=function(t){var e=this,n=e._pipelineMap=yt();t.eachSeries((function(t){var i=t.getProgressive(),r=t.uid;n.set(r,{id:r,head:null,tail:null,threshold:t.getProgressiveThreshold(),progressiveEnabled:i&&!(t.preventIncremental&&t.preventIncremental()),blockIndex:-1,step:Math.round(i||700),count:0}),e._pipe(t,t.dataTask)}))},t.prototype.prepareStageTasks=function(){var t=this._stageTaskMap,e=this.api.getModel(),n=this.api;E(this._allHandlers,(function(i){var r=t.get(i.uid)||t.set(i.uid,{}),o="";lt(!(i.reset&&i.overallReset),o),i.reset&&this._createSeriesStageTask(i,r,e,n),i.overallReset&&this._createOverallStageTask(i,r,e,n)}),this)},t.prototype.prepareView=function(t,e,n,i){var r=t.renderTask,o=r.context;o.model=e,o.ecModel=n,o.api=i,r.__block=!t.incrementalPrepareRender,this._pipe(e,r)},t.prototype.performDataProcessorTasks=function(t,e){this._performStageTasks(this._dataProcessorHandlers,t,e,{block:!0})},t.prototype.performVisualTasks=function(t,e,n){this._performStageTasks(this._visualHandlers,t,e,n)},t.prototype._performStageTasks=function(t,e,n,i){i=i||{};var r=!1,o=this;function a(t,e){return t.setDirty&&(!t.dirtyMap||t.dirtyMap.get(e.__pipeline.id))}E(t,(function(t,s){if(!i.visualType||i.visualType===t.visualType){var l=o._stageTaskMap.get(t.uid),u=l.seriesTaskMap,h=l.overallTask;if(h){var c,p=h.agentStubMap;p.each((function(t){a(i,t)&&(t.dirty(),c=!0)})),c&&h.dirty(),o.updatePayload(h,n);var d=o.getPerformArgs(h,i.block);p.each((function(t){t.perform(d)})),h.perform(d)&&(r=!0)}else u&&u.each((function(s,l){a(i,s)&&s.dirty();var u=o.getPerformArgs(s,i.block);u.skip=!t.performRawSeries&&e.isSeriesFiltered(s.context.model),o.updatePayload(s,n),s.perform(u)&&(r=!0)}))}})),this.unfinished=r||this.unfinished},t.prototype.performSeriesTasks=function(t){var e;t.eachSeries((function(t){e=t.dataTask.perform()||e})),this.unfinished=e||this.unfinished},t.prototype.plan=function(){this._pipelineMap.each((function(t){var e=t.tail;do{if(e.__block){t.blockIndex=e.__idxInPipeline;break}e=e.getUpstream()}while(e)}))},t.prototype.updatePayload=function(t,e){"remain"!==e&&(t.context.payload=e)},t.prototype._createSeriesStageTask=function(t,e,n,i){var r=this,o=e.seriesTaskMap,a=e.seriesTaskMap=yt(),s=t.seriesType,l=t.getTargetSeries;function u(e){var s=e.uid,l=a.set(s,o&&o.get(s)||xf({plan:iy,reset:ry,count:sy}));l.context={model:e,ecModel:n,api:i,useClearVisual:t.isVisual&&!t.isLayout,plan:t.plan,reset:t.reset,scheduler:r},r._pipe(e,l)}t.createOnAllSeries?n.eachRawSeries(u):s?n.eachRawSeriesByType(s,u):l&&l(n,i).each(u)},t.prototype._createOverallStageTask=function(t,e,n,i){var r=this,o=e.overallTask=e.overallTask||xf({reset:Qg});o.context={ecModel:n,api:i,overallReset:t.overallReset,scheduler:r};var a=o.agentStubMap,s=o.agentStubMap=yt(),l=t.seriesType,u=t.getTargetSeries,h=!0,c=!1,p="";function d(t){var e=t.uid,n=s.set(e,a&&a.get(e)||(c=!0,xf({reset:ty,onDirty:ny})));n.context={model:t,overallProgress:h},n.agent=o,n.__block=h,r._pipe(t,n)}lt(!t.createOnAllSeries,p),l?n.eachRawSeriesByType(l,d):u?u(n,i).each(d):(h=!1,E(n.getSeries(),d)),c&&o.dirty()},t.prototype._pipe=function(t,e){var n=t.uid,i=this._pipelineMap.get(n);!i.head&&(i.head=e),i.tail&&i.tail.pipe(e),i.tail=e,e.__idxInPipeline=i.count++,e.__pipeline=i},t.wrapStageHandler=function(t,e){return X(t)&&(t={overallReset:t,seriesType:ly(t)}),t.uid=Tc("stageHandler"),e&&(t.visualType=e),t},t}();function Qg(t){t.overallReset(t.ecModel,t.api,t.payload)}function ty(t){return t.overallProgress&&ey}function ey(){this.agent.dirty(),this.getDownstream().dirty()}function ny(){this.agent&&this.agent.dirty()}function iy(t){return t.plan?t.plan(t.model,t.ecModel,t.api,t.payload):null}function ry(t){t.useClearVisual&&t.data.clearAllVisual();var e=t.resetDefines=bo(t.reset(t.model,t.ecModel,t.api,t.payload));return e.length>1?z(e,(function(t,e){return ay(e)})):oy}var oy=ay(0);function ay(t){return function(e,n){var i=n.data,r=n.resetDefines[t];if(r&&r.dataEach)for(var o=e.start;o0&&h===r.length-u.length){var c=r.slice(0,h);"data"!==c&&(e.mainType=c,e[u.toLowerCase()]=t,s=!0)}}a.hasOwnProperty(r)&&(n[r]=t,s=!0),s||(i[r]=t)}))}return{cptQuery:e,dataQuery:n,otherQuery:i}},t.prototype.filter=function(t,e){var n=this.eventInfo;if(!n)return!0;var i=n.targetEl,r=n.packedEvent,o=n.model,a=n.view;if(!o||!a)return!0;var s=e.cptQuery,l=e.dataQuery;return u(s,o,"mainType")&&u(s,o,"subType")&&u(s,o,"index","componentIndex")&&u(s,o,"name")&&u(s,o,"id")&&u(l,r,"name")&&u(l,r,"dataIndex")&&u(l,r,"dataType")&&(!a.filterForExposedEvent||a.filterForExposedEvent(t,e.otherQuery,i,r));function u(t,e,n,i){return null==t[n]||e[i||n]===t[n]}},t.prototype.afterTrigger=function(){this.eventInfo=null},t}(),by=["symbol","symbolSize","symbolRotate","symbolOffset"],wy=by.concat(["symbolKeepAspect"]),Sy={createOnAllSeries:!0,performRawSeries:!0,reset:function(t,e){var n=t.getData();if(t.legendIcon&&n.setVisual("legendIcon",t.legendIcon),t.hasSymbolVisual){for(var i={},r={},o=!1,a=0;a=0&&Xy(l)?l:.5,t.createRadialGradient(a,s,0,a,s,l)}(t,e,n):function(t,e,n){var i=null==e.x?0:e.x,r=null==e.x2?1:e.x2,o=null==e.y?0:e.y,a=null==e.y2?0:e.y2;return e.global||(i=i*n.width+n.x,r=r*n.width+n.x,o=o*n.height+n.y,a=a*n.height+n.y),i=Xy(i)?i:0,r=Xy(r)?r:1,o=Xy(o)?o:0,a=Xy(a)?a:0,t.createLinearGradient(i,o,r,a)}(t,e,n),r=e.colorStops,o=0;o0&&(e=i.lineDash,n=i.lineWidth,e&&"solid"!==e&&n>0?"dashed"===e?[4*n,2*n]:"dotted"===e?[n]:j(e)?[e]:Y(e)?e:null:null),o=i.lineDashOffset;if(r){var a=i.strokeNoScale&&t.getLineScale?t.getLineScale():1;a&&1!==a&&(r=z(r,(function(t){return t/a})),o/=a)}return[r,o]}var Ky=new os(!0);function $y(t){var e=t.stroke;return!(null==e||"none"===e||!(t.lineWidth>0))}function Jy(t){return"string"==typeof t&&"none"!==t}function Qy(t){var e=t.fill;return null!=e&&"none"!==e}function tv(t,e){if(null!=e.fillOpacity&&1!==e.fillOpacity){var n=t.globalAlpha;t.globalAlpha=e.fillOpacity*e.opacity,t.fill(),t.globalAlpha=n}else t.fill()}function ev(t,e){if(null!=e.strokeOpacity&&1!==e.strokeOpacity){var n=t.globalAlpha;t.globalAlpha=e.strokeOpacity*e.opacity,t.stroke(),t.globalAlpha=n}else t.stroke()}function nv(t,e,n){var i=ia(e.image,e.__image,n);if(oa(i)){var r=t.createPattern(i,e.repeat||"repeat");if("function"==typeof DOMMatrix&&r&&r.setTransform){var o=new DOMMatrix;o.translateSelf(e.x||0,e.y||0),o.rotateSelf(0,0,(e.rotation||0)*wt),o.scaleSelf(e.scaleX||1,e.scaleY||1),r.setTransform(o)}return r}}var iv=["shadowBlur","shadowOffsetX","shadowOffsetY"],rv=[["lineCap","butt"],["lineJoin","miter"],["miterLimit",10]];function ov(t,e,n,i,r){var o=!1;if(!i&&e===(n=n||{}))return!1;if(i||e.opacity!==n.opacity){lv(t,r),o=!0;var a=Math.max(Math.min(e.opacity,1),0);t.globalAlpha=isNaN(a)?xa.opacity:a}(i||e.blend!==n.blend)&&(o||(lv(t,r),o=!0),t.globalCompositeOperation=e.blend||xa.blend);for(var s=0;s0&&t.unfinished);t.unfinished||this._zr.flush()}}},e.prototype.getDom=function(){return this._dom},e.prototype.getId=function(){return this.id},e.prototype.getZr=function(){return this._zr},e.prototype.isSSR=function(){return this._ssr},e.prototype.setOption=function(t,e,n){if(!this[Iv])if(this._disposed)nm(this.id);else{var i,r,o;if(q(e)&&(n=e.lazyUpdate,i=e.silent,r=e.replaceMerge,o=e.transition,e=e.notMerge),this[Iv]=!0,!this._model||e){var a=new bd(this._api),s=this._theme,l=this._model=new pd;l.scheduler=this._scheduler,l.ssr=this._ssr,l.init(null,null,null,s,this._locale,a)}this._model.setOption(t,{replaceMerge:r},am);var u={seriesTransition:o,optionChanged:!0};if(n)this[Tv]={silent:i,updateParams:u},this[Iv]=!1,this.getZr().wakeUp();else{try{Ov(this),Ev.update.call(this,null,u)}catch(t){throw this[Tv]=null,this[Iv]=!1,t}this._ssr||this._zr.flush(),this[Tv]=null,this[Iv]=!1,Fv.call(this,i),Gv.call(this,i)}}},e.prototype.setTheme=function(){yo()},e.prototype.getModel=function(){return this._model},e.prototype.getOption=function(){return this._model&&this._model.getOption()},e.prototype.getWidth=function(){return this._zr.getWidth()},e.prototype.getHeight=function(){return this._zr.getHeight()},e.prototype.getDevicePixelRatio=function(){return this._zr.painter.dpr||r.hasGlobalWindow&&window.devicePixelRatio||1},e.prototype.getRenderedCanvas=function(t){return this.renderToCanvas(t)},e.prototype.renderToCanvas=function(t){t=t||{};var e=this._zr.painter;return e.getRenderedCanvas({backgroundColor:t.backgroundColor||this._model.get("backgroundColor"),pixelRatio:t.pixelRatio||this.getDevicePixelRatio()})},e.prototype.renderToSVGString=function(t){t=t||{};var e=this._zr.painter;return e.renderToString({useViewBox:t.useViewBox})},e.prototype.getSvgDataURL=function(){if(r.svgSupported){var t=this._zr;return E(t.storage.getDisplayList(),(function(t){t.stopAnimation(null,!0)})),t.painter.toDataURL()}},e.prototype.getDataURL=function(t){if(!this._disposed){var e=(t=t||{}).excludeComponents,n=this._model,i=[],r=this;E(e,(function(t){n.eachComponent({mainType:t},(function(t){var e=r._componentsMap[t.__viewId];e.group.ignore||(i.push(e),e.group.ignore=!0)}))}));var o="svg"===this._zr.painter.getType()?this.getSvgDataURL():this.renderToCanvas(t).toDataURL("image/"+(t&&t.type||"png"));return E(i,(function(t){t.group.ignore=!1})),o}nm(this.id)},e.prototype.getConnectedDataURL=function(t){if(!this._disposed){var e="svg"===t.type,n=this.group,i=Math.min,r=Math.max,o=1/0;if(cm[n]){var a=o,s=o,l=-1/0,u=-1/0,c=[],p=t&&t.pixelRatio||this.getDevicePixelRatio();E(hm,(function(o,h){if(o.group===n){var p=e?o.getZr().painter.getSvgDom().innerHTML:o.renderToCanvas(T(t)),d=o.getDom().getBoundingClientRect();a=i(d.left,a),s=i(d.top,s),l=r(d.right,l),u=r(d.bottom,u),c.push({dom:p,left:d.left,top:d.top})}}));var d=(l*=p)-(a*=p),f=(u*=p)-(s*=p),g=h.createCanvas(),y=Gr(g,{renderer:e?"svg":"canvas"});if(y.resize({width:d,height:f}),e){var v="";return E(c,(function(t){var e=t.left-a,n=t.top-s;v+=''+t.dom+""})),y.painter.getSvgRoot().innerHTML=v,t.connectedBackgroundColor&&y.painter.setBackgroundColor(t.connectedBackgroundColor),y.refreshImmediately(),y.painter.toDataURL()}return t.connectedBackgroundColor&&y.add(new zs({shape:{x:0,y:0,width:d,height:f},style:{fill:t.connectedBackgroundColor}})),E(c,(function(t){var e=new ks({style:{x:t.left*p-a,y:t.top*p-s,image:t.dom}});y.add(e)})),y.refreshImmediately(),g.toDataURL("image/"+(t&&t.type||"png"))}return this.getDataURL(t)}nm(this.id)},e.prototype.convertToPixel=function(t,e){return zv(this,"convertToPixel",t,e)},e.prototype.convertFromPixel=function(t,e){return zv(this,"convertFromPixel",t,e)},e.prototype.containPixel=function(t,e){var n;if(!this._disposed)return E(No(this._model,t),(function(t,i){i.indexOf("Models")>=0&&E(t,(function(t){var r=t.coordinateSystem;if(r&&r.containPoint)n=n||!!r.containPoint(e);else if("seriesModels"===i){var o=this._chartsMap[t.__viewId];o&&o.containPoint&&(n=n||o.containPoint(e,t))}else 0}),this)}),this),!!n;nm(this.id)},e.prototype.getVisual=function(t,e){var n=No(this._model,t,{defaultMainType:"series"}),i=n.seriesModel;var r=i.getData(),o=n.hasOwnProperty("dataIndexInside")?n.dataIndexInside:n.hasOwnProperty("dataIndex")?r.indexOfRawIndex(n.dataIndex):null;return null!=o?Iy(r,o,e):Ty(r,e)},e.prototype.getViewOfComponentModel=function(t){return this._componentsMap[t.__viewId]},e.prototype.getViewOfSeriesModel=function(t){return this._chartsMap[t.__viewId]},e.prototype._initEvents=function(){var t,e,n,i=this;E(em,(function(t){var e=function(e){var n,r=i.getModel(),o=e.target,a="globalout"===t;if(a?n={}:o&&ky(o,(function(t){var e=Qs(t);if(e&&null!=e.dataIndex){var i=e.dataModel||r.getSeriesByIndex(e.seriesIndex);return n=i&&i.getDataParams(e.dataIndex,e.dataType,o)||{},!0}if(e.eventData)return n=A({},e.eventData),!0}),!0),n){var s=n.componentType,l=n.componentIndex;"markLine"!==s&&"markPoint"!==s&&"markArea"!==s||(s="series",l=n.seriesIndex);var u=s&&null!=l&&r.getComponent(s,l),h=u&&i["series"===u.mainType?"_chartsMap":"_componentsMap"][u.__viewId];0,n.event=e,n.type=t,i._$eventProcessor.eventInfo={targetEl:o,packedEvent:n,model:u,view:h},i.trigger(t,n)}};e.zrEventfulCallAtLast=!0,i._zr.on(t,e,i)})),E(rm,(function(t,e){i._messageCenter.on(e,(function(t){this.trigger(e,t)}),i)})),E(["selectchanged"],(function(t){i._messageCenter.on(t,(function(e){this.trigger(t,e)}),i)})),t=this._messageCenter,e=this,n=this._api,t.on("selectchanged",(function(t){var i=n.getModel();t.isFromClick?(Ay("map","selectchanged",e,i,t),Ay("pie","selectchanged",e,i,t)):"select"===t.fromAction?(Ay("map","selected",e,i,t),Ay("pie","selected",e,i,t)):"unselect"===t.fromAction&&(Ay("map","unselected",e,i,t),Ay("pie","unselected",e,i,t))}))},e.prototype.isDisposed=function(){return this._disposed},e.prototype.clear=function(){this._disposed?nm(this.id):this.setOption({series:[]},!0)},e.prototype.dispose=function(){if(this._disposed)nm(this.id);else{this._disposed=!0,this.getDom()&&Fo(this.getDom(),fm,"");var t=this,e=t._api,n=t._model;E(t._componentsViews,(function(t){t.dispose(n,e)})),E(t._chartsViews,(function(t){t.dispose(n,e)})),t._zr.dispose(),t._dom=t._model=t._chartsMap=t._componentsMap=t._chartsViews=t._componentsViews=t._scheduler=t._api=t._zr=t._throttledZrFlush=t._theme=t._coordSysMgr=t._messageCenter=null,delete hm[t.id]}},e.prototype.resize=function(t){if(!this[Iv])if(this._disposed)nm(this.id);else{this._zr.resize(t);var e=this._model;if(this._loadingFX&&this._loadingFX.resize(),e){var n=e.resetOption("media"),i=t&&t.silent;this[Tv]&&(null==i&&(i=this[Tv].silent),n=!0,this[Tv]=null),this[Iv]=!0;try{n&&Ov(this),Ev.update.call(this,{type:"resize",animation:A({duration:0},t&&t.animation)})}catch(t){throw this[Iv]=!1,t}this[Iv]=!1,Fv.call(this,i),Gv.call(this,i)}}},e.prototype.showLoading=function(t,e){if(this._disposed)nm(this.id);else if(q(t)&&(e=t,t=""),t=t||"default",this.hideLoading(),um[t]){var n=um[t](this._api,e),i=this._zr;this._loadingFX=n,i.add(n)}},e.prototype.hideLoading=function(){this._disposed?nm(this.id):(this._loadingFX&&this._zr.remove(this._loadingFX),this._loadingFX=null)},e.prototype.makeActionFromEvent=function(t){var e=A({},t);return e.type=rm[t.type],e},e.prototype.dispatchAction=function(t,e){if(this._disposed)nm(this.id);else if(q(e)||(e={silent:!!e}),im[t.type]&&this._model)if(this[Iv])this._pendingActions.push(t);else{var n=e.silent;Bv.call(this,t,n);var i=e.flush;i?this._zr.flush():!1!==i&&r.browser.weChat&&this._throttledZrFlush(),Fv.call(this,n),Gv.call(this,n)}},e.prototype.updateLabelLayout=function(){xv.trigger("series:layoutlabels",this._model,this._api,{updatedSeries:[]})},e.prototype.appendData=function(t){if(this._disposed)nm(this.id);else{var e=t.seriesIndex,n=this.getModel().getSeriesByIndex(e);0,n.appendData(t),this._scheduler.unfinished=!0,this.getZr().wakeUp()}},e.internalField=function(){function t(t){t.clearColorPalette(),t.eachSeries((function(t){t.clearColorPalette()}))}function e(t){for(var e=[],n=t.currentStates,i=0;i0?{duration:o,delay:i.get("delay"),easing:i.get("easing")}:null;n.eachRendered((function(t){if(t.states&&t.states.emphasis){if(yh(t))return;if(t instanceof Is&&function(t){var e=il(t);e.normalFill=t.style.fill,e.normalStroke=t.style.stroke;var n=t.states.select||{};e.selectFill=n.style&&n.style.fill||null,e.selectStroke=n.style&&n.style.stroke||null}(t),t.__dirty){var n=t.prevStates;n&&t.useStates(n)}if(r){t.stateTransition=a;var i=t.getTextContent(),o=t.getTextGuideLine();i&&(i.stateTransition=a),o&&(o.stateTransition=a)}t.__dirty&&e(t)}}))}Ov=function(t){var e=t._scheduler;e.restorePipelines(t._model),e.prepareStageTasks(),Rv(t,!0),Rv(t,!1),e.plan()},Rv=function(t,e){for(var n=t._model,i=t._scheduler,r=e?t._componentsViews:t._chartsViews,o=e?t._componentsMap:t._chartsMap,a=t._zr,s=t._api,l=0;le.get("hoverLayerThreshold")&&!r.node&&!r.worker&&e.eachSeries((function(e){if(!e.preventUsingHoverLayer){var n=t._chartsMap[e.__viewId];n.__alive&&n.eachRendered((function(t){t.states.emphasis&&(t.states.emphasis.hoverLayer=!0)}))}}))}(t,e),xv.trigger("series:afterupdate",e,n,l)},qv=function(t){t[Cv]=!0,t.getZr().wakeUp()},Kv=function(t){t[Cv]&&(t.getZr().storage.traverse((function(t){yh(t)||e(t)})),t[Cv]=!1)},Zv=function(t){return new(function(e){function i(){return null!==e&&e.apply(this,arguments)||this}return n(i,e),i.prototype.getCoordinateSystems=function(){return t._coordSysMgr.getCoordinateSystems()},i.prototype.getComponentByElement=function(e){for(;e;){var n=e.__ecComponentInfo;if(null!=n)return t._model.getComponent(n.mainType,n.index);e=e.parent}},i.prototype.enterEmphasis=function(e,n){kl(e,n),qv(t)},i.prototype.leaveEmphasis=function(e,n){Ll(e,n),qv(t)},i.prototype.enterBlur=function(e){Pl(e),qv(t)},i.prototype.leaveBlur=function(e){Ol(e),qv(t)},i.prototype.enterSelect=function(e){Rl(e),qv(t)},i.prototype.leaveSelect=function(e){Nl(e),qv(t)},i.prototype.getModel=function(){return t.getModel()},i.prototype.getViewOfComponentModel=function(e){return t.getViewOfComponentModel(e)},i.prototype.getViewOfSeriesModel=function(e){return t.getViewOfSeriesModel(e)},i}(vd))(t)},jv=function(t){function e(t,e){for(var n=0;n=0)){Dm.push(n);var o=Jg.wrapStageHandler(n,r);o.__prio=e,o.__raw=n,t.push(o)}}function km(t,e){um[t]=e}function Lm(t,e,n){var i=bv("registerMap");i&&i(t,e,n)}var Pm=function(t){var e=(t=T(t)).type,n="";e||vo(n);var i=e.split(":");2!==i.length&&vo(n);var r=!1;"echarts"===i[0]&&(e=i[1],r=!0),t.__isBuiltIn=r,Nf.set(e,t)};Cm(wv,Zg),Cm(Sv,qg),Cm(Sv,Kg),Cm(wv,Sy),Cm(Sv,My),Cm(7e3,(function(t,e){t.eachRawSeries((function(n){if(!t.isSeriesFiltered(n)){var i=n.getData();i.hasItemVisual()&&i.each((function(t){var n=i.getItemVisual(t,"decal");n&&(i.ensureUniqueItemVisual(t,"style").decal=gv(n,e))}));var r=i.getVisual("decal");if(r)i.getVisual("style").decal=gv(r,e)}}))})),xm(Wd),_m(900,(function(t){var e=yt();t.eachSeries((function(t){var n=t.get("stack");if(n){var i=e.get(n)||e.set(n,[]),r=t.getData(),o={stackResultDimension:r.getCalculationInfo("stackResultDimension"),stackedOverDimension:r.getCalculationInfo("stackedOverDimension"),stackedDimension:r.getCalculationInfo("stackedDimension"),stackedByDimension:r.getCalculationInfo("stackedByDimension"),isStackedByIndex:r.getCalculationInfo("isStackedByIndex"),data:r,seriesModel:t};if(!o.stackedDimension||!o.isStackedByIndex&&!o.stackedByDimension)return;i.length&&r.setCalculationInfo("stackedOnSeries",i[i.length-1].seriesModel),i.push(o)}})),e.each(Hd)})),km("default",(function(t,e){k(e=e||{},{text:"loading",textColor:"#000",fontSize:12,fontWeight:"normal",fontStyle:"normal",fontFamily:"sans-serif",maskColor:"rgba(255, 255, 255, 0.8)",showSpinner:!0,color:"#5470c6",spinnerRadius:10,lineWidth:5,zlevel:0});var n=new zr,i=new zs({style:{fill:e.maskColor},zlevel:e.zlevel,z:1e4});n.add(i);var r,o=new Fs({style:{text:e.text,fill:e.textColor,fontSize:e.fontSize,fontWeight:e.fontWeight,fontStyle:e.fontStyle,fontFamily:e.fontFamily},zlevel:e.zlevel,z:10001}),a=new zs({style:{fill:"none"},textContent:o,textConfig:{position:"right",distance:10},zlevel:e.zlevel,z:10001});return n.add(a),e.showSpinner&&((r=new Qu({shape:{startAngle:-$g/2,endAngle:-$g/2+.1,r:e.spinnerRadius},style:{stroke:e.color,lineCap:"round",lineWidth:e.lineWidth},zlevel:e.zlevel,z:10001})).animateShape(!0).when(1e3,{endAngle:3*$g/2}).start("circularInOut"),r.animateShape(!0).when(1e3,{startAngle:3*$g/2}).delay(300).start("circularInOut"),n.add(r)),n.resize=function(){var n=o.getBoundingRect().width,s=e.showSpinner?e.spinnerRadius:0,l=(t.getWidth()-2*s-(e.showSpinner&&n?10:0)-n)/2-(e.showSpinner&&n?0:5+n/2)+(e.showSpinner?0:n/2)+(n?0:s),u=t.getHeight()/2;e.showSpinner&&r.setShape({cx:l,cy:u}),a.setShape({x:l-s,y:u-s,width:2*s,height:2*s}),i.setShape({x:0,y:0,width:t.getWidth(),height:t.getHeight()})},n.resize(),n})),Mm({type:ll,event:ll,update:ll},bt),Mm({type:ul,event:ul,update:ul},bt),Mm({type:hl,event:hl,update:hl},bt),Mm({type:cl,event:cl,update:cl},bt),Mm({type:pl,event:pl,update:pl},bt),mm("light",fy),mm("dark",xy);var Om=[],Rm={registerPreprocessor:xm,registerProcessor:_m,registerPostInit:bm,registerPostUpdate:wm,registerUpdateLifecycle:Sm,registerAction:Mm,registerCoordinateSystem:Im,registerLayout:Tm,registerVisual:Cm,registerTransform:Pm,registerLoading:km,registerMap:Lm,registerImpl:function(t,e){_v[t]=e},PRIORITY:Mv,ComponentModel:Rp,ComponentView:Tg,SeriesModel:mg,ChartView:kg,registerComponentModel:function(t){Rp.registerClass(t)},registerComponentView:function(t){Tg.registerClass(t)},registerSeriesModel:function(t){mg.registerClass(t)},registerChartView:function(t){kg.registerClass(t)},registerSubTypeDefaulter:function(t,e){Rp.registerSubTypeDefaulter(t,e)},registerPainter:function(t,e){Wr(t,e)}};function Nm(t){Y(t)?E(t,(function(t){Nm(t)})):P(Om,t)>=0||(Om.push(t),X(t)&&(t={install:t}),t.install(Rm))}function Em(t){return null==t?0:t.length||1}function zm(t){return t}var Vm=function(){function t(t,e,n,i,r,o){this._old=t,this._new=e,this._oldKeyGetter=n||zm,this._newKeyGetter=i||zm,this.context=r,this._diffModeMultiple="multiple"===o}return t.prototype.add=function(t){return this._add=t,this},t.prototype.update=function(t){return this._update=t,this},t.prototype.updateManyToOne=function(t){return this._updateManyToOne=t,this},t.prototype.updateOneToMany=function(t){return this._updateOneToMany=t,this},t.prototype.updateManyToMany=function(t){return this._updateManyToMany=t,this},t.prototype.remove=function(t){return this._remove=t,this},t.prototype.execute=function(){this[this._diffModeMultiple?"_executeMultiple":"_executeOneToOne"]()},t.prototype._executeOneToOne=function(){var t=this._old,e=this._new,n={},i=new Array(t.length),r=new Array(e.length);this._initIndexMap(t,null,i,"_oldKeyGetter"),this._initIndexMap(e,n,r,"_newKeyGetter");for(var o=0;o1){var u=s.shift();1===s.length&&(n[a]=s[0]),this._update&&this._update(u,o)}else 1===l?(n[a]=null,this._update&&this._update(s,o)):this._remove&&this._remove(o)}this._performRestAdd(r,n)},t.prototype._executeMultiple=function(){var t=this._old,e=this._new,n={},i={},r=[],o=[];this._initIndexMap(t,n,r,"_oldKeyGetter"),this._initIndexMap(e,i,o,"_newKeyGetter");for(var a=0;a1&&1===c)this._updateManyToOne&&this._updateManyToOne(u,l),i[s]=null;else if(1===h&&c>1)this._updateOneToMany&&this._updateOneToMany(u,l),i[s]=null;else if(1===h&&1===c)this._update&&this._update(u,l),i[s]=null;else if(h>1&&c>1)this._updateManyToMany&&this._updateManyToMany(u,l),i[s]=null;else if(h>1)for(var p=0;p1)for(var a=0;a30}var Km,$m,Jm,Qm,tx,ex,nx,ix=q,rx=z,ox="undefined"==typeof Int32Array?Array:Int32Array,ax=["hasItemOption","_nameList","_idList","_invertedIndicesMap","_dimSummary","userOutput","_rawData","_dimValueGetter","_nameDimIdx","_idDimIdx","_nameRepeatCount"],sx=["_approximateExtent"],lx=function(){function t(t,e){var n;this.type="list",this._dimOmitted=!1,this._nameList=[],this._idList=[],this._visual={},this._layout={},this._itemVisuals=[],this._itemLayouts=[],this._graphicEls=[],this._approximateExtent={},this._calculationInfo={},this.hasItemOption=!1,this.TRANSFERABLE_METHODS=["cloneShallow","downSample","lttbDownSample","map"],this.CHANGABLE_METHODS=["filterSelf","selectRange"],this.DOWNSAMPLE_METHODS=["downSample","lttbDownSample"];var i=!1;Um(t)?(n=t.dimensions,this._dimOmitted=t.isDimensionOmitted(),this._schema=t):(i=!0,n=t),n=n||["x","y"];for(var r={},o=[],a={},s=!1,l={},u=0;u=e)){var n=this._store.getProvider();this._updateOrdinalMeta();var i=this._nameList,r=this._idList;if(n.getSource().sourceFormat===Bp&&!n.pure)for(var o=[],a=t;a0},t.prototype.ensureUniqueItemVisual=function(t,e){var n=this._itemVisuals,i=n[t];i||(i=n[t]={});var r=i[e];return null==r&&(Y(r=this.getVisual(e))?r=r.slice():ix(r)&&(r=A({},r)),i[e]=r),r},t.prototype.setItemVisual=function(t,e,n){var i=this._itemVisuals[t]||{};this._itemVisuals[t]=i,ix(e)?A(i,e):i[e]=n},t.prototype.clearAllVisual=function(){this._visual={},this._itemVisuals=[]},t.prototype.setLayout=function(t,e){ix(t)?A(this._layout,t):this._layout[t]=e},t.prototype.getLayout=function(t){return this._layout[t]},t.prototype.getItemLayout=function(t){return this._itemLayouts[t]},t.prototype.setItemLayout=function(t,e,n){this._itemLayouts[t]=n?A(this._itemLayouts[t]||{},e):e},t.prototype.clearItemLayouts=function(){this._itemLayouts.length=0},t.prototype.setItemGraphicEl=function(t,e){var n=this.hostModel&&this.hostModel.seriesIndex;tl(n,this.dataType,t,e),this._graphicEls[t]=e},t.prototype.getItemGraphicEl=function(t){return this._graphicEls[t]},t.prototype.eachItemGraphicEl=function(t,e){E(this._graphicEls,(function(n,i){n&&t&&t.call(e,n,i)}))},t.prototype.cloneShallow=function(e){return e||(e=new t(this._schema?this._schema:rx(this.dimensions,this._getDimInfo,this),this.hostModel)),tx(e,this),e._store=this._store,e},t.prototype.wrapMethod=function(t,e){var n=this[t];X(n)&&(this.__wrappedMethods=this.__wrappedMethods||[],this.__wrappedMethods.push(t),this[t]=function(){var t=n.apply(this,arguments);return e.apply(this,[t].concat(at(arguments)))})},t.internalField=(Km=function(t){var e=t._invertedIndicesMap;E(e,(function(n,i){var r=t._dimInfos[i],o=r.ordinalMeta,a=t._store;if(o){n=e[i]=new ox(o.categories.length);for(var s=0;s1&&(s+="__ec__"+u),i[e]=s}})),t}();function ux(t,e){Kd(t)||(t=Jd(t));var n=(e=e||{}).coordDimensions||[],i=e.dimensionsDefine||t.dimensionsDefine||[],r=yt(),o=[],a=function(t,e,n,i){var r=Math.max(t.dimensionsDetectedCount||1,e.length,n.length,i||0);return E(e,(function(t){var e;q(t)&&(e=t.dimsDef)&&(r=Math.max(r,e.length))})),r}(t,n,i,e.dimensionsCount),s=e.canOmitUnusedDimensions&&qm(a),l=i===t.dimensionsDefine,u=l?jm(t):Zm(i),h=e.encodeDefine;!h&&e.encodeDefaulter&&(h=e.encodeDefaulter(t,a));for(var c=yt(h),p=new Wf(a),d=0;d0&&(i.name=r+(o-1)),o++,e.set(r,o)}}(o),new Xm({source:t,dimensions:o,fullDimensionCount:a,dimensionOmitted:s})}function hx(t,e,n){if(n||e.hasKey(t)){for(var i=0;e.hasKey(t+i);)i++;t+=i}return e.set(t,!0),t}var cx=function(t){this.coordSysDims=[],this.axisMap=yt(),this.categoryAxisMap=yt(),this.coordSysName=t};var px={cartesian2d:function(t,e,n,i){var r=t.getReferringComponents("xAxis",zo).models[0],o=t.getReferringComponents("yAxis",zo).models[0];e.coordSysDims=["x","y"],n.set("x",r),n.set("y",o),dx(r)&&(i.set("x",r),e.firstCategoryDimIndex=0),dx(o)&&(i.set("y",o),null==e.firstCategoryDimIndex&&(e.firstCategoryDimIndex=1))},singleAxis:function(t,e,n,i){var r=t.getReferringComponents("singleAxis",zo).models[0];e.coordSysDims=["single"],n.set("single",r),dx(r)&&(i.set("single",r),e.firstCategoryDimIndex=0)},polar:function(t,e,n,i){var r=t.getReferringComponents("polar",zo).models[0],o=r.findAxisModel("radiusAxis"),a=r.findAxisModel("angleAxis");e.coordSysDims=["radius","angle"],n.set("radius",o),n.set("angle",a),dx(o)&&(i.set("radius",o),e.firstCategoryDimIndex=0),dx(a)&&(i.set("angle",a),null==e.firstCategoryDimIndex&&(e.firstCategoryDimIndex=1))},geo:function(t,e,n,i){e.coordSysDims=["lng","lat"]},parallel:function(t,e,n,i){var r=t.ecModel,o=r.getComponent("parallel",t.get("parallelIndex")),a=e.coordSysDims=o.dimensions.slice();E(o.parallelAxisIndex,(function(t,o){var s=r.getComponent("parallelAxis",t),l=a[o];n.set(l,s),dx(s)&&(i.set(l,s),null==e.firstCategoryDimIndex&&(e.firstCategoryDimIndex=o))}))}};function dx(t){return"category"===t.get("type")}function fx(t,e,n){var i,r,o,a=(n=n||{}).byIndex,s=n.stackedCoordDimension;!function(t){return!Um(t.schema)}(e)?(r=e.schema,i=r.dimensions,o=e.store):i=e;var l,u,h,c,p=!(!t||!t.get("stack"));if(E(i,(function(t,e){U(t)&&(i[e]=t={name:t}),p&&!t.isExtraCoord&&(a||l||!t.ordinalMeta||(l=t),u||"ordinal"===t.type||"time"===t.type||s&&s!==t.coordDim||(u=t))})),!u||a||l||(a=!0),u){h="__\0ecstackresult_"+t.id,c="__\0ecstackedover_"+t.id,l&&(l.createInvertedIndices=!0);var d=u.coordDim,f=u.type,g=0;E(i,(function(t){t.coordDim===d&&g++}));var y={name:h,coordDim:d,coordDimIndex:g,type:f,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:i.length},v={name:c,coordDim:c,coordDimIndex:g+1,type:f,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:i.length+1};r?(o&&(y.storeDimIndex=o.ensureCalculationDimension(c,f),v.storeDimIndex=o.ensureCalculationDimension(h,f)),r.appendCalculationDimension(y),r.appendCalculationDimension(v)):(i.push(y),i.push(v))}return{stackedDimension:u&&u.name,stackedByDimension:l&&l.name,isStackedByIndex:a,stackedOverDimension:c,stackResultDimension:h}}function gx(t,e){return!!e&&e===t.getCalculationInfo("stackedDimension")}function yx(t,e){return gx(t,e)?t.getCalculationInfo("stackResultDimension"):e}function vx(t,e,n){n=n||{};var i,r=e.getSourceManager(),o=!1;t?(o=!0,i=Jd(t)):o=(i=r.getSource()).sourceFormat===Bp;var a=function(t){var e=t.get("coordinateSystem"),n=new cx(e),i=px[e];if(i)return i(t,n,n.axisMap,n.categoryAxisMap),n}(e),s=function(t,e){var n,i=t.get("coordinateSystem"),r=xd.get(i);return e&&e.coordSysDims&&(n=z(e.coordSysDims,(function(t){var n={name:t},i=e.axisMap.get(t);if(i){var r=i.get("type");n.type=Gm(r)}return n}))),n||(n=r&&(r.getDimensionsInfo?r.getDimensionsInfo():r.dimensions.slice())||["x","y"]),n}(e,a),l=n.useEncodeDefaulter,u=X(l)?l:l?H($p,s,e):null,h=ux(i,{coordDimensions:s,generateCoord:n.generateCoord,encodeDefine:e.getEncode(),encodeDefaulter:u,canOmitUnusedDimensions:!o}),c=function(t,e,n){var i,r;return n&&E(t,(function(t,o){var a=t.coordDim,s=n.categoryAxisMap.get(a);s&&(null==i&&(i=o),t.ordinalMeta=s.getOrdinalMeta(),e&&(t.createInvertedIndices=!0)),null!=t.otherDims.itemName&&(r=!0)})),r||null==i||(t[i].otherDims.itemName=0),i}(h.dimensions,n.createInvertedIndices,a),p=o?null:r.getSharedDataStore(h),d=fx(e,{schema:h,store:p}),f=new lx(h,e);f.setCalculationInfo(d);var g=null!=c&&function(t){if(t.sourceFormat===Bp){var e=function(t){var e=0;for(;ee[1]&&(e[1]=t[1])},t.prototype.unionExtentFromData=function(t,e){this.unionExtent(t.getApproximateExtent(e))},t.prototype.getExtent=function(){return this._extent.slice()},t.prototype.setExtent=function(t,e){var n=this._extent;isNaN(t)||(n[0]=t),isNaN(e)||(n[1]=e)},t.prototype.isInExtentRange=function(t){return this._extent[0]<=t&&this._extent[1]>=t},t.prototype.isBlank=function(){return this._isBlank},t.prototype.setBlank=function(t){this._isBlank=t},t}();$o(mx);var xx=0,_x=function(){function t(t){this.categories=t.categories||[],this._needCollect=t.needCollect,this._deduplication=t.deduplication,this.uid=++xx}return t.createByAxisModel=function(e){var n=e.option,i=n.data,r=i&&z(i,bx);return new t({categories:r,needCollect:!r,deduplication:!1!==n.dedplication})},t.prototype.getOrdinal=function(t){return this._getOrCreateMap().get(t)},t.prototype.parseAndCollect=function(t){var e,n=this._needCollect;if(!U(t)&&!n)return t;if(n&&!this._deduplication)return e=this.categories.length,this.categories[e]=t,e;var i=this._getOrCreateMap();return null==(e=i.get(t))&&(n?(e=this.categories.length,this.categories[e]=t,i.set(t,e)):e=NaN),e},t.prototype._getOrCreateMap=function(){return this._map||(this._map=yt(this.categories))},t}();function bx(t){return q(t)&&null!=t.value?t.value:t+""}function Sx(t){return"interval"===t.type||"log"===t.type}function Mx(t,e,n,i){var r={},o=t[1]-t[0],a=r.interval=so(o/e,!0);null!=n&&ai&&(a=r.interval=i);var s=r.intervalPrecision=Tx(a);return function(t,e){!isFinite(t[0])&&(t[0]=e[0]),!isFinite(t[1])&&(t[1]=e[1]),Cx(t,0,e),Cx(t,1,e),t[0]>t[1]&&(t[0]=t[1])}(r.niceTickExtent=[Zr(Math.ceil(t[0]/a)*a,s),Zr(Math.floor(t[1]/a)*a,s)],t),r}function Ix(t){var e=Math.pow(10,ao(t)),n=t/e;return n?2===n?n=3:3===n?n=5:n*=2:n=1,Zr(n*e)}function Tx(t){return qr(t)+2}function Cx(t,e,n){t[e]=Math.max(Math.min(t[e],n[1]),n[0])}function Dx(t,e){return t>=e[0]&&t<=e[1]}function Ax(t,e){return e[1]===e[0]?.5:(t-e[0])/(e[1]-e[0])}function kx(t,e){return t*(e[1]-e[0])+e[0]}var Lx=function(t){function e(e){var n=t.call(this,e)||this;n.type="ordinal";var i=n.getSetting("ordinalMeta");return i||(i=new _x({})),Y(i)&&(i=new _x({categories:z(i,(function(t){return q(t)?t.value:t}))})),n._ordinalMeta=i,n._extent=n.getSetting("extent")||[0,i.categories.length-1],n}return n(e,t),e.prototype.parse=function(t){return null==t?NaN:U(t)?this._ordinalMeta.getOrdinal(t):Math.round(t)},e.prototype.contain=function(t){return Dx(t=this.parse(t),this._extent)&&null!=this._ordinalMeta.categories[t]},e.prototype.normalize=function(t){return Ax(t=this._getTickNumber(this.parse(t)),this._extent)},e.prototype.scale=function(t){return t=Math.round(kx(t,this._extent)),this.getRawOrdinalNumber(t)},e.prototype.getTicks=function(){for(var t=[],e=this._extent,n=e[0];n<=e[1];)t.push({value:n}),n++;return t},e.prototype.getMinorTicks=function(t){},e.prototype.setSortInfo=function(t){if(null!=t){for(var e=t.ordinalNumbers,n=this._ordinalNumbersByTick=[],i=this._ticksByOrdinalNumber=[],r=0,o=this._ordinalMeta.categories.length,a=Math.min(o,e.length);r=0&&t=0&&t=t},e.prototype.getOrdinalMeta=function(){return this._ordinalMeta},e.prototype.calcNiceTicks=function(){},e.prototype.calcNiceExtent=function(){},e.type="ordinal",e}(mx);mx.registerClass(Lx);var Px=Zr,Ox=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="interval",e._interval=0,e._intervalPrecision=2,e}return n(e,t),e.prototype.parse=function(t){return t},e.prototype.contain=function(t){return Dx(t,this._extent)},e.prototype.normalize=function(t){return Ax(t,this._extent)},e.prototype.scale=function(t){return kx(t,this._extent)},e.prototype.setExtent=function(t,e){var n=this._extent;isNaN(t)||(n[0]=parseFloat(t)),isNaN(e)||(n[1]=parseFloat(e))},e.prototype.unionExtent=function(t){var e=this._extent;t[0]e[1]&&(e[1]=t[1]),this.setExtent(e[0],e[1])},e.prototype.getInterval=function(){return this._interval},e.prototype.setInterval=function(t){this._interval=t,this._niceExtent=this._extent.slice(),this._intervalPrecision=Tx(t)},e.prototype.getTicks=function(t){var e=this._interval,n=this._extent,i=this._niceExtent,r=this._intervalPrecision,o=[];if(!e)return o;n[0]1e4)return[];var s=o.length?o[o.length-1].value:i[1];return n[1]>s&&(t?o.push({value:Px(s+e,r)}):o.push({value:n[1]})),o},e.prototype.getMinorTicks=function(t){for(var e=this.getTicks(!0),n=[],i=this.getExtent(),r=1;ri[0]&&h0&&(o=null===o?s:Math.min(o,s))}n[i]=o}}return n}(t),n=[];return E(t,(function(t){var i,r=t.coordinateSystem.getBaseAxis(),o=r.getExtent();if("category"===r.type)i=r.getBandWidth();else if("value"===r.type||"time"===r.type){var a=r.dim+"_"+r.index,s=e[a],l=Math.abs(o[1]-o[0]),u=r.scale.getExtent(),h=Math.abs(u[1]-u[0]);i=s?l/h*s:l}else{var c=t.getData();i=Math.abs(o[1]-o[0])/c.count()}var p=Ur(t.get("barWidth"),i),d=Ur(t.get("barMaxWidth"),i),f=Ur(t.get("barMinWidth")||(Ux(t)?.5:1),i),g=t.get("barGap"),y=t.get("barCategoryGap");n.push({bandWidth:i,barWidth:p,barMaxWidth:d,barMinWidth:f,barGap:g,barCategoryGap:y,axisKey:Bx(r),stackId:Vx(t)})})),Wx(n)}function Wx(t){var e={};E(t,(function(t,n){var i=t.axisKey,r=t.bandWidth,o=e[i]||{bandWidth:r,remainedWidth:r,autoWidthCount:0,categoryGap:null,gap:"20%",stacks:{}},a=o.stacks;e[i]=o;var s=t.stackId;a[s]||o.autoWidthCount++,a[s]=a[s]||{width:0,maxWidth:0};var l=t.barWidth;l&&!a[s].width&&(a[s].width=l,l=Math.min(o.remainedWidth,l),o.remainedWidth-=l);var u=t.barMaxWidth;u&&(a[s].maxWidth=u);var h=t.barMinWidth;h&&(a[s].minWidth=h);var c=t.barGap;null!=c&&(o.gap=c);var p=t.barCategoryGap;null!=p&&(o.categoryGap=p)}));var n={};return E(e,(function(t,e){n[e]={};var i=t.stacks,r=t.bandWidth,o=t.categoryGap;if(null==o){var a=G(i).length;o=Math.max(35-4*a,15)+"%"}var s=Ur(o,r),l=Ur(t.gap,1),u=t.remainedWidth,h=t.autoWidthCount,c=(u-s)/(h+(h-1)*l);c=Math.max(c,0),E(i,(function(t){var e=t.maxWidth,n=t.minWidth;if(t.width){i=t.width;e&&(i=Math.min(i,e)),n&&(i=Math.max(i,n)),t.width=i,u-=i+l*i,h--}else{var i=c;e&&ei&&(i=n),i!==c&&(t.width=i,u-=i+l*i,h--)}})),c=(u-s)/(h+(h-1)*l),c=Math.max(c,0);var p,d=0;E(i,(function(t,e){t.width||(t.width=c),p=t,d+=t.width*(1+l)})),p&&(d-=p.width*l);var f=-d/2;E(i,(function(t,i){n[e][i]=n[e][i]||{bandWidth:r,offset:f,width:t.width},f+=t.width*(1+l)}))})),n}function Hx(t,e){var n=Fx(t,e),i=Gx(n);E(n,(function(t){var e=t.getData(),n=t.coordinateSystem.getBaseAxis(),r=Vx(t),o=i[Bx(n)][r],a=o.offset,s=o.width;e.setLayout({bandWidth:o.bandWidth,offset:a,size:s})}))}function Yx(t){return{seriesType:t,plan:Cg(),reset:function(t){if(Xx(t)){var e=t.getData(),n=t.coordinateSystem,i=n.getBaseAxis(),r=n.getOtherAxis(i),o=e.getDimensionIndex(e.mapDimension(r.dim)),a=e.getDimensionIndex(e.mapDimension(i.dim)),s=t.get("showBackground",!0),l=e.mapDimension(r.dim),u=e.getCalculationInfo("stackResultDimension"),h=gx(e,l)&&!!e.getCalculationInfo("stackedOnSeries"),c=r.isHorizontal(),p=function(t,e){return e.toGlobalCoord(e.dataToCoord("log"===e.type?1:0))}(0,r),d=Ux(t),f=t.get("barMinHeight")||0,g=u&&e.getDimensionIndex(u),y=e.getLayout("size"),v=e.getLayout("offset");return{progress:function(t,e){for(var i,r=t.count,l=d&&Ex(3*r),u=d&&s&&Ex(3*r),m=d&&Ex(r),x=n.master.getRect(),_=c?x.width:x.height,b=e.getStore(),w=0;null!=(i=t.next());){var S=b.get(h?g:o,i),M=b.get(a,i),I=p,T=void 0;h&&(T=+S-b.get(o,i));var C=void 0,D=void 0,A=void 0,k=void 0;if(c){var L=n.dataToPoint([S,M]);if(h)I=n.dataToPoint([T,M])[0];C=I,D=L[1]+v,A=L[0]-I,k=y,Math.abs(A)0)for(var s=0;s=0;--s)if(l[u]){o=l[u];break}o=o||a.none}if(Y(o)){var h=null==t.level?0:t.level>=0?t.level:o.length+t.level;o=o[h=Math.min(h,o.length-1)]}}return qc(new Date(t.value),o,r,i)}(t,e,n,this.getSetting("locale"),i)},e.prototype.getTicks=function(){var t=this._interval,e=this._extent,n=[];if(!t)return n;n.push({value:e[0],level:0});var i=this.getSetting("useUTC"),r=function(t,e,n,i){var r=1e4,o=Xc,a=0;function s(t,e,n,r,o,a,s){for(var l=new Date(e),u=e,h=l[r]();u1&&0===u&&o.unshift({value:o[0].value-p})}}for(u=0;u=i[0]&&v<=i[1]&&c++)}var m=(i[1]-i[0])/e;if(c>1.5*m&&p>m/1.5)break;if(u.push(g),c>m||t===o[d])break}h=[]}}0;var x=B(z(u,(function(t){return B(t,(function(t){return t.value>=i[0]&&t.value<=i[1]&&!t.notAdd}))})),(function(t){return t.length>0})),_=[],b=x.length-1;for(d=0;dn&&(this._approxInterval=n);var o=jx.length,a=Math.min(function(t,e,n,i){for(;n>>1;t[r][1]16?16:t>7.5?7:t>3.5?4:t>1.5?2:1}function Kx(t){return(t/=2592e6)>6?6:t>3?3:t>2?2:1}function $x(t){return(t/=Vc)>12?12:t>6?6:t>3.5?4:t>2?2:1}function Jx(t,e){return(t/=e?zc:Ec)>30?30:t>20?20:t>15?15:t>10?10:t>5?5:t>2?2:1}function Qx(t){return so(t,!0)}function t_(t,e,n){var i=new Date(t);switch(Zc(e)){case"year":case"month":i[ap(n)](0);case"day":i[sp(n)](1);case"hour":i[lp(n)](0);case"minute":i[up(n)](0);case"second":i[hp(n)](0),i[cp(n)](0)}return i.getTime()}mx.registerClass(Zx);var e_=mx.prototype,n_=Ox.prototype,i_=Zr,r_=Math.floor,o_=Math.ceil,a_=Math.pow,s_=Math.log,l_=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="log",e.base=10,e._originalScale=new Ox,e._interval=0,e}return n(e,t),e.prototype.getTicks=function(t){var e=this._originalScale,n=this._extent,i=e.getExtent();return z(n_.getTicks.call(this,t),(function(t){var e=t.value,r=Zr(a_(this.base,e));return r=e===n[0]&&this._fixMin?h_(r,i[0]):r,{value:r=e===n[1]&&this._fixMax?h_(r,i[1]):r}}),this)},e.prototype.setExtent=function(t,e){var n=s_(this.base);t=s_(Math.max(0,t))/n,e=s_(Math.max(0,e))/n,n_.setExtent.call(this,t,e)},e.prototype.getExtent=function(){var t=this.base,e=e_.getExtent.call(this);e[0]=a_(t,e[0]),e[1]=a_(t,e[1]);var n=this._originalScale.getExtent();return this._fixMin&&(e[0]=h_(e[0],n[0])),this._fixMax&&(e[1]=h_(e[1],n[1])),e},e.prototype.unionExtent=function(t){this._originalScale.unionExtent(t);var e=this.base;t[0]=s_(t[0])/s_(e),t[1]=s_(t[1])/s_(e),e_.unionExtent.call(this,t)},e.prototype.unionExtentFromData=function(t,e){this.unionExtent(t.getApproximateExtent(e))},e.prototype.calcNiceTicks=function(t){t=t||10;var e=this._extent,n=e[1]-e[0];if(!(n===1/0||n<=0)){var i=oo(n);for(t/n*i<=.5&&(i*=10);!isNaN(i)&&Math.abs(i)<1&&Math.abs(i)>0;)i*=10;var r=[Zr(o_(e[0]/i)*i),Zr(r_(e[1]/i)*i)];this._interval=i,this._niceExtent=r}},e.prototype.calcNiceExtent=function(t){n_.calcNiceExtent.call(this,t),this._fixMin=t.fixMin,this._fixMax=t.fixMax},e.prototype.parse=function(t){return t},e.prototype.contain=function(t){return Dx(t=s_(t)/s_(this.base),this._extent)},e.prototype.normalize=function(t){return Ax(t=s_(t)/s_(this.base),this._extent)},e.prototype.scale=function(t){return t=kx(t,this._extent),a_(this.base,t)},e.type="log",e}(mx),u_=l_.prototype;function h_(t,e){return i_(t,qr(e))}u_.getMinorTicks=n_.getMinorTicks,u_.getLabel=n_.getLabel,mx.registerClass(l_);var c_=function(){function t(t,e,n){this._prepareParams(t,e,n)}return t.prototype._prepareParams=function(t,e,n){n[1]0&&s>0&&!l&&(a=0),a<0&&s<0&&!u&&(s=0));var c=this._determinedMin,p=this._determinedMax;return null!=c&&(a=c,l=!0),null!=p&&(s=p,u=!0),{min:a,max:s,minFixed:l,maxFixed:u,isBlank:h}},t.prototype.modifyDataMinMax=function(t,e){this[d_[t]]=e},t.prototype.setDeterminedMinMax=function(t,e){var n=p_[t];this[n]=e},t.prototype.freeze=function(){this.frozen=!0},t}(),p_={min:"_determinedMin",max:"_determinedMax"},d_={min:"_dataMin",max:"_dataMax"};function f_(t,e,n){var i=t.rawExtentInfo;return i||(i=new c_(t,e,n),t.rawExtentInfo=i,i)}function g_(t,e){return null==e?null:nt(e)?NaN:t.parse(e)}function y_(t,e){var n=t.type,i=f_(t,e,t.getExtent()).calculate();t.setBlank(i.isBlank);var r=i.min,o=i.max,a=e.ecModel;if(a&&"time"===n){var s=Fx("bar",a),l=!1;if(E(s,(function(t){l=l||t.getBaseAxis()===e.axis})),l){var u=Gx(s),h=function(t,e,n,i){var r=n.axis.getExtent(),o=r[1]-r[0],a=function(t,e,n){if(t&&e){var i=t[Bx(e)];return null!=i&&null!=n?i[Vx(n)]:i}}(i,n.axis);if(void 0===a)return{min:t,max:e};var s=1/0;E(a,(function(t){s=Math.min(t.offset,s)}));var l=-1/0;E(a,(function(t){l=Math.max(t.offset+t.width,l)})),s=Math.abs(s),l=Math.abs(l);var u=s+l,h=e-t,c=h/(1-(s+l)/o)-h;return e+=c*(l/u),t-=c*(s/u),{min:t,max:e}}(r,o,e,u);r=h.min,o=h.max}}return{extent:[r,o],fixMin:i.minFixed,fixMax:i.maxFixed}}function v_(t,e){var n=e,i=y_(t,n),r=i.extent,o=n.get("splitNumber");t instanceof l_&&(t.base=n.get("logBase"));var a=t.type,s=n.get("interval"),l="interval"===a||"time"===a;t.setExtent(r[0],r[1]),t.calcNiceExtent({splitNumber:o,fixMin:i.fixMin,fixMax:i.fixMax,minInterval:l?n.get("minInterval"):null,maxInterval:l?n.get("maxInterval"):null}),null!=s&&t.setInterval&&t.setInterval(s)}function m_(t,e){if(e=e||t.get("type"))switch(e){case"category":return new Lx({ordinalMeta:t.getOrdinalMeta?t.getOrdinalMeta():t.getCategories(),extent:[1/0,-1/0]});case"time":return new Zx({locale:t.ecModel.getLocaleModel(),useUTC:t.ecModel.get("useUTC")});default:return new(mx.getClass(e)||Ox)}}function x_(t){var e,n,i=t.getLabelModel().get("formatter"),r="category"===t.type?t.scale.getExtent()[0]:null;return"time"===t.scale.type?(n=i,function(e,i){return t.scale.getFormattedLabel(e,i,n)}):U(i)?function(e){return function(n){var i=t.scale.getLabel(n);return e.replace("{value}",null!=i?i:"")}}(i):X(i)?(e=i,function(n,i){return null!=r&&(i=n.value-r),e(__(t,n),i,null!=n.level?{level:n.level}:null)}):function(e){return t.scale.getLabel(e)}}function __(t,e){return"category"===t.type?t.scale.getLabel(e):e.value}function b_(t,e){var n=e*Math.PI/180,i=t.width,r=t.height,o=i*Math.abs(Math.cos(n))+Math.abs(r*Math.sin(n)),a=i*Math.abs(Math.sin(n))+Math.abs(r*Math.cos(n));return new ze(t.x,t.y,o,a)}function w_(t){var e=t.get("interval");return null==e?"auto":e}function S_(t){return"category"===t.type&&0===w_(t.getLabelModel())}function M_(t,e){var n={};return E(t.mapDimensionsAll(e),(function(e){n[yx(t,e)]=!0})),G(n)}var I_=function(){function t(){}return t.prototype.getNeedCrossZero=function(){return!this.option.scale},t.prototype.getCoordSysModel=function(){},t}();var T_={isDimensionStacked:gx,enableDataStack:fx,getStackedDimension:yx};var C_=Object.freeze({__proto__:null,createList:function(t){return vx(null,t)},getLayoutRect:Cp,dataStack:T_,createScale:function(t,e){var n=e;e instanceof Mc||(n=new Mc(e));var i=m_(n);return i.setExtent(t[0],t[1]),v_(i,n),i},mixinAxisModelCommonMethods:function(t){R(t,I_)},getECData:Qs,createTextStyle:function(t,e){return nc(t,null,null,"normal"!==(e=e||{}).state)},createDimensions:function(t,e){return ux(t,e).dimensions},createSymbol:Wy,enableHoverEmphasis:Hl});function D_(t,e){return Math.abs(t-e)<1e-8}function A_(t,e,n){var i=0,r=t[0];if(!r)return!1;for(var o=1;on&&(t=r,n=a)}if(t)return function(t){for(var e=0,n=0,i=0,r=t.length,o=t[r-1][0],a=t[r-1][1],s=0;s>1^-(1&s),l=l>>1^-(1&l),r=s+=r,o=l+=o,i.push([s/n,l/n])}return i}function F_(t,e){return z(B((t=function(t){if(!t.UTF8Encoding)return t;var e=t,n=e.UTF8Scale;return null==n&&(n=1024),E(e.features,(function(t){var e=t.geometry,i=e.encodeOffsets,r=e.coordinates;if(i)switch(e.type){case"LineString":e.coordinates=B_(r,i,n);break;case"Polygon":case"MultiLineString":V_(r,i,n);break;case"MultiPolygon":E(r,(function(t,e){return V_(t,i[e],n)}))}})),e.UTF8Encoding=!1,e}(t)).features,(function(t){return t.geometry&&t.properties&&t.geometry.coordinates.length>0})),(function(t){var n=t.properties,i=t.geometry,r=[];switch(i.type){case"Polygon":var o=i.coordinates;r.push(new R_(o[0],o.slice(1)));break;case"MultiPolygon":E(i.coordinates,(function(t){t[0]&&r.push(new R_(t[0],t.slice(1)))}));break;case"LineString":r.push(new N_([i.coordinates]));break;case"MultiLineString":r.push(new N_(i.coordinates))}var a=new E_(n[e||"name"],r,n.cp);return a.properties=n,a}))}var G_=Object.freeze({__proto__:null,linearMap:Xr,round:Zr,asc:jr,getPrecision:qr,getPrecisionSafe:Kr,getPixelPrecision:$r,getPercentWithPrecision:function(t,e,n){return t[e]&&Jr(t,n)[e]||0},MAX_SAFE_INTEGER:to,remRadian:eo,isRadianAroundZero:no,parseDate:ro,quantity:oo,quantityExponent:ao,nice:so,quantile:lo,reformIntervals:uo,isNumeric:co,numericToNumber:ho}),W_=Object.freeze({__proto__:null,parse:ro,format:qc}),H_=Object.freeze({__proto__:null,extendShape:Mh,extendPath:Th,makePath:Ah,makeImage:kh,mergePath:Ph,resizePath:Oh,createIcon:Hh,updateProps:fh,initProps:gh,getTransform:Eh,clipPointsByRect:Gh,clipRectByRect:Wh,registerShape:Ch,getShapeClass:Dh,Group:zr,Image:ks,Text:Fs,Circle:_u,Ellipse:wu,Sector:zu,Ring:Bu,Polygon:Wu,Polyline:Yu,Rect:zs,Line:Zu,BezierCurve:$u,Arc:Qu,IncrementalDisplayable:hh,CompoundPath:th,LinearGradient:nh,RadialGradient:ih,BoundingRect:ze}),Y_=Object.freeze({__proto__:null,addCommas:pp,toCamelCase:dp,normalizeCssArray:fp,encodeHTML:re,formatTpl:mp,getTooltipMarker:xp,formatTime:function(t,e,n){"week"!==t&&"month"!==t&&"quarter"!==t&&"half-year"!==t&&"year"!==t||(t="MM-dd\nyyyy");var i=ro(e),r=n?"getUTC":"get",o=i[r+"FullYear"](),a=i[r+"Month"]()+1,s=i[r+"Date"](),l=i[r+"Hours"](),u=i[r+"Minutes"](),h=i[r+"Seconds"](),c=i[r+"Milliseconds"]();return t=t.replace("MM",Uc(a,2)).replace("M",a).replace("yyyy",o).replace("yy",Uc(o%100+"",2)).replace("dd",Uc(s,2)).replace("d",s).replace("hh",Uc(l,2)).replace("h",l).replace("mm",Uc(u,2)).replace("m",u).replace("ss",Uc(h,2)).replace("s",h).replace("SSS",Uc(c,3))},capitalFirst:function(t){return t?t.charAt(0).toUpperCase()+t.substr(1):t},truncateText:sa,getTextRect:function(t,e,n,i,r,o,a,s){return new Fs({style:{text:t,font:e,align:n,verticalAlign:i,padding:r,rich:o,overflow:a?"truncate":null,lineHeight:s}}).getBoundingRect()}}),X_=Object.freeze({__proto__:null,map:z,each:E,indexOf:P,inherits:O,reduce:V,filter:B,bind:W,curry:H,isArray:Y,isString:U,isObject:q,isFunction:X,extend:A,defaults:k,clone:T,merge:C}),U_=Oo();function Z_(t){return"category"===t.type?function(t){var e=t.getLabelModel(),n=q_(t,e);return!e.get("show")||t.scale.isBlank()?{labels:[],labelCategoryInterval:n.labelCategoryInterval}:n}(t):function(t){var e=t.scale.getTicks(),n=x_(t);return{labels:z(e,(function(e,i){return{level:e.level,formattedLabel:n(e,i),rawLabel:t.scale.getLabel(e),tickValue:e.value}}))}}(t)}function j_(t,e){return"category"===t.type?function(t,e){var n,i,r=K_(t,"ticks"),o=w_(e),a=$_(r,o);if(a)return a;e.get("show")&&!t.scale.isBlank()||(n=[]);if(X(o))n=tb(t,o,!0);else if("auto"===o){var s=q_(t,t.getLabelModel());i=s.labelCategoryInterval,n=z(s.labels,(function(t){return t.tickValue}))}else n=Q_(t,i=o,!0);return J_(r,o,{ticks:n,tickCategoryInterval:i})}(t,e):{ticks:z(t.scale.getTicks(),(function(t){return t.value}))}}function q_(t,e){var n,i,r=K_(t,"labels"),o=w_(e),a=$_(r,o);return a||(X(o)?n=tb(t,o):(i="auto"===o?function(t){var e=U_(t).autoInterval;return null!=e?e:U_(t).autoInterval=t.calculateCategoryInterval()}(t):o,n=Q_(t,i)),J_(r,o,{labels:n,labelCategoryInterval:i}))}function K_(t,e){return U_(t)[e]||(U_(t)[e]=[])}function $_(t,e){for(var n=0;n1&&h/l>2&&(u=Math.round(Math.ceil(u/l)*l));var c=S_(t),p=a.get("showMinLabel")||c,d=a.get("showMaxLabel")||c;p&&u!==o[0]&&g(o[0]);for(var f=u;f<=o[1];f+=l)g(f);function g(t){var e={value:t};s.push(n?t:{formattedLabel:i(e),rawLabel:r.getLabel(e),tickValue:t})}return d&&f-l!==o[1]&&g(o[1]),s}function tb(t,e,n){var i=t.scale,r=x_(t),o=[];return E(i.getTicks(),(function(t){var a=i.getLabel(t),s=t.value;e(t.value,a)&&o.push(n?s:{formattedLabel:r(t),rawLabel:a,tickValue:s})})),o}var eb=[0,1],nb=function(){function t(t,e,n){this.onBand=!1,this.inverse=!1,this.dim=t,this.scale=e,this._extent=n||[0,0]}return t.prototype.contain=function(t){var e=this._extent,n=Math.min(e[0],e[1]),i=Math.max(e[0],e[1]);return t>=n&&t<=i},t.prototype.containData=function(t){return this.scale.contain(t)},t.prototype.getExtent=function(){return this._extent.slice()},t.prototype.getPixelPrecision=function(t){return $r(t||this.scale.getExtent(),this._extent)},t.prototype.setExtent=function(t,e){var n=this._extent;n[0]=t,n[1]=e},t.prototype.dataToCoord=function(t,e){var n=this._extent,i=this.scale;return t=i.normalize(t),this.onBand&&"ordinal"===i.type&&ib(n=n.slice(),i.count()),Xr(t,eb,n,e)},t.prototype.coordToData=function(t,e){var n=this._extent,i=this.scale;this.onBand&&"ordinal"===i.type&&ib(n=n.slice(),i.count());var r=Xr(t,n,eb,e);return this.scale.scale(r)},t.prototype.pointToData=function(t,e){},t.prototype.getTicksCoords=function(t){var e=(t=t||{}).tickModel||this.getTickModel(),n=z(j_(this,e).ticks,(function(t){return{coord:this.dataToCoord("ordinal"===this.scale.type?this.scale.getRawOrdinalNumber(t):t),tickValue:t}}),this);return function(t,e,n,i){var r=e.length;if(!t.onBand||n||!r)return;var o,a,s=t.getExtent();if(1===r)e[0].coord=s[0],o=e[1]={coord:s[1]};else{var l=e[r-1].tickValue-e[0].tickValue,u=(e[r-1].coord-e[0].coord)/l;E(e,(function(t){t.coord-=u/2})),a=1+t.scale.getExtent()[1]-e[r-1].tickValue,o={coord:e[r-1].coord+u*a},e.push(o)}var h=s[0]>s[1];c(e[0].coord,s[0])&&(i?e[0].coord=s[0]:e.shift());i&&c(s[0],e[0].coord)&&e.unshift({coord:s[0]});c(s[1],o.coord)&&(i?o.coord=s[1]:e.pop());i&&c(o.coord,s[1])&&e.push({coord:s[1]});function c(t,e){return t=Zr(t),e=Zr(e),h?t>e:t0&&t<100||(t=5),z(this.scale.getMinorTicks(t),(function(t){return z(t,(function(t){return{coord:this.dataToCoord(t),tickValue:t}}),this)}),this)},t.prototype.getViewLabels=function(){return Z_(this).labels},t.prototype.getLabelModel=function(){return this.model.getModel("axisLabel")},t.prototype.getTickModel=function(){return this.model.getModel("axisTick")},t.prototype.getBandWidth=function(){var t=this._extent,e=this.scale.getExtent(),n=e[1]-e[0]+(this.onBand?1:0);0===n&&(n=1);var i=Math.abs(t[1]-t[0]);return Math.abs(i)/n},t.prototype.calculateCategoryInterval=function(){return function(t){var e=function(t){var e=t.getLabelModel();return{axisRotate:t.getRotate?t.getRotate():t.isHorizontal&&!t.isHorizontal()?90:0,labelRotate:e.get("rotate")||0,font:e.getFont()}}(t),n=x_(t),i=(e.axisRotate-e.labelRotate)/180*Math.PI,r=t.scale,o=r.getExtent(),a=r.count();if(o[1]-o[0]<1)return 0;var s=1;a>40&&(s=Math.max(1,Math.floor(a/40)));for(var l=o[0],u=t.dataToCoord(l+1)-t.dataToCoord(l),h=Math.abs(u*Math.cos(i)),c=Math.abs(u*Math.sin(i)),p=0,d=0;l<=o[1];l+=s){var f,g,y=br(n({value:l}),e.font,"center","top");f=1.3*y.width,g=1.3*y.height,p=Math.max(p,f,7),d=Math.max(d,g,7)}var v=p/h,m=d/c;isNaN(v)&&(v=1/0),isNaN(m)&&(m=1/0);var x=Math.max(0,Math.floor(Math.min(v,m))),_=U_(t.model),b=t.getExtent(),w=_.lastAutoInterval,S=_.lastTickCount;return null!=w&&null!=S&&Math.abs(w-x)<=1&&Math.abs(S-a)<=1&&w>x&&_.axisExtent0===b[0]&&_.axisExtent1===b[1]?x=w:(_.lastTickCount=a,_.lastAutoInterval=x,_.axisExtent0=b[0],_.axisExtent1=b[1]),x}(this)},t}();function ib(t,e){var n=(t[1]-t[0])/e/2;t[0]+=n,t[1]-=n}var rb=2*Math.PI,ob=os.CMD,ab=["top","right","bottom","left"];function sb(t,e,n,i,r){var o=n.width,a=n.height;switch(t){case"top":i.set(n.x+o/2,n.y-e),r.set(0,-1);break;case"bottom":i.set(n.x+o/2,n.y+a+e),r.set(0,1);break;case"left":i.set(n.x-e,n.y+a/2),r.set(-1,0);break;case"right":i.set(n.x+o+e,n.y+a/2),r.set(1,0)}}function lb(t,e,n,i,r,o,a,s,l){a-=t,s-=e;var u=Math.sqrt(a*a+s*s),h=(a/=u)*n+t,c=(s/=u)*n+e;if(Math.abs(i-r)%rb<1e-4)return l[0]=h,l[1]=c,u-n;if(o){var p=i;i=hs(r),r=hs(p)}else i=hs(i),r=hs(r);i>r&&(r+=rb);var d=Math.atan2(s,a);if(d<0&&(d+=rb),d>=i&&d<=r||d+rb>=i&&d+rb<=r)return l[0]=h,l[1]=c,u-n;var f=n*Math.cos(i)+t,g=n*Math.sin(i)+e,y=n*Math.cos(r)+t,v=n*Math.sin(r)+e,m=(f-a)*(f-a)+(g-s)*(g-s),x=(y-a)*(y-a)+(v-s)*(v-s);return m0){e=e/180*Math.PI,fb.fromArray(t[0]),gb.fromArray(t[1]),yb.fromArray(t[2]),De.sub(vb,fb,gb),De.sub(mb,yb,gb);var n=vb.len(),i=mb.len();if(!(n<.001||i<.001)){vb.scale(1/n),mb.scale(1/i);var r=vb.dot(mb);if(Math.cos(e)1&&De.copy(bb,yb),bb.toArray(t[1])}}}}function Sb(t,e,n){if(n<=180&&n>0){n=n/180*Math.PI,fb.fromArray(t[0]),gb.fromArray(t[1]),yb.fromArray(t[2]),De.sub(vb,gb,fb),De.sub(mb,yb,gb);var i=vb.len(),r=mb.len();if(!(i<.001||r<.001))if(vb.scale(1/i),mb.scale(1/r),vb.dot(e)=a)De.copy(bb,yb);else{bb.scaleAndAdd(mb,o/Math.tan(Math.PI/2-s));var l=yb.x!==gb.x?(bb.x-gb.x)/(yb.x-gb.x):(bb.y-gb.y)/(yb.y-gb.y);if(isNaN(l))return;l<0?De.copy(bb,gb):l>1&&De.copy(bb,yb)}bb.toArray(t[1])}}}function Mb(t,e,n,i){var r="normal"===n,o=r?t:t.ensureState(n);o.ignore=e;var a=i.get("smooth");a&&!0===a&&(a=.3),o.shape=o.shape||{},a>0&&(o.shape.smooth=a);var s=i.getModel("lineStyle").getLineStyle();r?t.useStyle(s):o.style=s}function Ib(t,e){var n=e.smooth,i=e.points;if(i)if(t.moveTo(i[0][0],i[0][1]),n>0&&i.length>=3){var r=Vt(i[0],i[1]),o=Vt(i[1],i[2]);if(!r||!o)return t.lineTo(i[1][0],i[1][1]),void t.lineTo(i[2][0],i[2][1]);var a=Math.min(r,o)*n,s=Gt([],i[1],i[0],a/r),l=Gt([],i[1],i[2],a/o),u=Gt([],s,l,.5);t.bezierCurveTo(s[0],s[1],s[0],s[1],u[0],u[1]),t.bezierCurveTo(l[0],l[1],l[0],l[1],i[2][0],i[2][1])}else for(var h=1;h0&&o&&_(-h/a,0,a);var f,g,y=t[0],v=t[a-1];return m(),f<0&&b(-f,.8),g<0&&b(g,.8),m(),x(f,g,1),x(g,f,-1),m(),f<0&&w(-f),g<0&&w(g),u}function m(){f=y.rect[e]-i,g=r-v.rect[e]-v.rect[n]}function x(t,e,n){if(t<0){var i=Math.min(e,-t);if(i>0){_(i*n,0,a);var r=i+t;r<0&&b(-r*n,1)}else b(-t*n,1)}}function _(n,i,r){0!==n&&(u=!0);for(var o=i;o0)for(l=0;l0;l--){_(-(o[l-1]*c),l,a)}}}function w(t){var e=t<0?-1:1;t=Math.abs(t);for(var n=Math.ceil(t/(a-1)),i=0;i0?_(n,0,i+1):_(-n,a-i-1,a),(t-=n)<=0)return}}function kb(t,e,n,i){return Ab(t,"y","height",e,n,i)}function Lb(t){var e=[];t.sort((function(t,e){return e.priority-t.priority}));var n=new ze(0,0,0,0);function i(t){if(!t.ignore){var e=t.ensureState("emphasis");null==e.ignore&&(e.ignore=!1)}t.ignore=!0}for(var r=0;r=0&&n.attr(d.oldLayoutSelect),P(u,"emphasis")>=0&&n.attr(d.oldLayoutEmphasis)),fh(n,s,e,a)}else if(n.attr(s),!uc(n).valueAnimation){var h=rt(n.style.opacity,1);n.style.opacity=0,gh(n,{style:{opacity:h}},e,a)}if(d.oldLayout=s,n.states.select){var c=d.oldLayoutSelect={};Vb(c,s,Bb),Vb(c,n.states.select,Bb)}if(n.states.emphasis){var p=d.oldLayoutEmphasis={};Vb(p,s,Bb),Vb(p,n.states.emphasis,Bb)}cc(n,a,l,e,e)}if(i&&!i.ignore&&!i.invisible){r=(d=zb(i)).oldLayout;var d,f={points:i.shape.points};r?(i.attr({shape:r}),fh(i,{shape:f},e)):(i.setShape(f),i.style.strokePercent=0,gh(i,{style:{strokePercent:1}},e)),d.oldLayout=f}},t}(),Gb=Oo();var Wb=Math.sin,Hb=Math.cos,Yb=Math.PI,Xb=2*Math.PI,Ub=180/Yb,Zb=function(){function t(){}return t.prototype.reset=function(t){this._start=!0,this._d=[],this._str="",this._p=Math.pow(10,t||4)},t.prototype.moveTo=function(t,e){this._add("M",t,e)},t.prototype.lineTo=function(t,e){this._add("L",t,e)},t.prototype.bezierCurveTo=function(t,e,n,i,r,o){this._add("C",t,e,n,i,r,o)},t.prototype.quadraticCurveTo=function(t,e,n,i){this._add("Q",t,e,n,i)},t.prototype.arc=function(t,e,n,i,r,o){this.ellipse(t,e,n,n,0,i,r,o)},t.prototype.ellipse=function(t,e,n,i,r,o,a,s){var l=a-o,u=!s,h=Math.abs(l),c=hi(h-Xb)||(u?l>=Xb:-l>=Xb),p=l>0?l%Xb:l%Xb+Xb,d=!1;d=!!c||!hi(h)&&p>=Yb==!!u;var f=t+n*Hb(o),g=e+i*Wb(o);this._start&&this._add("M",f,g);var y=Math.round(r*Ub);if(c){var v=1/this._p,m=(u?1:-1)*(Xb-v);this._add("A",n,i,y,1,+u,t+n*Hb(o+m),e+i*Wb(o+m)),v>.01&&this._add("A",n,i,y,0,+u,f,g)}else{var x=t+n*Hb(a),_=e+i*Wb(a);this._add("A",n,i,y,+d,+u,x,_)}},t.prototype.rect=function(t,e,n,i){this._add("M",t,e),this._add("l",n,0),this._add("l",0,i),this._add("l",-n,0),this._add("Z")},t.prototype.closePath=function(){this._d.length>0&&this._add("Z")},t.prototype._add=function(t,e,n,i,r,o,a,s,l){for(var u=[],h=this._p,c=1;c"}(r,o)+("style"!==r?re(a):a||"")+(i?""+n+z(i,(function(e){return t(e)})).join(n)+n:"")+("")}(t)}function rw(t){return{zrId:t,shadowCache:{},patternCache:{},gradientCache:{},clipPathCache:{},defs:{},cssNodes:{},cssAnims:{},cssClassIdx:0,cssAnimIdx:0,shadowIdx:0,gradientIdx:0,patternIdx:0,clipPathIdx:0}}function ow(t,e,n,i){return nw("svg","root",{width:t,height:e,xmlns:Qb,"xmlns:xlink":tw,version:"1.1",baseProfile:"full",viewBox:!!i&&"0 0 "+t+" "+e},n)}var aw={cubicIn:"0.32,0,0.67,0",cubicOut:"0.33,1,0.68,1",cubicInOut:"0.65,0,0.35,1",quadraticIn:"0.11,0,0.5,0",quadraticOut:"0.5,1,0.89,1",quadraticInOut:"0.45,0,0.55,1",quarticIn:"0.5,0,0.75,0",quarticOut:"0.25,1,0.5,1",quarticInOut:"0.76,0,0.24,1",quinticIn:"0.64,0,0.78,0",quinticOut:"0.22,1,0.36,1",quinticInOut:"0.83,0,0.17,1",sinusoidalIn:"0.12,0,0.39,0",sinusoidalOut:"0.61,1,0.88,1",sinusoidalInOut:"0.37,0,0.63,1",exponentialIn:"0.7,0,0.84,0",exponentialOut:"0.16,1,0.3,1",exponentialInOut:"0.87,0,0.13,1",circularIn:"0.55,0,1,0.45",circularOut:"0,0.55,0.45,1",circularInOut:"0.85,0,0.15,1"},sw="transform-origin";function lw(t,e,n){var i=A({},t.shape);A(i,e),t.buildPath(n,i);var r=new Zb;return r.reset(_i(t)),n.rebuildPath(r,1),r.generateStr(),r.getStr()}function uw(t,e){var n=e.originX,i=e.originY;(n||i)&&(t[sw]=n+"px "+i+"px")}var hw={fill:"fill",opacity:"opacity",lineWidth:"stroke-width",lineDashOffset:"stroke-dashoffset"};function cw(t,e){var n=e.zrId+"-ani-"+e.cssAnimIdx++;return e.cssAnims[n]=t,n}function pw(t){return U(t)?aw[t]?"cubic-bezier("+aw[t]+")":Pn(t)?t:"":""}function dw(t,e,n,i){var r=t.animators,o=r.length,a=[];if(t instanceof th){var s=function(t,e,n){var i,r,o=t.shape.paths,a={};if(E(o,(function(t){var e=rw(n.zrId);e.animation=!0,dw(t,{},e,!0);var o=e.cssAnims,s=e.cssNodes,l=G(o),u=l.length;if(u){var h=o[r=l[u-1]];for(var c in h){var p=h[c];a[c]=a[c]||{d:""},a[c].d+=p.d||""}for(var d in s){var f=s[d].animation;f.indexOf(r)>=0&&(i=f)}}})),i){e.d=!1;var s=cw(a,n);return i.replace(r,s)}}(t,e,n);if(s)a.push(s);else if(!o)return}else if(!o)return;for(var l={},u=0;u0})).length)return cw(h,n)+" "+r[0]+" both"}for(var y in l){(s=g(l[y]))&&a.push(s)}if(a.length){var v=n.zrId+"-cls-"+n.cssClassIdx++;n.cssNodes["."+v]={animation:a.join(",")},e.class=v}}var fw=Math.round;function gw(t){return t&&U(t.src)}function yw(t){return t&&X(t.toDataURL)}function vw(t,e,n,i){Jb((function(r,o){var a="fill"===r||"stroke"===r;a&&mi(o)?Cw(e,t,r,i):a&&gi(o)?Dw(n,t,r,i):t[r]=o}),e,n,!1),function(t,e,n){var i=t.style;if(function(t){return t&&(t.shadowBlur||t.shadowOffsetX||t.shadowOffsetY)}(i)){var r=function(t){var e=t.style,n=t.getGlobalScale();return[e.shadowColor,(e.shadowBlur||0).toFixed(2),(e.shadowOffsetX||0).toFixed(2),(e.shadowOffsetY||0).toFixed(2),n[0],n[1]].join(",")}(t),o=n.shadowCache,a=o[r];if(!a){var s=t.getGlobalScale(),l=s[0],u=s[1];if(!l||!u)return;var h=i.shadowOffsetX||0,c=i.shadowOffsetY||0,p=i.shadowBlur,d=li(i.shadowColor),f=d.opacity,g=d.color,y=p/2/l+" "+p/2/u;a=n.zrId+"-s"+n.shadowIdx++,n.defs[a]=nw("filter",a,{id:a,x:"-100%",y:"-100%",width:"300%",height:"300%"},[nw("feDropShadow","",{dx:h/l,dy:c/u,stdDeviation:y,"flood-color":g,"flood-opacity":f})]),o[r]=a}e.filter=xi(a)}}(n,t,i)}function mw(t){return hi(t[0]-1)&&hi(t[1])&&hi(t[2])&&hi(t[3]-1)}function xw(t,e,n){if(e&&(!function(t){return hi(t[4])&&hi(t[5])}(e)||!mw(e))){var i=n?10:1e4;t.transform=mw(e)?"translate("+fw(e[4]*i)/i+" "+fw(e[5]*i)/i+")":function(t){return"matrix("+ci(t[0])+","+ci(t[1])+","+ci(t[2])+","+ci(t[3])+","+pi(t[4])+","+pi(t[5])+")"}(e)}}function _w(t,e,n){for(var i=t.points,r=[],o=0;ol?Hw(t,null==n[c+1]?null:n[c+1].elm,n,s,c):Yw(t,e,a,l))}(n,i,r):Bw(r)?(Bw(t.text)&&Ew(n,""),Hw(n,null,r,0,r.length-1)):Bw(i)?Yw(n,i,0,i.length-1):Bw(t.text)&&Ew(n,""):t.text!==e.text&&(Bw(i)&&Yw(n,i,0,i.length-1),Ew(n,e.text)))}var Zw=0,jw=function(){function t(t,e,n){if(this.type="svg",this.refreshHover=qw("refreshHover"),this.configLayer=qw("configLayer"),this.storage=e,this._opts=n=A({},n),this.root=t,this._id="zr"+Zw++,this._oldVNode=ow(n.width,n.height),t&&!n.ssr){var i=this._viewport=document.createElement("div");i.style.cssText="position:relative;overflow:hidden";var r=this._svgDom=this._oldVNode.elm=ew("svg");Xw(null,this._oldVNode),i.appendChild(r),t.appendChild(i)}this.resize(n.width,n.height)}return t.prototype.getType=function(){return this.type},t.prototype.getViewportRoot=function(){return this._viewport},t.prototype.getViewportRootOffset=function(){var t=this.getViewportRoot();if(t)return{offsetLeft:t.offsetLeft||0,offsetTop:t.offsetTop||0}},t.prototype.getSvgDom=function(){return this._svgDom},t.prototype.refresh=function(){if(this.root){var t=this.renderToVNode({willUpdate:!0});t.attrs.style="position:absolute;left:0;top:0;user-select:none",function(t,e){if(Gw(t,e))Uw(t,e);else{var n=t.elm,i=Rw(n);Ww(e),null!==i&&(Lw(i,e.elm,Nw(n)),Yw(i,[t],0,0))}}(this._oldVNode,t),this._oldVNode=t}},t.prototype.renderOneToVNode=function(t){return Tw(t,rw(this._id))},t.prototype.renderToVNode=function(t){t=t||{};var e=this.storage.getDisplayList(!0),n=this._width,i=this._height,r=rw(this._id);r.animation=t.animation,r.willUpdate=t.willUpdate,r.compress=t.compress;var o=[],a=this._bgVNode=function(t,e,n,i){var r;if(n&&"none"!==n)if(r=nw("rect","bg",{width:t,height:e,x:"0",y:"0",id:"0"}),mi(n))Cw({fill:n},r.attrs,"fill",i);else if(gi(n))Dw({style:{fill:n},dirty:bt,getBoundingRect:function(){return{width:t,height:e}}},r.attrs,"fill",i);else{var o=li(n),a=o.color,s=o.opacity;r.attrs.fill=a,s<1&&(r.attrs["fill-opacity"]=s)}return r}(n,i,this._backgroundColor,r);a&&o.push(a);var s=t.compress?null:this._mainVNode=nw("g","main",{},[]);this._paintList(e,r,s?s.children:o),s&&o.push(s);var l=z(G(r.defs),(function(t){return r.defs[t]}));if(l.length&&o.push(nw("defs","defs",{},l)),t.animation){var u=function(t,e,n){var i=(n=n||{}).newline?"\n":"",r=" {"+i,o=i+"}",a=z(G(t),(function(e){return e+r+z(G(t[e]),(function(n){return n+":"+t[e][n]+";"})).join(i)+o})).join(i),s=z(G(e),(function(t){return"@keyframes "+t+r+z(G(e[t]),(function(n){return n+r+z(G(e[t][n]),(function(i){var r=e[t][n][i];return"d"===i&&(r='path("'+r+'")'),i+":"+r+";"})).join(i)+o})).join(i)+o})).join(i);return a||s?[""].join(i):""}(r.cssNodes,r.cssAnims,{newline:!0});if(u){var h=nw("style","stl",{},[],u);o.push(h)}}return ow(n,i,o,t.useViewBox)},t.prototype.renderToString=function(t){return t=t||{},iw(this.renderToVNode({animation:rt(t.cssAnimation,!0),willUpdate:!1,compress:!0,useViewBox:rt(t.useViewBox,!0)}),{newline:!0})},t.prototype.setBackgroundColor=function(t){this._backgroundColor=t},t.prototype.getSvgRoot=function(){return this._mainVNode&&this._mainVNode.elm},t.prototype._paintList=function(t,e,n){for(var i,r,o=t.length,a=[],s=0,l=0,u=0;u=0&&(!c||!r||c[f]!==r[f]);f--);for(var g=d-1;g>f;g--)i=a[--s-1];for(var y=f+1;y=a)}}for(var h=this.__startIndex;h15)break}n.prevElClipPaths&&u.restore()};if(p)if(0===p.length)s=l.__endIndex;else for(var _=d.dpr,b=0;b0&&t>i[0]){for(s=0;st);s++);a=n[i[s]]}if(i.splice(s+1,0,t),n[t]=e,!e.virtual)if(a){var l=a.dom;l.nextSibling?o.insertBefore(e.dom,l.nextSibling):o.appendChild(e.dom)}else o.firstChild?o.insertBefore(e.dom,o.firstChild):o.appendChild(e.dom);e.__painter=this}},t.prototype.eachLayer=function(t,e){for(var n=this._zlevelList,i=0;i0?tS:0),this._needsManuallyCompositing),u.__builtin__||I("ZLevel "+l+" has been used by unkown layer "+u.id),u!==o&&(u.__used=!0,u.__startIndex!==r&&(u.__dirty=!0),u.__startIndex=r,u.incremental?u.__drawIndex=-1:u.__drawIndex=r,e(r),o=u),1&s.__dirty&&!s.__inHover&&(u.__dirty=!0,u.incremental&&u.__drawIndex<0&&(u.__drawIndex=r))}e(r),this.eachBuiltinLayer((function(t,e){!t.__used&&t.getElementCount()>0&&(t.__dirty=!0,t.__startIndex=t.__endIndex=t.__drawIndex=0),t.__dirty&&t.__drawIndex<0&&(t.__drawIndex=t.__startIndex)}))},t.prototype.clear=function(){return this.eachBuiltinLayer(this._clearLayer),this},t.prototype._clearLayer=function(t){t.clear()},t.prototype.setBackgroundColor=function(t){this._backgroundColor=t,E(this._layers,(function(t){t.setUnpainted()}))},t.prototype.configLayer=function(t,e){if(e){var n=this._layerConfig;n[t]?C(n[t],e,!0):n[t]=e;for(var i=0;i-1&&(s.style.stroke=s.style.fill,s.style.fill="#fff",s.style.lineWidth=2),e},e.type="series.line",e.dependencies=["grid","polar"],e.defaultOption={z:3,coordinateSystem:"cartesian2d",legendHoverLink:!0,clip:!0,label:{position:"top"},endLabel:{show:!1,valueAnimation:!0,distance:8},lineStyle:{width:2,type:"solid"},emphasis:{scale:!0},step:!1,smooth:!1,smoothMonotone:null,symbol:"emptyCircle",symbolSize:4,symbolRotate:null,showSymbol:!0,showAllSymbol:"auto",connectNulls:!1,sampling:"none",animationEasing:"linear",progressive:0,hoverLayerThreshold:1/0,universalTransition:{divideShape:"clone"},triggerLineEvent:!1},e}(mg);function iS(t,e){var n=t.mapDimensionsAll("defaultedLabel"),i=n.length;if(1===i){var r=gf(t,e,n[0]);return null!=r?r+"":null}if(i){for(var o=[],a=0;a=0&&i.push(e[o])}return i.join(" ")}var oS=function(t){function e(e,n,i,r){var o=t.call(this)||this;return o.updateData(e,n,i,r),o}return n(e,t),e.prototype._createSymbol=function(t,e,n,i,r){this.removeAll();var o=Wy(t,-1,-1,2,2,null,r);o.attr({z2:100,culling:!0,scaleX:i[0]/2,scaleY:i[1]/2}),o.drift=aS,this._symbolType=t,this.add(o)},e.prototype.stopSymbolAnimation=function(t){this.childAt(0).stopAnimation(null,t)},e.prototype.getSymbolType=function(){return this._symbolType},e.prototype.getSymbolPath=function(){return this.childAt(0)},e.prototype.highlight=function(){kl(this.childAt(0))},e.prototype.downplay=function(){Ll(this.childAt(0))},e.prototype.setZ=function(t,e){var n=this.childAt(0);n.zlevel=t,n.z=e},e.prototype.setDraggable=function(t,e){var n=this.childAt(0);n.draggable=t,n.cursor=!e&&t?"move":n.cursor},e.prototype.updateData=function(t,n,i,r){this.silent=!1;var o=t.getItemVisual(n,"symbol")||"circle",a=t.hostModel,s=e.getSymbolSize(t,n),l=o!==this._symbolType,u=r&&r.disableAnimation;if(l){var h=t.getItemVisual(n,"symbolKeepAspect");this._createSymbol(o,t,n,s,h)}else{(p=this.childAt(0)).silent=!1;var c={scaleX:s[0]/2,scaleY:s[1]/2};u?p.attr(c):fh(p,c,a,n),_h(p)}if(this._updateCommon(t,n,s,i,r),l){var p=this.childAt(0);if(!u){c={scaleX:this._sizeX,scaleY:this._sizeY,style:{opacity:p.style.opacity}};p.scaleX=p.scaleY=0,p.style.opacity=0,gh(p,c,a,n)}}u&&this.childAt(0).stopAnimation("leave")},e.prototype._updateCommon=function(t,e,n,i,r){var o,a,s,l,u,h,c,p,d,f=this.childAt(0),g=t.hostModel;if(i&&(o=i.emphasisItemStyle,a=i.blurItemStyle,s=i.selectItemStyle,l=i.focus,u=i.blurScope,c=i.labelStatesModels,p=i.hoverScale,d=i.cursorStyle,h=i.emphasisDisabled),!i||t.hasItemOption){var y=i&&i.itemModel?i.itemModel:t.getItemModel(e),v=y.getModel("emphasis");o=v.getModel("itemStyle").getItemStyle(),s=y.getModel(["select","itemStyle"]).getItemStyle(),a=y.getModel(["blur","itemStyle"]).getItemStyle(),l=v.get("focus"),u=v.get("blurScope"),h=v.get("disabled"),c=ec(y),p=v.getShallow("scale"),d=y.getShallow("cursor")}var m=t.getItemVisual(e,"symbolRotate");f.attr("rotation",(m||0)*Math.PI/180||0);var x=Yy(t.getItemVisual(e,"symbolOffset"),n);x&&(f.x=x[0],f.y=x[1]),d&&f.attr("cursor",d);var _=t.getItemVisual(e,"style"),b=_.fill;if(f instanceof ks){var w=f.style;f.useStyle(A({image:w.image,x:w.x,y:w.y,width:w.width,height:w.height},_))}else f.__isEmptyBrush?f.useStyle(A({},_)):f.useStyle(_),f.style.decal=null,f.setColor(b,r&&r.symbolInnerColor),f.style.strokeNoScale=!0;var S=t.getItemVisual(e,"liftZ"),M=this._z2;null!=S?null==M&&(this._z2=f.z2,f.z2+=S):null!=M&&(f.z2=M,this._z2=null);var I=r&&r.useNameLabel;tc(f,c,{labelFetcher:g,labelDataIndex:e,defaultText:function(e){return I?t.getName(e):iS(t,e)},inheritColor:b,defaultOpacity:_.opacity}),this._sizeX=n[0]/2,this._sizeY=n[1]/2;var T=f.ensureState("emphasis");T.style=o,f.ensureState("select").style=s,f.ensureState("blur").style=a;var C=null==p||!0===p?Math.max(1.1,3/this._sizeY):isFinite(p)&&p>0?+p:1;T.scaleX=this._sizeX*C,T.scaleY=this._sizeY*C,this.setSymbolScale(1),Yl(this,l,u,h)},e.prototype.setSymbolScale=function(t){this.scaleX=this.scaleY=t},e.prototype.fadeOut=function(t,e,n){var i=this.childAt(0),r=Qs(this).dataIndex,o=n&&n.animation;if(this.silent=i.silent=!0,n&&n.fadeLabel){var a=i.getTextContent();a&&vh(a,{style:{opacity:0}},e,{dataIndex:r,removeOpt:o,cb:function(){i.removeTextContent()}})}else i.removeTextContent();vh(i,{style:{opacity:0},scaleX:0,scaleY:0},e,{dataIndex:r,cb:t,removeOpt:o})},e.getSymbolSize=function(t,e){return Hy(t.getItemVisual(e,"symbolSize"))},e}(zr);function aS(t,e){this.parent.drift(t,e)}function sS(t,e,n,i){return e&&!isNaN(e[0])&&!isNaN(e[1])&&!(i.isIgnore&&i.isIgnore(n))&&!(i.clipShape&&!i.clipShape.contain(e[0],e[1]))&&"none"!==t.getItemVisual(n,"symbol")}function lS(t){return null==t||q(t)||(t={isIgnore:t}),t||{}}function uS(t){var e=t.hostModel,n=e.getModel("emphasis");return{emphasisItemStyle:n.getModel("itemStyle").getItemStyle(),blurItemStyle:e.getModel(["blur","itemStyle"]).getItemStyle(),selectItemStyle:e.getModel(["select","itemStyle"]).getItemStyle(),focus:n.get("focus"),blurScope:n.get("blurScope"),emphasisDisabled:n.get("disabled"),hoverScale:n.get("scale"),labelStatesModels:ec(e),cursorStyle:e.get("cursor")}}var hS=function(){function t(t){this.group=new zr,this._SymbolCtor=t||oS}return t.prototype.updateData=function(t,e){this._progressiveEls=null,e=lS(e);var n=this.group,i=t.hostModel,r=this._data,o=this._SymbolCtor,a=e.disableAnimation,s=uS(t),l={disableAnimation:a},u=e.getSymbolPoint||function(e){return t.getItemLayout(e)};r||n.removeAll(),t.diff(r).add((function(i){var r=u(i);if(sS(t,r,i,e)){var a=new o(t,i,s,l);a.setPosition(r),t.setItemGraphicEl(i,a),n.add(a)}})).update((function(h,c){var p=r.getItemGraphicEl(c),d=u(h);if(sS(t,d,h,e)){var f=t.getItemVisual(h,"symbol")||"circle",g=p&&p.getSymbolType&&p.getSymbolType();if(!p||g&&g!==f)n.remove(p),(p=new o(t,h,s,l)).setPosition(d);else{p.updateData(t,h,s,l);var y={x:d[0],y:d[1]};a?p.attr(y):fh(p,y,i)}n.add(p),t.setItemGraphicEl(h,p)}else n.remove(p)})).remove((function(t){var e=r.getItemGraphicEl(t);e&&e.fadeOut((function(){n.remove(e)}),i)})).execute(),this._getSymbolPoint=u,this._data=t},t.prototype.updateLayout=function(){var t=this,e=this._data;e&&e.eachItemGraphicEl((function(e,n){var i=t._getSymbolPoint(n);e.setPosition(i),e.markRedraw()}))},t.prototype.incrementalPrepareUpdate=function(t){this._seriesScope=uS(t),this._data=null,this.group.removeAll()},t.prototype.incrementalUpdate=function(t,e,n){function i(t){t.isGroup||(t.incremental=!0,t.ensureState("emphasis").hoverLayer=!0)}this._progressiveEls=[],n=lS(n);for(var r=t.start;r0?n=i[0]:i[1]<0&&(n=i[1]);return n}(r,n),a=i.dim,s=r.dim,l=e.mapDimension(s),u=e.mapDimension(a),h="x"===s||"radius"===s?1:0,c=z(t.dimensions,(function(t){return e.mapDimension(t)})),p=!1,d=e.getCalculationInfo("stackResultDimension");return gx(e,c[0])&&(p=!0,c[0]=d),gx(e,c[1])&&(p=!0,c[1]=d),{dataDimsForPoint:c,valueStart:o,valueAxisDim:s,baseAxisDim:a,stacked:!!p,valueDim:l,baseDim:u,baseDataOffset:h,stackedOverDimension:e.getCalculationInfo("stackedOverDimension")}}function pS(t,e,n,i){var r=NaN;t.stacked&&(r=n.get(n.getCalculationInfo("stackedOverDimension"),i)),isNaN(r)&&(r=t.valueStart);var o=t.baseDataOffset,a=[];return a[o]=n.get(t.baseDim,i),a[1-o]=r,e.dataToPoint(a)}var dS=Math.min,fS=Math.max;function gS(t,e){return isNaN(t)||isNaN(e)}function yS(t,e,n,i,r,o,a,s,l){for(var u,h,c,p,d,f,g=n,y=0;y=r||g<0)break;if(gS(v,m)){if(l){g+=o;continue}break}if(g===n)t[o>0?"moveTo":"lineTo"](v,m),c=v,p=m;else{var x=v-u,_=m-h;if(x*x+_*_<.5){g+=o;continue}if(a>0){for(var b=g+o,w=e[2*b],S=e[2*b+1];w===v&&S===m&&y=i||gS(w,S))d=v,f=m;else{T=w-u,C=S-h;var k=v-u,L=w-v,P=m-h,O=S-m,R=void 0,N=void 0;if("x"===s){var E=T>0?1:-1;d=v-E*(R=Math.abs(k))*a,f=m,D=v+E*(N=Math.abs(L))*a,A=m}else if("y"===s){var z=C>0?1:-1;d=v,f=m-z*(R=Math.abs(P))*a,D=v,A=m+z*(N=Math.abs(O))*a}else R=Math.sqrt(k*k+P*P),d=v-T*a*(1-(I=(N=Math.sqrt(L*L+O*O))/(N+R))),f=m-C*a*(1-I),A=m+C*a*I,D=dS(D=v+T*a*I,fS(w,v)),A=dS(A,fS(S,m)),D=fS(D,dS(w,v)),f=m-(C=(A=fS(A,dS(S,m)))-m)*R/N,d=dS(d=v-(T=D-v)*R/N,fS(u,v)),f=dS(f,fS(h,m)),D=v+(T=v-(d=fS(d,dS(u,v))))*N/R,A=m+(C=m-(f=fS(f,dS(h,m))))*N/R}t.bezierCurveTo(c,p,d,f,v,m),c=D,p=A}else t.lineTo(v,m)}u=v,h=m,g+=o}return y}var vS=function(){this.smooth=0,this.smoothConstraint=!0},mS=function(t){function e(e){var n=t.call(this,e)||this;return n.type="ec-polyline",n}return n(e,t),e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new vS},e.prototype.buildPath=function(t,e){var n=e.points,i=0,r=n.length/2;if(e.connectNulls){for(;r>0&&gS(n[2*r-2],n[2*r-1]);r--);for(;i=0){var y=a?(h-i)*g+i:(u-n)*g+n;return a?[t,y]:[y,t]}n=u,i=h;break;case o.C:u=r[l++],h=r[l++],c=r[l++],p=r[l++],d=r[l++],f=r[l++];var v=a?_n(n,u,c,d,t,s):_n(i,h,p,f,t,s);if(v>0)for(var m=0;m=0){y=a?mn(i,h,p,f,x):mn(n,u,c,d,x);return a?[t,y]:[y,t]}}n=d,i=f}}},e}(Is),xS=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return n(e,t),e}(vS),_S=function(t){function e(e){var n=t.call(this,e)||this;return n.type="ec-polygon",n}return n(e,t),e.prototype.getDefaultShape=function(){return new xS},e.prototype.buildPath=function(t,e){var n=e.points,i=e.stackedOnPoints,r=0,o=n.length/2,a=e.smoothMonotone;if(e.connectNulls){for(;o>0&&gS(n[2*o-2],n[2*o-1]);o--);for(;r=0;a--){var s=t.getDimensionInfo(i[a].dimension);if("x"===(r=s&&s.coordDim)||"y"===r){o=i[a];break}}if(o){var l=e.getAxis(r),u=z(o.stops,(function(t){return{coord:l.toGlobalCoord(l.dataToCoord(t.value)),color:t.color}})),h=u.length,c=o.outerColors.slice();h&&u[0].coord>u[h-1].coord&&(u.reverse(),c.reverse());var p=function(t,e){var n,i,r=[],o=t.length;function a(t,e,n){var i=t.coord;return{coord:n,color:ti((n-i)/(e.coord-i),[t.color,e.color])}}for(var s=0;se){i?r.push(a(i,l,e)):n&&r.push(a(n,l,0),a(n,l,e));break}n&&(r.push(a(n,l,0)),n=null),r.push(l),i=l}}return r}(u,"x"===r?n.getWidth():n.getHeight()),d=p.length;if(!d&&h)return u[0].coord<0?c[1]?c[1]:u[h-1].color:c[0]?c[0]:u[0].color;var f=p[0].coord-10,g=p[d-1].coord+10,y=g-f;if(y<.001)return"transparent";E(p,(function(t){t.offset=(t.coord-f)/y})),p.push({offset:d?p[d-1].offset:.5,color:c[1]||"transparent"}),p.unshift({offset:d?p[0].offset:.5,color:c[0]||"transparent"});var v=new nh(0,0,0,0,p,!0);return v[r]=f,v[r+"2"]=g,v}}}function LS(t,e,n){var i=t.get("showAllSymbol"),r="auto"===i;if(!i||r){var o=n.getAxesByScale("ordinal")[0];if(o&&(!r||!function(t,e){var n=t.getExtent(),i=Math.abs(n[1]-n[0])/t.scale.count();isNaN(i)&&(i=0);for(var r=e.count(),o=Math.max(1,Math.round(r/5)),a=0;ai)return!1;return!0}(o,e))){var a=e.mapDimension(o.dim),s={};return E(o.getViewLabels(),(function(t){var e=o.scale.getRawOrdinalNumber(t.tickValue);s[e]=1})),function(t){return!s.hasOwnProperty(e.get(a,t))}}}}function PS(t,e){return[t[2*e],t[2*e+1]]}function OS(t){if(t.get(["endLabel","show"]))return!0;for(var e=0;e0&&"bolder"===t.get(["emphasis","lineStyle","width"]))&&(d.getState("emphasis").style.lineWidth=+d.style.lineWidth+1);Qs(d).seriesIndex=t.seriesIndex,Yl(d,L,P,O);var R=DS(t.get("smooth")),N=t.get("smoothMonotone");if(d.setShape({smooth:R,smoothMonotone:N,connectNulls:w}),f){var E=a.getCalculationInfo("stackedOnSeries"),z=0;f.useStyle(k(l.getAreaStyle(),{fill:C,opacity:.7,lineJoin:"bevel",decal:a.getVisual("style").decal})),E&&(z=DS(E.get("smooth"))),f.setShape({smooth:R,stackedOnSmooth:z,smoothMonotone:N,connectNulls:w}),jl(f,t,"areaStyle"),Qs(f).seriesIndex=t.seriesIndex,Yl(f,L,P,O)}var V=function(t){i._changePolyState(t)};a.eachItemGraphicEl((function(t){t&&(t.onHoverStateChange=V)})),this._polyline.onHoverStateChange=V,this._data=a,this._coordSys=r,this._stackedOnPoints=_,this._points=u,this._step=T,this._valueOrigin=m,t.get("triggerLineEvent")&&(this.packEventData(t,d),f&&this.packEventData(t,f))},e.prototype.packEventData=function(t,e){Qs(e).eventData={componentType:"series",componentSubType:"line",componentIndex:t.componentIndex,seriesIndex:t.seriesIndex,seriesName:t.name,seriesType:"line"}},e.prototype.highlight=function(t,e,n,i){var r=t.getData(),o=Po(r,i);if(this._changePolyState("emphasis"),!(o instanceof Array)&&null!=o&&o>=0){var a=r.getLayout("points"),s=r.getItemGraphicEl(o);if(!s){var l=a[2*o],u=a[2*o+1];if(isNaN(l)||isNaN(u))return;if(this._clipShapeForSymbol&&!this._clipShapeForSymbol.contain(l,u))return;var h=t.get("zlevel")||0,c=t.get("z")||0;(s=new oS(r,o)).x=l,s.y=u,s.setZ(h,c);var p=s.getSymbolPath().getTextContent();p&&(p.zlevel=h,p.z=c,p.z2=this._polyline.z2+1),s.__temp=!0,r.setItemGraphicEl(o,s),s.stopSymbolAnimation(!0),this.group.add(s)}s.highlight()}else kg.prototype.highlight.call(this,t,e,n,i)},e.prototype.downplay=function(t,e,n,i){var r=t.getData(),o=Po(r,i);if(this._changePolyState("normal"),null!=o&&o>=0){var a=r.getItemGraphicEl(o);a&&(a.__temp?(r.setItemGraphicEl(o,null),this.group.remove(a)):a.downplay())}else kg.prototype.downplay.call(this,t,e,n,i)},e.prototype._changePolyState=function(t){var e=this._polygon;Il(this._polyline,t),e&&Il(e,t)},e.prototype._newPolyline=function(t){var e=this._polyline;return e&&this._lineGroup.remove(e),e=new mS({shape:{points:t},segmentIgnoreThreshold:2,z2:10}),this._lineGroup.add(e),this._polyline=e,e},e.prototype._newPolygon=function(t,e){var n=this._polygon;return n&&this._lineGroup.remove(n),n=new _S({shape:{points:t,stackedOnPoints:e},segmentIgnoreThreshold:2}),this._lineGroup.add(n),this._polygon=n,n},e.prototype._initSymbolLabelAnimation=function(t,e,n){var i,r,o=e.getBaseAxis(),a=o.inverse;"cartesian2d"===e.type?(i=o.isHorizontal(),r=!1):"polar"===e.type&&(i="angle"===o.dim,r=!0);var s=t.hostModel,l=s.get("animationDuration");X(l)&&(l=l(null));var u=s.get("animationDelay")||0,h=X(u)?u(null):u;t.eachItemGraphicEl((function(t,o){var s=t;if(s){var c=[t.x,t.y],p=void 0,d=void 0,f=void 0;if(n)if(r){var g=n,y=e.pointToCoord(c);i?(p=g.startAngle,d=g.endAngle,f=-y[1]/180*Math.PI):(p=g.r0,d=g.r,f=y[0])}else{var v=n;i?(p=v.x,d=v.x+v.width,f=t.x):(p=v.y+v.height,d=v.y,f=t.y)}var m=d===p?0:(f-p)/(d-p);a&&(m=1-m);var x=X(u)?u(o):l*m+h,_=s.getSymbolPath(),b=_.getTextContent();s.attr({scaleX:0,scaleY:0}),s.animateTo({scaleX:1,scaleY:1},{duration:200,setToFinal:!0,delay:x}),b&&b.animateFrom({style:{opacity:0}},{duration:300,delay:x}),_.disableLabelAnimation=!0}}))},e.prototype._initOrUpdateEndLabel=function(t,e,n){var i=t.getModel("endLabel");if(OS(t)){var r=t.getData(),o=this._polyline,a=r.getLayout("points");if(!a)return o.removeTextContent(),void(this._endLabel=null);var s=this._endLabel;s||((s=this._endLabel=new Fs({z2:200})).ignoreClip=!0,o.setTextContent(this._endLabel),o.disableLabelAnimation=!0);var l=function(t){for(var e,n,i=t.length/2;i>0&&(e=t[2*i-2],n=t[2*i-1],isNaN(e)||isNaN(n));i--);return i-1}(a);l>=0&&(tc(o,ec(t,"endLabel"),{inheritColor:n,labelFetcher:t,labelDataIndex:l,defaultText:function(t,e,n){return null!=n?rS(r,n):iS(r,t)},enableTextSetter:!0},function(t,e){var n=e.getBaseAxis(),i=n.isHorizontal(),r=n.inverse,o=i?r?"right":"left":"center",a=i?"middle":r?"top":"bottom";return{normal:{align:t.get("align")||o,verticalAlign:t.get("verticalAlign")||a}}}(i,e)),o.textConfig.position=null)}else this._endLabel&&(this._polyline.removeTextContent(),this._endLabel=null)},e.prototype._endLabelOnDuring=function(t,e,n,i,r,o,a){var s=this._endLabel,l=this._polyline;if(s){t<1&&null==i.originalX&&(i.originalX=s.x,i.originalY=s.y);var u=n.getLayout("points"),h=n.hostModel,c=h.get("connectNulls"),p=o.get("precision"),d=o.get("distance")||0,f=a.getBaseAxis(),g=f.isHorizontal(),y=f.inverse,v=e.shape,m=y?g?v.x:v.y+v.height:g?v.x+v.width:v.y,x=(g?d:0)*(y?-1:1),_=(g?0:-d)*(y?-1:1),b=g?"x":"y",w=function(t,e,n){for(var i,r,o=t.length/2,a="x"===n?0:1,s=0,l=-1,u=0;u=e||i>=e&&r<=e){l=u;break}s=u,i=r}else i=r;return{range:[s,l],t:(e-i)/(r-i)}}(u,m,b),S=w.range,M=S[1]-S[0],I=void 0;if(M>=1){if(M>1&&!c){var T=PS(u,S[0]);s.attr({x:T[0]+x,y:T[1]+_}),r&&(I=h.getRawValue(S[0]))}else{(T=l.getPointOn(m,b))&&s.attr({x:T[0]+x,y:T[1]+_});var C=h.getRawValue(S[0]),D=h.getRawValue(S[1]);r&&(I=Wo(n,p,C,D,w.t))}i.lastFrameIndex=S[0]}else{var A=1===t||i.lastFrameIndex>0?S[0]:0;T=PS(u,A);r&&(I=h.getRawValue(A)),s.attr({x:T[0]+x,y:T[1]+_})}if(r){var k=uc(s);"function"==typeof k.setLabelText&&k.setLabelText(I)}}},e.prototype._doUpdateAnimation=function(t,e,n,i,r,o,a){var s=this._polyline,l=this._polygon,u=t.hostModel,h=function(t,e,n,i,r,o,a,s){for(var l=function(t,e){var n=[];return e.diff(t).add((function(t){n.push({cmd:"+",idx:t})})).update((function(t,e){n.push({cmd:"=",idx:e,idx1:t})})).remove((function(t){n.push({cmd:"-",idx:t})})).execute(),n}(t,e),u=[],h=[],c=[],p=[],d=[],f=[],g=[],y=cS(r,e,a),v=t.getLayout("points")||[],m=e.getLayout("points")||[],x=0;x3e3||l&&CS(p,f)>3e3)return s.stopAnimation(),s.setShape({points:d}),void(l&&(l.stopAnimation(),l.setShape({points:d,stackedOnPoints:f})));s.shape.__points=h.current,s.shape.points=c;var g={shape:{points:d}};h.current!==c&&(g.shape.__points=h.next),s.stopAnimation(),fh(s,g,u),l&&(l.setShape({points:c,stackedOnPoints:p}),l.stopAnimation(),fh(l,{shape:{stackedOnPoints:f}},u),s.shape.points!==l.shape.points&&(l.shape.points=s.shape.points));for(var y=[],v=h.status,m=0;me&&(e=t[n]);return isFinite(e)?e:NaN},min:function(t){for(var e=1/0,n=0;n10&&"cartesian2d"===o.type&&r){var s=o.getBaseAxis(),l=o.getOtherAxis(s),u=s.getExtent(),h=n.getDevicePixelRatio(),c=Math.abs(u[1]-u[0])*(h||1),p=Math.round(a/c);if(isFinite(p)&&p>1){"lttb"===r&&t.setData(i.lttbDownSample(i.mapDimension(l.dim),1/p));var d=void 0;U(r)?d=zS[r]:X(r)&&(d=r),d&&t.setData(i.downSample(i.mapDimension(l.dim),1/p,d,VS))}}}}}var FS=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.prototype.getInitialData=function(t,e){return vx(null,this,{useEncodeDefaulter:!0})},e.prototype.getMarkerPosition=function(t,e,n){var i=this.coordinateSystem;if(i&&i.clampData){var r=i.clampData(t),o=i.dataToPoint(r);if(n)E(i.getAxes(),(function(t,n){if("category"===t.type&&null!=e){var i=t.getTicksCoords(),a=r[n],s="x1"===e[n]||"y1"===e[n];if(s&&(a+=1),i.length<2)return;if(2===i.length)return void(o[n]=t.toGlobalCoord(t.getExtent()[s?1:0]));for(var l=void 0,u=void 0,h=1,c=0;ca){u=(p+l)/2;break}1===c&&(h=d-i[0].tickValue)}null==u&&(l?l&&(u=i[i.length-1].coord):u=i[0].coord),o[n]=t.toGlobalCoord(u)}}));else{var a=this.getData(),s=a.getLayout("offset"),l=a.getLayout("size"),u=i.getBaseAxis().isHorizontal()?0:1;o[u]+=s+l/2}return o}return[NaN,NaN]},e.type="series.__base_bar__",e.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,barMinHeight:0,barMinAngle:0,large:!1,largeThreshold:400,progressive:3e3,progressiveChunkMode:"mod"},e}(mg);mg.registerClass(FS);var GS=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.prototype.getInitialData=function(){return vx(null,this,{useEncodeDefaulter:!0,createInvertedIndices:!!this.get("realtimeSort",!0)||null})},e.prototype.getProgressive=function(){return!!this.get("large")&&this.get("progressive")},e.prototype.getProgressiveThreshold=function(){var t=this.get("progressiveThreshold"),e=this.get("largeThreshold");return e>t&&(t=e),t},e.prototype.brushSelector=function(t,e,n){return n.rect(e.getItemLayout(t))},e.type="series.bar",e.dependencies=["grid","polar"],e.defaultOption=Cc(FS.defaultOption,{clip:!0,roundCap:!1,showBackground:!1,backgroundStyle:{color:"rgba(180, 180, 180, 0.2)",borderColor:null,borderWidth:0,borderType:"solid",borderRadius:0,shadowBlur:0,shadowColor:null,shadowOffsetX:0,shadowOffsetY:0,opacity:1},select:{itemStyle:{borderColor:"#212121"}},realtimeSort:!1}),e}(FS),WS=function(){this.cx=0,this.cy=0,this.r0=0,this.r=0,this.startAngle=0,this.endAngle=2*Math.PI,this.clockwise=!0},HS=function(t){function e(e){var n=t.call(this,e)||this;return n.type="sausage",n}return n(e,t),e.prototype.getDefaultShape=function(){return new WS},e.prototype.buildPath=function(t,e){var n=e.cx,i=e.cy,r=Math.max(e.r0||0,0),o=Math.max(e.r,0),a=.5*(o-r),s=r+a,l=e.startAngle,u=e.endAngle,h=e.clockwise,c=2*Math.PI,p=h?u-lo)return!0;o=u}return!1},e.prototype._isOrderDifferentInView=function(t,e){for(var n=e.scale,i=n.getExtent(),r=Math.max(0,i[0]),o=Math.min(i[1],n.getOrdinalMeta().categories.length-1);r<=o;++r)if(t.ordinalNumbers[r]!==n.getRawOrdinalNumber(r))return!0},e.prototype._updateSortWithinSameData=function(t,e,n,i){if(this._isOrderChangedWithinSameData(t,e,n)){var r=this._dataSort(t,n,e);this._isOrderDifferentInView(r,n)&&(this._removeOnRenderedListener(i),i.dispatchAction({type:"changeAxisOrder",componentType:n.dim+"Axis",axisId:n.index,sortInfo:r}))}},e.prototype._dispatchInitSort=function(t,e,n){var i=e.baseAxis,r=this._dataSort(t,i,(function(n){return t.get(t.mapDimension(e.otherAxis.dim),n)}));n.dispatchAction({type:"changeAxisOrder",componentType:i.dim+"Axis",isInitSort:!0,axisId:i.index,sortInfo:r})},e.prototype.remove=function(t,e){this._clear(this._model),this._removeOnRenderedListener(e)},e.prototype.dispose=function(t,e){this._removeOnRenderedListener(e)},e.prototype._removeOnRenderedListener=function(t){this._onRendered&&(t.getZr().off("rendered",this._onRendered),this._onRendered=null)},e.prototype._clear=function(t){var e=this.group,n=this._data;t&&t.isAnimationEnabled()&&n&&!this._isLargeDraw?(this._removeBackground(),this._backgroundEls=[],n.eachItemGraphicEl((function(e){xh(e,t,Qs(e).dataIndex)}))):e.removeAll(),this._data=null,this._isFirstFrame=!0},e.prototype._removeBackground=function(){this.group.remove(this._backgroundGroup),this._backgroundGroup=null},e.type="bar",e}(kg),KS={cartesian2d:function(t,e){var n=e.width<0?-1:1,i=e.height<0?-1:1;n<0&&(e.x+=e.width,e.width=-e.width),i<0&&(e.y+=e.height,e.height=-e.height);var r=t.x+t.width,o=t.y+t.height,a=ZS(e.x,t.x),s=jS(e.x+e.width,r),l=ZS(e.y,t.y),u=jS(e.y+e.height,o),h=sr?s:a,e.y=c&&l>o?u:l,e.width=h?0:s-a,e.height=c?0:u-l,n<0&&(e.x+=e.width,e.width=-e.width),i<0&&(e.y+=e.height,e.height=-e.height),h||c},polar:function(t,e){var n=e.r0<=e.r?1:-1;if(n<0){var i=e.r;e.r=e.r0,e.r0=i}var r=jS(e.r,t.r),o=ZS(e.r0,t.r0);e.r=r,e.r0=o;var a=r-o<0;if(n<0){i=e.r;e.r=e.r0,e.r0=i}return a}},$S={cartesian2d:function(t,e,n,i,r,o,a,s,l){var u=new zs({shape:A({},i),z2:1});(u.__dataIndex=n,u.name="item",o)&&(u.shape[r?"height":"width"]=0);return u},polar:function(t,e,n,i,r,o,a,s,l){var u=!r&&l?HS:zu,h=new u({shape:i,z2:1});h.name="item";var c,p,d=rM(r);if(h.calculateTextPosition=(c=d,p=({isRoundCap:u===HS}||{}).isRoundCap,function(t,e,n){var i=e.position;if(!i||i instanceof Array)return Tr(t,e,n);var r=c(i),o=null!=e.distance?e.distance:5,a=this.shape,s=a.cx,l=a.cy,u=a.r,h=a.r0,d=(u+h)/2,f=a.startAngle,g=a.endAngle,y=(f+g)/2,v=p?Math.abs(u-h)/2:0,m=Math.cos,x=Math.sin,_=s+u*m(f),b=l+u*x(f),w="left",S="top";switch(r){case"startArc":_=s+(h-o)*m(y),b=l+(h-o)*x(y),w="center",S="top";break;case"insideStartArc":_=s+(h+o)*m(y),b=l+(h+o)*x(y),w="center",S="bottom";break;case"startAngle":_=s+d*m(f)+YS(f,o+v,!1),b=l+d*x(f)+XS(f,o+v,!1),w="right",S="middle";break;case"insideStartAngle":_=s+d*m(f)+YS(f,-o+v,!1),b=l+d*x(f)+XS(f,-o+v,!1),w="left",S="middle";break;case"middle":_=s+d*m(y),b=l+d*x(y),w="center",S="middle";break;case"endArc":_=s+(u+o)*m(y),b=l+(u+o)*x(y),w="center",S="bottom";break;case"insideEndArc":_=s+(u-o)*m(y),b=l+(u-o)*x(y),w="center",S="top";break;case"endAngle":_=s+d*m(g)+YS(g,o+v,!0),b=l+d*x(g)+XS(g,o+v,!0),w="left",S="middle";break;case"insideEndAngle":_=s+d*m(g)+YS(g,-o+v,!0),b=l+d*x(g)+XS(g,-o+v,!0),w="right",S="middle";break;default:return Tr(t,e,n)}return(t=t||{}).x=_,t.y=b,t.align=w,t.verticalAlign=S,t}),o){var f=r?"r":"endAngle",g={};h.shape[f]=r?i.r0:i.startAngle,g[f]=i[f],(s?fh:gh)(h,{shape:g},o)}return h}};function JS(t,e,n,i,r,o,a,s){var l,u;o?(u={x:i.x,width:i.width},l={y:i.y,height:i.height}):(u={y:i.y,height:i.height},l={x:i.x,width:i.width}),s||(a?fh:gh)(n,{shape:l},e,r,null),(a?fh:gh)(n,{shape:u},e?t.baseAxis.model:null,r)}function QS(t,e){for(var n=0;n0?1:-1,a=i.height>0?1:-1;return{x:i.x+o*r/2,y:i.y+a*r/2,width:i.width-o*r,height:i.height-a*r}},polar:function(t,e,n){var i=t.getItemLayout(e);return{cx:i.cx,cy:i.cy,r0:i.r0,r:i.r,startAngle:i.startAngle,endAngle:i.endAngle,clockwise:i.clockwise}}};function rM(t){return function(t){var e=t?"Arc":"Angle";return function(t){switch(t){case"start":case"insideStart":case"end":case"insideEnd":return t+e;default:return t}}}(t)}function oM(t,e,n,i,r,o,a,s){var l=e.getItemVisual(n,"style");if(s){if(!o.get("roundCap")){var u=t.shape;A(u,US(i.getModel("itemStyle"),u,!0)),t.setShape(u)}}else{var h=i.get(["itemStyle","borderRadius"])||0;t.setShape("r",h)}t.useStyle(l);var c=i.getShallow("cursor");c&&t.attr("cursor",c);var p=s?a?r.r>=r.r0?"endArc":"startArc":r.endAngle>=r.startAngle?"endAngle":"startAngle":a?r.height>=0?"bottom":"top":r.width>=0?"right":"left",d=ec(i);tc(t,d,{labelFetcher:o,labelDataIndex:n,defaultText:iS(o.getData(),n),inheritColor:l.fill,defaultOpacity:l.opacity,defaultOutsidePosition:p});var f=t.getTextContent();if(s&&f){var g=i.get(["label","position"]);t.textConfig.inside="middle"===g||null,function(t,e,n,i){if(j(i))t.setTextConfig({rotation:i});else if(Y(e))t.setTextConfig({rotation:0});else{var r,o=t.shape,a=o.clockwise?o.startAngle:o.endAngle,s=o.clockwise?o.endAngle:o.startAngle,l=(a+s)/2,u=n(e);switch(u){case"startArc":case"insideStartArc":case"middle":case"insideEndArc":case"endArc":r=l;break;case"startAngle":case"insideStartAngle":r=a;break;case"endAngle":case"insideEndAngle":r=s;break;default:return void t.setTextConfig({rotation:0})}var h=1.5*Math.PI-r;"middle"===u&&h>Math.PI/2&&h<1.5*Math.PI&&(h-=Math.PI),t.setTextConfig({rotation:h})}}(t,"outside"===g?p:g,rM(a),i.get(["label","rotate"]))}hc(f,d,o.getRawValue(n),(function(t){return rS(e,t)}));var y=i.getModel(["emphasis"]);Yl(t,y.get("focus"),y.get("blurScope"),y.get("disabled")),jl(t,i),function(t){return null!=t.startAngle&&null!=t.endAngle&&t.startAngle===t.endAngle}(r)&&(t.style.fill="none",t.style.stroke="none",E(t.states,(function(t){t.style&&(t.style.fill=t.style.stroke="none")})))}var aM=function(){},sM=function(t){function e(e){var n=t.call(this,e)||this;return n.type="largeBar",n}return n(e,t),e.prototype.getDefaultShape=function(){return new aM},e.prototype.buildPath=function(t,e){for(var n=e.points,i=this.baseDimIdx,r=1-this.baseDimIdx,o=[],a=[],s=this.barWidth,l=0;l=s[0]&&e<=s[0]+l[0]&&n>=s[1]&&n<=s[1]+l[1])return a[h]}return-1}(this,t.offsetX,t.offsetY);Qs(this).dataIndex=e>=0?e:null}),30,!1);function hM(t,e,n){if(MS(n,"cartesian2d")){var i=e,r=n.getArea();return{x:t?i.x:r.x,y:t?r.y:i.y,width:t?i.width:r.width,height:t?r.height:i.height}}var o=e;return{cx:(r=n.getArea()).cx,cy:r.cy,r0:t?r.r0:o.r0,r:t?r.r:o.r,startAngle:t?o.startAngle:0,endAngle:t?o.endAngle:2*Math.PI}}var cM=2*Math.PI,pM=Math.PI/180;function dM(t,e){return Cp(t.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}function fM(t,e){var n=dM(t,e),i=t.get("center"),r=t.get("radius");Y(r)||(r=[0,r]);var o,a,s=Ur(n.width,e.getWidth()),l=Ur(n.height,e.getHeight()),u=Math.min(s,l),h=Ur(r[0],u/2),c=Ur(r[1],u/2),p=t.coordinateSystem;if(p){var d=p.dataToPoint(i);o=d[0]||0,a=d[1]||0}else Y(i)||(i=[i,i]),o=Ur(i[0],s)+n.x,a=Ur(i[1],l)+n.y;return{cx:o,cy:a,r0:h,r:c}}function gM(t,e,n){e.eachSeriesByType(t,(function(t){var e=t.getData(),i=e.mapDimension("value"),r=dM(t,n),o=fM(t,n),a=o.cx,s=o.cy,l=o.r,u=o.r0,h=-t.get("startAngle")*pM,c=t.get("minAngle")*pM,p=0;e.each(i,(function(t){!isNaN(t)&&p++}));var d=e.getSum(i),f=Math.PI/(d||p)*2,g=t.get("clockwise"),y=t.get("roseType"),v=t.get("stillShowZeroSum"),m=e.getDataExtent(i);m[0]=0;var x=cM,_=0,b=h,w=g?1:-1;if(e.setLayout({viewRect:r,r:l}),e.each(i,(function(t,n){var i;if(isNaN(t))e.setItemLayout(n,{angle:NaN,startAngle:NaN,endAngle:NaN,clockwise:g,cx:a,cy:s,r0:u,r:y?NaN:l});else{(i="area"!==y?0===d&&v?f:t*f:cM/p)n?a:o,h=Math.abs(l.label.y-n);if(h>=u.maxY){var c=l.label.x-e-l.len2*r,p=i+l.len,f=Math.abs(c)t.unconstrainedWidth?null:d:null;i.setStyle("width",f)}var g=i.getBoundingRect();o.width=g.width;var y=(i.style.margin||0)+2.1;o.height=g.height+y,o.y-=(o.height-c)/2}}}function _M(t){return"center"===t.position}function bM(t){var e,n,i=t.getData(),r=[],o=!1,a=(t.get("minShowLabelAngle")||0)*vM,s=i.getLayout("viewRect"),l=i.getLayout("r"),u=s.width,h=s.x,c=s.y,p=s.height;function d(t){t.ignore=!0}i.each((function(t){var s=i.getItemGraphicEl(t),c=s.shape,p=s.getTextContent(),f=s.getTextGuideLine(),g=i.getItemModel(t),y=g.getModel("label"),v=y.get("position")||g.get(["emphasis","label","position"]),m=y.get("distanceToLabelLine"),x=y.get("alignTo"),_=Ur(y.get("edgeDistance"),u),b=y.get("bleedMargin"),w=g.getModel("labelLine"),S=w.get("length");S=Ur(S,u);var M=w.get("length2");if(M=Ur(M,u),Math.abs(c.endAngle-c.startAngle)0?"right":"left":k>0?"left":"right"}var B=Math.PI,F=0,G=y.get("rotate");if(j(G))F=G*(B/180);else if("center"===v)F=0;else if("radial"===G||!0===G){F=k<0?-A+B:-A}else if("tangential"===G&&"outside"!==v&&"outer"!==v){var W=Math.atan2(k,L);W<0&&(W=2*B+W),L>0&&(W=B+W),F=W-B}if(o=!!F,p.x=I,p.y=T,p.rotation=F,p.setStyle({verticalAlign:"middle"}),P){p.setStyle({align:D});var H=p.states.select;H&&(H.x+=p.x,H.y+=p.y)}else{var Y=p.getBoundingRect().clone();Y.applyTransform(p.getComputedTransform());var X=(p.style.margin||0)+2.1;Y.y-=X/2,Y.height+=X,r.push({label:p,labelLine:f,position:v,len:S,len2:M,minTurnAngle:w.get("minTurnAngle"),maxSurfaceAngle:w.get("maxSurfaceAngle"),surfaceNormal:new De(k,L),linePoints:C,textAlign:D,labelDistance:m,labelAlignTo:x,edgeDistance:_,bleedMargin:b,rect:Y,unconstrainedWidth:Y.width,labelStyleWidth:p.style.width})}s.setTextConfig({inside:P})}})),!o&&t.get("avoidLabelOverlap")&&function(t,e,n,i,r,o,a,s){for(var l=[],u=[],h=Number.MAX_VALUE,c=-Number.MAX_VALUE,p=0;p0){for(var l=o.getItemLayout(0),u=1;isNaN(l&&l.startAngle)&&u=n.r0}},e.type="pie",e}(kg);function MM(t,e,n){e=Y(e)&&{coordDimensions:e}||A({encodeDefine:t.getEncode()},e);var i=t.getSource(),r=ux(i,e).dimensions,o=new lx(r,t);return o.initData(i,n),o}var IM=function(){function t(t,e){this._getDataWithEncodedVisual=t,this._getRawData=e}return t.prototype.getAllNames=function(){var t=this._getRawData();return t.mapArray(t.getName)},t.prototype.containName=function(t){return this._getRawData().indexOfName(t)>=0},t.prototype.indexOfName=function(t){return this._getDataWithEncodedVisual().indexOfName(t)},t.prototype.getItemVisual=function(t,e){return this._getDataWithEncodedVisual().getItemVisual(t,e)},t}(),TM=Oo(),CM=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return n(e,t),e.prototype.init=function(e){t.prototype.init.apply(this,arguments),this.legendVisualProvider=new IM(W(this.getData,this),W(this.getRawData,this)),this._defaultLabelLine(e)},e.prototype.mergeOption=function(){t.prototype.mergeOption.apply(this,arguments)},e.prototype.getInitialData=function(){return MM(this,{coordDimensions:["value"],encodeDefaulter:H(Jp,this)})},e.prototype.getDataParams=function(e){var n=this.getData(),i=TM(n),r=i.seats;if(!r){var o=[];n.each(n.mapDimension("value"),(function(t){o.push(t)})),r=i.seats=Jr(o,n.hostModel.get("percentPrecision"))}var a=t.prototype.getDataParams.call(this,e);return a.percent=r[e]||0,a.$vars.push("percent"),a},e.prototype._defaultLabelLine=function(t){wo(t,"labelLine",["show"]);var e=t.labelLine,n=t.emphasis.labelLine;e.show=e.show&&t.label.show,n.show=n.show&&t.emphasis.label.show},e.type="series.pie",e.defaultOption={z:2,legendHoverLink:!0,colorBy:"data",center:["50%","50%"],radius:[0,"75%"],clockwise:!0,startAngle:90,minAngle:0,minShowLabelAngle:0,selectedOffset:10,percentPrecision:2,stillShowZeroSum:!0,left:0,top:0,right:0,bottom:0,width:null,height:null,label:{rotate:0,show:!0,overflow:"truncate",position:"outer",alignTo:"none",edgeDistance:"25%",bleedMargin:10,distanceToLabelLine:5},labelLine:{show:!0,length:15,length2:15,smooth:!1,minTurnAngle:90,maxSurfaceAngle:90,lineStyle:{width:1,type:"solid"}},itemStyle:{borderWidth:1,borderJoin:"round"},showEmptyCircle:!0,emptyCircleStyle:{color:"lightgray",opacity:1},labelLayout:{hideOverlap:!0},emphasis:{scale:!0,scaleSize:5},avoidLabelOverlap:!0,animationType:"expansion",animationDuration:1e3,animationTypeUpdate:"transition",animationEasingUpdate:"cubicInOut",animationDurationUpdate:500,animationEasing:"cubicInOut"},e}(mg);var DM=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.hasSymbolVisual=!0,n}return n(e,t),e.prototype.getInitialData=function(t,e){return vx(null,this,{useEncodeDefaulter:!0})},e.prototype.getProgressive=function(){var t=this.option.progressive;return null==t?this.option.large?5e3:this.get("progressive"):t},e.prototype.getProgressiveThreshold=function(){var t=this.option.progressiveThreshold;return null==t?this.option.large?1e4:this.get("progressiveThreshold"):t},e.prototype.brushSelector=function(t,e,n){return n.point(e.getItemLayout(t))},e.prototype.getZLevelKey=function(){return this.getData().count()>this.getProgressiveThreshold()?this.id:""},e.type="series.scatter",e.dependencies=["grid","polar","geo","singleAxis","calendar"],e.defaultOption={coordinateSystem:"cartesian2d",z:2,legendHoverLink:!0,symbolSize:10,large:!1,largeThreshold:2e3,itemStyle:{opacity:.8},emphasis:{scale:!0},clip:!0,select:{itemStyle:{borderColor:"#212121"}},universalTransition:{divideShape:"clone"}},e}(mg),AM=function(){},kM=function(t){function e(e){var n=t.call(this,e)||this;return n._off=0,n.hoverDataIdx=-1,n}return n(e,t),e.prototype.getDefaultShape=function(){return new AM},e.prototype.reset=function(){this.notClear=!1,this._off=0},e.prototype.buildPath=function(t,e){var n,i=e.points,r=e.size,o=this.symbolProxy,a=o.shape,s=t.getContext?t.getContext():t,l=s&&r[0]<4,u=this.softClipShape;if(l)this._ctx=s;else{for(this._ctx=null,n=this._off;n=0;s--){var l=2*s,u=i[l]-o/2,h=i[l+1]-a/2;if(t>=u&&e>=h&&t<=u+o&&e<=h+a)return s}return-1},e.prototype.contain=function(t,e){var n=this.transformCoordToLocal(t,e),i=this.getBoundingRect();return t=n[0],e=n[1],i.contain(t,e)?(this.hoverDataIdx=this.findDataIndex(t,e))>=0:(this.hoverDataIdx=-1,!1)},e.prototype.getBoundingRect=function(){var t=this._rect;if(!t){for(var e=this.shape,n=e.points,i=e.size,r=i[0],o=i[1],a=1/0,s=1/0,l=-1/0,u=-1/0,h=0;h=0&&(l.dataIndex=n+(t.startIndex||0))}))},t.prototype.remove=function(){this._clear()},t.prototype._clear=function(){this._newAdded=[],this.group.removeAll()},t}(),PM=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.prototype.render=function(t,e,n){var i=t.getData();this._updateSymbolDraw(i,t).updateData(i,{clipShape:this._getClipShape(t)}),this._finished=!0},e.prototype.incrementalPrepareRender=function(t,e,n){var i=t.getData();this._updateSymbolDraw(i,t).incrementalPrepareUpdate(i),this._finished=!1},e.prototype.incrementalRender=function(t,e,n){this._symbolDraw.incrementalUpdate(t,e.getData(),{clipShape:this._getClipShape(e)}),this._finished=t.end===e.getData().count()},e.prototype.updateTransform=function(t,e,n){var i=t.getData();if(this.group.dirty(),!this._finished||i.count()>1e4)return{update:!0};var r=ES("").reset(t,e,n);r.progress&&r.progress({start:0,end:i.count(),count:i.count()},i),this._symbolDraw.updateLayout(i)},e.prototype.eachRendered=function(t){this._symbolDraw&&this._symbolDraw.eachRendered(t)},e.prototype._getClipShape=function(t){var e=t.coordinateSystem,n=e&&e.getArea&&e.getArea();return t.get("clip",!0)?n:null},e.prototype._updateSymbolDraw=function(t,e){var n=this._symbolDraw,i=e.pipelineContext.large;return n&&i===this._isLargeDraw||(n&&n.remove(),n=this._symbolDraw=i?new LM:new hS,this._isLargeDraw=i,this.group.removeAll()),this.group.add(n.group),n},e.prototype.remove=function(t,e){this._symbolDraw&&this._symbolDraw.remove(!0),this._symbolDraw=null},e.prototype.dispose=function(){},e.type="scatter",e}(kg),OM=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return n(e,t),e.type="grid",e.dependencies=["xAxis","yAxis"],e.layoutMode="box",e.defaultOption={show:!1,z:0,left:"10%",top:60,right:"10%",bottom:70,containLabel:!1,backgroundColor:"rgba(0,0,0,0)",borderWidth:1,borderColor:"#ccc"},e}(Rp),RM=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return n(e,t),e.prototype.getCoordSysModel=function(){return this.getReferringComponents("grid",zo).models[0]},e.type="cartesian2dAxis",e}(Rp);R(RM,I_);var NM={show:!0,z:0,inverse:!1,name:"",nameLocation:"end",nameRotate:null,nameTruncate:{maxWidth:null,ellipsis:"...",placeholder:"."},nameTextStyle:{},nameGap:15,silent:!1,triggerEvent:!1,tooltip:{show:!1},axisPointer:{},axisLine:{show:!0,onZero:!0,onZeroAxisIndex:null,lineStyle:{color:"#6E7079",width:1,type:"solid"},symbol:["none","none"],symbolSize:[10,15]},axisTick:{show:!0,inside:!1,length:5,lineStyle:{width:1}},axisLabel:{show:!0,inside:!1,rotate:0,showMinLabel:null,showMaxLabel:null,margin:8,fontSize:12},splitLine:{show:!0,lineStyle:{color:["#E0E6F1"],width:1,type:"solid"}},splitArea:{show:!1,areaStyle:{color:["rgba(250,250,250,0.2)","rgba(210,219,238,0.2)"]}}},EM=C({boundaryGap:!0,deduplication:null,splitLine:{show:!1},axisTick:{alignWithLabel:!1,interval:"auto"},axisLabel:{interval:"auto"}},NM),zM=C({boundaryGap:[0,0],axisLine:{show:"auto"},axisTick:{show:"auto"},splitNumber:5,minorTick:{show:!1,splitNumber:5,length:3,lineStyle:{}},minorSplitLine:{show:!1,lineStyle:{color:"#F4F7FD",width:1}}},NM),VM={category:EM,value:zM,time:C({splitNumber:6,axisLabel:{showMinLabel:!1,showMaxLabel:!1,rich:{primary:{fontWeight:"bold"}}},splitLine:{show:!1}},zM),log:k({logBase:10},zM)},BM={value:1,category:1,time:1,log:1};function FM(t,e,i,r){E(BM,(function(o,a){var s=C(C({},VM[a],!0),r,!0),l=function(t){function i(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e+"Axis."+a,n}return n(i,t),i.prototype.mergeDefaultAndTheme=function(t,e){var n=Ap(this),i=n?Lp(t):{};C(t,e.getTheme().get(a+"Axis")),C(t,this.getDefaultOption()),t.type=GM(t),n&&kp(t,i,n)},i.prototype.optionUpdated=function(){"category"===this.option.type&&(this.__ordinalMeta=_x.createByAxisModel(this))},i.prototype.getCategories=function(t){var e=this.option;if("category"===e.type)return t?e.data:this.__ordinalMeta.categories},i.prototype.getOrdinalMeta=function(){return this.__ordinalMeta},i.type=e+"Axis."+a,i.defaultOption=s,i}(i);t.registerComponentModel(l)})),t.registerSubTypeDefaulter(e+"Axis",GM)}function GM(t){return t.type||(t.data?"category":"value")}var WM=function(){function t(t){this.type="cartesian",this._dimList=[],this._axes={},this.name=t||""}return t.prototype.getAxis=function(t){return this._axes[t]},t.prototype.getAxes=function(){return z(this._dimList,(function(t){return this._axes[t]}),this)},t.prototype.getAxesByScale=function(t){return t=t.toLowerCase(),B(this.getAxes(),(function(e){return e.scale.type===t}))},t.prototype.addAxis=function(t){var e=t.dim;this._axes[e]=t,this._dimList.push(e)},t}(),HM=["x","y"];function YM(t){return"interval"===t.type||"time"===t.type}var XM=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="cartesian2d",e.dimensions=HM,e}return n(e,t),e.prototype.calcAffineTransform=function(){this._transform=this._invTransform=null;var t=this.getAxis("x").scale,e=this.getAxis("y").scale;if(YM(t)&&YM(e)){var n=t.getExtent(),i=e.getExtent(),r=this.dataToPoint([n[0],i[0]]),o=this.dataToPoint([n[1],i[1]]),a=n[1]-n[0],s=i[1]-i[0];if(a&&s){var l=(o[0]-r[0])/a,u=(o[1]-r[1])/s,h=r[0]-n[0]*l,c=r[1]-i[0]*u,p=this._transform=[l,0,0,u,h,c];this._invTransform=Ie([],p)}}},e.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAxis("x")},e.prototype.containPoint=function(t){var e=this.getAxis("x"),n=this.getAxis("y");return e.contain(e.toLocalCoord(t[0]))&&n.contain(n.toLocalCoord(t[1]))},e.prototype.containData=function(t){return this.getAxis("x").containData(t[0])&&this.getAxis("y").containData(t[1])},e.prototype.containZone=function(t,e){var n=this.dataToPoint(t),i=this.dataToPoint(e),r=this.getArea(),o=new ze(n[0],n[1],i[0]-n[0],i[1]-n[1]);return r.intersect(o)},e.prototype.dataToPoint=function(t,e,n){n=n||[];var i=t[0],r=t[1];if(this._transform&&null!=i&&isFinite(i)&&null!=r&&isFinite(r))return Wt(n,t,this._transform);var o=this.getAxis("x"),a=this.getAxis("y");return n[0]=o.toGlobalCoord(o.dataToCoord(i,e)),n[1]=a.toGlobalCoord(a.dataToCoord(r,e)),n},e.prototype.clampData=function(t,e){var n=this.getAxis("x").scale,i=this.getAxis("y").scale,r=n.getExtent(),o=i.getExtent(),a=n.parse(t[0]),s=i.parse(t[1]);return(e=e||[])[0]=Math.min(Math.max(Math.min(r[0],r[1]),a),Math.max(r[0],r[1])),e[1]=Math.min(Math.max(Math.min(o[0],o[1]),s),Math.max(o[0],o[1])),e},e.prototype.pointToData=function(t,e){var n=[];if(this._invTransform)return Wt(n,t,this._invTransform);var i=this.getAxis("x"),r=this.getAxis("y");return n[0]=i.coordToData(i.toLocalCoord(t[0]),e),n[1]=r.coordToData(r.toLocalCoord(t[1]),e),n},e.prototype.getOtherAxis=function(t){return this.getAxis("x"===t.dim?"y":"x")},e.prototype.getArea=function(){var t=this.getAxis("x").getGlobalExtent(),e=this.getAxis("y").getGlobalExtent(),n=Math.min(t[0],t[1]),i=Math.min(e[0],e[1]),r=Math.max(t[0],t[1])-n,o=Math.max(e[0],e[1])-i;return new ze(n,i,r,o)},e}(WM),UM=function(t){function e(e,n,i,r,o){var a=t.call(this,e,n,i)||this;return a.index=0,a.type=r||"value",a.position=o||"bottom",a}return n(e,t),e.prototype.isHorizontal=function(){var t=this.position;return"top"===t||"bottom"===t},e.prototype.getGlobalExtent=function(t){var e=this.getExtent();return e[0]=this.toGlobalCoord(e[0]),e[1]=this.toGlobalCoord(e[1]),t&&e[0]>e[1]&&e.reverse(),e},e.prototype.pointToData=function(t,e){return this.coordToData(this.toLocalCoord(t["x"===this.dim?0:1]),e)},e.prototype.setCategorySortInfo=function(t){if("category"!==this.type)return!1;this.model.option.categorySortInfo=t,this.scale.setSortInfo(t)},e}(nb);function ZM(t,e,n){n=n||{};var i=t.coordinateSystem,r=e.axis,o={},a=r.getAxesOnZeroOf()[0],s=r.position,l=a?"onZero":s,u=r.dim,h=i.getRect(),c=[h.x,h.x+h.width,h.y,h.y+h.height],p={left:0,right:1,top:0,bottom:1,onZero:2},d=e.get("offset")||0,f="x"===u?[c[2]-d,c[3]+d]:[c[0]-d,c[1]+d];if(a){var g=a.toGlobalCoord(a.dataToCoord(0));f[p.onZero]=Math.max(Math.min(g,f[1]),f[0])}o.position=["y"===u?f[p[l]]:c[0],"x"===u?f[p[l]]:c[3]],o.rotation=Math.PI/2*("x"===u?0:1);o.labelDirection=o.tickDirection=o.nameDirection={top:-1,bottom:1,left:-1,right:1}[s],o.labelOffset=a?f[p[s]]-f[p.onZero]:0,e.get(["axisTick","inside"])&&(o.tickDirection=-o.tickDirection),it(n.labelInside,e.get(["axisLabel","inside"]))&&(o.labelDirection=-o.labelDirection);var y=e.get(["axisLabel","rotate"]);return o.labelRotate="top"===l?-y:y,o.z2=1,o}function jM(t){return"cartesian2d"===t.get("coordinateSystem")}function qM(t){var e={xAxisModel:null,yAxisModel:null};return E(e,(function(n,i){var r=i.replace(/Model$/,""),o=t.getReferringComponents(r,zo).models[0];e[i]=o})),e}var KM=Math.log;function $M(t,e,n){var i=Ox.prototype,r=i.getTicks.call(n),o=i.getTicks.call(n,!0),a=r.length-1,s=i.getInterval.call(n),l=y_(t,e),u=l.extent,h=l.fixMin,c=l.fixMax;if("log"===t.type){var p=KM(t.base);u=[KM(u[0])/p,KM(u[1])/p]}t.setExtent(u[0],u[1]),t.calcNiceExtent({splitNumber:a,fixMin:h,fixMax:c});var d=i.getExtent.call(t);h&&(u[0]=d[0]),c&&(u[1]=d[1]);var f=i.getInterval.call(t),g=u[0],y=u[1];if(h&&c)f=(y-g)/a;else if(h)for(y=u[0]+f*a;yu[0]&&isFinite(g)&&isFinite(u[0]);)f=Ix(f),g=u[1]-f*a;else{t.getTicks().length-1>a&&(f=Ix(f));var v=f*a;(g=Zr((y=Math.ceil(u[1]/f)*f)-v))<0&&u[0]>=0?(g=0,y=Zr(v)):y>0&&u[1]<=0&&(y=0,g=-Zr(v))}var m=(r[0].value-o[0].value)/s,x=(r[a].value-o[a].value)/s;i.setExtent.call(t,g+f*m,y+f*x),i.setInterval.call(t,f),(m||x)&&i.setNiceExtent.call(t,g+f,y-f)}var JM=function(){function t(t,e,n){this.type="grid",this._coordsMap={},this._coordsList=[],this._axesMap={},this._axesList=[],this.axisPointerEnabled=!0,this.dimensions=HM,this._initCartesian(t,e,n),this.model=t}return t.prototype.getRect=function(){return this._rect},t.prototype.update=function(t,e){var n=this._axesMap;function i(t){var e,n=G(t),i=n.length;if(i){for(var r=[],o=i-1;o>=0;o--){var a=t[+n[o]],s=a.model,l=a.scale;Sx(l)&&s.get("alignTicks")&&null==s.get("interval")?r.push(a):(v_(l,s),Sx(l)&&(e=a))}r.length&&(e||v_((e=r.pop()).scale,e.model),E(r,(function(t){$M(t.scale,t.model,e.scale)})))}}this._updateScale(t,this.model),i(n.x),i(n.y);var r={};E(n.x,(function(t){tI(n,"y",t,r)})),E(n.y,(function(t){tI(n,"x",t,r)})),this.resize(this.model,e)},t.prototype.resize=function(t,e,n){var i=t.getBoxLayoutParams(),r=!n&&t.get("containLabel"),o=Cp(i,{width:e.getWidth(),height:e.getHeight()});this._rect=o;var a=this._axesList;function s(){E(a,(function(t){var e=t.isHorizontal(),n=e?[0,o.width]:[0,o.height],i=t.inverse?1:0;t.setExtent(n[i],n[1-i]),function(t,e){var n=t.getExtent(),i=n[0]+n[1];t.toGlobalCoord="x"===t.dim?function(t){return t+e}:function(t){return i-t+e},t.toLocalCoord="x"===t.dim?function(t){return t-e}:function(t){return i-t+e}}(t,e?o.x:o.y)}))}s(),r&&(E(a,(function(t){if(!t.model.get(["axisLabel","inside"])){var e=function(t){var e=t.model,n=t.scale;if(e.get(["axisLabel","show"])&&!n.isBlank()){var i,r,o=n.getExtent();r=n instanceof Lx?n.count():(i=n.getTicks()).length;var a,s=t.getLabelModel(),l=x_(t),u=1;r>40&&(u=Math.ceil(r/40));for(var h=0;h0&&i>0||n<0&&i<0)}(t)}var nI=Math.PI,iI=function(){function t(t,e){this.group=new zr,this.opt=e,this.axisModel=t,k(e,{labelOffset:0,nameDirection:1,tickDirection:1,labelDirection:1,silent:!0,handleAutoShown:function(){return!0}});var n=new zr({x:e.position[0],y:e.position[1],rotation:e.rotation});n.updateTransform(),this._transformGroup=n}return t.prototype.hasBuilder=function(t){return!!rI[t]},t.prototype.add=function(t){rI[t](this.opt,this.axisModel,this.group,this._transformGroup)},t.prototype.getGroup=function(){return this.group},t.innerTextLayout=function(t,e,n){var i,r,o=eo(e-t);return no(o)?(r=n>0?"top":"bottom",i="center"):no(o-nI)?(r=n>0?"bottom":"top",i="center"):(r="middle",i=o>0&&o0?"right":"left":n>0?"left":"right"),{rotation:o,textAlign:i,textVerticalAlign:r}},t.makeAxisEventDataBase=function(t){var e={componentType:t.mainType,componentIndex:t.componentIndex};return e[t.mainType+"Index"]=t.componentIndex,e},t.isLabelSilent=function(t){var e=t.get("tooltip");return t.get("silent")||!(t.get("triggerEvent")||e&&e.show)},t}(),rI={axisLine:function(t,e,n,i){var r=e.get(["axisLine","show"]);if("auto"===r&&t.handleAutoShown&&(r=t.handleAutoShown("axisLine")),r){var o=e.axis.getExtent(),a=i.transform,s=[o[0],0],l=[o[1],0],u=s[0]>l[0];a&&(Wt(s,s,a),Wt(l,l,a));var h=A({lineCap:"round"},e.getModel(["axisLine","lineStyle"]).getLineStyle()),c=new Zu({shape:{x1:s[0],y1:s[1],x2:l[0],y2:l[1]},style:h,strokeContainThreshold:t.strokeContainThreshold||5,silent:!0,z2:1});Rh(c.shape,c.style.lineWidth),c.anid="line",n.add(c);var p=e.get(["axisLine","symbol"]);if(null!=p){var d=e.get(["axisLine","symbolSize"]);U(p)&&(p=[p,p]),(U(d)||j(d))&&(d=[d,d]);var f=Yy(e.get(["axisLine","symbolOffset"])||0,d),g=d[0],y=d[1];E([{rotate:t.rotation+Math.PI/2,offset:f[0],r:0},{rotate:t.rotation-Math.PI/2,offset:f[1],r:Math.sqrt((s[0]-l[0])*(s[0]-l[0])+(s[1]-l[1])*(s[1]-l[1]))}],(function(e,i){if("none"!==p[i]&&null!=p[i]){var r=Wy(p[i],-g/2,-y/2,g,y,h.stroke,!0),o=e.r+e.offset,a=u?l:s;r.attr({rotation:e.rotate,x:a[0]+o*Math.cos(t.rotation),y:a[1]-o*Math.sin(t.rotation),silent:!0,z2:11}),n.add(r)}}))}}},axisTickLabel:function(t,e,n,i){var r=function(t,e,n,i){var r=n.axis,o=n.getModel("axisTick"),a=o.get("show");"auto"===a&&i.handleAutoShown&&(a=i.handleAutoShown("axisTick"));if(!a||r.scale.isBlank())return;for(var s=o.getModel("lineStyle"),l=i.tickDirection*o.get("length"),u=lI(r.getTicksCoords(),e.transform,l,k(s.getLineStyle(),{stroke:n.get(["axisLine","lineStyle","color"])}),"ticks"),h=0;hc[1]?-1:1,d=["start"===s?c[0]-p*h:"end"===s?c[1]+p*h:(c[0]+c[1])/2,sI(s)?t.labelOffset+l*h:0],f=e.get("nameRotate");null!=f&&(f=f*nI/180),sI(s)?o=iI.innerTextLayout(t.rotation,null!=f?f:t.rotation,l):(o=function(t,e,n,i){var r,o,a=eo(n-t),s=i[0]>i[1],l="start"===e&&!s||"start"!==e&&s;no(a-nI/2)?(o=l?"bottom":"top",r="center"):no(a-1.5*nI)?(o=l?"top":"bottom",r="center"):(o="middle",r=a<1.5*nI&&a>nI/2?l?"left":"right":l?"right":"left");return{rotation:a,textAlign:r,textVerticalAlign:o}}(t.rotation,s,f||0,c),null!=(a=t.axisNameAvailableWidth)&&(a=Math.abs(a/Math.sin(o.rotation)),!isFinite(a)&&(a=null)));var g=u.getFont(),y=e.get("nameTruncate",!0)||{},v=y.ellipsis,m=it(t.nameTruncateMaxWidth,y.maxWidth,a),x=new Fs({x:d[0],y:d[1],rotation:o.rotation,silent:iI.isLabelSilent(e),style:nc(u,{text:r,font:g,overflow:"truncate",width:m,ellipsis:v,fill:u.getTextColor()||e.get(["axisLine","lineStyle","color"]),align:u.get("align")||o.textAlign,verticalAlign:u.get("verticalAlign")||o.textVerticalAlign}),z2:1});if(Zh({el:x,componentModel:e,itemName:r}),x.__fullText=r,x.anid="name",e.get("triggerEvent")){var _=iI.makeAxisEventDataBase(e);_.targetType="axisName",_.name=r,Qs(x).eventData=_}i.add(x),x.updateTransform(),n.add(x),x.decomposeTransform()}}};function oI(t){t&&(t.ignore=!0)}function aI(t,e){var n=t&&t.getBoundingRect().clone(),i=e&&e.getBoundingRect().clone();if(n&&i){var r=xe([]);return Se(r,r,-t.rotation),n.applyTransform(be([],r,t.getLocalTransform())),i.applyTransform(be([],r,e.getLocalTransform())),n.intersect(i)}}function sI(t){return"middle"===t||"center"===t}function lI(t,e,n,i,r){for(var o=[],a=[],s=[],l=0;l=0||t===e}function cI(t){var e=pI(t);if(e){var n=e.axisPointerModel,i=e.axis.scale,r=n.option,o=n.get("status"),a=n.get("value");null!=a&&(a=i.parse(a));var s=dI(n);null==o&&(r.status=s?"show":"hide");var l=i.getExtent().slice();l[0]>l[1]&&l.reverse(),(null==a||a>l[1])&&(a=l[1]),a0&&!c.min?c.min=0:null!=c.min&&c.min<0&&!c.max&&(c.max=0);var p=a;null!=c.color&&(p=k({color:c.color},a));var d=C(T(c),{boundaryGap:t,splitNumber:e,scale:n,axisLine:i,axisTick:r,axisLabel:o,name:c.text,showName:s,nameLocation:"end",nameGap:u,nameTextStyle:p,triggerEvent:h},!1);if(U(l)){var f=d.name;d.name=l.replace("{value}",null!=f?f:"")}else X(l)&&(d.name=l(d.name,d));var g=new Mc(d,null,this.ecModel);return R(g,I_.prototype),g.mainType="radar",g.componentIndex=this.componentIndex,g}),this);this._indicatorModels=c},e.prototype.getIndicatorModels=function(){return this._indicatorModels},e.type="radar",e.defaultOption={z:0,center:["50%","50%"],radius:"75%",startAngle:90,axisName:{show:!0},boundaryGap:[0,0],splitNumber:5,axisNameGap:15,scale:!1,shape:"polygon",axisLine:C({lineStyle:{color:"#bbb"}},NI.axisLine),axisLabel:EI(NI.axisLabel,!1),axisTick:EI(NI.axisTick,!1),splitLine:EI(NI.splitLine,!0),splitArea:EI(NI.splitArea,!0),indicator:[]},e}(Rp),VI=["axisLine","axisTickLabel","axisName"],BI=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.prototype.render=function(t,e,n){this.group.removeAll(),this._buildAxes(t),this._buildSplitLineAndArea(t)},e.prototype._buildAxes=function(t){var e=t.coordinateSystem;E(z(e.getIndicatorAxes(),(function(t){var n=t.model.get("showName")?t.name:"";return new iI(t.model,{axisName:n,position:[e.cx,e.cy],rotation:t.angle,labelDirection:-1,tickDirection:-1,nameDirection:1})})),(function(t){E(VI,t.add,t),this.group.add(t.getGroup())}),this)},e.prototype._buildSplitLineAndArea=function(t){var e=t.coordinateSystem,n=e.getIndicatorAxes();if(n.length){var i=t.get("shape"),r=t.getModel("splitLine"),o=t.getModel("splitArea"),a=r.getModel("lineStyle"),s=o.getModel("areaStyle"),l=r.get("show"),u=o.get("show"),h=a.get("color"),c=s.get("color"),p=Y(h)?h:[h],d=Y(c)?c:[c],f=[],g=[];if("circle"===i)for(var y=n[0].getTicksCoords(),v=e.cx,m=e.cy,x=0;x3?1.4:r>1?1.2:1.1;ZI(this,"zoom","zoomOnMouseWheel",t,{scale:i>0?s:1/s,originX:o,originY:a,isAvailableBehavior:null})}if(n){var l=Math.abs(i);ZI(this,"scrollMove","moveOnMouseWheel",t,{scrollDelta:(i>0?1:-1)*(l>3?.4:l>1?.15:.05),originX:o,originY:a,isAvailableBehavior:null})}}},e.prototype._pinchHandler=function(t){YI(this._zr,"globalPan")||ZI(this,"zoom",null,t,{scale:t.pinchScale>1?1.1:1/1.1,originX:t.pinchX,originY:t.pinchY,isAvailableBehavior:null})},e}(jt);function ZI(t,e,n,i,r){t.pointerChecker&&t.pointerChecker(i,r.originX,r.originY)&&(de(i.event),jI(t,e,n,i,r))}function jI(t,e,n,i,r){r.isAvailableBehavior=W(qI,null,n,i),t.trigger(e,r)}function qI(t,e,n){var i=n[t];return!t||i&&(!U(i)||e.event[i+"Key"])}function KI(t,e,n){var i=t.target;i.x+=e,i.y+=n,i.dirty()}function $I(t,e,n,i){var r=t.target,o=t.zoomLimit,a=t.zoom=t.zoom||1;if(a*=e,o){var s=o.min||0,l=o.max||1/0;a=Math.max(Math.min(l,a),s)}var u=a/t.zoom;t.zoom=a,r.x-=(n-r.x)*(u-1),r.y-=(i-r.y)*(u-1),r.scaleX*=u,r.scaleY*=u,r.dirty()}var JI,QI={axisPointer:1,tooltip:1,brush:1};function tT(t,e,n){var i=e.getComponentByElement(t.topTarget),r=i&&i.coordinateSystem;return i&&i!==n&&!QI.hasOwnProperty(i.mainType)&&r&&r.model!==n}function eT(t){U(t)&&(t=(new DOMParser).parseFromString(t,"text/xml"));var e=t;for(9===e.nodeType&&(e=e.firstChild);"svg"!==e.nodeName.toLowerCase()||1!==e.nodeType;)e=e.nextSibling;return e}var nT={fill:"fill",stroke:"stroke","stroke-width":"lineWidth",opacity:"opacity","fill-opacity":"fillOpacity","stroke-opacity":"strokeOpacity","stroke-dasharray":"lineDash","stroke-dashoffset":"lineDashOffset","stroke-linecap":"lineCap","stroke-linejoin":"lineJoin","stroke-miterlimit":"miterLimit","font-family":"fontFamily","font-size":"fontSize","font-style":"fontStyle","font-weight":"fontWeight","text-anchor":"textAlign",visibility:"visibility",display:"display"},iT=G(nT),rT={"alignment-baseline":"textBaseline","stop-color":"stopColor"},oT=G(rT),aT=function(){function t(){this._defs={},this._root=null}return t.prototype.parse=function(t,e){e=e||{};var n=eT(t);this._defsUsePending=[];var i=new zr;this._root=i;var r=[],o=n.getAttribute("viewBox")||"",a=parseFloat(n.getAttribute("width")||e.width),s=parseFloat(n.getAttribute("height")||e.height);isNaN(a)&&(a=null),isNaN(s)&&(s=null),pT(n,i,null,!0,!1);for(var l,u,h=n.firstChild;h;)this._parseNode(h,i,r,null,!1,!1),h=h.nextSibling;if(function(t,e){for(var n=0;n=4&&(l={x:parseFloat(c[0]||0),y:parseFloat(c[1]||0),width:parseFloat(c[2]),height:parseFloat(c[3])})}if(l&&null!=a&&null!=s&&(u=bT(l,{x:0,y:0,width:a,height:s}),!e.ignoreViewBox)){var p=i;(i=new zr).add(p),p.scaleX=p.scaleY=u.scale,p.x=u.x,p.y=u.y}return e.ignoreRootClip||null==a||null==s||i.setClipPath(new zs({shape:{x:0,y:0,width:a,height:s}})),{root:i,width:a,height:s,viewBoxRect:l,viewBoxTransform:u,named:r}},t.prototype._parseNode=function(t,e,n,i,r,o){var a,s=t.nodeName.toLowerCase(),l=i;if("defs"===s&&(r=!0),"text"===s&&(o=!0),"defs"===s||"switch"===s)a=e;else{if(!r){var u=JI[s];if(u&&_t(JI,s)){a=u.call(this,t,e);var h=t.getAttribute("name");if(h){var c={name:h,namedFrom:null,svgNodeTagLower:s,el:a};n.push(c),"g"===s&&(l=c)}else i&&n.push({name:i.name,namedFrom:i,svgNodeTagLower:s,el:a});e.add(a)}}var p=sT[s];if(p&&_t(sT,s)){var d=p.call(this,t),f=t.getAttribute("id");f&&(this._defs[f]=d)}}if(a&&a.isGroup)for(var g=t.firstChild;g;)1===g.nodeType?this._parseNode(g,a,n,l,r,o):3===g.nodeType&&o&&this._parseText(g,a),g=g.nextSibling},t.prototype._parseText=function(t,e){var n=new Cs({style:{text:t.textContent},silent:!0,x:this._textX||0,y:this._textY||0});hT(e,n),pT(t,n,this._defsUsePending,!1,!1),function(t,e){var n=e.__selfStyle;if(n){var i=n.textBaseline,r=i;i&&"auto"!==i?"baseline"===i?r="alphabetic":"before-edge"===i||"text-before-edge"===i?r="top":"after-edge"===i||"text-after-edge"===i?r="bottom":"central"!==i&&"mathematical"!==i||(r="middle"):r="alphabetic",t.style.textBaseline=r}var o=e.__inheritedStyle;if(o){var a=o.textAlign,s=a;a&&("middle"===a&&(s="center"),t.style.textAlign=s)}}(n,e);var i=n.style,r=i.fontSize;r&&r<9&&(i.fontSize=9,n.scaleX*=r/9,n.scaleY*=r/9);var o=(i.fontSize||i.fontFamily)&&[i.fontStyle,i.fontWeight,(i.fontSize||12)+"px",i.fontFamily||"sans-serif"].join(" ");i.font=o;var a=n.getBoundingRect();return this._textX+=a.width,e.add(n),n},t.internalField=void(JI={g:function(t,e){var n=new zr;return hT(e,n),pT(t,n,this._defsUsePending,!1,!1),n},rect:function(t,e){var n=new zs;return hT(e,n),pT(t,n,this._defsUsePending,!1,!1),n.setShape({x:parseFloat(t.getAttribute("x")||"0"),y:parseFloat(t.getAttribute("y")||"0"),width:parseFloat(t.getAttribute("width")||"0"),height:parseFloat(t.getAttribute("height")||"0")}),n.silent=!0,n},circle:function(t,e){var n=new _u;return hT(e,n),pT(t,n,this._defsUsePending,!1,!1),n.setShape({cx:parseFloat(t.getAttribute("cx")||"0"),cy:parseFloat(t.getAttribute("cy")||"0"),r:parseFloat(t.getAttribute("r")||"0")}),n.silent=!0,n},line:function(t,e){var n=new Zu;return hT(e,n),pT(t,n,this._defsUsePending,!1,!1),n.setShape({x1:parseFloat(t.getAttribute("x1")||"0"),y1:parseFloat(t.getAttribute("y1")||"0"),x2:parseFloat(t.getAttribute("x2")||"0"),y2:parseFloat(t.getAttribute("y2")||"0")}),n.silent=!0,n},ellipse:function(t,e){var n=new wu;return hT(e,n),pT(t,n,this._defsUsePending,!1,!1),n.setShape({cx:parseFloat(t.getAttribute("cx")||"0"),cy:parseFloat(t.getAttribute("cy")||"0"),rx:parseFloat(t.getAttribute("rx")||"0"),ry:parseFloat(t.getAttribute("ry")||"0")}),n.silent=!0,n},polygon:function(t,e){var n,i=t.getAttribute("points");i&&(n=cT(i));var r=new Wu({shape:{points:n||[]},silent:!0});return hT(e,r),pT(t,r,this._defsUsePending,!1,!1),r},polyline:function(t,e){var n,i=t.getAttribute("points");i&&(n=cT(i));var r=new Yu({shape:{points:n||[]},silent:!0});return hT(e,r),pT(t,r,this._defsUsePending,!1,!1),r},image:function(t,e){var n=new ks;return hT(e,n),pT(t,n,this._defsUsePending,!1,!1),n.setStyle({image:t.getAttribute("xlink:href")||t.getAttribute("href"),x:+t.getAttribute("x"),y:+t.getAttribute("y"),width:+t.getAttribute("width"),height:+t.getAttribute("height")}),n.silent=!0,n},text:function(t,e){var n=t.getAttribute("x")||"0",i=t.getAttribute("y")||"0",r=t.getAttribute("dx")||"0",o=t.getAttribute("dy")||"0";this._textX=parseFloat(n)+parseFloat(r),this._textY=parseFloat(i)+parseFloat(o);var a=new zr;return hT(e,a),pT(t,a,this._defsUsePending,!1,!0),a},tspan:function(t,e){var n=t.getAttribute("x"),i=t.getAttribute("y");null!=n&&(this._textX=parseFloat(n)),null!=i&&(this._textY=parseFloat(i));var r=t.getAttribute("dx")||"0",o=t.getAttribute("dy")||"0",a=new zr;return hT(e,a),pT(t,a,this._defsUsePending,!1,!0),this._textX+=parseFloat(r),this._textY+=parseFloat(o),a},path:function(t,e){var n=vu(t.getAttribute("d")||"");return hT(e,n),pT(t,n,this._defsUsePending,!1,!1),n.silent=!0,n}}),t}(),sT={lineargradient:function(t){var e=parseInt(t.getAttribute("x1")||"0",10),n=parseInt(t.getAttribute("y1")||"0",10),i=parseInt(t.getAttribute("x2")||"10",10),r=parseInt(t.getAttribute("y2")||"0",10),o=new nh(e,n,i,r);return lT(t,o),uT(t,o),o},radialgradient:function(t){var e=parseInt(t.getAttribute("cx")||"0",10),n=parseInt(t.getAttribute("cy")||"0",10),i=parseInt(t.getAttribute("r")||"0",10),r=new ih(e,n,i);return lT(t,r),uT(t,r),r}};function lT(t,e){"userSpaceOnUse"===t.getAttribute("gradientUnits")&&(e.global=!0)}function uT(t,e){for(var n=t.firstChild;n;){if(1===n.nodeType&&"stop"===n.nodeName.toLocaleLowerCase()){var i=n.getAttribute("offset"),r=void 0;r=i&&i.indexOf("%")>0?parseInt(i,10)/100:i?parseFloat(i):0;var o={};_T(n,o,o);var a=o.stopColor||n.getAttribute("stop-color")||"#000000";e.colorStops.push({offset:r,color:a})}n=n.nextSibling}}function hT(t,e){t&&t.__inheritedStyle&&(e.__inheritedStyle||(e.__inheritedStyle={}),k(e.__inheritedStyle,t.__inheritedStyle))}function cT(t){for(var e=yT(t),n=[],i=0;i0;o-=2){var a=i[o],s=i[o-1],l=yT(a);switch(r=r||[1,0,0,1,0,0],s){case"translate":we(r,r,[parseFloat(l[0]),parseFloat(l[1]||"0")]);break;case"scale":Me(r,r,[parseFloat(l[0]),parseFloat(l[1]||l[0])]);break;case"rotate":Se(r,r,-parseFloat(l[0])*mT);break;case"skewX":be(r,[1,0,Math.tan(parseFloat(l[0])*mT),1,0,0],r);break;case"skewY":be(r,[1,Math.tan(parseFloat(l[0])*mT),0,1,0,0],r);break;case"matrix":r[0]=parseFloat(l[0]),r[1]=parseFloat(l[1]),r[2]=parseFloat(l[2]),r[3]=parseFloat(l[3]),r[4]=parseFloat(l[4]),r[5]=parseFloat(l[5])}}e.setLocalTransform(r)}}(t,e),_T(t,a,s),i||function(t,e,n){for(var i=0;i0,f={api:n,geo:s,mapOrGeoModel:t,data:a,isVisualEncodedByVisualMap:d,isGeo:o,transformInfoRaw:c};"geoJSON"===s.resourceType?this._buildGeoJSON(f):"geoSVG"===s.resourceType&&this._buildSVG(f),this._updateController(t,e,n),this._updateMapSelectHandler(t,l,n,i)},t.prototype._buildGeoJSON=function(t){var e=this._regionsGroupByName=yt(),n=yt(),i=this._regionsGroup,r=t.transformInfoRaw,o=t.mapOrGeoModel,a=t.data,s=t.geo.projection,l=s&&s.stream;function u(t,e){return e&&(t=e(t)),t&&[t[0]*r.scaleX+r.x,t[1]*r.scaleY+r.y]}function h(t){for(var e=[],n=!l&&s&&s.project,i=0;i=0)&&(p=r);var d=a?{normal:{align:"center",verticalAlign:"middle"}}:null;tc(e,ec(i),{labelFetcher:p,labelDataIndex:c,defaultText:n},d);var f=e.getTextContent();if(f&&(WT(f).ignore=f.ignore,e.textConfig&&a)){var g=e.getBoundingRect().clone();e.textConfig.layoutRect=g,e.textConfig.position=[(a[0]-g.x)/g.width*100+"%",(a[1]-g.y)/g.height*100+"%"]}e.disableLabelAnimation=!0}else e.removeTextContent(),e.removeTextConfig(),e.disableLabelAnimation=null}function jT(t,e,n,i,r,o){t.data?t.data.setItemGraphicEl(o,e):Qs(e).eventData={componentType:"geo",componentIndex:r.componentIndex,geoIndex:r.componentIndex,name:n,region:i&&i.option||{}}}function qT(t,e,n,i,r){t.data||Zh({el:e,componentModel:r,itemName:n,itemTooltipOption:i.get("tooltip")})}function KT(t,e,n,i,r){e.highDownSilentOnTouch=!!r.get("selectedMode");var o=i.getModel("emphasis"),a=o.get("focus");return Yl(e,a,o.get("blurScope"),o.get("disabled")),t.isGeo&&function(t,e,n){var i=Qs(t);i.componentMainType=e.mainType,i.componentIndex=e.componentIndex,i.componentHighDownName=n}(e,r,n),a}function $T(t,e,n){var i,r=[];function o(){i=[]}function a(){i.length&&(r.push(i),i=[])}var s=e({polygonStart:o,polygonEnd:a,lineStart:o,lineEnd:a,point:function(t,e){isFinite(t)&&isFinite(e)&&i.push([t,e])},sphere:function(){}});return!n&&s.polygonStart(),E(t,(function(t){s.lineStart();for(var e=0;e-1&&(n.style.stroke=n.style.fill,n.style.fill="#fff",n.style.lineWidth=2),n},e.type="series.map",e.dependencies=["geo"],e.layoutMode="box",e.defaultOption={z:2,coordinateSystem:"geo",map:"",left:"center",top:"center",aspectScale:null,showLegendSymbol:!0,boundingCoords:null,center:null,zoom:1,scaleLimit:null,selectedMode:!0,label:{show:!1,color:"#000"},itemStyle:{borderWidth:.5,borderColor:"#444",areaColor:"#eee"},emphasis:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{areaColor:"rgba(255,215,0,0.8)"}},select:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{color:"rgba(255,215,0,0.8)"}},nameProperty:"name"},e}(mg);function tC(t){var e={};t.eachSeriesByType("map",(function(t){var n=t.getHostGeoModel(),i=n?"o"+n.id:"i"+t.getMapType();(e[i]=e[i]||[]).push(t)})),E(e,(function(t,e){for(var n,i,r,o=(n=z(t,(function(t){return t.getData()})),i=t[0].get("mapValueCalculation"),r={},E(n,(function(t){t.each(t.mapDimension("value"),(function(e,n){var i="ec-"+t.getName(n);r[i]=r[i]||[],isNaN(e)||r[i].push(e)}))})),n[0].map(n[0].mapDimension("value"),(function(t,e){for(var o="ec-"+n[0].getName(e),a=0,s=1/0,l=-1/0,u=r[o].length,h=0;h1?(d.width=p,d.height=p/x):(d.height=p,d.width=p*x),d.y=c[1]-d.height/2,d.x=c[0]-d.width/2;else{var b=t.getBoxLayoutParams();b.aspect=x,d=Cp(b,{width:v,height:m})}this.setViewRect(d.x,d.y,d.width,d.height),this.setCenter(t.get("center"),e),this.setZoom(t.get("zoom"))}R(sC,iC);var hC=function(){function t(){this.dimensions=aC}return t.prototype.create=function(t,e){var n=[];function i(t){return{nameProperty:t.get("nameProperty"),aspectScale:t.get("aspectScale"),projection:t.get("projection")}}t.eachComponent("geo",(function(t,r){var o=t.get("map"),a=new sC(o+r,o,A({nameMap:t.get("nameMap")},i(t)));a.zoomLimit=t.get("scaleLimit"),n.push(a),t.coordinateSystem=a,a.model=t,a.resize=uC,a.resize(t,e)})),t.eachSeries((function(t){if("geo"===t.get("coordinateSystem")){var e=t.get("geoIndex")||0;t.coordinateSystem=n[e]}}));var r={};return t.eachSeriesByType("map",(function(t){if(!t.getHostGeoModel()){var e=t.getMapType();r[e]=r[e]||[],r[e].push(t)}})),E(r,(function(t,r){var o=z(t,(function(t){return t.get("nameMap")})),a=new sC(r,r,A({nameMap:D(o)},i(t[0])));a.zoomLimit=it.apply(null,z(t,(function(t){return t.get("scaleLimit")}))),n.push(a),a.resize=uC,a.resize(t[0],e),E(t,(function(t){t.coordinateSystem=a,function(t,e){E(e.get("geoCoord"),(function(e,n){t.addGeoCoord(n,e)}))}(a,t)}))})),n},t.prototype.getFilledRegions=function(t,e,n,i){for(var r=(t||[]).slice(),o=yt(),a=0;a=0;){var o=e[n];o.hierNode.prelim+=i,o.hierNode.modifier+=i,r+=o.hierNode.change,i+=o.hierNode.shift+r}}(t);var o=(n[0].hierNode.prelim+n[n.length-1].hierNode.prelim)/2;r?(t.hierNode.prelim=r.hierNode.prelim+e(t,r),t.hierNode.modifier=t.hierNode.prelim-o):t.hierNode.prelim=o}else r&&(t.hierNode.prelim=r.hierNode.prelim+e(t,r));t.parentNode.hierNode.defaultAncestor=function(t,e,n,i){if(e){for(var r=t,o=t,a=o.parentNode.children[0],s=e,l=r.hierNode.modifier,u=o.hierNode.modifier,h=a.hierNode.modifier,c=s.hierNode.modifier;s=wC(s),o=SC(o),s&&o;){r=wC(r),a=SC(a),r.hierNode.ancestor=t;var p=s.hierNode.prelim+c-o.hierNode.prelim-u+i(s,o);p>0&&(IC(MC(s,t,n),t,p),u+=p,l+=p),c+=s.hierNode.modifier,u+=o.hierNode.modifier,l+=r.hierNode.modifier,h+=a.hierNode.modifier}s&&!wC(r)&&(r.hierNode.thread=s,r.hierNode.modifier+=c-l),o&&!SC(a)&&(a.hierNode.thread=o,a.hierNode.modifier+=u-h,n=t)}return n}(t,r,t.parentNode.hierNode.defaultAncestor||i[0],e)}function xC(t){var e=t.hierNode.prelim+t.parentNode.hierNode.modifier;t.setLayout({x:e},!0),t.hierNode.modifier+=t.parentNode.hierNode.modifier}function _C(t){return arguments.length?t:TC}function bC(t,e){return t-=Math.PI/2,{x:e*Math.cos(t),y:e*Math.sin(t)}}function wC(t){var e=t.children;return e.length&&t.isExpand?e[e.length-1]:t.hierNode.thread}function SC(t){var e=t.children;return e.length&&t.isExpand?e[0]:t.hierNode.thread}function MC(t,e,n){return t.hierNode.ancestor.parentNode===e.parentNode?t.hierNode.ancestor:n}function IC(t,e,n){var i=n/(e.hierNode.i-t.hierNode.i);e.hierNode.change-=i,e.hierNode.shift+=n,e.hierNode.modifier+=n,e.hierNode.prelim+=n,t.hierNode.change+=i}function TC(t,e){return t.parentNode===e.parentNode?1:2}var CC=function(){this.parentPoint=[],this.childPoints=[]},DC=function(t){function e(e){return t.call(this,e)||this}return n(e,t),e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new CC},e.prototype.buildPath=function(t,e){var n=e.childPoints,i=n.length,r=e.parentPoint,o=n[0],a=n[i-1];if(1===i)return t.moveTo(r[0],r[1]),void t.lineTo(o[0],o[1]);var s=e.orient,l="TB"===s||"BT"===s?0:1,u=1-l,h=Ur(e.forkPosition,1),c=[];c[l]=r[l],c[u]=r[u]+(a[u]-r[u])*h,t.moveTo(r[0],r[1]),t.lineTo(c[0],c[1]),t.moveTo(o[0],o[1]),c[l]=o[l],t.lineTo(c[0],c[1]),c[l]=a[l],t.lineTo(c[0],c[1]),t.lineTo(a[0],a[1]);for(var p=1;pm.x)||(_-=Math.PI);var S=b?"left":"right",M=s.getModel("label"),I=M.get("rotate"),T=I*(Math.PI/180),C=y.getTextContent();C&&(y.setTextConfig({position:M.get("position")||S,rotation:null==I?-_:T,origin:"center"}),C.setStyle("verticalAlign","middle"))}var D=s.get(["emphasis","focus"]),A="relative"===D?vt(a.getAncestorsIndices(),a.getDescendantIndices()):"ancestor"===D?a.getAncestorsIndices():"descendant"===D?a.getDescendantIndices():null;A&&(Qs(n).focus=A),function(t,e,n,i,r,o,a,s){var l=e.getModel(),u=t.get("edgeShape"),h=t.get("layout"),c=t.getOrient(),p=t.get(["lineStyle","curveness"]),d=t.get("edgeForkPosition"),f=l.getModel("lineStyle").getLineStyle(),g=i.__edge;if("curve"===u)e.parentNode&&e.parentNode!==n&&(g||(g=i.__edge=new $u({shape:NC(h,c,p,r,r)})),fh(g,{shape:NC(h,c,p,o,a)},t));else if("polyline"===u)if("orthogonal"===h){if(e!==n&&e.children&&0!==e.children.length&&!0===e.isExpand){for(var y=e.children,v=[],m=0;me&&(e=i.height)}this.height=e+1},t.prototype.getNodeById=function(t){if(this.getId()===t)return this;for(var e=0,n=this.children,i=n.length;e=0&&this.hostTree.data.setItemLayout(this.dataIndex,t,e)},t.prototype.getLayout=function(){return this.hostTree.data.getItemLayout(this.dataIndex)},t.prototype.getModel=function(t){if(!(this.dataIndex<0))return this.hostTree.data.getItemModel(this.dataIndex).getModel(t)},t.prototype.getLevelModel=function(){return(this.hostTree.levelModels||[])[this.depth]},t.prototype.setVisual=function(t,e){this.dataIndex>=0&&this.hostTree.data.setItemVisual(this.dataIndex,t,e)},t.prototype.getVisual=function(t){return this.hostTree.data.getItemVisual(this.dataIndex,t)},t.prototype.getRawIndex=function(){return this.hostTree.data.getRawIndex(this.dataIndex)},t.prototype.getId=function(){return this.hostTree.data.getId(this.dataIndex)},t.prototype.getChildIndex=function(){if(this.parentNode){for(var t=this.parentNode.children,e=0;e=0){var i=n.getData().tree.root,r=t.targetNode;if(U(r)&&(r=i.getNodeById(r)),r&&i.contains(r))return{node:r};var o=t.targetNodeId;if(null!=o&&(r=i.getNodeById(o)))return{node:r}}}function jC(t){for(var e=[];t;)(t=t.parentNode)&&e.push(t);return e.reverse()}function qC(t,e){return P(jC(t),e)>=0}function KC(t,e){for(var n=[];t;){var i=t.dataIndex;n.push({name:t.name,dataIndex:i,value:e.getRawValue(i)}),t=t.parentNode}return n.reverse(),n}var $C=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.hasSymbolVisual=!0,e.ignoreStyleOnData=!0,e}return n(e,t),e.prototype.getInitialData=function(t){var e={name:t.name,children:t.data},n=t.leaves||{},i=new Mc(n,this,this.ecModel),r=UC.createTree(e,this,(function(t){t.wrapMethod("getItemModel",(function(t,e){var n=r.getNodeByDataIndex(e);return n&&n.children.length&&n.isExpand||(t.parentModel=i),t}))}));var o=0;r.eachNode("preorder",(function(t){t.depth>o&&(o=t.depth)}));var a=t.expandAndCollapse&&t.initialTreeDepth>=0?t.initialTreeDepth:o;return r.root.eachNode("preorder",(function(t){var e=t.hostTree.data.getRawDataItem(t.dataIndex);t.isExpand=e&&null!=e.collapsed?!e.collapsed:t.depth<=a})),r.data},e.prototype.getOrient=function(){var t=this.get("orient");return"horizontal"===t?t="LR":"vertical"===t&&(t="TB"),t},e.prototype.setZoom=function(t){this.option.zoom=t},e.prototype.setCenter=function(t){this.option.center=t},e.prototype.formatTooltip=function(t,e,n){for(var i=this.getData().tree,r=i.root.children[0],o=i.getNodeByDataIndex(t),a=o.getValue(),s=o.name;o&&o!==r;)s=o.parentNode.name+"."+s,o=o.parentNode;return ng("nameValue",{name:s,value:a,noValue:isNaN(a)||null==a})},e.prototype.getDataParams=function(e){var n=t.prototype.getDataParams.apply(this,arguments),i=this.getData().tree.getNodeByDataIndex(e);return n.treeAncestors=KC(i,this),n.collapsed=!i.isExpand,n},e.type="series.tree",e.layoutMode="box",e.defaultOption={z:2,coordinateSystem:"view",left:"12%",top:"12%",right:"12%",bottom:"12%",layout:"orthogonal",edgeShape:"curve",edgeForkPosition:"50%",roam:!1,nodeScaleRatio:.4,center:null,zoom:1,orient:"LR",symbol:"emptyCircle",symbolSize:7,expandAndCollapse:!0,initialTreeDepth:2,lineStyle:{color:"#ccc",width:1.5,curveness:.5},itemStyle:{color:"lightsteelblue",borderWidth:1.5},label:{show:!0},animationEasing:"linear",animationDuration:700,animationDurationUpdate:500},e}(mg);function JC(t,e){for(var n,i=[t];n=i.pop();)if(e(n),n.isExpand){var r=n.children;if(r.length)for(var o=r.length-1;o>=0;o--)i.push(r[o])}}function QC(t,e){t.eachSeriesByType("tree",(function(t){!function(t,e){var n=function(t,e){return Cp(t.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}(t,e);t.layoutInfo=n;var i=t.get("layout"),r=0,o=0,a=null;"radial"===i?(r=2*Math.PI,o=Math.min(n.height,n.width)/2,a=_C((function(t,e){return(t.parentNode===e.parentNode?1:2)/t.depth}))):(r=n.width,o=n.height,a=_C());var s=t.getData().tree.root,l=s.children[0];if(l){!function(t){var e=t;e.hierNode={defaultAncestor:null,ancestor:e,prelim:0,modifier:0,change:0,shift:0,i:0,thread:null};for(var n,i,r=[e];n=r.pop();)if(i=n.children,n.isExpand&&i.length)for(var o=i.length-1;o>=0;o--){var a=i[o];a.hierNode={defaultAncestor:null,ancestor:a,prelim:0,modifier:0,change:0,shift:0,i:o,thread:null},r.push(a)}}(s),function(t,e,n){for(var i,r=[t],o=[];i=r.pop();)if(o.push(i),i.isExpand){var a=i.children;if(a.length)for(var s=0;sh.getLayout().x&&(h=t),t.depth>c.depth&&(c=t)}));var p=u===h?1:a(u,h)/2,d=p-u.getLayout().x,f=0,g=0,y=0,v=0;if("radial"===i)f=r/(h.getLayout().x+p+d),g=o/(c.depth-1||1),JC(l,(function(t){y=(t.getLayout().x+d)*f,v=(t.depth-1)*g;var e=bC(y,v);t.setLayout({x:e.x,y:e.y,rawX:y,rawY:v},!0)}));else{var m=t.getOrient();"RL"===m||"LR"===m?(g=o/(h.getLayout().x+p+d),f=r/(c.depth-1||1),JC(l,(function(t){v=(t.getLayout().x+d)*g,y="LR"===m?(t.depth-1)*f:r-(t.depth-1)*f,t.setLayout({x:y,y:v},!0)}))):"TB"!==m&&"BT"!==m||(f=r/(h.getLayout().x+p+d),g=o/(c.depth-1||1),JC(l,(function(t){y=(t.getLayout().x+d)*f,v="TB"===m?(t.depth-1)*g:o-(t.depth-1)*g,t.setLayout({x:y,y:v},!0)})))}}}(t,e)}))}function tD(t){t.eachSeriesByType("tree",(function(t){var e=t.getData();e.tree.eachNode((function(t){var n=t.getModel().getModel("itemStyle").getItemStyle();A(e.ensureUniqueItemVisual(t.dataIndex,"style"),n)}))}))}var eD=["treemapZoomToNode","treemapRender","treemapMove"];function nD(t){var e=t.getData().tree,n={};e.eachNode((function(e){for(var i=e;i&&i.depth>1;)i=i.parentNode;var r=ud(t.ecModel,i.name||i.dataIndex+"",n);e.setVisual("decal",r)}))}var iD=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.preventUsingHoverLayer=!0,n}return n(e,t),e.prototype.getInitialData=function(t,e){var n={name:t.name,children:t.data};rD(n);var i=t.levels||[],r=this.designatedVisualItemStyle={},o=new Mc({itemStyle:r},this,e);i=t.levels=function(t,e){var n,i,r=bo(e.get("color")),o=bo(e.get(["aria","decal","decals"]));if(!r)return;t=t||[],E(t,(function(t){var e=new Mc(t),r=e.get("color"),o=e.get("decal");(e.get(["itemStyle","color"])||r&&"none"!==r)&&(n=!0),(e.get(["itemStyle","decal"])||o&&"none"!==o)&&(i=!0)}));var a=t[0]||(t[0]={});n||(a.color=r.slice());!i&&o&&(a.decal=o.slice());return t}(i,e);var a=z(i||[],(function(t){return new Mc(t,o,e)}),this),s=UC.createTree(n,this,(function(t){t.wrapMethod("getItemModel",(function(t,e){var n=s.getNodeByDataIndex(e),i=n?a[n.depth]:null;return t.parentModel=i||o,t}))}));return s.data},e.prototype.optionUpdated=function(){this.resetViewRoot()},e.prototype.formatTooltip=function(t,e,n){var i=this.getData(),r=this.getRawValue(t);return ng("nameValue",{name:i.getName(t),value:r})},e.prototype.getDataParams=function(e){var n=t.prototype.getDataParams.apply(this,arguments),i=this.getData().tree.getNodeByDataIndex(e);return n.treeAncestors=KC(i,this),n.treePathInfo=n.treeAncestors,n},e.prototype.setLayoutInfo=function(t){this.layoutInfo=this.layoutInfo||{},A(this.layoutInfo,t)},e.prototype.mapIdToIndex=function(t){var e=this._idIndexMap;e||(e=this._idIndexMap=yt(),this._idIndexMapCount=0);var n=e.get(t);return null==n&&e.set(t,n=this._idIndexMapCount++),n},e.prototype.getViewRoot=function(){return this._viewRoot},e.prototype.resetViewRoot=function(t){t?this._viewRoot=t:t=this._viewRoot;var e=this.getRawData().tree.root;t&&(t===e||e.contains(t))||(this._viewRoot=e)},e.prototype.enableAriaDecal=function(){nD(this)},e.type="series.treemap",e.layoutMode="box",e.defaultOption={progressive:0,left:"center",top:"middle",width:"80%",height:"80%",sort:!0,clipWindow:"origin",squareRatio:.5*(1+Math.sqrt(5)),leafDepth:null,drillDownIcon:"▶",zoomToNodeRatio:.1024,roam:!0,nodeClick:"zoomToNode",animation:!0,animationDurationUpdate:900,animationEasing:"quinticInOut",breadcrumb:{show:!0,height:22,left:"center",top:"bottom",emptyItemWidth:25,itemStyle:{color:"rgba(0,0,0,0.7)",textStyle:{color:"#fff"}},emphasis:{itemStyle:{color:"rgba(0,0,0,0.9)"}}},label:{show:!0,distance:0,padding:5,position:"inside",color:"#fff",overflow:"truncate"},upperLabel:{show:!1,position:[0,"50%"],height:20,overflow:"truncate",verticalAlign:"middle"},itemStyle:{color:null,colorAlpha:null,colorSaturation:null,borderWidth:0,gapWidth:0,borderColor:"#fff",borderColorSaturation:null},emphasis:{upperLabel:{show:!0,position:[0,"50%"],overflow:"truncate",verticalAlign:"middle"}},visualDimension:0,visualMin:null,visualMax:null,color:[],colorAlpha:null,colorSaturation:null,colorMappingBy:"index",visibleMin:10,childrenVisibleMin:null,levels:[]},e}(mg);function rD(t){var e=0;E(t.children,(function(t){rD(t);var n=t.value;Y(n)&&(n=n[0]),e+=n}));var n=t.value;Y(n)&&(n=n[0]),(null==n||isNaN(n))&&(n=e),n<0&&(n=0),Y(t.value)?t.value[0]=n:t.value=n}var oD=function(){function t(t){this.group=new zr,t.add(this.group)}return t.prototype.render=function(t,e,n,i){var r=t.getModel("breadcrumb"),o=this.group;if(o.removeAll(),r.get("show")&&n){var a=r.getModel("itemStyle"),s=r.getModel("emphasis"),l=a.getModel("textStyle"),u=s.getModel(["itemStyle","textStyle"]),h={pos:{left:r.get("left"),right:r.get("right"),top:r.get("top"),bottom:r.get("bottom")},box:{width:e.getWidth(),height:e.getHeight()},emptyItemWidth:r.get("emptyItemWidth"),totalWidth:0,renderList:[]};this._prepare(n,h,l),this._renderContent(t,h,a,s,l,u,i),Dp(o,h.pos,h.box)}},t.prototype._prepare=function(t,e,n){for(var i=t;i;i=i.parentNode){var r=Ao(i.getModel().get("name"),""),o=n.getTextRect(r),a=Math.max(o.width+16,e.emptyItemWidth);e.totalWidth+=a+8,e.renderList.push({node:i,text:r,width:a})}},t.prototype._renderContent=function(t,e,n,i,r,o,a){for(var s,l,u,h,c,p,d,f,g,y=0,v=e.emptyItemWidth,m=t.get(["breadcrumb","height"]),x=(s=e.pos,l=e.box,h=l.width,c=l.height,p=Ur(s.left,h),d=Ur(s.top,c),f=Ur(s.right,h),g=Ur(s.bottom,c),(isNaN(p)||isNaN(parseFloat(s.left)))&&(p=0),(isNaN(f)||isNaN(parseFloat(s.right)))&&(f=h),(isNaN(d)||isNaN(parseFloat(s.top)))&&(d=0),(isNaN(g)||isNaN(parseFloat(s.bottom)))&&(g=c),u=fp(u||0),{width:Math.max(f-p-u[1]-u[3],0),height:Math.max(g-d-u[0]-u[2],0)}),_=e.totalWidth,b=e.renderList,w=i.getModel("itemStyle").getItemStyle(),S=b.length-1;S>=0;S--){var M=b[S],I=M.node,T=M.width,C=M.text;_>x.width&&(_-=T-v,T=v,C=null);var D=new Wu({shape:{points:aD(y,0,T,m,S===b.length-1,0===S)},style:k(n.getItemStyle(),{lineJoin:"bevel"}),textContent:new Fs({style:nc(r,{text:C})}),textConfig:{position:"inside"},z2:1e5,onclick:H(a,I)});D.disableLabelAnimation=!0,D.getTextContent().ensureState("emphasis").style=nc(o,{text:C}),D.ensureState("emphasis").style=w,Yl(D,i.get("focus"),i.get("blurScope"),i.get("disabled")),this.group.add(D),sD(D,t,I),y+=T+8}},t.prototype.remove=function(){this.group.removeAll()},t}();function aD(t,e,n,i,r,o){var a=[[r?t:t-5,e],[t+n,e],[t+n,e+i],[r?t:t-5,e+i]];return!o&&a.splice(2,0,[t+n+5,e+i/2]),!r&&a.push([t,e+i/2]),a}function sD(t,e,n){Qs(t).eventData={componentType:"series",componentSubType:"treemap",componentIndex:e.componentIndex,seriesIndex:e.seriesIndex,seriesName:e.name,seriesType:"treemap",selfType:"breadcrumb",nodeData:{dataIndex:n&&n.dataIndex,name:n&&n.name},treePathInfo:n&&KC(n,e)}}var lD=function(){function t(){this._storage=[],this._elExistsMap={}}return t.prototype.add=function(t,e,n,i,r){return!this._elExistsMap[t.id]&&(this._elExistsMap[t.id]=!0,this._storage.push({el:t,target:e,duration:n,delay:i,easing:r}),!0)},t.prototype.finished=function(t){return this._finishedCallback=t,this},t.prototype.start=function(){for(var t=this,e=this._storage.length,n=function(){--e<=0&&(t._storage.length=0,t._elExistsMap={},t._finishedCallback&&t._finishedCallback())},i=0,r=this._storage.length;i3||Math.abs(t.dy)>3)){var e=this.seriesModel.getData().tree.root;if(!e)return;var n=e.getLayout();if(!n)return;this.api.dispatchAction({type:"treemapMove",from:this.uid,seriesId:this.seriesModel.id,rootRect:{x:n.x+t.dx,y:n.y+t.dy,width:n.width,height:n.height}})}},e.prototype._onZoom=function(t){var e=t.originX,n=t.originY;if("animating"!==this._state){var i=this.seriesModel.getData().tree.root;if(!i)return;var r=i.getLayout();if(!r)return;var o=new ze(r.x,r.y,r.width,r.height),a=this.seriesModel.layoutInfo,s=[1,0,0,1,0,0];we(s,s,[-(e-=a.x),-(n-=a.y)]),Me(s,s,[t.scale,t.scale]),we(s,s,[e,n]),o.applyTransform(s),this.api.dispatchAction({type:"treemapRender",from:this.uid,seriesId:this.seriesModel.id,rootRect:{x:o.x,y:o.y,width:o.width,height:o.height}})}},e.prototype._initEvents=function(t){var e=this;t.on("click",(function(t){if("ready"===e._state){var n=e.seriesModel.get("nodeClick",!0);if(n){var i=e.findTarget(t.offsetX,t.offsetY);if(i){var r=i.node;if(r.getLayout().isLeafRoot)e._rootToNode(i);else if("zoomToNode"===n)e._zoomToNode(i);else if("link"===n){var o=r.hostTree.data.getItemModel(r.dataIndex),a=o.get("link",!0),s=o.get("target",!0)||"blank";a&&bp(a,s)}}}}}),this)},e.prototype._renderBreadcrumb=function(t,e,n){var i=this;n||(n=null!=t.get("leafDepth",!0)?{node:t.getViewRoot()}:this.findTarget(e.getWidth()/2,e.getHeight()/2))||(n={node:t.getData().tree.root}),(this._breadcrumb||(this._breadcrumb=new oD(this.group))).render(t,e,n.node,(function(e){"animating"!==i._state&&(qC(t.getViewRoot(),e)?i._rootToNode({node:e}):i._zoomToNode({node:e}))}))},e.prototype.remove=function(){this._clearController(),this._containerGroup&&this._containerGroup.removeAll(),this._storage={nodeGroup:[],background:[],content:[]},this._state="ready",this._breadcrumb&&this._breadcrumb.remove()},e.prototype.dispose=function(){this._clearController()},e.prototype._zoomToNode=function(t){this.api.dispatchAction({type:"treemapZoomToNode",from:this.uid,seriesId:this.seriesModel.id,targetNode:t.node})},e.prototype._rootToNode=function(t){this.api.dispatchAction({type:"treemapRootToNode",from:this.uid,seriesId:this.seriesModel.id,targetNode:t.node})},e.prototype.findTarget=function(t,e){var n;return this.seriesModel.getViewRoot().eachNode({attr:"viewChildren",order:"preorder"},(function(i){var r=this._storage.background[i.getRawIndex()];if(r){var o=r.transformCoordToLocal(t,e),a=r.shape;if(!(a.x<=o[0]&&o[0]<=a.x+a.width&&a.y<=o[1]&&o[1]<=a.y+a.height))return!1;n={node:i,offsetX:o[0],offsetY:o[1]}}}),this),n},e.type="treemap",e}(kg);var vD=E,mD=q,xD=-1,_D=function(){function t(e){var n=e.mappingMethod,i=e.type,r=this.option=T(e);this.type=i,this.mappingMethod=n,this._normalizeData=kD[n];var o=t.visualHandlers[i];this.applyVisual=o.applyVisual,this.getColorMapper=o.getColorMapper,this._normalizedToVisual=o._normalizedToVisual[n],"piecewise"===n?(bD(r),function(t){var e=t.pieceList;t.hasSpecialVisual=!1,E(e,(function(e,n){e.originIndex=n,null!=e.visual&&(t.hasSpecialVisual=!0)}))}(r)):"category"===n?r.categories?function(t){var e=t.categories,n=t.categoryMap={},i=t.visual;if(vD(e,(function(t,e){n[t]=e})),!Y(i)){var r=[];q(i)?vD(i,(function(t,e){var i=n[e];r[null!=i?i:xD]=t})):r[-1]=i,i=AD(t,r)}for(var o=e.length-1;o>=0;o--)null==i[o]&&(delete n[e[o]],e.pop())}(r):bD(r,!0):(lt("linear"!==n||r.dataExtent),bD(r))}return t.prototype.mapValueToVisual=function(t){var e=this._normalizeData(t);return this._normalizedToVisual(e,t)},t.prototype.getNormalizer=function(){return W(this._normalizeData,this)},t.listVisualTypes=function(){return G(t.visualHandlers)},t.isValidType=function(e){return t.visualHandlers.hasOwnProperty(e)},t.eachVisual=function(t,e,n){q(t)?E(t,e,n):e.call(n,t)},t.mapVisual=function(e,n,i){var r,o=Y(e)?[]:q(e)?{}:(r=!0,null);return t.eachVisual(e,(function(t,e){var a=n.call(i,t,e);r?o=a:o[e]=a})),o},t.retrieveVisuals=function(e){var n,i={};return e&&vD(t.visualHandlers,(function(t,r){e.hasOwnProperty(r)&&(i[r]=e[r],n=!0)})),n?i:null},t.prepareVisualTypes=function(t){if(Y(t))t=t.slice();else{if(!mD(t))return[];var e=[];vD(t,(function(t,n){e.push(n)})),t=e}return t.sort((function(t,e){return"color"===e&&"color"!==t&&0===t.indexOf("color")?1:-1})),t},t.dependsOn=function(t,e){return"color"===e?!(!t||0!==t.indexOf(e)):t===e},t.findPieceIndex=function(t,e,n){for(var i,r=1/0,o=0,a=e.length;ou[1]&&(u[1]=l);var h=e.get("colorMappingBy"),c={type:a.name,dataExtent:u,visual:a.range};"color"!==c.type||"index"!==h&&"id"!==h?c.mappingMethod="linear":(c.mappingMethod="category",c.loop=!0);var p=new _D(c);return PD(p).drColorMappingBy=h,p}(0,r,o,0,u,d);E(d,(function(t,e){if(t.depth>=n.length||t===n[t.depth]){var o=function(t,e,n,i,r,o){var a=A({},e);if(r){var s=r.type,l="color"===s&&PD(r).drColorMappingBy,u="index"===l?i:"id"===l?o.mapIdToIndex(n.getId()):n.getValue(t.get("visualDimension"));a[s]=r.mapValueToVisual(u)}return a}(r,u,t,e,f,i);RD(t,o,n,i)}}))}else s=ND(u),h.fill=s}}function ND(t){var e=ED(t,"color");if(e){var n=ED(t,"colorAlpha"),i=ED(t,"colorSaturation");return i&&(e=ni(e,null,null,i)),n&&(e=ii(e,n)),e}}function ED(t,e){var n=t[e];if(null!=n&&"none"!==n)return n}function zD(t,e){var n=t.get(e);return Y(n)&&n.length?{name:e,range:n}:null}var VD=Math.max,BD=Math.min,FD=it,GD=E,WD=["itemStyle","borderWidth"],HD=["itemStyle","gapWidth"],YD=["upperLabel","show"],XD=["upperLabel","height"],UD={seriesType:"treemap",reset:function(t,e,n,i){var r=n.getWidth(),o=n.getHeight(),a=t.option,s=Cp(t.getBoxLayoutParams(),{width:n.getWidth(),height:n.getHeight()}),l=a.size||[],u=Ur(FD(s.width,l[0]),r),h=Ur(FD(s.height,l[1]),o),c=i&&i.type,p=ZC(i,["treemapZoomToNode","treemapRootToNode"],t),d="treemapRender"===c||"treemapMove"===c?i.rootRect:null,f=t.getViewRoot(),g=jC(f);if("treemapMove"!==c){var y="treemapZoomToNode"===c?function(t,e,n,i,r){var o,a=(e||{}).node,s=[i,r];if(!a||a===n)return s;var l=i*r,u=l*t.option.zoomToNodeRatio;for(;o=a.parentNode;){for(var h=0,c=o.children,p=0,d=c.length;pto&&(u=to),a=o}ua[1]&&(a[1]=e)}))):a=[NaN,NaN];return{sum:i,dataExtent:a}}(e,a,s);if(0===u.sum)return t.viewChildren=[];if(u.sum=function(t,e,n,i,r){if(!i)return n;for(var o=t.get("visibleMin"),a=r.length,s=a,l=a-1;l>=0;l--){var u=r["asc"===i?a-l-1:l].getValue();u/n*ei&&(i=a));var l=t.area*t.area,u=e*e*n;return l?VD(u*i/l,l/(u*r)):1/0}function qD(t,e,n,i,r){var o=e===n.width?0:1,a=1-o,s=["x","y"],l=["width","height"],u=n[s[o]],h=e?t.area/e:0;(r||h>n[l[a]])&&(h=n[l[a]]);for(var c=0,p=t.length;ci&&(i=e);var o=i%2?i+2:i+3;r=[];for(var a=0;a0&&(m[0]=-m[0],m[1]=-m[1]);var _=v[0]<0?-1:1;if("start"!==i.__position&&"end"!==i.__position){var b=-Math.atan2(v[1],v[0]);u[0].8?"left":h[0]<-.8?"right":"center",p=h[1]>.8?"top":h[1]<-.8?"bottom":"middle";break;case"start":i.x=-h[0]*f+l[0],i.y=-h[1]*g+l[1],c=h[0]>.8?"right":h[0]<-.8?"left":"center",p=h[1]>.8?"bottom":h[1]<-.8?"top":"middle";break;case"insideStartTop":case"insideStart":case"insideStartBottom":i.x=f*_+l[0],i.y=l[1]+w,c=v[0]<0?"right":"left",i.originX=-f*_,i.originY=-w;break;case"insideMiddleTop":case"insideMiddle":case"insideMiddleBottom":case"middle":i.x=x[0],i.y=x[1]+w,c="center",i.originY=-w;break;case"insideEndTop":case"insideEnd":case"insideEndBottom":i.x=-f*_+u[0],i.y=u[1]+w,c=v[0]>=0?"right":"left",i.originX=f*_,i.originY=-w}i.scaleX=i.scaleY=r,i.setStyle({verticalAlign:i.__verticalAlign||p,align:i.__align||c})}}}function S(t,e){var n=t.__specifiedRotation;if(null==n){var i=a.tangentAt(e);t.attr("rotation",(1===e?-1:1)*Math.PI/2-Math.atan2(i[1],i[0]))}else t.attr("rotation",n)}},e}(zr),RA=function(){function t(t){this.group=new zr,this._LineCtor=t||OA}return t.prototype.updateData=function(t){var e=this;this._progressiveEls=null;var n=this,i=n.group,r=n._lineData;n._lineData=t,r||i.removeAll();var o=NA(t);t.diff(r).add((function(n){e._doAdd(t,n,o)})).update((function(n,i){e._doUpdate(r,t,i,n,o)})).remove((function(t){i.remove(r.getItemGraphicEl(t))})).execute()},t.prototype.updateLayout=function(){var t=this._lineData;t&&t.eachItemGraphicEl((function(e,n){e.updateLayout(t,n)}),this)},t.prototype.incrementalPrepareUpdate=function(t){this._seriesScope=NA(t),this._lineData=null,this.group.removeAll()},t.prototype.incrementalUpdate=function(t,e){function n(t){t.isGroup||function(t){return t.animators&&t.animators.length>0}(t)||(t.incremental=!0,t.ensureState("emphasis").hoverLayer=!0)}this._progressiveEls=[];for(var i=t.start;i=0?i+=u:i-=u:f>=0?i-=u:i+=u}return i}function XA(t,e){var n=[],i=Dn,r=[[],[],[]],o=[[],[]],a=[];e/=2,t.eachEdge((function(t,s){var l=t.getLayout(),u=t.getVisual("fromSymbol"),h=t.getVisual("toSymbol");l.__original||(l.__original=[Tt(l[0]),Tt(l[1])],l[2]&&l.__original.push(Tt(l[2])));var c=l.__original;if(null!=l[2]){if(It(r[0],c[0]),It(r[1],c[2]),It(r[2],c[1]),u&&"none"!==u){var p=dA(t.node1),d=YA(r,c[0],p*e);i(r[0][0],r[1][0],r[2][0],d,n),r[0][0]=n[3],r[1][0]=n[4],i(r[0][1],r[1][1],r[2][1],d,n),r[0][1]=n[3],r[1][1]=n[4]}if(h&&"none"!==h){p=dA(t.node2),d=YA(r,c[1],p*e);i(r[0][0],r[1][0],r[2][0],d,n),r[1][0]=n[1],r[2][0]=n[2],i(r[0][1],r[1][1],r[2][1],d,n),r[1][1]=n[1],r[2][1]=n[2]}It(l[0],r[0]),It(l[1],r[2]),It(l[2],r[1])}else{if(It(o[0],c[0]),It(o[1],c[1]),kt(a,o[1],o[0]),Et(a,a),u&&"none"!==u){p=dA(t.node1);At(o[0],o[0],a,p*e)}if(h&&"none"!==h){p=dA(t.node2);At(o[1],o[1],a,-p*e)}It(l[0],o[0]),It(l[1],o[1])}}))}function UA(t){return"view"===t.type}var ZA=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.prototype.init=function(t,e){var n=new hS,i=new RA,r=this.group;this._controller=new UI(e.getZr()),this._controllerHost={target:r},r.add(n.group),r.add(i.group),this._symbolDraw=n,this._lineDraw=i,this._firstRender=!0},e.prototype.render=function(t,e,n){var i=this,r=t.coordinateSystem;this._model=t;var o=this._symbolDraw,a=this._lineDraw,s=this.group;if(UA(r)){var l={x:r.x,y:r.y,scaleX:r.scaleX,scaleY:r.scaleY};this._firstRender?s.attr(l):fh(s,l,t)}XA(t.getGraph(),pA(t));var u=t.getData();o.updateData(u);var h=t.getEdgeData();a.updateData(h),this._updateNodeAndLinkScale(),this._updateController(t,e,n),clearTimeout(this._layoutTimeout);var c=t.forceLayout,p=t.get(["force","layoutAnimation"]);c&&this._startForceLayoutIteration(c,p);var d=t.get("layout");u.graph.eachNode((function(e){var n=e.dataIndex,r=e.getGraphicEl(),o=e.getModel();if(r){r.off("drag").off("dragend");var a=o.get("draggable");a&&r.on("drag",(function(o){switch(d){case"force":c.warmUp(),!i._layouting&&i._startForceLayoutIteration(c,p),c.setFixed(n),u.setItemLayout(n,[r.x,r.y]);break;case"circular":u.setItemLayout(n,[r.x,r.y]),e.setLayout({fixed:!0},!0),yA(t,"symbolSize",e,[o.offsetX,o.offsetY]),i.updateLayout(t);break;default:u.setItemLayout(n,[r.x,r.y]),hA(t.getGraph(),t),i.updateLayout(t)}})).on("dragend",(function(){c&&c.setUnfixed(n)})),r.setDraggable(a,!!o.get("cursor")),"adjacency"===o.get(["emphasis","focus"])&&(Qs(r).focus=e.getAdjacentDataIndices())}})),u.graph.eachEdge((function(t){var e=t.getGraphicEl(),n=t.getModel().get(["emphasis","focus"]);e&&"adjacency"===n&&(Qs(e).focus={edge:[t.dataIndex],node:[t.node1.dataIndex,t.node2.dataIndex]})}));var f="circular"===t.get("layout")&&t.get(["circular","rotateLabel"]),g=u.getLayout("cx"),y=u.getLayout("cy");u.graph.eachNode((function(t){mA(t,f,g,y)})),this._firstRender=!1},e.prototype.dispose=function(){this._controller&&this._controller.dispose(),this._controllerHost=null},e.prototype._startForceLayoutIteration=function(t,e){var n=this;!function i(){t.step((function(t){n.updateLayout(n._model),(n._layouting=!t)&&(e?n._layoutTimeout=setTimeout(i,16):i())}))}()},e.prototype._updateController=function(t,e,n){var i=this,r=this._controller,o=this._controllerHost,a=this.group;r.setPointerChecker((function(e,i,r){var o=a.getBoundingRect();return o.applyTransform(a.transform),o.contain(i,r)&&!tT(e,n,t)})),UA(t.coordinateSystem)?(r.enable(t.get("roam")),o.zoomLimit=t.get("scaleLimit"),o.zoom=t.coordinateSystem.getZoom(),r.off("pan").off("zoom").on("pan",(function(e){KI(o,e.dx,e.dy),n.dispatchAction({seriesId:t.id,type:"graphRoam",dx:e.dx,dy:e.dy})})).on("zoom",(function(e){$I(o,e.scale,e.originX,e.originY),n.dispatchAction({seriesId:t.id,type:"graphRoam",zoom:e.scale,originX:e.originX,originY:e.originY}),i._updateNodeAndLinkScale(),XA(t.getGraph(),pA(t)),i._lineDraw.updateLayout(),n.updateLabelLayout()}))):r.disable()},e.prototype._updateNodeAndLinkScale=function(){var t=this._model,e=t.getData(),n=pA(t);e.eachItemGraphicEl((function(t,e){t&&t.setSymbolScale(n)}))},e.prototype.updateLayout=function(t){XA(t.getGraph(),pA(t)),this._symbolDraw.updateLayout(),this._lineDraw.updateLayout()},e.prototype.remove=function(t,e){this._symbolDraw&&this._symbolDraw.remove(),this._lineDraw&&this._lineDraw.remove()},e.type="graph",e}(kg);function jA(t){return"_EC_"+t}var qA=function(){function t(t){this.type="graph",this.nodes=[],this.edges=[],this._nodesMap={},this._edgesMap={},this._directed=t||!1}return t.prototype.isDirected=function(){return this._directed},t.prototype.addNode=function(t,e){t=null==t?""+e:""+t;var n=this._nodesMap;if(!n[jA(t)]){var i=new KA(t,e);return i.hostGraph=this,this.nodes.push(i),n[jA(t)]=i,i}},t.prototype.getNodeByIndex=function(t){var e=this.data.getRawIndex(t);return this.nodes[e]},t.prototype.getNodeById=function(t){return this._nodesMap[jA(t)]},t.prototype.addEdge=function(t,e,n){var i=this._nodesMap,r=this._edgesMap;if(j(t)&&(t=this.nodes[t]),j(e)&&(e=this.nodes[e]),t instanceof KA||(t=i[jA(t)]),e instanceof KA||(e=i[jA(e)]),t&&e){var o=t.id+"-"+e.id,a=new $A(t,e,n);return a.hostGraph=this,this._directed&&(t.outEdges.push(a),e.inEdges.push(a)),t.edges.push(a),t!==e&&e.edges.push(a),this.edges.push(a),r[o]=a,a}},t.prototype.getEdgeByIndex=function(t){var e=this.edgeData.getRawIndex(t);return this.edges[e]},t.prototype.getEdge=function(t,e){t instanceof KA&&(t=t.id),e instanceof KA&&(e=e.id);var n=this._edgesMap;return this._directed?n[t+"-"+e]:n[t+"-"+e]||n[e+"-"+t]},t.prototype.eachNode=function(t,e){for(var n=this.nodes,i=n.length,r=0;r=0&&t.call(e,n[r],r)},t.prototype.eachEdge=function(t,e){for(var n=this.edges,i=n.length,r=0;r=0&&n[r].node1.dataIndex>=0&&n[r].node2.dataIndex>=0&&t.call(e,n[r],r)},t.prototype.breadthFirstTraverse=function(t,e,n,i){if(e instanceof KA||(e=this._nodesMap[jA(e)]),e){for(var r="out"===n?"outEdges":"in"===n?"inEdges":"edges",o=0;o=0&&n.node2.dataIndex>=0}));for(r=0,o=i.length;r=0&&this[t][e].setItemVisual(this.dataIndex,n,i)},getVisual:function(n){return this[t][e].getItemVisual(this.dataIndex,n)},setLayout:function(n,i){this.dataIndex>=0&&this[t][e].setItemLayout(this.dataIndex,n,i)},getLayout:function(){return this[t][e].getItemLayout(this.dataIndex)},getGraphicEl:function(){return this[t][e].getItemGraphicEl(this.dataIndex)},getRawIndex:function(){return this[t][e].getRawIndex(this.dataIndex)}}}function QA(t,e,n,i,r){for(var o=new qA(i),a=0;a "+p)),u++)}var d,f=n.get("coordinateSystem");if("cartesian2d"===f||"polar"===f)d=vx(t,n);else{var g=xd.get(f),y=g&&g.dimensions||[];P(y,"value")<0&&y.concat(["value"]);var v=ux(t,{coordDimensions:y,encodeDefine:n.getEncode()}).dimensions;(d=new lx(v,n)).initData(t)}var m=new lx(["value"],n);return m.initData(l,s),r&&r(d,m),zC({mainData:d,struct:o,structAttr:"graph",datas:{node:d,edge:m},datasAttr:{node:"data",edge:"edgeData"}}),o.update(),o}R(KA,JA("hostGraph","data")),R($A,JA("hostGraph","edgeData"));var tk=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.hasSymbolVisual=!0,n}return n(e,t),e.prototype.init=function(e){t.prototype.init.apply(this,arguments);var n=this;function i(){return n._categoriesData}this.legendVisualProvider=new IM(i,i),this.fillDataTextStyle(e.edges||e.links),this._updateCategoriesData()},e.prototype.mergeOption=function(e){t.prototype.mergeOption.apply(this,arguments),this.fillDataTextStyle(e.edges||e.links),this._updateCategoriesData()},e.prototype.mergeDefaultAndTheme=function(e){t.prototype.mergeDefaultAndTheme.apply(this,arguments),wo(e,"edgeLabel",["show"])},e.prototype.getInitialData=function(t,e){var n,i=t.edges||t.links||[],r=t.data||t.nodes||[],o=this;if(r&&i){iA(n=this)&&(n.__curvenessList=[],n.__edgeMap={},rA(n));var a=QA(r,i,this,!0,(function(t,e){t.wrapMethod("getItemModel",(function(t){var e=o._categoriesModels[t.getShallow("category")];return e&&(e.parentModel=t.parentModel,t.parentModel=e),t}));var n=Mc.prototype.getModel;function i(t,e){var i=n.call(this,t,e);return i.resolveParentPath=r,i}function r(t){if(t&&("label"===t[0]||"label"===t[1])){var e=t.slice();return"label"===t[0]?e[0]="edgeLabel":"label"===t[1]&&(e[1]="edgeLabel"),e}return t}e.wrapMethod("getItemModel",(function(t){return t.resolveParentPath=r,t.getModel=i,t}))}));return E(a.edges,(function(t){!function(t,e,n,i){if(iA(n)){var r=oA(t,e,n),o=n.__edgeMap,a=o[aA(r)];o[r]&&!a?o[r].isForward=!0:a&&o[r]&&(a.isForward=!0,o[r].isForward=!1),o[r]=o[r]||[],o[r].push(i)}}(t.node1,t.node2,this,t.dataIndex)}),this),a.data}},e.prototype.getGraph=function(){return this.getData().graph},e.prototype.getEdgeData=function(){return this.getGraph().edgeData},e.prototype.getCategoriesData=function(){return this._categoriesData},e.prototype.formatTooltip=function(t,e,n){if("edge"===n){var i=this.getData(),r=this.getDataParams(t,n),o=i.graph.getEdgeByIndex(t),a=i.getName(o.node1.dataIndex),s=i.getName(o.node2.dataIndex),l=[];return null!=a&&l.push(a),null!=s&&l.push(s),ng("nameValue",{name:l.join(" > "),value:r.value,noValue:null==r.value})}return fg({series:this,dataIndex:t,multipleSeries:e})},e.prototype._updateCategoriesData=function(){var t=z(this.option.categories||[],(function(t){return null!=t.value?t:A({value:0},t)})),e=new lx(["value"],this);e.initData(t),this._categoriesData=e,this._categoriesModels=e.mapArray((function(t){return e.getItemModel(t)}))},e.prototype.setZoom=function(t){this.option.zoom=t},e.prototype.setCenter=function(t){this.option.center=t},e.prototype.isAnimationEnabled=function(){return t.prototype.isAnimationEnabled.call(this)&&!("force"===this.get("layout")&&this.get(["force","layoutAnimation"]))},e.type="series.graph",e.dependencies=["grid","polar","geo","singleAxis","calendar"],e.defaultOption={z:2,coordinateSystem:"view",legendHoverLink:!0,layout:null,circular:{rotateLabel:!1},force:{initLayout:null,repulsion:[0,50],gravity:.1,friction:.6,edgeLength:30,layoutAnimation:!0},left:"center",top:"center",symbol:"circle",symbolSize:10,edgeSymbol:["none","none"],edgeSymbolSize:10,edgeLabel:{position:"middle",distance:5},draggable:!1,roam:!1,center:null,zoom:1,nodeScaleRatio:.6,label:{show:!1,formatter:"{b}"},itemStyle:{},lineStyle:{color:"#aaa",width:1,opacity:.5},emphasis:{scale:!0,label:{show:!0}},select:{itemStyle:{borderColor:"#212121"}}},e}(mg),ek={type:"graphRoam",event:"graphRoam",update:"none"};var nk=function(){this.angle=0,this.width=10,this.r=10,this.x=0,this.y=0},ik=function(t){function e(e){var n=t.call(this,e)||this;return n.type="pointer",n}return n(e,t),e.prototype.getDefaultShape=function(){return new nk},e.prototype.buildPath=function(t,e){var n=Math.cos,i=Math.sin,r=e.r,o=e.width,a=e.angle,s=e.x-n(a)*o*(o>=r/3?1:2),l=e.y-i(a)*o*(o>=r/3?1:2);a=e.angle-Math.PI/2,t.moveTo(s,l),t.lineTo(e.x+n(a)*o,e.y+i(a)*o),t.lineTo(e.x+n(e.angle)*r,e.y+i(e.angle)*r),t.lineTo(e.x-n(a)*o,e.y-i(a)*o),t.lineTo(s,l)},e}(Is);function rk(t,e){var n=null==t?"":t+"";return e&&(U(e)?n=e.replace("{value}",n):X(e)&&(n=e(t))),n}var ok=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.prototype.render=function(t,e,n){this.group.removeAll();var i=t.get(["axisLine","lineStyle","color"]),r=function(t,e){var n=t.get("center"),i=e.getWidth(),r=e.getHeight(),o=Math.min(i,r);return{cx:Ur(n[0],e.getWidth()),cy:Ur(n[1],e.getHeight()),r:Ur(t.get("radius"),o/2)}}(t,n);this._renderMain(t,e,n,i,r),this._data=t.getData()},e.prototype.dispose=function(){},e.prototype._renderMain=function(t,e,n,i,r){var o=this.group,a=t.get("clockwise"),s=-t.get("startAngle")/180*Math.PI,l=-t.get("endAngle")/180*Math.PI,u=t.getModel("axisLine"),h=u.get("roundCap")?HS:zu,c=u.get("show"),p=u.getModel("lineStyle"),d=p.get("width"),f=[s,l];rs(f,!a);for(var g=(l=f[1])-(s=f[0]),y=s,v=[],m=0;c&&m=t&&(0===e?0:i[e-1][0])Math.PI/2&&(V+=Math.PI):"tangential"===z?V=-M-Math.PI/2:j(z)&&(V=z*Math.PI/180),0===V?c.add(new Fs({style:nc(x,{text:O,x:N,y:E,verticalAlign:h<-.8?"top":h>.8?"bottom":"middle",align:u<-.4?"left":u>.4?"right":"center"},{inheritColor:R}),silent:!0})):c.add(new Fs({style:nc(x,{text:O,x:N,y:E,verticalAlign:"middle",align:"center"},{inheritColor:R}),silent:!0,originX:N,originY:E,rotation:V}))}if(m.get("show")&&k!==_){P=(P=m.get("distance"))?P+l:l;for(var B=0;B<=b;B++){u=Math.cos(M),h=Math.sin(M);var F=new Zu({shape:{x1:u*(f-P)+p,y1:h*(f-P)+d,x2:u*(f-S-P)+p,y2:h*(f-S-P)+d},silent:!0,style:D});"auto"===D.stroke&&F.setStyle({stroke:i((k+B/b)/_)}),c.add(F),M+=T}M-=T}else M+=I}},e.prototype._renderPointer=function(t,e,n,i,r,o,a,s,l){var u=this.group,h=this._data,c=this._progressEls,p=[],d=t.get(["pointer","show"]),f=t.getModel("progress"),g=f.get("show"),y=t.getData(),v=y.mapDimension("value"),m=+t.get("min"),x=+t.get("max"),_=[m,x],b=[o,a];function w(e,n){var i,o=y.getItemModel(e).getModel("pointer"),a=Ur(o.get("width"),r.r),s=Ur(o.get("length"),r.r),l=t.get(["pointer","icon"]),u=o.get("offsetCenter"),h=Ur(u[0],r.r),c=Ur(u[1],r.r),p=o.get("keepAspect");return(i=l?Wy(l,h-a/2,c-s,a,s,null,p):new ik({shape:{angle:-Math.PI/2,width:a,r:s,x:h,y:c}})).rotation=-(n+Math.PI/2),i.x=r.cx,i.y=r.cy,i}function S(t,e){var n=f.get("roundCap")?HS:zu,i=f.get("overlap"),a=i?f.get("width"):l/y.count(),u=i?r.r-a:r.r-(t+1)*a,h=i?r.r:r.r-t*a,c=new n({shape:{startAngle:o,endAngle:e,cx:r.cx,cy:r.cy,clockwise:s,r0:u,r:h}});return i&&(c.z2=x-y.get(v,t)%x),c}(g||d)&&(y.diff(h).add((function(e){var n=y.get(v,e);if(d){var i=w(e,o);gh(i,{rotation:-((isNaN(+n)?b[0]:Xr(n,_,b,!0))+Math.PI/2)},t),u.add(i),y.setItemGraphicEl(e,i)}if(g){var r=S(e,o),a=f.get("clip");gh(r,{shape:{endAngle:Xr(n,_,b,a)}},t),u.add(r),tl(t.seriesIndex,y.dataType,e,r),p[e]=r}})).update((function(e,n){var i=y.get(v,e);if(d){var r=h.getItemGraphicEl(n),a=r?r.rotation:o,s=w(e,a);s.rotation=a,fh(s,{rotation:-((isNaN(+i)?b[0]:Xr(i,_,b,!0))+Math.PI/2)},t),u.add(s),y.setItemGraphicEl(e,s)}if(g){var l=c[n],m=S(e,l?l.shape.endAngle:o),x=f.get("clip");fh(m,{shape:{endAngle:Xr(i,_,b,x)}},t),u.add(m),tl(t.seriesIndex,y.dataType,e,m),p[e]=m}})).execute(),y.each((function(t){var e=y.getItemModel(t),n=e.getModel("emphasis"),r=n.get("focus"),o=n.get("blurScope"),a=n.get("disabled");if(d){var s=y.getItemGraphicEl(t),l=y.getItemVisual(t,"style"),u=l.fill;if(s instanceof ks){var h=s.style;s.useStyle(A({image:h.image,x:h.x,y:h.y,width:h.width,height:h.height},l))}else s.useStyle(l),"pointer"!==s.type&&s.setColor(u);s.setStyle(e.getModel(["pointer","itemStyle"]).getItemStyle()),"auto"===s.style.fill&&s.setStyle("fill",i(Xr(y.get(v,t),_,[0,1],!0))),s.z2EmphasisLift=0,jl(s,e),Yl(s,r,o,a)}if(g){var c=p[t];c.useStyle(y.getItemVisual(t,"style")),c.setStyle(e.getModel(["progress","itemStyle"]).getItemStyle()),c.z2EmphasisLift=0,jl(c,e),Yl(c,r,o,a)}})),this._progressEls=p)},e.prototype._renderAnchor=function(t,e){var n=t.getModel("anchor");if(n.get("show")){var i=n.get("size"),r=n.get("icon"),o=n.get("offsetCenter"),a=n.get("keepAspect"),s=Wy(r,e.cx-i/2+Ur(o[0],e.r),e.cy-i/2+Ur(o[1],e.r),i,i,null,a);s.z2=n.get("showAbove")?1:0,s.setStyle(n.getModel("itemStyle").getItemStyle()),this.group.add(s)}},e.prototype._renderTitleAndDetail=function(t,e,n,i,r){var o=this,a=t.getData(),s=a.mapDimension("value"),l=+t.get("min"),u=+t.get("max"),h=new zr,c=[],p=[],d=t.isAnimationEnabled(),f=t.get(["pointer","showAbove"]);a.diff(this._data).add((function(t){c[t]=new Fs({silent:!0}),p[t]=new Fs({silent:!0})})).update((function(t,e){c[t]=o._titleEls[e],p[t]=o._detailEls[e]})).execute(),a.each((function(e){var n=a.getItemModel(e),o=a.get(s,e),g=new zr,y=i(Xr(o,[l,u],[0,1],!0)),v=n.getModel("title");if(v.get("show")){var m=v.get("offsetCenter"),x=r.cx+Ur(m[0],r.r),_=r.cy+Ur(m[1],r.r);(D=c[e]).attr({z2:f?0:2,style:nc(v,{x:x,y:_,text:a.getName(e),align:"center",verticalAlign:"middle"},{inheritColor:y})}),g.add(D)}var b=n.getModel("detail");if(b.get("show")){var w=b.get("offsetCenter"),S=r.cx+Ur(w[0],r.r),M=r.cy+Ur(w[1],r.r),I=Ur(b.get("width"),r.r),T=Ur(b.get("height"),r.r),C=t.get(["progress","show"])?a.getItemVisual(e,"style").fill:y,D=p[e],A=b.get("formatter");D.attr({z2:f?0:2,style:nc(b,{x:S,y:M,text:rk(o,A),width:isNaN(I)?null:I,height:isNaN(T)?null:T,align:"center",verticalAlign:"middle"},{inheritColor:C})}),hc(D,{normal:b},o,(function(t){return rk(t,A)})),d&&cc(D,e,a,t,{getFormattedLabel:function(t,e,n,i,r,a){return rk(a?a.interpolatedValue:o,A)}}),g.add(D)}h.add(g)})),this.group.add(h),this._titleEls=c,this._detailEls=p},e.type="gauge",e}(kg),ak=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.visualStyleAccessPath="itemStyle",n}return n(e,t),e.prototype.getInitialData=function(t,e){return MM(this,["value"])},e.type="series.gauge",e.defaultOption={z:2,colorBy:"data",center:["50%","50%"],legendHoverLink:!0,radius:"75%",startAngle:225,endAngle:-45,clockwise:!0,min:0,max:100,splitNumber:10,axisLine:{show:!0,roundCap:!1,lineStyle:{color:[[1,"#E6EBF8"]],width:10}},progress:{show:!1,overlap:!0,width:10,roundCap:!1,clip:!0},splitLine:{show:!0,length:10,distance:10,lineStyle:{color:"#63677A",width:3,type:"solid"}},axisTick:{show:!0,splitNumber:5,length:6,distance:10,lineStyle:{color:"#63677A",width:1,type:"solid"}},axisLabel:{show:!0,distance:15,color:"#464646",fontSize:12,rotate:0},pointer:{icon:null,offsetCenter:[0,0],show:!0,showAbove:!0,length:"60%",width:6,keepAspect:!1},anchor:{show:!1,showAbove:!1,size:6,icon:"circle",offsetCenter:[0,0],keepAspect:!1,itemStyle:{color:"#fff",borderWidth:0,borderColor:"#5470c6"}},title:{show:!0,offsetCenter:[0,"20%"],color:"#464646",fontSize:16,valueAnimation:!1},detail:{show:!0,backgroundColor:"rgba(0,0,0,0)",borderWidth:0,borderColor:"#ccc",width:100,height:null,padding:[5,10],offsetCenter:[0,"40%"],color:"#464646",fontSize:30,fontWeight:"bold",lineHeight:30,valueAnimation:!1}},e}(mg);var sk=["itemStyle","opacity"],lk=function(t){function e(e,n){var i=t.call(this)||this,r=i,o=new Yu,a=new Fs;return r.setTextContent(a),i.setTextGuideLine(o),i.updateData(e,n,!0),i}return n(e,t),e.prototype.updateData=function(t,e,n){var i=this,r=t.hostModel,o=t.getItemModel(e),a=t.getItemLayout(e),s=o.getModel("emphasis"),l=o.get(sk);l=null==l?1:l,n||_h(i),i.useStyle(t.getItemVisual(e,"style")),i.style.lineJoin="round",n?(i.setShape({points:a.points}),i.style.opacity=0,gh(i,{style:{opacity:l}},r,e)):fh(i,{style:{opacity:l},shape:{points:a.points}},r,e),jl(i,o),this._updateLabel(t,e),Yl(this,s.get("focus"),s.get("blurScope"),s.get("disabled"))},e.prototype._updateLabel=function(t,e){var n=this,i=this.getTextGuideLine(),r=n.getTextContent(),o=t.hostModel,a=t.getItemModel(e),s=t.getItemLayout(e).label,l=t.getItemVisual(e,"style"),u=l.fill;tc(r,ec(a),{labelFetcher:t.hostModel,labelDataIndex:e,defaultOpacity:l.opacity,defaultText:t.getName(e)},{normal:{align:s.textAlign,verticalAlign:s.verticalAlign}}),n.setTextConfig({local:!0,inside:!!s.inside,insideStroke:u,outsideFill:u});var h=s.linePoints;i.setShape({points:h}),n.textGuideLineConfig={anchor:h?new De(h[0][0],h[0][1]):null},fh(r,{style:{x:s.x,y:s.y}},o,e),r.attr({rotation:s.rotation,originX:s.x,originY:s.y,z2:10}),Tb(n,Cb(a),{stroke:u})},e}(Wu),uk=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.ignoreLabelLineUpdate=!0,n}return n(e,t),e.prototype.render=function(t,e,n){var i=t.getData(),r=this._data,o=this.group;i.diff(r).add((function(t){var e=new lk(i,t);i.setItemGraphicEl(t,e),o.add(e)})).update((function(t,e){var n=r.getItemGraphicEl(e);n.updateData(i,t),o.add(n),i.setItemGraphicEl(t,n)})).remove((function(e){xh(r.getItemGraphicEl(e),t,e)})).execute(),this._data=i},e.prototype.remove=function(){this.group.removeAll(),this._data=null},e.prototype.dispose=function(){},e.type="funnel",e}(kg),hk=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.prototype.init=function(e){t.prototype.init.apply(this,arguments),this.legendVisualProvider=new IM(W(this.getData,this),W(this.getRawData,this)),this._defaultLabelLine(e)},e.prototype.getInitialData=function(t,e){return MM(this,{coordDimensions:["value"],encodeDefaulter:H(Jp,this)})},e.prototype._defaultLabelLine=function(t){wo(t,"labelLine",["show"]);var e=t.labelLine,n=t.emphasis.labelLine;e.show=e.show&&t.label.show,n.show=n.show&&t.emphasis.label.show},e.prototype.getDataParams=function(e){var n=this.getData(),i=t.prototype.getDataParams.call(this,e),r=n.mapDimension("value"),o=n.getSum(r);return i.percent=o?+(n.get(r,e)/o*100).toFixed(2):0,i.$vars.push("percent"),i},e.type="series.funnel",e.defaultOption={z:2,legendHoverLink:!0,colorBy:"data",left:80,top:60,right:80,bottom:60,minSize:"0%",maxSize:"100%",sort:"descending",orient:"vertical",gap:0,funnelAlign:"center",label:{show:!0,position:"outer"},labelLine:{show:!0,length:20,lineStyle:{width:1}},itemStyle:{borderColor:"#fff",borderWidth:1},emphasis:{label:{show:!0}},select:{itemStyle:{borderColor:"#212121"}}},e}(mg);function ck(t,e){t.eachSeriesByType("funnel",(function(t){var n=t.getData(),i=n.mapDimension("value"),r=t.get("sort"),o=function(t,e){return Cp(t.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}(t,e),a=t.get("orient"),s=o.width,l=o.height,u=function(t,e){for(var n=t.mapDimension("value"),i=t.mapArray(n,(function(t){return t})),r=[],o="ascending"===e,a=0,s=t.count();a5)return;var i=this._model.coordinateSystem.getSlidedAxisExpandWindow([t.offsetX,t.offsetY]);"none"!==i.behavior&&this._dispatchExpand({axisExpandWindow:i.axisExpandWindow})}this._mouseDownPoint=null},mousemove:function(t){if(!this._mouseDownPoint&&Mk(this,"mousemove")){var e=this._model,n=e.coordinateSystem.getSlidedAxisExpandWindow([t.offsetX,t.offsetY]),i=n.behavior;"jump"===i&&this._throttledDispatchExpand.debounceNextCall(e.get("axisExpandDebounce")),this._throttledDispatchExpand("none"===i?null:{axisExpandWindow:n.axisExpandWindow,animation:"jump"===i?null:{duration:0}})}}};function Mk(t,e){var n=t._model;return n.get("axisExpandable")&&n.get("axisExpandTriggerOn")===e}var Ik=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.prototype.init=function(){t.prototype.init.apply(this,arguments),this.mergeOption({})},e.prototype.mergeOption=function(t){var e=this.option;t&&C(e,t,!0),this._initDimensions()},e.prototype.contains=function(t,e){var n=t.get("parallelIndex");return null!=n&&e.getComponent("parallel",n)===this},e.prototype.setAxisExpand=function(t){E(["axisExpandable","axisExpandCenter","axisExpandCount","axisExpandWidth","axisExpandWindow"],(function(e){t.hasOwnProperty(e)&&(this.option[e]=t[e])}),this)},e.prototype._initDimensions=function(){var t=this.dimensions=[],e=this.parallelAxisIndex=[];E(B(this.ecModel.queryComponents({mainType:"parallelAxis"}),(function(t){return(t.get("parallelIndex")||0)===this.componentIndex}),this),(function(n){t.push("dim"+n.get("dim")),e.push(n.componentIndex)}))},e.type="parallel",e.dependencies=["parallelAxis"],e.layoutMode="box",e.defaultOption={z:0,left:80,top:60,right:80,bottom:60,layout:"horizontal",axisExpandable:!1,axisExpandCenter:null,axisExpandCount:0,axisExpandWidth:50,axisExpandRate:17,axisExpandDebounce:50,axisExpandSlideTriggerArea:[-.15,.05,.4],axisExpandTriggerOn:"click",parallelAxisDefault:null},e}(Rp),Tk=function(t){function e(e,n,i,r,o){var a=t.call(this,e,n,i)||this;return a.type=r||"value",a.axisIndex=o,a}return n(e,t),e.prototype.isHorizontal=function(){return"horizontal"!==this.coordinateSystem.getModel().get("layout")},e}(nb);function Ck(t,e,n,i,r,o){t=t||0;var a=n[1]-n[0];if(null!=r&&(r=Ak(r,[0,a])),null!=o&&(o=Math.max(o,null!=r?r:0)),"all"===i){var s=Math.abs(e[1]-e[0]);s=Ak(s,[0,a]),r=o=Ak(s,[r,o]),i=0}e[0]=Ak(e[0],n),e[1]=Ak(e[1],n);var l=Dk(e,i);e[i]+=t;var u,h=r||0,c=n.slice();return l.sign<0?c[0]+=h:c[1]-=h,e[i]=Ak(e[i],c),u=Dk(e,i),null!=r&&(u.sign!==l.sign||u.spano&&(e[1-i]=e[i]+u.sign*o),e}function Dk(t,e){var n=t[e]-t[1-e];return{span:Math.abs(n),sign:n>0?-1:n<0?1:e?-1:1}}function Ak(t,e){return Math.min(null!=e[1]?e[1]:1/0,Math.max(null!=e[0]?e[0]:-1/0,t))}var kk=E,Lk=Math.min,Pk=Math.max,Ok=Math.floor,Rk=Math.ceil,Nk=Zr,Ek=Math.PI,zk=function(){function t(t,e,n){this.type="parallel",this._axesMap=yt(),this._axesLayout={},this.dimensions=t.dimensions,this._model=t,this._init(t,e,n)}return t.prototype._init=function(t,e,n){var i=t.dimensions,r=t.parallelAxisIndex;kk(i,(function(t,n){var i=r[n],o=e.getComponent("parallelAxis",i),a=this._axesMap.set(t,new Tk(t,m_(o),[0,0],o.get("type"),i)),s="category"===a.type;a.onBand=s&&o.get("boundaryGap"),a.inverse=o.get("inverse"),o.axis=a,a.model=o,a.coordinateSystem=o.coordinateSystem=this}),this)},t.prototype.update=function(t,e){this._updateAxesFromSeries(this._model,t)},t.prototype.containPoint=function(t){var e=this._makeLayoutInfo(),n=e.axisBase,i=e.layoutBase,r=e.pixelDimIndex,o=t[1-r],a=t[r];return o>=n&&o<=n+e.axisLength&&a>=i&&a<=i+e.layoutLength},t.prototype.getModel=function(){return this._model},t.prototype._updateAxesFromSeries=function(t,e){e.eachSeries((function(n){if(t.contains(n,e)){var i=n.getData();kk(this.dimensions,(function(t){var e=this._axesMap.get(t);e.scale.unionExtentFromData(i,i.mapDimension(t)),v_(e.scale,e.model)}),this)}}),this)},t.prototype.resize=function(t,e){this._rect=Cp(t.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()}),this._layoutAxes()},t.prototype.getRect=function(){return this._rect},t.prototype._makeLayoutInfo=function(){var t,e=this._model,n=this._rect,i=["x","y"],r=["width","height"],o=e.get("layout"),a="horizontal"===o?0:1,s=n[r[a]],l=[0,s],u=this.dimensions.length,h=Vk(e.get("axisExpandWidth"),l),c=Vk(e.get("axisExpandCount")||0,[0,u]),p=e.get("axisExpandable")&&u>3&&u>c&&c>1&&h>0&&s>0,d=e.get("axisExpandWindow");d?(t=Vk(d[1]-d[0],l),d[1]=d[0]+t):(t=Vk(h*(c-1),l),(d=[h*(e.get("axisExpandCenter")||Ok(u/2))-t/2])[1]=d[0]+t);var f=(s-t)/(u-c);f<3&&(f=0);var g=[Ok(Nk(d[0]/h,1))+1,Rk(Nk(d[1]/h,1))-1],y=f/h*d[0];return{layout:o,pixelDimIndex:a,layoutBase:n[i[a]],layoutLength:s,axisBase:n[i[1-a]],axisLength:n[r[1-a]],axisExpandable:p,axisExpandWidth:h,axisCollapseWidth:f,axisExpandWindow:d,axisCount:u,winInnerIndices:g,axisExpandWindow0Pos:y}},t.prototype._layoutAxes=function(){var t=this._rect,e=this._axesMap,n=this.dimensions,i=this._makeLayoutInfo(),r=i.layout;e.each((function(t){var e=[0,i.axisLength],n=t.inverse?1:0;t.setExtent(e[n],e[1-n])})),kk(n,(function(e,n){var o=(i.axisExpandable?Fk:Bk)(n,i),a={horizontal:{x:o.position,y:i.axisLength},vertical:{x:0,y:o.position}},s={horizontal:Ek/2,vertical:0},l=[a[r].x+t.x,a[r].y+t.y],u=s[r],h=[1,0,0,1,0,0];Se(h,h,u),we(h,h,l),this._axesLayout[e]={position:l,rotation:u,transform:h,axisNameAvailableWidth:o.axisNameAvailableWidth,axisLabelShow:o.axisLabelShow,nameTruncateMaxWidth:o.nameTruncateMaxWidth,tickDirection:1,labelDirection:1}}),this)},t.prototype.getAxis=function(t){return this._axesMap.get(t)},t.prototype.dataToPoint=function(t,e){return this.axisCoordToPoint(this._axesMap.get(e).dataToCoord(t),e)},t.prototype.eachActiveState=function(t,e,n,i){null==n&&(n=0),null==i&&(i=t.count());var r=this._axesMap,o=this.dimensions,a=[],s=[];E(o,(function(e){a.push(t.mapDimension(e)),s.push(r.get(e).model)}));for(var l=this.hasAxisBrushed(),u=n;ur*(1-h[0])?(l="jump",a=s-r*(1-h[2])):(a=s-r*h[1])>=0&&(a=s-r*(1-h[1]))<=0&&(a=0),(a*=e.axisExpandWidth/u)?Ck(a,i,o,"all"):l="none";else{var p=i[1]-i[0];(i=[Pk(0,o[1]*s/p-p/2)])[1]=Lk(o[1],i[0]+p),i[0]=i[1]-p}return{axisExpandWindow:i,behavior:l}},t}();function Vk(t,e){return Lk(Pk(t,e[0]),e[1])}function Bk(t,e){var n=e.layoutLength/(e.axisCount-1);return{position:n*t,axisNameAvailableWidth:n,axisLabelShow:!0}}function Fk(t,e){var n,i,r=e.layoutLength,o=e.axisExpandWidth,a=e.axisCount,s=e.axisCollapseWidth,l=e.winInnerIndices,u=s,h=!1;return t=0;n--)jr(e[n])},e.prototype.getActiveState=function(t){var e=this.activeIntervals;if(!e.length)return"normal";if(null==t||isNaN(+t))return"inactive";if(1===e.length){var n=e[0];if(n[0]<=t&&t<=n[1])return"active"}else for(var i=0,r=e.length;i6}(t)||o){if(a&&!o){"single"===s.brushMode&&sL(t);var l=T(s);l.brushType=ML(l.brushType,a),l.panelId=a===Hk?null:a.panelId,o=t._creatingCover=Qk(t,l),t._covers.push(o)}if(o){var u=CL[ML(t._brushType,a)];o.__brushOption.range=u.getCreatingRange(_L(t,o,t._track)),i&&(tL(t,o),u.updateCommon(t,o)),eL(t,o),r={isEnd:i}}}else i&&"single"===s.brushMode&&s.removeOnClick&&oL(t,e,n)&&sL(t)&&(r={isEnd:i,removeOnClick:!0});return r}function ML(t,e){return"auto"===t?e.defaultBrushType:t}var IL={mousedown:function(t){if(this._dragging)TL(this,t);else if(!t.target||!t.target.draggable){bL(t);var e=this.group.transformCoordToLocal(t.offsetX,t.offsetY);this._creatingCover=null,(this._creatingPanel=oL(this,t,e))&&(this._dragging=!0,this._track=[e.slice()])}},mousemove:function(t){var e=t.offsetX,n=t.offsetY,i=this.group.transformCoordToLocal(e,n);if(function(t,e,n){if(t._brushType&&!function(t,e,n){var i=t._zr;return e<0||e>i.getWidth()||n<0||n>i.getHeight()}(t,e.offsetX,e.offsetY)){var i=t._zr,r=t._covers,o=oL(t,e,n);if(!t._dragging)for(var a=0;a=0&&(o[r[a].depth]=new Mc(r[a],this,e));if(i&&n){var s=QA(i,n,this,!0,(function(t,e){t.wrapMethod("getItemModel",(function(t,e){var n=t.parentModel,i=n.getData().getItemLayout(e);if(i){var r=i.depth,o=n.levelModels[r];o&&(t.parentModel=o)}return t})),e.wrapMethod("getItemModel",(function(t,e){var n=t.parentModel,i=n.getGraph().getEdgeByIndex(e).node1.getLayout();if(i){var r=i.depth,o=n.levelModels[r];o&&(t.parentModel=o)}return t}))}));return s.data}},e.prototype.setNodePosition=function(t,e){var n=(this.option.data||this.option.nodes)[t];n.localX=e[0],n.localY=e[1]},e.prototype.getGraph=function(){return this.getData().graph},e.prototype.getEdgeData=function(){return this.getGraph().edgeData},e.prototype.formatTooltip=function(t,e,n){function i(t){return isNaN(t)||null==t}if("edge"===n){var r=this.getDataParams(t,n),o=r.data,a=r.value;return ng("nameValue",{name:o.source+" -- "+o.target,value:a,noValue:i(a)})}var s=this.getGraph().getNodeByIndex(t).getLayout().value,l=this.getDataParams(t,n).data.name;return ng("nameValue",{name:null!=l?l+"":null,value:s,noValue:i(s)})},e.prototype.optionUpdated=function(){},e.prototype.getDataParams=function(e,n){var i=t.prototype.getDataParams.call(this,e,n);if(null==i.value&&"node"===n){var r=this.getGraph().getNodeByIndex(e).getLayout().value;i.value=r}return i},e.type="series.sankey",e.defaultOption={z:2,coordinateSystem:"view",left:"5%",top:"5%",right:"20%",bottom:"5%",orient:"horizontal",nodeWidth:20,nodeGap:8,draggable:!0,layoutIterations:32,label:{show:!0,position:"right",fontSize:12},edgeLabel:{show:!1,fontSize:12},levels:[],nodeAlign:"justify",lineStyle:{color:"#314656",opacity:.2,curveness:.5},emphasis:{label:{show:!0},lineStyle:{opacity:.5}},select:{itemStyle:{borderColor:"#212121"}},animationEasing:"linear",animationDuration:1e3},e}(mg);function HL(t,e){t.eachSeriesByType("sankey",(function(t){var n=t.get("nodeWidth"),i=t.get("nodeGap"),r=function(t,e){return Cp(t.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}(t,e);t.layoutInfo=r;var o=r.width,a=r.height,s=t.getGraph(),l=s.nodes,u=s.edges;!function(t){E(t,(function(t){var e=QL(t.outEdges,JL),n=QL(t.inEdges,JL),i=t.getValue()||0,r=Math.max(e,n,i);t.setLayout({value:r},!0)}))}(l),function(t,e,n,i,r,o,a,s,l){(function(t,e,n,i,r,o,a){for(var s=[],l=[],u=[],h=[],c=0,p=0;p=0;v&&y.depth>d&&(d=y.depth),g.setLayout({depth:v?y.depth:c},!0),"vertical"===o?g.setLayout({dy:n},!0):g.setLayout({dx:n},!0);for(var m=0;mc-1?d:c-1;a&&"left"!==a&&function(t,e,n,i){if("right"===e){for(var r=[],o=t,a=0;o.length;){for(var s=0;s0;o--)UL(s,l*=.99,a),XL(s,r,n,i,a),tP(s,l,a),XL(s,r,n,i,a)}(t,e,o,r,i,a,s),function(t,e){var n="vertical"===e?"x":"y";E(t,(function(t){t.outEdges.sort((function(t,e){return t.node2.getLayout()[n]-e.node2.getLayout()[n]})),t.inEdges.sort((function(t,e){return t.node1.getLayout()[n]-e.node1.getLayout()[n]}))})),E(t,(function(t){var e=0,n=0;E(t.outEdges,(function(t){t.setLayout({sy:e},!0),e+=t.getLayout().dy})),E(t.inEdges,(function(t){t.setLayout({ty:n},!0),n+=t.getLayout().dy}))}))}(t,s)}(l,u,n,i,o,a,0!==B(l,(function(t){return 0===t.getLayout().value})).length?0:t.get("layoutIterations"),t.get("orient"),t.get("nodeAlign"))}))}function YL(t){var e=t.hostGraph.data.getRawDataItem(t.dataIndex);return null!=e.depth&&e.depth>=0}function XL(t,e,n,i,r){var o="vertical"===r?"x":"y";E(t,(function(t){var a,s,l;t.sort((function(t,e){return t.getLayout()[o]-e.getLayout()[o]}));for(var u=0,h=t.length,c="vertical"===r?"dx":"dy",p=0;p0&&(a=s.getLayout()[o]+l,"vertical"===r?s.setLayout({x:a},!0):s.setLayout({y:a},!0)),u=s.getLayout()[o]+s.getLayout()[c]+e;if((l=u-e-("vertical"===r?i:n))>0){a=s.getLayout()[o]-l,"vertical"===r?s.setLayout({x:a},!0):s.setLayout({y:a},!0),u=a;for(p=h-2;p>=0;--p)(l=(s=t[p]).getLayout()[o]+s.getLayout()[c]+e-u)>0&&(a=s.getLayout()[o]-l,"vertical"===r?s.setLayout({x:a},!0):s.setLayout({y:a},!0)),u=s.getLayout()[o]}}))}function UL(t,e,n){E(t.slice().reverse(),(function(t){E(t,(function(t){if(t.outEdges.length){var i=QL(t.outEdges,ZL,n)/QL(t.outEdges,JL);if(isNaN(i)){var r=t.outEdges.length;i=r?QL(t.outEdges,jL,n)/r:0}if("vertical"===n){var o=t.getLayout().x+(i-$L(t,n))*e;t.setLayout({x:o},!0)}else{var a=t.getLayout().y+(i-$L(t,n))*e;t.setLayout({y:a},!0)}}}))}))}function ZL(t,e){return $L(t.node2,e)*t.getValue()}function jL(t,e){return $L(t.node2,e)}function qL(t,e){return $L(t.node1,e)*t.getValue()}function KL(t,e){return $L(t.node1,e)}function $L(t,e){return"vertical"===e?t.getLayout().x+t.getLayout().dx/2:t.getLayout().y+t.getLayout().dy/2}function JL(t){return t.getValue()}function QL(t,e,n){for(var i=0,r=t.length,o=-1;++oo&&(o=e)})),E(n,(function(e){var n=new _D({type:"color",mappingMethod:"linear",dataExtent:[r,o],visual:t.get("color")}).mapValueToVisual(e.getLayout().value),i=e.getModel().get(["itemStyle","color"]);null!=i?(e.setVisual("color",i),e.setVisual("style",{fill:i})):(e.setVisual("color",n),e.setVisual("style",{fill:n}))}))}i.length&&E(i,(function(t){var e=t.getModel().get("lineStyle");t.setVisual("style",e)}))}))}var nP=function(){function t(){}return t.prototype.getInitialData=function(t,e){var n,i,r=e.getComponent("xAxis",this.get("xAxisIndex")),o=e.getComponent("yAxis",this.get("yAxisIndex")),a=r.get("type"),s=o.get("type");"category"===a?(t.layout="horizontal",n=r.getOrdinalMeta(),i=!0):"category"===s?(t.layout="vertical",n=o.getOrdinalMeta(),i=!0):t.layout=t.layout||"horizontal";var l=["x","y"],u="horizontal"===t.layout?0:1,h=this._baseAxisDim=l[u],c=l[1-u],p=[r,o],d=p[u].get("type"),f=p[1-u].get("type"),g=t.data;if(g&&i){var y=[];E(g,(function(t,e){var n;Y(t)?(n=t.slice(),t.unshift(e)):Y(t.value)?((n=A({},t)).value=n.value.slice(),t.value.unshift(e)):n=t,y.push(n)})),t.data=y}var v=this.defaultValueDimensions,m=[{name:h,type:Gm(d),ordinalMeta:n,otherDims:{tooltip:!1,itemName:0},dimsDef:["base"]},{name:c,type:Gm(f),dimsDef:v.slice()}];return MM(this,{coordDimensions:m,dimensionsCount:v.length+1,encodeDefaulter:H($p,m,this)})},t.prototype.getBaseAxis=function(){var t=this._baseAxisDim;return this.ecModel.getComponent(t+"Axis",this.get(t+"AxisIndex")).axis},t}(),iP=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.defaultValueDimensions=[{name:"min",defaultTooltip:!0},{name:"Q1",defaultTooltip:!0},{name:"median",defaultTooltip:!0},{name:"Q3",defaultTooltip:!0},{name:"max",defaultTooltip:!0}],n.visualDrawType="stroke",n}return n(e,t),e.type="series.boxplot",e.dependencies=["xAxis","yAxis","grid"],e.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,layout:null,boxWidth:[7,50],itemStyle:{color:"#fff",borderWidth:1},emphasis:{scale:!0,itemStyle:{borderWidth:2,shadowBlur:5,shadowOffsetX:1,shadowOffsetY:1,shadowColor:"rgba(0,0,0,0.2)"}},animationDuration:800},e}(mg);R(iP,nP,!0);var rP=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.prototype.render=function(t,e,n){var i=t.getData(),r=this.group,o=this._data;this._data||r.removeAll();var a="horizontal"===t.get("layout")?1:0;i.diff(o).add((function(t){if(i.hasValue(t)){var e=sP(i.getItemLayout(t),i,t,a,!0);i.setItemGraphicEl(t,e),r.add(e)}})).update((function(t,e){var n=o.getItemGraphicEl(e);if(i.hasValue(t)){var s=i.getItemLayout(t);n?(_h(n),lP(s,n,i,t)):n=sP(s,i,t,a),r.add(n),i.setItemGraphicEl(t,n)}else r.remove(n)})).remove((function(t){var e=o.getItemGraphicEl(t);e&&r.remove(e)})).execute(),this._data=i},e.prototype.remove=function(t){var e=this.group,n=this._data;this._data=null,n&&n.eachItemGraphicEl((function(t){t&&e.remove(t)}))},e.type="boxplot",e}(kg),oP=function(){},aP=function(t){function e(e){var n=t.call(this,e)||this;return n.type="boxplotBoxPath",n}return n(e,t),e.prototype.getDefaultShape=function(){return new oP},e.prototype.buildPath=function(t,e){var n=e.points,i=0;for(t.moveTo(n[i][0],n[i][1]),i++;i<4;i++)t.lineTo(n[i][0],n[i][1]);for(t.closePath();ig){var _=[v,x];i.push(_)}}}return{boxData:n,outliers:i}}(e.getRawData(),t.config);return[{dimensions:["ItemName","Low","Q1","Q2","Q3","High"],data:i.boxData},{data:i.outliers}]}};var dP=["color","borderColor"],fP=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.prototype.render=function(t,e,n){this.group.removeClipPath(),this._progressiveEls=null,this._updateDrawMode(t),this._isLargeDraw?this._renderLarge(t):this._renderNormal(t)},e.prototype.incrementalPrepareRender=function(t,e,n){this._clear(),this._updateDrawMode(t)},e.prototype.incrementalRender=function(t,e,n,i){this._progressiveEls=[],this._isLargeDraw?this._incrementalRenderLarge(t,e):this._incrementalRenderNormal(t,e)},e.prototype.eachRendered=function(t){qh(this._progressiveEls||this.group,t)},e.prototype._updateDrawMode=function(t){var e=t.pipelineContext.large;null!=this._isLargeDraw&&e===this._isLargeDraw||(this._isLargeDraw=e,this._clear())},e.prototype._renderNormal=function(t){var e=t.getData(),n=this._data,i=this.group,r=e.getLayout("isSimpleBox"),o=t.get("clip",!0),a=t.coordinateSystem,s=a.getArea&&a.getArea();this._data||i.removeAll(),e.diff(n).add((function(n){if(e.hasValue(n)){var a=e.getItemLayout(n);if(o&&mP(s,a))return;var l=vP(a,n,!0);gh(l,{shape:{points:a.ends}},t,n),xP(l,e,n,r),i.add(l),e.setItemGraphicEl(n,l)}})).update((function(a,l){var u=n.getItemGraphicEl(l);if(e.hasValue(a)){var h=e.getItemLayout(a);o&&mP(s,h)?i.remove(u):(u?(fh(u,{shape:{points:h.ends}},t,a),_h(u)):u=vP(h),xP(u,e,a,r),i.add(u),e.setItemGraphicEl(a,u))}else i.remove(u)})).remove((function(t){var e=n.getItemGraphicEl(t);e&&i.remove(e)})).execute(),this._data=e},e.prototype._renderLarge=function(t){this._clear(),SP(t,this.group);var e=t.get("clip",!0)?SS(t.coordinateSystem,!1,t):null;e?this.group.setClipPath(e):this.group.removeClipPath()},e.prototype._incrementalRenderNormal=function(t,e){for(var n,i=e.getData(),r=i.getLayout("isSimpleBox");null!=(n=t.next());){var o=vP(i.getItemLayout(n));xP(o,i,n,r),o.incremental=!0,this.group.add(o),this._progressiveEls.push(o)}},e.prototype._incrementalRenderLarge=function(t,e){SP(e,this.group,this._progressiveEls,!0)},e.prototype.remove=function(t){this._clear()},e.prototype._clear=function(){this.group.removeAll(),this._data=null},e.type="candlestick",e}(kg),gP=function(){},yP=function(t){function e(e){var n=t.call(this,e)||this;return n.type="normalCandlestickBox",n}return n(e,t),e.prototype.getDefaultShape=function(){return new gP},e.prototype.buildPath=function(t,e){var n=e.points;this.__simpleBox?(t.moveTo(n[4][0],n[4][1]),t.lineTo(n[6][0],n[6][1])):(t.moveTo(n[0][0],n[0][1]),t.lineTo(n[1][0],n[1][1]),t.lineTo(n[2][0],n[2][1]),t.lineTo(n[3][0],n[3][1]),t.closePath(),t.moveTo(n[4][0],n[4][1]),t.lineTo(n[5][0],n[5][1]),t.moveTo(n[6][0],n[6][1]),t.lineTo(n[7][0],n[7][1]))},e}(Is);function vP(t,e,n){var i=t.ends;return new yP({shape:{points:n?_P(i,t):i},z2:100})}function mP(t,e){for(var n=!0,i=0;i0?"borderColor":"borderColor0"])||n.get(["itemStyle",t>0?"color":"color0"]);0===t&&(r=n.get(["itemStyle","borderColorDoji"]));var o=n.getModel("itemStyle").getItemStyle(dP);e.useStyle(o),e.style.fill=null,e.style.stroke=r}var IP=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.defaultValueDimensions=[{name:"open",defaultTooltip:!0},{name:"close",defaultTooltip:!0},{name:"lowest",defaultTooltip:!0},{name:"highest",defaultTooltip:!0}],n}return n(e,t),e.prototype.getShadowDim=function(){return"open"},e.prototype.brushSelector=function(t,e,n){var i=e.getItemLayout(t);return i&&n.rect(i.brushRect)},e.type="series.candlestick",e.dependencies=["xAxis","yAxis","grid"],e.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,layout:null,clip:!0,itemStyle:{color:"#eb5454",color0:"#47b262",borderColor:"#eb5454",borderColor0:"#47b262",borderColorDoji:null,borderWidth:1},emphasis:{scale:!0,itemStyle:{borderWidth:2}},barMaxWidth:null,barMinWidth:null,barWidth:null,large:!0,largeThreshold:600,progressive:3e3,progressiveThreshold:1e4,progressiveChunkMode:"mod",animationEasing:"linear",animationDuration:300},e}(mg);function TP(t){t&&Y(t.series)&&E(t.series,(function(t){q(t)&&"k"===t.type&&(t.type="candlestick")}))}R(IP,nP,!0);var CP=["itemStyle","borderColor"],DP=["itemStyle","borderColor0"],AP=["itemStyle","borderColorDoji"],kP=["itemStyle","color"],LP=["itemStyle","color0"],PP={seriesType:"candlestick",plan:Cg(),performRawSeries:!0,reset:function(t,e){function n(t,e){return e.get(t>0?kP:LP)}function i(t,e){return e.get(0===t?AP:t>0?CP:DP)}if(!e.isSeriesFiltered(t))return!t.pipelineContext.large&&{progress:function(t,e){for(var r;null!=(r=t.next());){var o=e.getItemModel(r),a=e.getItemLayout(r).sign,s=o.getItemStyle();s.fill=n(a,o),s.stroke=i(a,o)||s.fill,A(e.ensureUniqueItemVisual(r,"style"),s)}}}}},OP={seriesType:"candlestick",plan:Cg(),reset:function(t){var e=t.coordinateSystem,n=t.getData(),i=function(t,e){var n,i=t.getBaseAxis(),r="category"===i.type?i.getBandWidth():(n=i.getExtent(),Math.abs(n[1]-n[0])/e.count()),o=Ur(rt(t.get("barMaxWidth"),r),r),a=Ur(rt(t.get("barMinWidth"),1),r),s=t.get("barWidth");return null!=s?Ur(s,r):Math.max(Math.min(r/2,o),a)}(t,n),r=["x","y"],o=n.getDimensionIndex(n.mapDimension(r[0])),a=z(n.mapDimensionsAll(r[1]),n.getDimensionIndex,n),s=a[0],l=a[1],u=a[2],h=a[3];if(n.setLayout({candleWidth:i,isSimpleBox:i<=1.3}),!(o<0||a.length<4))return{progress:t.pipelineContext.large?function(n,i){var r,a,c=Ex(4*n.count),p=0,d=[],f=[],g=i.getStore(),y=!!t.get(["itemStyle","borderColorDoji"]);for(;null!=(a=n.next());){var v=g.get(o,a),m=g.get(s,a),x=g.get(l,a),_=g.get(u,a),b=g.get(h,a);isNaN(v)||isNaN(_)||isNaN(b)?(c[p++]=NaN,p+=3):(c[p++]=RP(g,a,m,x,l,y),d[0]=v,d[1]=_,r=e.dataToPoint(d,null,f),c[p++]=r?r[0]:NaN,c[p++]=r?r[1]:NaN,d[1]=b,r=e.dataToPoint(d,null,f),c[p++]=r?r[1]:NaN)}i.setLayout("largePoints",c)}:function(t,n){var r,a=n.getStore();for(;null!=(r=t.next());){var c=a.get(o,r),p=a.get(s,r),d=a.get(l,r),f=a.get(u,r),g=a.get(h,r),y=Math.min(p,d),v=Math.max(p,d),m=M(y,c),x=M(v,c),_=M(f,c),b=M(g,c),w=[];I(w,x,0),I(w,m,1),w.push(C(b),C(x),C(_),C(m));var S=!!n.getItemModel(r).get(["itemStyle","borderColorDoji"]);n.setItemLayout(r,{sign:RP(a,r,p,d,l,S),initBaseline:p>d?x[1]:m[1],ends:w,brushRect:T(f,g,c)})}function M(t,n){var i=[];return i[0]=n,i[1]=t,isNaN(n)||isNaN(t)?[NaN,NaN]:e.dataToPoint(i)}function I(t,e,n){var r=e.slice(),o=e.slice();r[0]=Nh(r[0]+i/2,1,!1),o[0]=Nh(o[0]-i/2,1,!0),n?t.push(r,o):t.push(o,r)}function T(t,e,n){var r=M(t,n),o=M(e,n);return r[0]-=i/2,o[0]-=i/2,{x:r[0],y:r[1],width:i,height:o[1]-r[1]}}function C(t){return t[0]=Nh(t[0],1),t}}}}};function RP(t,e,n,i,r,o){return n>i?-1:n0?t.get(r,e-1)<=i?1:-1:1}function NP(t,e){var n=e.rippleEffectColor||e.color;t.eachChild((function(t){t.attr({z:e.z,zlevel:e.zlevel,style:{stroke:"stroke"===e.brushType?n:null,fill:"fill"===e.brushType?n:null}})}))}var EP=function(t){function e(e,n){var i=t.call(this)||this,r=new oS(e,n),o=new zr;return i.add(r),i.add(o),i.updateData(e,n),i}return n(e,t),e.prototype.stopEffectAnimation=function(){this.childAt(1).removeAll()},e.prototype.startEffectAnimation=function(t){for(var e=t.symbolType,n=t.color,i=t.rippleNumber,r=this.childAt(1),o=0;o0&&(o=this._getLineLength(i)/l*1e3),o!==this._period||a!==this._loop||s!==this._roundTrip){i.stopAnimation();var h=void 0;h=X(u)?u(n):u,i.__t>0&&(h=-o*i.__t),this._animateSymbol(i,o,h,a,s)}this._period=o,this._loop=a,this._roundTrip=s}},e.prototype._animateSymbol=function(t,e,n,i,r){if(e>0){t.__t=0;var o=this,a=t.animate("",i).when(r?2*e:e,{__t:r?2:1}).delay(n).during((function(){o._updateSymbolPosition(t)}));i||a.done((function(){o.remove(t)})),a.start()}},e.prototype._getLineLength=function(t){return Vt(t.__p1,t.__cp1)+Vt(t.__cp1,t.__p2)},e.prototype._updateAnimationPoints=function(t,e){t.__p1=e[0],t.__p2=e[1],t.__cp1=e[2]||[(e[0][0]+e[1][0])/2,(e[0][1]+e[1][1])/2]},e.prototype.updateData=function(t,e,n){this.childAt(0).updateData(t,e,n),this._updateEffectSymbol(t,e)},e.prototype._updateSymbolPosition=function(t){var e=t.__p1,n=t.__p2,i=t.__cp1,r=t.__t<1?t.__t:2-t.__t,o=[t.x,t.y],a=o.slice(),s=In,l=Tn;o[0]=s(e[0],i[0],n[0],r),o[1]=s(e[1],i[1],n[1],r);var u=t.__t<1?l(e[0],i[0],n[0],r):l(n[0],i[0],e[0],1-r),h=t.__t<1?l(e[1],i[1],n[1],r):l(n[1],i[1],e[1],1-r);t.rotation=-Math.atan2(h,u)-Math.PI/2,"line"!==this._symbolType&&"rect"!==this._symbolType&&"roundRect"!==this._symbolType||(void 0!==t.__lastT&&t.__lastT=0&&!(i[o]<=e);o--);o=Math.min(o,r-2)}else{for(o=a;oe);o++);o=Math.min(o-1,r-2)}var s=(e-i[o])/(i[o+1]-i[o]),l=n[o],u=n[o+1];t.x=l[0]*(1-s)+s*u[0],t.y=l[1]*(1-s)+s*u[1];var h=t.__t<1?u[0]-l[0]:l[0]-u[0],c=t.__t<1?u[1]-l[1]:l[1]-u[1];t.rotation=-Math.atan2(c,h)-Math.PI/2,this._lastFrame=o,this._lastFramePercent=e,t.ignore=!1}},e}(BP),WP=function(){this.polyline=!1,this.curveness=0,this.segs=[]},HP=function(t){function e(e){var n=t.call(this,e)||this;return n._off=0,n.hoverDataIdx=-1,n}return n(e,t),e.prototype.reset=function(){this.notClear=!1,this._off=0},e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new WP},e.prototype.buildPath=function(t,e){var n,i=e.segs,r=e.curveness;if(e.polyline)for(n=this._off;n0){t.moveTo(i[n++],i[n++]);for(var a=1;a0){var c=(s+u)/2-(l-h)*r,p=(l+h)/2-(u-s)*r;t.quadraticCurveTo(c,p,u,h)}else t.lineTo(u,h)}this.incremental&&(this._off=n,this.notClear=!0)},e.prototype.findDataIndex=function(t,e){var n=this.shape,i=n.segs,r=n.curveness,o=this.style.lineWidth;if(n.polyline)for(var a=0,s=0;s0)for(var u=i[s++],h=i[s++],c=1;c0){if(ls(u,h,(u+p)/2-(h-d)*r,(h+d)/2-(p-u)*r,p,d,o,t,e))return a}else if(as(u,h,p,d,o,t,e))return a;a++}return-1},e.prototype.contain=function(t,e){var n=this.transformCoordToLocal(t,e),i=this.getBoundingRect();return t=n[0],e=n[1],i.contain(t,e)?(this.hoverDataIdx=this.findDataIndex(t,e))>=0:(this.hoverDataIdx=-1,!1)},e.prototype.getBoundingRect=function(){var t=this._rect;if(!t){for(var e=this.shape.segs,n=1/0,i=1/0,r=-1/0,o=-1/0,a=0;a0&&(o.dataIndex=n+t.__startIndex)}))},t.prototype._clear=function(){this._newAdded=[],this.group.removeAll()},t}(),XP={seriesType:"lines",plan:Cg(),reset:function(t){var e=t.coordinateSystem;if(e){var n=t.get("polyline"),i=t.pipelineContext.large;return{progress:function(r,o){var a=[];if(i){var s=void 0,l=r.end-r.start;if(n){for(var u=0,h=r.start;h0&&(l||s.configLayer(o,{motionBlur:!0,lastFrameAlpha:Math.max(Math.min(a/10+.9,1),0)})),r.updateData(i);var u=t.get("clip",!0)&&SS(t.coordinateSystem,!1,t);u?this.group.setClipPath(u):this.group.removeClipPath(),this._lastZlevel=o,this._finished=!0},e.prototype.incrementalPrepareRender=function(t,e,n){var i=t.getData();this._updateLineDraw(i,t).incrementalPrepareUpdate(i),this._clearLayer(n),this._finished=!1},e.prototype.incrementalRender=function(t,e,n){this._lineDraw.incrementalUpdate(t,e.getData()),this._finished=t.end===e.getData().count()},e.prototype.eachRendered=function(t){this._lineDraw&&this._lineDraw.eachRendered(t)},e.prototype.updateTransform=function(t,e,n){var i=t.getData(),r=t.pipelineContext;if(!this._finished||r.large||r.progressiveRender)return{update:!0};var o=XP.reset(t,e,n);o.progress&&o.progress({start:0,end:i.count(),count:i.count()},i),this._lineDraw.updateLayout(),this._clearLayer(n)},e.prototype._updateLineDraw=function(t,e){var n=this._lineDraw,i=this._showEffect(e),r=!!e.get("polyline"),o=e.pipelineContext.large;return n&&i===this._hasEffet&&r===this._isPolyline&&o===this._isLargeDraw||(n&&n.remove(),n=this._lineDraw=o?new YP:new RA(r?i?GP:FP:i?BP:OA),this._hasEffet=i,this._isPolyline=r,this._isLargeDraw=o),this.group.add(n.group),n},e.prototype._showEffect=function(t){return!!t.get(["effect","show"])},e.prototype._clearLayer=function(t){var e=t.getZr();"svg"===e.painter.getType()||null==this._lastZlevel||e.painter.getLayer(this._lastZlevel).clear(!0)},e.prototype.remove=function(t,e){this._lineDraw&&this._lineDraw.remove(),this._lineDraw=null,this._clearLayer(e)},e.prototype.dispose=function(t,e){this.remove(t,e)},e.type="lines",e}(kg),ZP="undefined"==typeof Uint32Array?Array:Uint32Array,jP="undefined"==typeof Float64Array?Array:Float64Array;function qP(t){var e=t.data;e&&e[0]&&e[0][0]&&e[0][0].coord&&(t.data=z(e,(function(t){var e={coords:[t[0].coord,t[1].coord]};return t[0].name&&(e.fromName=t[0].name),t[1].name&&(e.toName=t[1].name),D([e,t[0],t[1]])})))}var KP=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.visualStyleAccessPath="lineStyle",n.visualDrawType="stroke",n}return n(e,t),e.prototype.init=function(e){e.data=e.data||[],qP(e);var n=this._processFlatCoordsArray(e.data);this._flatCoords=n.flatCoords,this._flatCoordsOffset=n.flatCoordsOffset,n.flatCoords&&(e.data=new Float32Array(n.count)),t.prototype.init.apply(this,arguments)},e.prototype.mergeOption=function(e){if(qP(e),e.data){var n=this._processFlatCoordsArray(e.data);this._flatCoords=n.flatCoords,this._flatCoordsOffset=n.flatCoordsOffset,n.flatCoords&&(e.data=new Float32Array(n.count))}t.prototype.mergeOption.apply(this,arguments)},e.prototype.appendData=function(t){var e=this._processFlatCoordsArray(t.data);e.flatCoords&&(this._flatCoords?(this._flatCoords=vt(this._flatCoords,e.flatCoords),this._flatCoordsOffset=vt(this._flatCoordsOffset,e.flatCoordsOffset)):(this._flatCoords=e.flatCoords,this._flatCoordsOffset=e.flatCoordsOffset),t.data=new Float32Array(e.count)),this.getRawData().appendData(t.data)},e.prototype._getCoordsFromItemModel=function(t){var e=this.getData().getItemModel(t),n=e.option instanceof Array?e.option:e.getShallow("coords");return n},e.prototype.getLineCoordsCount=function(t){return this._flatCoordsOffset?this._flatCoordsOffset[2*t+1]:this._getCoordsFromItemModel(t).length},e.prototype.getLineCoords=function(t,e){if(this._flatCoordsOffset){for(var n=this._flatCoordsOffset[2*t],i=this._flatCoordsOffset[2*t+1],r=0;r ")})},e.prototype.preventIncremental=function(){return!!this.get(["effect","show"])},e.prototype.getProgressive=function(){var t=this.option.progressive;return null==t?this.option.large?1e4:this.get("progressive"):t},e.prototype.getProgressiveThreshold=function(){var t=this.option.progressiveThreshold;return null==t?this.option.large?2e4:this.get("progressiveThreshold"):t},e.prototype.getZLevelKey=function(){var t=this.getModel("effect"),e=t.get("trailLength");return this.getData().count()>this.getProgressiveThreshold()?this.id:t.get("show")&&e>0?e+"":""},e.type="series.lines",e.dependencies=["grid","polar","geo","calendar"],e.defaultOption={coordinateSystem:"geo",z:2,legendHoverLink:!0,xAxisIndex:0,yAxisIndex:0,symbol:["none","none"],symbolSize:[10,10],geoIndex:0,effect:{show:!1,period:4,constantSpeed:0,symbol:"circle",symbolSize:3,loop:!0,trailLength:.2},large:!1,largeThreshold:2e3,polyline:!1,clip:!0,label:{show:!1,position:"end"},lineStyle:{opacity:.5}},e}(mg);function $P(t){return t instanceof Array||(t=[t,t]),t}var JP={seriesType:"lines",reset:function(t){var e=$P(t.get("symbol")),n=$P(t.get("symbolSize")),i=t.getData();return i.setVisual("fromSymbol",e&&e[0]),i.setVisual("toSymbol",e&&e[1]),i.setVisual("fromSymbolSize",n&&n[0]),i.setVisual("toSymbolSize",n&&n[1]),{dataEach:i.hasItemOption?function(t,e){var n=t.getItemModel(e),i=$P(n.getShallow("symbol",!0)),r=$P(n.getShallow("symbolSize",!0));i[0]&&t.setItemVisual(e,"fromSymbol",i[0]),i[1]&&t.setItemVisual(e,"toSymbol",i[1]),r[0]&&t.setItemVisual(e,"fromSymbolSize",r[0]),r[1]&&t.setItemVisual(e,"toSymbolSize",r[1])}:null}}};var QP=function(){function t(){this.blurSize=30,this.pointSize=20,this.maxOpacity=1,this.minOpacity=0,this._gradientPixels={inRange:null,outOfRange:null};var t=h.createCanvas();this.canvas=t}return t.prototype.update=function(t,e,n,i,r,o){var a=this._getBrush(),s=this._getGradient(r,"inRange"),l=this._getGradient(r,"outOfRange"),u=this.pointSize+this.blurSize,h=this.canvas,c=h.getContext("2d"),p=t.length;h.width=e,h.height=n;for(var d=0;d0){var I=o(v)?s:l;v>0&&(v=v*S+w),x[_++]=I[M],x[_++]=I[M+1],x[_++]=I[M+2],x[_++]=I[M+3]*v*256}else _+=4}return c.putImageData(m,0,0),h},t.prototype._getBrush=function(){var t=this._brushCanvas||(this._brushCanvas=h.createCanvas()),e=this.pointSize+this.blurSize,n=2*e;t.width=n,t.height=n;var i=t.getContext("2d");return i.clearRect(0,0,n,n),i.shadowOffsetX=n,i.shadowBlur=this.blurSize,i.shadowColor="#000",i.beginPath(),i.arc(-e,e,this.pointSize,0,2*Math.PI,!0),i.closePath(),i.fill(),t},t.prototype._getGradient=function(t,e){for(var n=this._gradientPixels,i=n[e]||(n[e]=new Uint8ClampedArray(1024)),r=[0,0,0,0],o=0,a=0;a<256;a++)t[e](a/255,!0,r),i[o++]=r[0],i[o++]=r[1],i[o++]=r[2],i[o++]=r[3];return i},t}();function tO(t){var e=t.dimensions;return"lng"===e[0]&&"lat"===e[1]}var eO=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.prototype.render=function(t,e,n){var i;e.eachComponent("visualMap",(function(e){e.eachTargetSeries((function(n){n===t&&(i=e)}))})),this._progressiveEls=null,this.group.removeAll();var r=t.coordinateSystem;"cartesian2d"===r.type||"calendar"===r.type?this._renderOnCartesianAndCalendar(t,n,0,t.getData().count()):tO(r)&&this._renderOnGeo(r,t,i,n)},e.prototype.incrementalPrepareRender=function(t,e,n){this.group.removeAll()},e.prototype.incrementalRender=function(t,e,n,i){var r=e.coordinateSystem;r&&(tO(r)?this.render(e,n,i):(this._progressiveEls=[],this._renderOnCartesianAndCalendar(e,i,t.start,t.end,!0)))},e.prototype.eachRendered=function(t){qh(this._progressiveEls||this.group,t)},e.prototype._renderOnCartesianAndCalendar=function(t,e,n,i,r){var o,a,s,l,u=t.coordinateSystem,h=MS(u,"cartesian2d");if(h){var c=u.getAxis("x"),p=u.getAxis("y");0,o=c.getBandWidth()+.5,a=p.getBandWidth()+.5,s=c.scale.getExtent(),l=p.scale.getExtent()}for(var d=this.group,f=t.getData(),g=t.getModel(["emphasis","itemStyle"]).getItemStyle(),y=t.getModel(["blur","itemStyle"]).getItemStyle(),v=t.getModel(["select","itemStyle"]).getItemStyle(),m=t.get(["itemStyle","borderRadius"]),x=ec(t),_=t.getModel("emphasis"),b=_.get("focus"),w=_.get("blurScope"),S=_.get("disabled"),M=h?[f.mapDimension("x"),f.mapDimension("y"),f.mapDimension("value")]:[f.mapDimension("time"),f.mapDimension("value")],I=n;Is[1]||Al[1])continue;var k=u.dataToPoint([D,A]);T=new zs({shape:{x:k[0]-o/2,y:k[1]-a/2,width:o,height:a},style:C})}else{if(isNaN(f.get(M[1],I)))continue;T=new zs({z2:1,shape:u.dataToRect([f.get(M[0],I)]).contentShape,style:C})}if(f.hasItemOption){var L=f.getItemModel(I),P=L.getModel("emphasis");g=P.getModel("itemStyle").getItemStyle(),y=L.getModel(["blur","itemStyle"]).getItemStyle(),v=L.getModel(["select","itemStyle"]).getItemStyle(),m=L.get(["itemStyle","borderRadius"]),b=P.get("focus"),w=P.get("blurScope"),S=P.get("disabled"),x=ec(L)}T.shape.r=m;var O=t.getRawValue(I),R="-";O&&null!=O[2]&&(R=O[2]+""),tc(T,x,{labelFetcher:t,labelDataIndex:I,defaultOpacity:C.opacity,defaultText:R}),T.ensureState("emphasis").style=g,T.ensureState("blur").style=y,T.ensureState("select").style=v,Yl(T,b,w,S),T.incremental=r,r&&(T.states.emphasis.hoverLayer=!0),d.add(T),f.setItemGraphicEl(I,T),this._progressiveEls&&this._progressiveEls.push(T)}},e.prototype._renderOnGeo=function(t,e,n,i){var r=n.targetVisuals.inRange,o=n.targetVisuals.outOfRange,a=e.getData(),s=this._hmLayer||this._hmLayer||new QP;s.blurSize=e.get("blurSize"),s.pointSize=e.get("pointSize"),s.minOpacity=e.get("minOpacity"),s.maxOpacity=e.get("maxOpacity");var l=t.getViewRect().clone(),u=t.getRoamTransform();l.applyTransform(u);var h=Math.max(l.x,0),c=Math.max(l.y,0),p=Math.min(l.width+l.x,i.getWidth()),d=Math.min(l.height+l.y,i.getHeight()),f=p-h,g=d-c,y=[a.mapDimension("lng"),a.mapDimension("lat"),a.mapDimension("value")],v=a.mapArray(y,(function(e,n,i){var r=t.dataToPoint([e,n]);return r[0]-=h,r[1]-=c,r.push(i),r})),m=n.getExtent(),x="visualMap.continuous"===n.type?function(t,e){var n=t[1]-t[0];return e=[(e[0]-t[0])/n,(e[1]-t[0])/n],function(t){return t>=e[0]&&t<=e[1]}}(m,n.option.range):function(t,e,n){var i=t[1]-t[0],r=(e=z(e,(function(e){return{interval:[(e.interval[0]-t[0])/i,(e.interval[1]-t[0])/i]}}))).length,o=0;return function(t){var i;for(i=o;i=0;i--){var a;if((a=e[i].interval)[0]<=t&&t<=a[1]){o=i;break}}return i>=0&&i0?1:-1}(n,o,r,i,c),function(t,e,n,i,r,o,a,s,l,u){var h,c=l.valueDim,p=l.categoryDim,d=Math.abs(n[p.wh]),f=t.getItemVisual(e,"symbolSize");h=Y(f)?f.slice():null==f?["100%","100%"]:[f,f];h[p.index]=Ur(h[p.index],d),h[c.index]=Ur(h[c.index],i?d:Math.abs(o)),u.symbolSize=h;var g=u.symbolScale=[h[0]/s,h[1]/s];g[c.index]*=(l.isHorizontal?-1:1)*a}(t,e,r,o,0,c.boundingLength,c.pxSign,u,i,c),function(t,e,n,i,r){var o=t.get(iO)||0;o&&(oO.attr({scaleX:e[0],scaleY:e[1],rotation:n}),oO.updateTransform(),o/=oO.getLineScale(),o*=e[i.valueDim.index]);r.valueLineWidth=o||0}(n,c.symbolScale,l,i,c);var p=c.symbolSize,d=Yy(n.get("symbolOffset"),p);return function(t,e,n,i,r,o,a,s,l,u,h,c){var p=h.categoryDim,d=h.valueDim,f=c.pxSign,g=Math.max(e[d.index]+s,0),y=g;if(i){var v=Math.abs(l),m=it(t.get("symbolMargin"),"15%")+"",x=!1;m.lastIndexOf("!")===m.length-1&&(x=!0,m=m.slice(0,m.length-1));var _=Ur(m,e[d.index]),b=Math.max(g+2*_,0),w=x?0:2*_,S=co(i),M=S?i:SO((v+w)/b);b=g+2*(_=(v-M*g)/2/(x?M:Math.max(M-1,1))),w=x?0:2*_,S||"fixed"===i||(M=u?SO((Math.abs(u)+w)/b):0),y=M*b-w,c.repeatTimes=M,c.symbolMargin=_}var I=f*(y/2),T=c.pathPosition=[];T[p.index]=n[p.wh]/2,T[d.index]="start"===a?I:"end"===a?l-I:l/2,o&&(T[0]+=o[0],T[1]+=o[1]);var C=c.bundlePosition=[];C[p.index]=n[p.xy],C[d.index]=n[d.xy];var D=c.barRectShape=A({},n);D[d.wh]=f*Math.max(Math.abs(n[d.wh]),Math.abs(T[d.index]+I)),D[p.wh]=n[p.wh];var k=c.clipShape={};k[p.xy]=-n[p.xy],k[p.wh]=h.ecSize[p.wh],k[d.xy]=0,k[d.wh]=n[d.wh]}(n,p,r,o,0,d,s,c.valueLineWidth,c.boundingLength,c.repeatCutLength,i,c),c}function lO(t,e){return t.toGlobalCoord(t.dataToCoord(t.scale.parse(e)))}function uO(t){var e=t.symbolPatternSize,n=Wy(t.symbolType,-e/2,-e/2,e,e);return n.attr({culling:!0}),"image"!==n.type&&n.setStyle({strokeNoScale:!0}),n}function hO(t,e,n,i){var r=t.__pictorialBundle,o=n.symbolSize,a=n.valueLineWidth,s=n.pathPosition,l=e.valueDim,u=n.repeatTimes||0,h=0,c=o[e.valueDim.index]+a+2*n.symbolMargin;for(_O(t,(function(t){t.__pictorialAnimationIndex=h,t.__pictorialRepeatTimes=u,h0:i<0)&&(r=u-1-t),e[l.index]=c*(r-u/2+.5)+s[l.index],{x:e[0],y:e[1],scaleX:n.symbolScale[0],scaleY:n.symbolScale[1],rotation:n.rotation}}}function cO(t,e,n,i){var r=t.__pictorialBundle,o=t.__pictorialMainPath;o?bO(o,null,{x:n.pathPosition[0],y:n.pathPosition[1],scaleX:n.symbolScale[0],scaleY:n.symbolScale[1],rotation:n.rotation},n,i):(o=t.__pictorialMainPath=uO(n),r.add(o),bO(o,{x:n.pathPosition[0],y:n.pathPosition[1],scaleX:0,scaleY:0,rotation:n.rotation},{scaleX:n.symbolScale[0],scaleY:n.symbolScale[1]},n,i))}function pO(t,e,n){var i=A({},e.barRectShape),r=t.__pictorialBarRect;r?bO(r,null,{shape:i},e,n):((r=t.__pictorialBarRect=new zs({z2:2,shape:i,silent:!0,style:{stroke:"transparent",fill:"transparent",lineWidth:0}})).disableMorphing=!0,t.add(r))}function dO(t,e,n,i){if(n.symbolClip){var r=t.__pictorialClipPath,o=A({},n.clipShape),a=e.valueDim,s=n.animationModel,l=n.dataIndex;if(r)fh(r,{shape:o},s,l);else{o[a.wh]=0,r=new zs({shape:o}),t.__pictorialBundle.setClipPath(r),t.__pictorialClipPath=r;var u={};u[a.wh]=n.clipShape[a.wh],Kh[i?"updateProps":"initProps"](r,{shape:u},s,l)}}}function fO(t,e){var n=t.getItemModel(e);return n.getAnimationDelayParams=gO,n.isAnimationEnabled=yO,n}function gO(t){return{index:t.__pictorialAnimationIndex,count:t.__pictorialRepeatTimes}}function yO(){return this.parentModel.isAnimationEnabled()&&!!this.getShallow("animation")}function vO(t,e,n,i){var r=new zr,o=new zr;return r.add(o),r.__pictorialBundle=o,o.x=n.bundlePosition[0],o.y=n.bundlePosition[1],n.symbolRepeat?hO(r,e,n):cO(r,0,n),pO(r,n,i),dO(r,e,n,i),r.__pictorialShapeStr=xO(t,n),r.__pictorialSymbolMeta=n,r}function mO(t,e,n,i){var r=i.__pictorialBarRect;r&&r.removeTextContent();var o=[];_O(i,(function(t){o.push(t)})),i.__pictorialMainPath&&o.push(i.__pictorialMainPath),i.__pictorialClipPath&&(n=null),E(o,(function(t){vh(t,{scaleX:0,scaleY:0},n,e,(function(){i.parent&&i.parent.remove(i)}))})),t.setItemGraphicEl(e,null)}function xO(t,e){return[t.getItemVisual(e.dataIndex,"symbol")||"none",!!e.symbolRepeat,!!e.symbolClip].join(":")}function _O(t,e,n){E(t.__pictorialBundle.children(),(function(i){i!==t.__pictorialBarRect&&e.call(n,i)}))}function bO(t,e,n,i,r,o){e&&t.attr(e),i.symbolClip&&!r?n&&t.attr(n):n&&Kh[r?"updateProps":"initProps"](t,n,i.animationModel,i.dataIndex,o)}function wO(t,e,n){var i=n.dataIndex,r=n.itemModel,o=r.getModel("emphasis"),a=o.getModel("itemStyle").getItemStyle(),s=r.getModel(["blur","itemStyle"]).getItemStyle(),l=r.getModel(["select","itemStyle"]).getItemStyle(),u=r.getShallow("cursor"),h=o.get("focus"),c=o.get("blurScope"),p=o.get("scale");_O(t,(function(t){if(t instanceof ks){var e=t.style;t.useStyle(A({image:e.image,x:e.x,y:e.y,width:e.width,height:e.height},n.style))}else t.useStyle(n.style);var i=t.ensureState("emphasis");i.style=a,p&&(i.scaleX=1.1*t.scaleX,i.scaleY=1.1*t.scaleY),t.ensureState("blur").style=s,t.ensureState("select").style=l,u&&(t.cursor=u),t.z2=n.z2}));var d=e.valueDim.posDesc[+(n.boundingLength>0)];tc(t.__pictorialBarRect,ec(r),{labelFetcher:e.seriesModel,labelDataIndex:i,defaultText:iS(e.seriesModel.getData(),i),inheritColor:n.style.fill,defaultOpacity:n.style.opacity,defaultOutsidePosition:d}),Yl(t,h,c,o.get("disabled"))}function SO(t){var e=Math.round(t);return Math.abs(t-e)<1e-4?e:Math.ceil(t)}var MO=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.hasSymbolVisual=!0,n.defaultSymbol="roundRect",n}return n(e,t),e.prototype.getInitialData=function(e){return e.stack=null,t.prototype.getInitialData.apply(this,arguments)},e.type="series.pictorialBar",e.dependencies=["grid"],e.defaultOption=Cc(FS.defaultOption,{symbol:"circle",symbolSize:null,symbolRotate:null,symbolPosition:null,symbolOffset:null,symbolMargin:null,symbolRepeat:!1,symbolRepeatDirection:"end",symbolClip:!1,symbolBoundingData:null,symbolPatternSize:400,barGap:"-100%",progressive:0,emphasis:{scale:!1},select:{itemStyle:{borderColor:"#212121"}}}),e}(FS);var IO=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n._layers=[],n}return n(e,t),e.prototype.render=function(t,e,n){var i=t.getData(),r=this,o=this.group,a=t.getLayerSeries(),s=i.getLayout("layoutInfo"),l=s.rect,u=s.boundaryGap;function h(t){return t.name}o.x=0,o.y=l.y+u[0];var c=new Vm(this._layersSeries||[],a,h,h),p=[];function d(e,n,s){var l=r._layers;if("remove"!==e){for(var u,h,c=[],d=[],f=a[n].indices,g=0;go&&(o=s),i.push(s)}for(var u=0;uo&&(o=c)}return{y0:r,max:o}}(l),h=u.y0,c=n/u.max,p=o.length,d=o[0].indices.length,f=0;fMath.PI/2?"right":"left"):S&&"center"!==S?"left"===S?(m=r.r0+w,a>Math.PI/2&&(S="right")):"right"===S&&(m=r.r-w,a>Math.PI/2&&(S="left")):(m=o===2*Math.PI&&0===r.r0?0:(r.r+r.r0)/2,S="center"),g.style.align=S,g.style.verticalAlign=f(p,"verticalAlign")||"middle",g.x=m*s+r.cx,g.y=m*l+r.cy;var M=f(p,"rotate"),I=0;"radial"===M?(I=hs(-a))>Math.PI/2&&I<1.5*Math.PI&&(I+=Math.PI):"tangential"===M?(I=Math.PI/2-a)>Math.PI/2?I-=Math.PI:I<-Math.PI/2&&(I+=Math.PI):j(M)&&(I=M*Math.PI/180),g.rotation=hs(I)})),h.dirtyStyle()},e}(zu),kO="sunburstRootToNode",LO="sunburstHighlight";var PO=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.prototype.render=function(t,e,n,i){var r=this;this.seriesModel=t,this.api=n,this.ecModel=e;var o=t.getData(),a=o.tree.root,s=t.getViewRoot(),l=this.group,u=t.get("renderLabelForZeroData"),h=[];s.eachNode((function(t){h.push(t)}));var c=this._oldChildren||[];!function(i,r){if(0===i.length&&0===r.length)return;function s(t){return t.getId()}function h(s,h){!function(i,r){u||!i||i.getValue()||(i=null);if(i!==a&&r!==a)if(r&&r.piece)i?(r.piece.updateData(!1,i,t,e,n),o.setItemGraphicEl(i.dataIndex,r.piece)):function(t){if(!t)return;t.piece&&(l.remove(t.piece),t.piece=null)}(r);else if(i){var s=new AO(i,t,e,n);l.add(s),o.setItemGraphicEl(i.dataIndex,s)}}(null==s?null:i[s],null==h?null:r[h])}new Vm(r,i,s,s).add(h).update(h).remove(H(h,null)).execute()}(h,c),function(i,o){o.depth>0?(r.virtualPiece?r.virtualPiece.updateData(!1,i,t,e,n):(r.virtualPiece=new AO(i,t,e,n),l.add(r.virtualPiece)),o.piece.off("click"),r.virtualPiece.on("click",(function(t){r._rootToNode(o.parentNode)}))):r.virtualPiece&&(l.remove(r.virtualPiece),r.virtualPiece=null)}(a,s),this._initEvents(),this._oldChildren=h},e.prototype._initEvents=function(){var t=this;this.group.off("click"),this.group.on("click",(function(e){var n=!1;t.seriesModel.getViewRoot().eachNode((function(i){if(!n&&i.piece&&i.piece===e.target){var r=i.getModel().get("nodeClick");if("rootToNode"===r)t._rootToNode(i);else if("link"===r){var o=i.getModel(),a=o.get("link");if(a)bp(a,o.get("target",!0)||"_blank")}n=!0}}))}))},e.prototype._rootToNode=function(t){t!==this.seriesModel.getViewRoot()&&this.api.dispatchAction({type:kO,from:this.uid,seriesId:this.seriesModel.id,targetNode:t})},e.prototype.containPoint=function(t,e){var n=e.getData().getItemLayout(0);if(n){var i=t[0]-n.cx,r=t[1]-n.cy,o=Math.sqrt(i*i+r*r);return o<=n.r&&o>=n.r0}},e.type="sunburst",e}(kg),OO=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.ignoreStyleOnData=!0,n}return n(e,t),e.prototype.getInitialData=function(t,e){var n={name:t.name,children:t.data};RO(n);var i=this._levelModels=z(t.levels||[],(function(t){return new Mc(t,this,e)}),this),r=UC.createTree(n,this,(function(t){t.wrapMethod("getItemModel",(function(t,e){var n=r.getNodeByDataIndex(e),o=i[n.depth];return o&&(t.parentModel=o),t}))}));return r.data},e.prototype.optionUpdated=function(){this.resetViewRoot()},e.prototype.getDataParams=function(e){var n=t.prototype.getDataParams.apply(this,arguments),i=this.getData().tree.getNodeByDataIndex(e);return n.treePathInfo=KC(i,this),n},e.prototype.getLevelModel=function(t){return this._levelModels&&this._levelModels[t.depth]},e.prototype.getViewRoot=function(){return this._viewRoot},e.prototype.resetViewRoot=function(t){t?this._viewRoot=t:t=this._viewRoot;var e=this.getRawData().tree.root;t&&(t===e||e.contains(t))||(this._viewRoot=e)},e.prototype.enableAriaDecal=function(){nD(this)},e.type="series.sunburst",e.defaultOption={z:2,center:["50%","50%"],radius:[0,"75%"],clockwise:!0,startAngle:90,minAngle:0,stillShowZeroSum:!0,nodeClick:"rootToNode",renderLabelForZeroData:!1,label:{rotate:"radial",show:!0,opacity:1,align:"center",position:"inside",distance:5,silent:!0},itemStyle:{borderWidth:1,borderColor:"white",borderType:"solid",shadowBlur:0,shadowColor:"rgba(0, 0, 0, 0.2)",shadowOffsetX:0,shadowOffsetY:0,opacity:1},emphasis:{focus:"descendant"},blur:{itemStyle:{opacity:.2},label:{opacity:.1}},animationType:"expansion",animationDuration:1e3,animationDurationUpdate:500,data:[],sort:"desc"},e}(mg);function RO(t){var e=0;E(t.children,(function(t){RO(t);var n=t.value;Y(n)&&(n=n[0]),e+=n}));var n=t.value;Y(n)&&(n=n[0]),(null==n||isNaN(n))&&(n=e),n<0&&(n=0),Y(t.value)?t.value[0]=n:t.value=n}var NO=Math.PI/180;function EO(t,e,n){e.eachSeriesByType(t,(function(t){var e=t.get("center"),i=t.get("radius");Y(i)||(i=[0,i]),Y(e)||(e=[e,e]);var r=n.getWidth(),o=n.getHeight(),a=Math.min(r,o),s=Ur(e[0],r),l=Ur(e[1],o),u=Ur(i[0],a/2),h=Ur(i[1],a/2),c=-t.get("startAngle")*NO,p=t.get("minAngle")*NO,d=t.getData().tree.root,f=t.getViewRoot(),g=f.depth,y=t.get("sort");null!=y&&zO(f,y);var v=0;E(f.children,(function(t){!isNaN(t.getValue())&&v++}));var m=f.getValue(),x=Math.PI/(m||v)*2,_=f.depth>0,b=f.height-(_?-1:1),w=(h-u)/(b||1),S=t.get("clockwise"),M=t.get("stillShowZeroSum"),I=S?1:-1,T=function(e,n){if(e){var i=n;if(e!==d){var r=e.getValue(),o=0===m&&M?x:r*x;o1;)r=r.parentNode;var o=n.getColorFromPalette(r.name||r.dataIndex+"",e);return t.depth>1&&U(o)&&(o=$n(o,(t.depth-1)/(i-1)*.5)),o}(r,t,i.root.height)),A(n.ensureUniqueItemVisual(r.dataIndex,"style"),o)}))}))}var BO={color:"fill",borderColor:"stroke"},FO={symbol:1,symbolSize:1,symbolKeepAspect:1,legendIcon:1,visualMeta:1,liftZ:1,decal:1},GO=Oo(),WO=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.prototype.optionUpdated=function(){this.currentZLevel=this.get("zlevel",!0),this.currentZ=this.get("z",!0)},e.prototype.getInitialData=function(t,e){return vx(null,this)},e.prototype.getDataParams=function(e,n,i){var r=t.prototype.getDataParams.call(this,e,n);return i&&(r.info=GO(i).info),r},e.type="series.custom",e.dependencies=["grid","polar","geo","singleAxis","calendar"],e.defaultOption={coordinateSystem:"cartesian2d",z:2,legendHoverLink:!0,clip:!1},e}(mg);function HO(t,e){return e=e||[0,0],z(["x","y"],(function(n,i){var r=this.getAxis(n),o=e[i],a=t[i]/2;return"category"===r.type?r.getBandWidth():Math.abs(r.dataToCoord(o-a)-r.dataToCoord(o+a))}),this)}function YO(t,e){return e=e||[0,0],z([0,1],(function(n){var i=e[n],r=t[n]/2,o=[],a=[];return o[n]=i-r,a[n]=i+r,o[1-n]=a[1-n]=e[1-n],Math.abs(this.dataToPoint(o)[n]-this.dataToPoint(a)[n])}),this)}function XO(t,e){var n=this.getAxis(),i=e instanceof Array?e[0]:e,r=(t instanceof Array?t[0]:t)/2;return"category"===n.type?n.getBandWidth():Math.abs(n.dataToCoord(i-r)-n.dataToCoord(i+r))}function UO(t,e){return e=e||[0,0],z(["Radius","Angle"],(function(n,i){var r=this["get"+n+"Axis"](),o=e[i],a=t[i]/2,s="category"===r.type?r.getBandWidth():Math.abs(r.dataToCoord(o-a)-r.dataToCoord(o+a));return"Angle"===n&&(s=s*Math.PI/180),s}),this)}function ZO(t,e,n,i){return t&&(t.legacy||!1!==t.legacy&&!n&&!i&&"tspan"!==e&&("text"===e||_t(t,"text")))}function jO(t,e,n){var i,r,o,a=t;if("text"===e)o=a;else{o={},_t(a,"text")&&(o.text=a.text),_t(a,"rich")&&(o.rich=a.rich),_t(a,"textFill")&&(o.fill=a.textFill),_t(a,"textStroke")&&(o.stroke=a.textStroke),_t(a,"fontFamily")&&(o.fontFamily=a.fontFamily),_t(a,"fontSize")&&(o.fontSize=a.fontSize),_t(a,"fontStyle")&&(o.fontStyle=a.fontStyle),_t(a,"fontWeight")&&(o.fontWeight=a.fontWeight),r={type:"text",style:o,silent:!0},i={};var s=_t(a,"textPosition");n?i.position=s?a.textPosition:"inside":s&&(i.position=a.textPosition),_t(a,"textPosition")&&(i.position=a.textPosition),_t(a,"textOffset")&&(i.offset=a.textOffset),_t(a,"textRotation")&&(i.rotation=a.textRotation),_t(a,"textDistance")&&(i.distance=a.textDistance)}return qO(o,t),E(o.rich,(function(t){qO(t,t)})),{textConfig:i,textContent:r}}function qO(t,e){e&&(e.font=e.textFont||e.font,_t(e,"textStrokeWidth")&&(t.lineWidth=e.textStrokeWidth),_t(e,"textAlign")&&(t.align=e.textAlign),_t(e,"textVerticalAlign")&&(t.verticalAlign=e.textVerticalAlign),_t(e,"textLineHeight")&&(t.lineHeight=e.textLineHeight),_t(e,"textWidth")&&(t.width=e.textWidth),_t(e,"textHeight")&&(t.height=e.textHeight),_t(e,"textBackgroundColor")&&(t.backgroundColor=e.textBackgroundColor),_t(e,"textPadding")&&(t.padding=e.textPadding),_t(e,"textBorderColor")&&(t.borderColor=e.textBorderColor),_t(e,"textBorderWidth")&&(t.borderWidth=e.textBorderWidth),_t(e,"textBorderRadius")&&(t.borderRadius=e.textBorderRadius),_t(e,"textBoxShadowColor")&&(t.shadowColor=e.textBoxShadowColor),_t(e,"textBoxShadowBlur")&&(t.shadowBlur=e.textBoxShadowBlur),_t(e,"textBoxShadowOffsetX")&&(t.shadowOffsetX=e.textBoxShadowOffsetX),_t(e,"textBoxShadowOffsetY")&&(t.shadowOffsetY=e.textBoxShadowOffsetY))}function KO(t,e,n){var i=t;i.textPosition=i.textPosition||n.position||"inside",null!=n.offset&&(i.textOffset=n.offset),null!=n.rotation&&(i.textRotation=n.rotation),null!=n.distance&&(i.textDistance=n.distance);var r=i.textPosition.indexOf("inside")>=0,o=t.fill||"#000";$O(i,e);var a=null==i.textFill;return r?a&&(i.textFill=n.insideFill||"#fff",!i.textStroke&&n.insideStroke&&(i.textStroke=n.insideStroke),!i.textStroke&&(i.textStroke=o),null==i.textStrokeWidth&&(i.textStrokeWidth=2)):(a&&(i.textFill=t.fill||n.outsideFill||"#000"),!i.textStroke&&n.outsideStroke&&(i.textStroke=n.outsideStroke)),i.text=e.text,i.rich=e.rich,E(e.rich,(function(t){$O(t,t)})),i}function $O(t,e){e&&(_t(e,"fill")&&(t.textFill=e.fill),_t(e,"stroke")&&(t.textStroke=e.fill),_t(e,"lineWidth")&&(t.textStrokeWidth=e.lineWidth),_t(e,"font")&&(t.font=e.font),_t(e,"fontStyle")&&(t.fontStyle=e.fontStyle),_t(e,"fontWeight")&&(t.fontWeight=e.fontWeight),_t(e,"fontSize")&&(t.fontSize=e.fontSize),_t(e,"fontFamily")&&(t.fontFamily=e.fontFamily),_t(e,"align")&&(t.textAlign=e.align),_t(e,"verticalAlign")&&(t.textVerticalAlign=e.verticalAlign),_t(e,"lineHeight")&&(t.textLineHeight=e.lineHeight),_t(e,"width")&&(t.textWidth=e.width),_t(e,"height")&&(t.textHeight=e.height),_t(e,"backgroundColor")&&(t.textBackgroundColor=e.backgroundColor),_t(e,"padding")&&(t.textPadding=e.padding),_t(e,"borderColor")&&(t.textBorderColor=e.borderColor),_t(e,"borderWidth")&&(t.textBorderWidth=e.borderWidth),_t(e,"borderRadius")&&(t.textBorderRadius=e.borderRadius),_t(e,"shadowColor")&&(t.textBoxShadowColor=e.shadowColor),_t(e,"shadowBlur")&&(t.textBoxShadowBlur=e.shadowBlur),_t(e,"shadowOffsetX")&&(t.textBoxShadowOffsetX=e.shadowOffsetX),_t(e,"shadowOffsetY")&&(t.textBoxShadowOffsetY=e.shadowOffsetY),_t(e,"textShadowColor")&&(t.textShadowColor=e.textShadowColor),_t(e,"textShadowBlur")&&(t.textShadowBlur=e.textShadowBlur),_t(e,"textShadowOffsetX")&&(t.textShadowOffsetX=e.textShadowOffsetX),_t(e,"textShadowOffsetY")&&(t.textShadowOffsetY=e.textShadowOffsetY))}var JO={position:["x","y"],scale:["scaleX","scaleY"],origin:["originX","originY"]},QO=G(JO),tR=(V(yr,(function(t,e){return t[e]=1,t}),{}),yr.join(", "),["","style","shape","extra"]),eR=Oo();function nR(t,e,n,i,r){var o=t+"Animation",a=ph(t,i,r)||{},s=eR(e).userDuring;return a.duration>0&&(a.during=s?W(uR,{el:e,userDuring:s}):null,a.setToFinal=!0,a.scope=t),A(a,n[o]),a}function iR(t,e,n,i){var r=(i=i||{}).dataIndex,o=i.isInit,a=i.clearStyle,s=n.isAnimationEnabled(),l=eR(t),u=e.style;l.userDuring=e.during;var h={},c={};if(function(t,e,n){for(var i=0;i=0)){var c=t.getAnimationStyleProps(),p=c?c.style:null;if(p){!r&&(r=i.style={});var d=G(n);for(u=0;u0&&t.animateFrom(p,d)}else!function(t,e,n,i,r){if(r){var o=nR("update",t,e,i,n);o.duration>0&&t.animateFrom(r,o)}}(t,e,r||0,n,h);rR(t,e),u?t.dirty():t.markRedraw()}function rR(t,e){for(var n=eR(t).leaveToProps,i=0;i=0){!o&&(o=i[t]={});var p=G(a);for(h=0;hi[1]&&i.reverse(),{coordSys:{type:"polar",cx:t.cx,cy:t.cy,r:i[1],r0:i[0]},api:{coord:function(i){var r=e.dataToRadius(i[0]),o=n.dataToAngle(i[1]),a=t.coordToPoint([r,o]);return a.push(r,o*Math.PI/180),a},size:W(UO,t)}}},calendar:function(t){var e=t.getRect(),n=t.getRangeInfo();return{coordSys:{type:"calendar",x:e.x,y:e.y,width:e.width,height:e.height,cellWidth:t.getCellWidth(),cellHeight:t.getCellHeight(),rangeInfo:{start:n.start,end:n.end,weeks:n.weeks,dayCount:n.allDay}},api:{coord:function(e,n){return t.dataToPoint(e,n)}}}}};function CR(t){return t instanceof Is}function DR(t){return t instanceof Sa}var AR=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.prototype.render=function(t,e,n,i){this._progressiveEls=null;var r=this._data,o=t.getData(),a=this.group,s=RR(t,o,e,n);r||a.removeAll(),o.diff(r).add((function(e){ER(n,null,e,s(e,i),t,a,o)})).remove((function(e){var n=r.getItemGraphicEl(e);n&&oR(n,GO(n).option,t)})).update((function(e,l){var u=r.getItemGraphicEl(l);ER(n,u,e,s(e,i),t,a,o)})).execute();var l=t.get("clip",!0)?SS(t.coordinateSystem,!1,t):null;l?a.setClipPath(l):a.removeClipPath(),this._data=o},e.prototype.incrementalPrepareRender=function(t,e,n){this.group.removeAll(),this._data=null},e.prototype.incrementalRender=function(t,e,n,i,r){var o=e.getData(),a=RR(e,o,n,i),s=this._progressiveEls=[];function l(t){t.isGroup||(t.incremental=!0,t.ensureState("emphasis").hoverLayer=!0)}for(var u=t.start;u=0?e.getStore().get(r,n):void 0}var o=e.get(i.name,n),a=i&&i.ordinalMeta;return a?a.categories[o]:o},styleEmphasis:function(n,i){0;null==i&&(i=s);var r=m(i,vR).getItemStyle(),o=x(i,vR),a=nc(o,null,null,!0,!0);a.text=o.getShallow("show")?ot(t.getFormattedLabel(i,vR),t.getFormattedLabel(i,mR),iS(e,i)):null;var l=ic(o,null,!0);return b(n,r),r=KO(r,a,l),n&&_(r,n),r.legacy=!0,r},visual:function(t,n){if(null==n&&(n=s),_t(BO,t)){var i=e.getItemVisual(n,"style");return i?i[BO[t]]:null}if(_t(FO,t))return e.getItemVisual(n,t)},barLayout:function(t){if("cartesian2d"===o.type){return function(t){var e=[],n=t.axis,i="axis0";if("category"===n.type){for(var r=n.getBandWidth(),o=0;o=c;f--){var g=e.childAt(f);WR(e,g,r)}}(t,c,n,i,r),a>=0?o.replaceAt(c,a):o.add(c),c}function VR(t,e,n){var i,r=GO(t),o=e.type,a=e.shape,s=e.style;return n.isUniversalTransitionEnabled()||null!=o&&o!==r.customGraphicType||"path"===o&&((i=a)&&(_t(i,"pathData")||_t(i,"d")))&&UR(a)!==r.customPathData||"image"===o&&_t(s,"image")&&s.image!==r.customImagePath}function BR(t,e,n){var i=e?FR(t,e):t,r=e?GR(t,i,vR):t.style,o=t.type,a=i?i.textConfig:null,s=t.textContent,l=s?e?FR(s,e):s:null;if(r&&(n.isLegacy||ZO(r,o,!!a,!!l))){n.isLegacy=!0;var u=jO(r,o,!e);!a&&u.textConfig&&(a=u.textConfig),!l&&u.textContent&&(l=u.textContent)}if(!e&&l){var h=l;!h.type&&(h.type="text")}var c=e?n[e]:n.normal;c.cfg=a,c.conOpt=l}function FR(t,e){return e?t?t[e]:null:t}function GR(t,e,n){var i=e&&e.style;return null==i&&n===vR&&t&&(i=t.styleEmphasis),i}function WR(t,e,n){e&&oR(e,GO(t).option,n)}function HR(t,e){var n=t&&t.name;return null!=n?n:"e\0\0"+e}function YR(t,e){var n=this.context,i=null!=t?n.newChildren[t]:null,r=null!=e?n.oldChildren[e]:null;zR(n.api,r,n.dataIndex,i,n.seriesModel,n.group)}function XR(t){var e=this.context,n=e.oldChildren[t];n&&oR(n,GO(n).option,e.seriesModel)}function UR(t){return t&&(t.pathData||t.d)}var ZR=Oo(),jR=T,qR=W,KR=function(){function t(){this._dragging=!1,this.animationThreshold=15}return t.prototype.render=function(t,e,n,i){var r=e.get("value"),o=e.get("status");if(this._axisModel=t,this._axisPointerModel=e,this._api=n,i||this._lastValue!==r||this._lastStatus!==o){this._lastValue=r,this._lastStatus=o;var a=this._group,s=this._handle;if(!o||"hide"===o)return a&&a.hide(),void(s&&s.hide());a&&a.show(),s&&s.show();var l={};this.makeElOption(l,r,t,e,n);var u=l.graphicKey;u!==this._lastGraphicKey&&this.clear(n),this._lastGraphicKey=u;var h=this._moveAnimation=this.determineAnimation(t,e);if(a){var c=H($R,e,h);this.updatePointerEl(a,l,c),this.updateLabelEl(a,l,c,e)}else a=this._group=new zr,this.createPointerEl(a,l,t,e),this.createLabelEl(a,l,t,e),n.getZr().add(a);eN(a,e,!0),this._renderHandle(r)}},t.prototype.remove=function(t){this.clear(t)},t.prototype.dispose=function(t){this.clear(t)},t.prototype.determineAnimation=function(t,e){var n=e.get("animation"),i=t.axis,r="category"===i.type,o=e.get("snap");if(!o&&!r)return!1;if("auto"===n||null==n){var a=this.animationThreshold;if(r&&i.getBandWidth()>a)return!0;if(o){var s=pI(t).seriesDataCount,l=i.getExtent();return Math.abs(l[0]-l[1])/s>a}return!1}return!0===n},t.prototype.makeElOption=function(t,e,n,i,r){},t.prototype.createPointerEl=function(t,e,n,i){var r=e.pointer;if(r){var o=ZR(t).pointerEl=new Kh[r.type](jR(e.pointer));t.add(o)}},t.prototype.createLabelEl=function(t,e,n,i){if(e.label){var r=ZR(t).labelEl=new Fs(jR(e.label));t.add(r),QR(r,i)}},t.prototype.updatePointerEl=function(t,e,n){var i=ZR(t).pointerEl;i&&e.pointer&&(i.setStyle(e.pointer.style),n(i,{shape:e.pointer.shape}))},t.prototype.updateLabelEl=function(t,e,n,i){var r=ZR(t).labelEl;r&&(r.setStyle(e.label.style),n(r,{x:e.label.x,y:e.label.y}),QR(r,i))},t.prototype._renderHandle=function(t){if(!this._dragging&&this.updateHandleTransform){var e,n=this._axisPointerModel,i=this._api.getZr(),r=this._handle,o=n.getModel("handle"),a=n.get("status");if(!o.get("show")||!a||"hide"===a)return r&&i.remove(r),void(this._handle=null);this._handle||(e=!0,r=this._handle=Hh(o.get("icon"),{cursor:"move",draggable:!0,onmousemove:function(t){de(t.event)},onmousedown:qR(this._onHandleDragMove,this,0,0),drift:qR(this._onHandleDragMove,this),ondragend:qR(this._onHandleDragEnd,this)}),i.add(r)),eN(r,n,!1),r.setStyle(o.getItemStyle(null,["color","borderColor","borderWidth","opacity","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"]));var s=o.get("size");Y(s)||(s=[s,s]),r.scaleX=s[0]/2,r.scaleY=s[1]/2,Fg(this,"_doDispatchAxisPointer",o.get("throttle")||0,"fixRate"),this._moveHandleToValue(t,e)}},t.prototype._moveHandleToValue=function(t,e){$R(this._axisPointerModel,!e&&this._moveAnimation,this._handle,tN(this.getHandleTransform(t,this._axisModel,this._axisPointerModel)))},t.prototype._onHandleDragMove=function(t,e){var n=this._handle;if(n){this._dragging=!0;var i=this.updateHandleTransform(tN(n),[t,e],this._axisModel,this._axisPointerModel);this._payloadInfo=i,n.stopAnimation(),n.attr(tN(i)),ZR(n).lastProp=null,this._doDispatchAxisPointer()}},t.prototype._doDispatchAxisPointer=function(){if(this._handle){var t=this._payloadInfo,e=this._axisModel;this._api.dispatchAction({type:"updateAxisPointer",x:t.cursorPoint[0],y:t.cursorPoint[1],tooltipOption:t.tooltipOption,axesInfo:[{axisDim:e.axis.dim,axisIndex:e.componentIndex}]})}},t.prototype._onHandleDragEnd=function(){if(this._dragging=!1,this._handle){var t=this._axisPointerModel.get("value");this._moveHandleToValue(t),this._api.dispatchAction({type:"hideTip"})}},t.prototype.clear=function(t){this._lastValue=null,this._lastStatus=null;var e=t.getZr(),n=this._group,i=this._handle;e&&n&&(this._lastGraphicKey=null,n&&e.remove(n),i&&e.remove(i),this._group=null,this._handle=null,this._payloadInfo=null),Gg(this,"_doDispatchAxisPointer")},t.prototype.doClear=function(){},t.prototype.buildLabel=function(t,e,n){return{x:t[n=n||0],y:t[1-n],width:e[n],height:e[1-n]}},t}();function $R(t,e,n,i){JR(ZR(n).lastProp,i)||(ZR(n).lastProp=i,e?fh(n,i,t):(n.stopAnimation(),n.attr(i)))}function JR(t,e){if(q(t)&&q(e)){var n=!0;return E(e,(function(e,i){n=n&&JR(t[i],e)})),!!n}return t===e}function QR(t,e){t[e.get(["label","show"])?"show":"hide"]()}function tN(t){return{x:t.x||0,y:t.y||0,rotation:t.rotation||0}}function eN(t,e,n){var i=e.get("z"),r=e.get("zlevel");t&&t.traverse((function(t){"group"!==t.type&&(null!=i&&(t.z=i),null!=r&&(t.zlevel=r),t.silent=n)}))}function nN(t){var e,n=t.get("type"),i=t.getModel(n+"Style");return"line"===n?(e=i.getLineStyle()).fill=null:"shadow"===n&&((e=i.getAreaStyle()).stroke=null),e}function iN(t,e,n,i,r){var o=rN(n.get("value"),e.axis,e.ecModel,n.get("seriesDataIndices"),{precision:n.get(["label","precision"]),formatter:n.get(["label","formatter"])}),a=n.getModel("label"),s=fp(a.get("padding")||0),l=a.getFont(),u=br(o,l),h=r.position,c=u.width+s[1]+s[3],p=u.height+s[0]+s[2],d=r.align;"right"===d&&(h[0]-=c),"center"===d&&(h[0]-=c/2);var f=r.verticalAlign;"bottom"===f&&(h[1]-=p),"middle"===f&&(h[1]-=p/2),function(t,e,n,i){var r=i.getWidth(),o=i.getHeight();t[0]=Math.min(t[0]+e,r)-e,t[1]=Math.min(t[1]+n,o)-n,t[0]=Math.max(t[0],0),t[1]=Math.max(t[1],0)}(h,c,p,i);var g=a.get("backgroundColor");g&&"auto"!==g||(g=e.get(["axisLine","lineStyle","color"])),t.label={x:h[0],y:h[1],style:nc(a,{text:o,font:l,fill:a.getTextColor(),padding:s,backgroundColor:g}),z2:10}}function rN(t,e,n,i,r){t=e.scale.parse(t);var o=e.scale.getLabel({value:t},{precision:r.precision}),a=r.formatter;if(a){var s={value:__(e,{value:t}),axisDimension:e.dim,axisIndex:e.index,seriesData:[]};E(i,(function(t){var e=n.getSeriesByIndex(t.seriesIndex),i=t.dataIndexInside,r=e&&e.getDataParams(i);r&&s.seriesData.push(r)})),U(a)?o=a.replace("{value}",o):X(a)&&(o=a(s))}return o}function oN(t,e,n){var i=[1,0,0,1,0,0];return Se(i,i,n.rotation),we(i,i,n.position),zh([t.dataToCoord(e),(n.labelOffset||0)+(n.labelDirection||1)*(n.labelMargin||0)],i)}function aN(t,e,n,i,r,o){var a=iI.innerTextLayout(n.rotation,0,n.labelDirection);n.labelMargin=r.get(["label","margin"]),iN(e,i,r,o,{position:oN(i.axis,t,n),align:a.textAlign,verticalAlign:a.textVerticalAlign})}function sN(t,e,n){return{x1:t[n=n||0],y1:t[1-n],x2:e[n],y2:e[1-n]}}function lN(t,e,n){return{x:t[n=n||0],y:t[1-n],width:e[n],height:e[1-n]}}function uN(t,e,n,i,r,o){return{cx:t,cy:e,r0:n,r:i,startAngle:r,endAngle:o,clockwise:!0}}var hN=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return n(e,t),e.prototype.makeElOption=function(t,e,n,i,r){var o=n.axis,a=o.grid,s=i.get("type"),l=cN(a,o).getOtherAxis(o).getGlobalExtent(),u=o.toGlobalCoord(o.dataToCoord(e,!0));if(s&&"none"!==s){var h=nN(i),c=pN[s](o,u,l);c.style=h,t.graphicKey=c.type,t.pointer=c}aN(e,t,ZM(a.model,n),n,i,r)},e.prototype.getHandleTransform=function(t,e,n){var i=ZM(e.axis.grid.model,e,{labelInside:!1});i.labelMargin=n.get(["handle","margin"]);var r=oN(e.axis,t,i);return{x:r[0],y:r[1],rotation:i.rotation+(i.labelDirection<0?Math.PI:0)}},e.prototype.updateHandleTransform=function(t,e,n,i){var r=n.axis,o=r.grid,a=r.getGlobalExtent(!0),s=cN(o,r).getOtherAxis(r).getGlobalExtent(),l="x"===r.dim?0:1,u=[t.x,t.y];u[l]+=e[l],u[l]=Math.min(a[1],u[l]),u[l]=Math.max(a[0],u[l]);var h=(s[1]+s[0])/2,c=[h,h];c[l]=u[l];return{x:u[0],y:u[1],rotation:t.rotation,cursorPoint:c,tooltipOption:[{verticalAlign:"middle"},{align:"center"}][l]}},e}(KR);function cN(t,e){var n={};return n[e.dim+"AxisIndex"]=e.index,t.getCartesian(n)}var pN={line:function(t,e,n){return{type:"Line",subPixelOptimize:!0,shape:sN([e,n[0]],[e,n[1]],dN(t))}},shadow:function(t,e,n){var i=Math.max(1,t.getBandWidth()),r=n[1]-n[0];return{type:"Rect",shape:lN([e-i/2,n[0]],[i,r],dN(t))}}};function dN(t){return"x"===t.dim?0:1}var fN=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.type="axisPointer",e.defaultOption={show:"auto",z:50,type:"line",snap:!1,triggerTooltip:!0,triggerEmphasis:!0,value:null,status:null,link:[],animation:null,animationDurationUpdate:200,lineStyle:{color:"#B9BEC9",width:1,type:"dashed"},shadowStyle:{color:"rgba(210,219,238,0.2)"},label:{show:!0,formatter:null,precision:"auto",margin:3,color:"#fff",padding:[5,7,5,7],backgroundColor:"auto",borderColor:null,borderWidth:0,borderRadius:3},handle:{show:!1,icon:"M10.7,11.9v-1.3H9.3v1.3c-4.9,0.3-8.8,4.4-8.8,9.4c0,5,3.9,9.1,8.8,9.4h1.3c4.9-0.3,8.8-4.4,8.8-9.4C19.5,16.3,15.6,12.2,10.7,11.9z M13.3,24.4H6.7v-1.2h6.6z M13.3,22H6.7v-1.2h6.6z M13.3,19.6H6.7v-1.2h6.6z",size:45,margin:50,color:"#333",shadowBlur:3,shadowColor:"#aaa",shadowOffsetX:0,shadowOffsetY:2,throttle:40}},e}(Rp),gN=Oo(),yN=E;function vN(t,e,n){if(!r.node){var i=e.getZr();gN(i).records||(gN(i).records={}),function(t,e){if(gN(t).initialized)return;function n(n,i){t.on(n,(function(n){var r=function(t){var e={showTip:[],hideTip:[]},n=function(i){var r=e[i.type];r?r.push(i):(i.dispatchAction=n,t.dispatchAction(i))};return{dispatchAction:n,pendings:e}}(e);yN(gN(t).records,(function(t){t&&i(t,n,r.dispatchAction)})),function(t,e){var n,i=t.showTip.length,r=t.hideTip.length;i?n=t.showTip[i-1]:r&&(n=t.hideTip[r-1]);n&&(n.dispatchAction=null,e.dispatchAction(n))}(r.pendings,e)}))}gN(t).initialized=!0,n("click",H(xN,"click")),n("mousemove",H(xN,"mousemove")),n("globalout",mN)}(i,e),(gN(i).records[t]||(gN(i).records[t]={})).handler=n}}function mN(t,e,n){t.handler("leave",null,n)}function xN(t,e,n,i){e.handler(t,n,i)}function _N(t,e){if(!r.node){var n=e.getZr();(gN(n).records||{})[t]&&(gN(n).records[t]=null)}}var bN=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.prototype.render=function(t,e,n){var i=e.getComponent("tooltip"),r=t.get("triggerOn")||i&&i.get("triggerOn")||"mousemove|click";vN("axisPointer",n,(function(t,e,n){"none"!==r&&("leave"===t||r.indexOf(t)>=0)&&n({type:"updateAxisPointer",currTrigger:t,x:e&&e.offsetX,y:e&&e.offsetY})}))},e.prototype.remove=function(t,e){_N("axisPointer",e)},e.prototype.dispose=function(t,e){_N("axisPointer",e)},e.type="axisPointer",e}(Tg);function wN(t,e){var n,i=[],r=t.seriesIndex;if(null==r||!(n=e.getSeriesByIndex(r)))return{point:[]};var o=n.getData(),a=Po(o,t);if(null==a||a<0||Y(a))return{point:[]};var s=o.getItemGraphicEl(a),l=n.coordinateSystem;if(n.getTooltipPosition)i=n.getTooltipPosition(a)||[];else if(l&&l.dataToPoint)if(t.isStacked){var u=l.getBaseAxis(),h=l.getOtherAxis(u).dim,c=u.dim,p="x"===h||"radius"===h?1:0,d=o.mapDimension(c),f=[];f[p]=o.get(d,a),f[1-p]=o.get(o.getCalculationInfo("stackResultDimension"),a),i=l.dataToPoint(f)||[]}else i=l.dataToPoint(o.getValues(z(l.dimensions,(function(t){return o.mapDimension(t)})),a))||[];else if(s){var g=s.getBoundingRect().clone();g.applyTransform(s.transform),i=[g.x+g.width/2,g.y+g.height/2]}return{point:i,el:s}}var SN=Oo();function MN(t,e,n){var i=t.currTrigger,r=[t.x,t.y],o=t,a=t.dispatchAction||W(n.dispatchAction,n),s=e.getComponent("axisPointer").coordSysAxesInfo;if(s){AN(r)&&(r=wN({seriesIndex:o.seriesIndex,dataIndex:o.dataIndex},e).point);var l=AN(r),u=o.axesInfo,h=s.axesInfo,c="leave"===i||AN(r),p={},d={},f={list:[],map:{}},g={showPointer:H(TN,d),showTooltip:H(CN,f)};E(s.coordSysMap,(function(t,e){var n=l||t.containPoint(r);E(s.coordSysAxesInfo[e],(function(t,e){var i=t.axis,o=function(t,e){for(var n=0;n<(t||[]).length;n++){var i=t[n];if(e.axis.dim===i.axisDim&&e.axis.model.componentIndex===i.axisIndex)return i}}(u,t);if(!c&&n&&(!u||o)){var a=o&&o.value;null!=a||l||(a=i.pointToData(r)),null!=a&&IN(t,a,g,!1,p)}}))}));var y={};return E(h,(function(t,e){var n=t.linkGroup;n&&!d[e]&&E(n.axesInfo,(function(e,i){var r=d[i];if(e!==t&&r){var o=r.value;n.mapper&&(o=t.axis.scale.parse(n.mapper(o,DN(e),DN(t)))),y[t.key]=o}}))})),E(y,(function(t,e){IN(h[e],t,g,!0,p)})),function(t,e,n){var i=n.axesInfo=[];E(e,(function(e,n){var r=e.axisPointerModel.option,o=t[n];o?(!e.useHandle&&(r.status="show"),r.value=o.value,r.seriesDataIndices=(o.payloadBatch||[]).slice()):!e.useHandle&&(r.status="hide"),"show"===r.status&&i.push({axisDim:e.axis.dim,axisIndex:e.axis.model.componentIndex,value:r.value})}))}(d,h,p),function(t,e,n,i){if(AN(e)||!t.list.length)return void i({type:"hideTip"});var r=((t.list[0].dataByAxis[0]||{}).seriesDataIndices||[])[0]||{};i({type:"showTip",escapeConnect:!0,x:e[0],y:e[1],tooltipOption:n.tooltipOption,position:n.position,dataIndexInside:r.dataIndexInside,dataIndex:r.dataIndex,seriesIndex:r.seriesIndex,dataByCoordSys:t.list})}(f,r,t,a),function(t,e,n){var i=n.getZr(),r="axisPointerLastHighlights",o=SN(i)[r]||{},a=SN(i)[r]={};E(t,(function(t,e){var n=t.axisPointerModel.option;"show"===n.status&&t.triggerEmphasis&&E(n.seriesDataIndices,(function(t){var e=t.seriesIndex+" | "+t.dataIndex;a[e]=t}))}));var s=[],l=[];E(o,(function(t,e){!a[e]&&l.push(t)})),E(a,(function(t,e){!o[e]&&s.push(t)})),l.length&&n.dispatchAction({type:"downplay",escapeConnect:!0,notBlur:!0,batch:l}),s.length&&n.dispatchAction({type:"highlight",escapeConnect:!0,notBlur:!0,batch:s})}(h,0,n),p}}function IN(t,e,n,i,r){var o=t.axis;if(!o.scale.isBlank()&&o.containData(e))if(t.involveSeries){var a=function(t,e){var n=e.axis,i=n.dim,r=t,o=[],a=Number.MAX_VALUE,s=-1;return E(e.seriesModels,(function(e,l){var u,h,c=e.getData().mapDimensionsAll(i);if(e.getAxisTooltipData){var p=e.getAxisTooltipData(c,t,n);h=p.dataIndices,u=p.nestestValue}else{if(!(h=e.getData().indicesOfNearest(c[0],t,"category"===n.type?.5:null)).length)return;u=e.getData().get(c[0],h[0])}if(null!=u&&isFinite(u)){var d=t-u,f=Math.abs(d);f<=a&&((f=0&&s<0)&&(a=f,s=d,r=u,o.length=0),E(h,(function(t){o.push({seriesIndex:e.seriesIndex,dataIndexInside:t,dataIndex:e.getData().getRawIndex(t)})})))}})),{payloadBatch:o,snapToValue:r}}(e,t),s=a.payloadBatch,l=a.snapToValue;s[0]&&null==r.seriesIndex&&A(r,s[0]),!i&&t.snap&&o.containData(l)&&null!=l&&(e=l),n.showPointer(t,e,s),n.showTooltip(t,a,l)}else n.showPointer(t,e)}function TN(t,e,n,i){t[e.key]={value:n,payloadBatch:i}}function CN(t,e,n,i){var r=n.payloadBatch,o=e.axis,a=o.model,s=e.axisPointerModel;if(e.triggerTooltip&&r.length){var l=e.coordSys.model,u=fI(l),h=t.map[u];h||(h=t.map[u]={coordSysId:l.id,coordSysIndex:l.componentIndex,coordSysType:l.type,coordSysMainType:l.mainType,dataByAxis:[]},t.list.push(h)),h.dataByAxis.push({axisDim:o.dim,axisIndex:a.componentIndex,axisType:a.type,axisId:a.id,value:i,valueLabelOpt:{precision:s.get(["label","precision"]),formatter:s.get(["label","formatter"])},seriesDataIndices:r.slice()})}}function DN(t){var e=t.axis.model,n={},i=n.axisDim=t.axis.dim;return n.axisIndex=n[i+"AxisIndex"]=e.componentIndex,n.axisName=n[i+"AxisName"]=e.name,n.axisId=n[i+"AxisId"]=e.id,n}function AN(t){return!t||null==t[0]||isNaN(t[0])||null==t[1]||isNaN(t[1])}function kN(t){yI.registerAxisPointerClass("CartesianAxisPointer",hN),t.registerComponentModel(fN),t.registerComponentView(bN),t.registerPreprocessor((function(t){if(t){(!t.axisPointer||0===t.axisPointer.length)&&(t.axisPointer={});var e=t.axisPointer.link;e&&!Y(e)&&(t.axisPointer.link=[e])}})),t.registerProcessor(t.PRIORITY.PROCESSOR.STATISTIC,(function(t,e){t.getComponent("axisPointer").coordSysAxesInfo=uI(t,e)})),t.registerAction({type:"updateAxisPointer",event:"updateAxisPointer",update:":updateAxisPointer"},MN)}var LN=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return n(e,t),e.prototype.makeElOption=function(t,e,n,i,r){var o=n.axis;"angle"===o.dim&&(this.animationThreshold=Math.PI/18);var a=o.polar,s=a.getOtherAxis(o).getExtent(),l=o.dataToCoord(e),u=i.get("type");if(u&&"none"!==u){var h=nN(i),c=PN[u](o,a,l,s);c.style=h,t.graphicKey=c.type,t.pointer=c}var p=function(t,e,n,i,r){var o=e.axis,a=o.dataToCoord(t),s=i.getAngleAxis().getExtent()[0];s=s/180*Math.PI;var l,u,h,c=i.getRadiusAxis().getExtent();if("radius"===o.dim){var p=[1,0,0,1,0,0];Se(p,p,s),we(p,p,[i.cx,i.cy]),l=zh([a,-r],p);var d=e.getModel("axisLabel").get("rotate")||0,f=iI.innerTextLayout(s,d*Math.PI/180,-1);u=f.textAlign,h=f.textVerticalAlign}else{var g=c[1];l=i.coordToPoint([g+r,a]);var y=i.cx,v=i.cy;u=Math.abs(l[0]-y)/g<.3?"center":l[0]>y?"left":"right",h=Math.abs(l[1]-v)/g<.3?"middle":l[1]>v?"top":"bottom"}return{position:l,align:u,verticalAlign:h}}(e,n,0,a,i.get(["label","margin"]));iN(t,n,i,r,p)},e}(KR);var PN={line:function(t,e,n,i){return"angle"===t.dim?{type:"Line",shape:sN(e.coordToPoint([i[0],n]),e.coordToPoint([i[1],n]))}:{type:"Circle",shape:{cx:e.cx,cy:e.cy,r:n}}},shadow:function(t,e,n,i){var r=Math.max(1,t.getBandWidth()),o=Math.PI/180;return"angle"===t.dim?{type:"Sector",shape:uN(e.cx,e.cy,i[0],i[1],(-n-r/2)*o,(r/2-n)*o)}:{type:"Sector",shape:uN(e.cx,e.cy,n-r/2,n+r/2,0,2*Math.PI)}}},ON=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.prototype.findAxisModel=function(t){var e;return this.ecModel.eachComponent(t,(function(t){t.getCoordSysModel()===this&&(e=t)}),this),e},e.type="polar",e.dependencies=["radiusAxis","angleAxis"],e.defaultOption={z:0,center:["50%","50%"],radius:"80%"},e}(Rp),RN=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return n(e,t),e.prototype.getCoordSysModel=function(){return this.getReferringComponents("polar",zo).models[0]},e.type="polarAxis",e}(Rp);R(RN,I_);var NN=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.type="angleAxis",e}(RN),EN=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.type="radiusAxis",e}(RN),zN=function(t){function e(e,n){return t.call(this,"radius",e,n)||this}return n(e,t),e.prototype.pointToData=function(t,e){return this.polar.pointToData(t,e)["radius"===this.dim?0:1]},e}(nb);zN.prototype.dataToRadius=nb.prototype.dataToCoord,zN.prototype.radiusToData=nb.prototype.coordToData;var VN=Oo(),BN=function(t){function e(e,n){return t.call(this,"angle",e,n||[0,360])||this}return n(e,t),e.prototype.pointToData=function(t,e){return this.polar.pointToData(t,e)["radius"===this.dim?0:1]},e.prototype.calculateCategoryInterval=function(){var t=this,e=t.getLabelModel(),n=t.scale,i=n.getExtent(),r=n.count();if(i[1]-i[0]<1)return 0;var o=i[0],a=t.dataToCoord(o+1)-t.dataToCoord(o),s=Math.abs(a),l=br(null==o?"":o+"",e.getFont(),"center","top"),u=Math.max(l.height,7)/s;isNaN(u)&&(u=1/0);var h=Math.max(0,Math.floor(u)),c=VN(t.model),p=c.lastAutoInterval,d=c.lastTickCount;return null!=p&&null!=d&&Math.abs(p-h)<=1&&Math.abs(d-r)<=1&&p>h?h=p:(c.lastTickCount=r,c.lastAutoInterval=h),h},e}(nb);BN.prototype.dataToAngle=nb.prototype.dataToCoord,BN.prototype.angleToData=nb.prototype.coordToData;var FN=["radius","angle"],GN=function(){function t(t){this.dimensions=FN,this.type="polar",this.cx=0,this.cy=0,this._radiusAxis=new zN,this._angleAxis=new BN,this.axisPointerEnabled=!0,this.name=t||"",this._radiusAxis.polar=this._angleAxis.polar=this}return t.prototype.containPoint=function(t){var e=this.pointToCoord(t);return this._radiusAxis.contain(e[0])&&this._angleAxis.contain(e[1])},t.prototype.containData=function(t){return this._radiusAxis.containData(t[0])&&this._angleAxis.containData(t[1])},t.prototype.getAxis=function(t){return this["_"+t+"Axis"]},t.prototype.getAxes=function(){return[this._radiusAxis,this._angleAxis]},t.prototype.getAxesByScale=function(t){var e=[],n=this._angleAxis,i=this._radiusAxis;return n.scale.type===t&&e.push(n),i.scale.type===t&&e.push(i),e},t.prototype.getAngleAxis=function(){return this._angleAxis},t.prototype.getRadiusAxis=function(){return this._radiusAxis},t.prototype.getOtherAxis=function(t){var e=this._angleAxis;return t===e?this._radiusAxis:e},t.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAngleAxis()},t.prototype.getTooltipAxes=function(t){var e=null!=t&&"auto"!==t?this.getAxis(t):this.getBaseAxis();return{baseAxes:[e],otherAxes:[this.getOtherAxis(e)]}},t.prototype.dataToPoint=function(t,e){return this.coordToPoint([this._radiusAxis.dataToRadius(t[0],e),this._angleAxis.dataToAngle(t[1],e)])},t.prototype.pointToData=function(t,e){var n=this.pointToCoord(t);return[this._radiusAxis.radiusToData(n[0],e),this._angleAxis.angleToData(n[1],e)]},t.prototype.pointToCoord=function(t){var e=t[0]-this.cx,n=t[1]-this.cy,i=this.getAngleAxis(),r=i.getExtent(),o=Math.min(r[0],r[1]),a=Math.max(r[0],r[1]);i.inverse?o=a-360:a=o+360;var s=Math.sqrt(e*e+n*n);e/=s,n/=s;for(var l=Math.atan2(-n,e)/Math.PI*180,u=la;)l+=360*u;return[s,l]},t.prototype.coordToPoint=function(t){var e=t[0],n=t[1]/180*Math.PI;return[Math.cos(n)*e+this.cx,-Math.sin(n)*e+this.cy]},t.prototype.getArea=function(){var t=this.getAngleAxis(),e=this.getRadiusAxis().getExtent().slice();e[0]>e[1]&&e.reverse();var n=t.getExtent(),i=Math.PI/180;return{cx:this.cx,cy:this.cy,r0:e[0],r:e[1],startAngle:-n[0]*i,endAngle:-n[1]*i,clockwise:t.inverse,contain:function(t,e){var n=t-this.cx,i=e-this.cy,r=n*n+i*i-1e-4,o=this.r,a=this.r0;return r<=o*o&&r>=a*a}}},t.prototype.convertToPixel=function(t,e,n){return WN(e)===this?this.dataToPoint(n):null},t.prototype.convertFromPixel=function(t,e,n){return WN(e)===this?this.pointToData(n):null},t}();function WN(t){var e=t.seriesModel,n=t.polarModel;return n&&n.coordinateSystem||e&&e.coordinateSystem}function HN(t,e){var n=this,i=n.getAngleAxis(),r=n.getRadiusAxis();if(i.scale.setExtent(1/0,-1/0),r.scale.setExtent(1/0,-1/0),t.eachSeries((function(t){if(t.coordinateSystem===n){var e=t.getData();E(M_(e,"radius"),(function(t){r.scale.unionExtentFromData(e,t)})),E(M_(e,"angle"),(function(t){i.scale.unionExtentFromData(e,t)}))}})),v_(i.scale,i.model),v_(r.scale,r.model),"category"===i.type&&!i.onBand){var o=i.getExtent(),a=360/i.scale.count();i.inverse?o[1]+=a:o[1]-=a,i.setExtent(o[0],o[1])}}function YN(t,e){if(t.type=e.get("type"),t.scale=m_(e),t.onBand=e.get("boundaryGap")&&"category"===t.type,t.inverse=e.get("inverse"),function(t){return"angleAxis"===t.mainType}(e)){t.inverse=t.inverse!==e.get("clockwise");var n=e.get("startAngle");t.setExtent(n,n+(t.inverse?-360:360))}e.axis=t,t.model=e}var XN={dimensions:FN,create:function(t,e){var n=[];return t.eachComponent("polar",(function(t,i){var r=new GN(i+"");r.update=HN;var o=r.getRadiusAxis(),a=r.getAngleAxis(),s=t.findAxisModel("radiusAxis"),l=t.findAxisModel("angleAxis");YN(o,s),YN(a,l),function(t,e,n){var i=e.get("center"),r=n.getWidth(),o=n.getHeight();t.cx=Ur(i[0],r),t.cy=Ur(i[1],o);var a=t.getRadiusAxis(),s=Math.min(r,o)/2,l=e.get("radius");null==l?l=[0,"100%"]:Y(l)||(l=[0,l]);var u=[Ur(l[0],s),Ur(l[1],s)];a.inverse?a.setExtent(u[1],u[0]):a.setExtent(u[0],u[1])}(r,t,e),n.push(r),t.coordinateSystem=r,r.model=t})),t.eachSeries((function(t){if("polar"===t.get("coordinateSystem")){var e=t.getReferringComponents("polar",zo).models[0];0,t.coordinateSystem=e.coordinateSystem}})),n}},UN=["axisLine","axisLabel","axisTick","minorTick","splitLine","minorSplitLine","splitArea"];function ZN(t,e,n){e[1]>e[0]&&(e=e.slice().reverse());var i=t.coordToPoint([e[0],n]),r=t.coordToPoint([e[1],n]);return{x1:i[0],y1:i[1],x2:r[0],y2:r[1]}}function jN(t){return t.getRadiusAxis().inverse?0:1}function qN(t){var e=t[0],n=t[t.length-1];e&&n&&Math.abs(Math.abs(e.coord-n.coord)-360)<1e-4&&t.pop()}var KN=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.axisPointerClass="PolarAxisPointer",n}return n(e,t),e.prototype.render=function(t,e){if(this.group.removeAll(),t.get("show")){var n=t.axis,i=n.polar,r=i.getRadiusAxis().getExtent(),o=n.getTicksCoords(),a=n.getMinorTicksCoords(),s=z(n.getViewLabels(),(function(t){t=T(t);var e=n.scale,i="ordinal"===e.type?e.getRawOrdinalNumber(t.tickValue):t.tickValue;return t.coord=n.dataToCoord(i),t}));qN(s),qN(o),E(UN,(function(e){!t.get([e,"show"])||n.scale.isBlank()&&"axisLine"!==e||$N[e](this.group,t,i,o,a,r,s)}),this)}},e.type="angleAxis",e}(yI),$N={axisLine:function(t,e,n,i,r,o){var a,s=e.getModel(["axisLine","lineStyle"]),l=jN(n),u=l?0:1;(a=0===o[u]?new _u({shape:{cx:n.cx,cy:n.cy,r:o[l]},style:s.getLineStyle(),z2:1,silent:!0}):new Bu({shape:{cx:n.cx,cy:n.cy,r:o[l],r0:o[u]},style:s.getLineStyle(),z2:1,silent:!0})).style.fill=null,t.add(a)},axisTick:function(t,e,n,i,r,o){var a=e.getModel("axisTick"),s=(a.get("inside")?-1:1)*a.get("length"),l=o[jN(n)],u=z(i,(function(t){return new Zu({shape:ZN(n,[l,l+s],t.coord)})}));t.add(Ph(u,{style:k(a.getModel("lineStyle").getLineStyle(),{stroke:e.get(["axisLine","lineStyle","color"])})}))},minorTick:function(t,e,n,i,r,o){if(r.length){for(var a=e.getModel("axisTick"),s=e.getModel("minorTick"),l=(a.get("inside")?-1:1)*s.get("length"),u=o[jN(n)],h=[],c=0;cf?"left":"right",v=Math.abs(d[1]-g)/p<.3?"middle":d[1]>g?"top":"bottom";if(s&&s[c]){var m=s[c];q(m)&&m.textStyle&&(a=new Mc(m.textStyle,l,l.ecModel))}var x=new Fs({silent:iI.isLabelSilent(e),style:nc(a,{x:d[0],y:d[1],fill:a.getTextColor()||e.get(["axisLine","lineStyle","color"]),text:i.formattedLabel,align:y,verticalAlign:v})});if(t.add(x),h){var _=iI.makeAxisEventDataBase(e);_.targetType="axisLabel",_.value=i.rawLabel,Qs(x).eventData=_}}),this)},splitLine:function(t,e,n,i,r,o){var a=e.getModel("splitLine").getModel("lineStyle"),s=a.get("color"),l=0;s=s instanceof Array?s:[s];for(var u=[],h=0;h=0?"p":"n",T=_;m&&(i[s][M]||(i[s][M]={p:_,n:_}),T=i[s][M][I]);var C=void 0,D=void 0,A=void 0,k=void 0;if("radius"===c.dim){var L=c.dataToCoord(S)-_,P=o.dataToCoord(M);Math.abs(L)=k})}}}))}var oE={startAngle:90,clockwise:!0,splitNumber:12,axisLabel:{rotate:0}},aE={splitNumber:5},sE=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.type="polar",e}(Tg);function lE(t,e){e=e||{};var n=t.coordinateSystem,i=t.axis,r={},o=i.position,a=i.orient,s=n.getRect(),l=[s.x,s.x+s.width,s.y,s.y+s.height],u={horizontal:{top:l[2],bottom:l[3]},vertical:{left:l[0],right:l[1]}};r.position=["vertical"===a?u.vertical[o]:l[0],"horizontal"===a?u.horizontal[o]:l[3]];r.rotation=Math.PI/2*{horizontal:0,vertical:1}[a];r.labelDirection=r.tickDirection=r.nameDirection={top:-1,bottom:1,right:1,left:-1}[o],t.get(["axisTick","inside"])&&(r.tickDirection=-r.tickDirection),it(e.labelInside,t.get(["axisLabel","inside"]))&&(r.labelDirection=-r.labelDirection);var h=e.rotate;return null==h&&(h=t.get(["axisLabel","rotate"])),r.labelRotation="top"===o?-h:h,r.z2=1,r}var uE=["axisLine","axisTickLabel","axisName"],hE=["splitArea","splitLine"],cE=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.axisPointerClass="SingleAxisPointer",n}return n(e,t),e.prototype.render=function(e,n,i,r){var o=this.group;o.removeAll();var a=this._axisGroup;this._axisGroup=new zr;var s=lE(e),l=new iI(e,s);E(uE,l.add,l),o.add(this._axisGroup),o.add(l.getGroup()),E(hE,(function(t){e.get([t,"show"])&&pE[t](this,this.group,this._axisGroup,e)}),this),Fh(a,this._axisGroup,e),t.prototype.render.call(this,e,n,i,r)},e.prototype.remove=function(){xI(this)},e.type="singleAxis",e}(yI),pE={splitLine:function(t,e,n,i){var r=i.axis;if(!r.scale.isBlank()){var o=i.getModel("splitLine"),a=o.getModel("lineStyle"),s=a.get("color");s=s instanceof Array?s:[s];for(var l=a.get("width"),u=i.coordinateSystem.getRect(),h=r.isHorizontal(),c=[],p=0,d=r.getTicksCoords({tickModel:o}),f=[],g=[],y=0;y=e.y&&t[1]<=e.y+e.height:n.contain(n.toLocalCoord(t[1]))&&t[0]>=e.y&&t[0]<=e.y+e.height},t.prototype.pointToData=function(t){var e=this.getAxis();return[e.coordToData(e.toLocalCoord(t["horizontal"===e.orient?0:1]))]},t.prototype.dataToPoint=function(t){var e=this.getAxis(),n=this.getRect(),i=[],r="horizontal"===e.orient?0:1;return t instanceof Array&&(t=t[0]),i[r]=e.toGlobalCoord(e.dataToCoord(+t)),i[1-r]=0===r?n.y+n.height/2:n.x+n.width/2,i},t.prototype.convertToPixel=function(t,e,n){return vE(e)===this?this.dataToPoint(n):null},t.prototype.convertFromPixel=function(t,e,n){return vE(e)===this?this.pointToData(n):null},t}();function vE(t){var e=t.seriesModel,n=t.singleAxisModel;return n&&n.coordinateSystem||e&&e.coordinateSystem}var mE={create:function(t,e){var n=[];return t.eachComponent("singleAxis",(function(i,r){var o=new yE(i,t,e);o.name="single_"+r,o.resize(i,e),i.coordinateSystem=o,n.push(o)})),t.eachSeries((function(t){if("singleAxis"===t.get("coordinateSystem")){var e=t.getReferringComponents("singleAxis",zo).models[0];t.coordinateSystem=e&&e.coordinateSystem}})),n},dimensions:gE},xE=["x","y"],_E=["width","height"],bE=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return n(e,t),e.prototype.makeElOption=function(t,e,n,i,r){var o=n.axis,a=o.coordinateSystem,s=ME(a,1-SE(o)),l=a.dataToPoint(e)[0],u=i.get("type");if(u&&"none"!==u){var h=nN(i),c=wE[u](o,l,s);c.style=h,t.graphicKey=c.type,t.pointer=c}aN(e,t,lE(n),n,i,r)},e.prototype.getHandleTransform=function(t,e,n){var i=lE(e,{labelInside:!1});i.labelMargin=n.get(["handle","margin"]);var r=oN(e.axis,t,i);return{x:r[0],y:r[1],rotation:i.rotation+(i.labelDirection<0?Math.PI:0)}},e.prototype.updateHandleTransform=function(t,e,n,i){var r=n.axis,o=r.coordinateSystem,a=SE(r),s=ME(o,a),l=[t.x,t.y];l[a]+=e[a],l[a]=Math.min(s[1],l[a]),l[a]=Math.max(s[0],l[a]);var u=ME(o,1-a),h=(u[1]+u[0])/2,c=[h,h];return c[a]=l[a],{x:l[0],y:l[1],rotation:t.rotation,cursorPoint:c,tooltipOption:{verticalAlign:"middle"}}},e}(KR),wE={line:function(t,e,n){return{type:"Line",subPixelOptimize:!0,shape:sN([e,n[0]],[e,n[1]],SE(t))}},shadow:function(t,e,n){var i=t.getBandWidth(),r=n[1]-n[0];return{type:"Rect",shape:lN([e-i/2,n[0]],[i,r],SE(t))}}};function SE(t){return t.isHorizontal()?0:1}function ME(t,e){var n=t.getRect();return[n[xE[e]],n[xE[e]]+n[_E[e]]]}var IE=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.type="single",e}(Tg);var TE=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.prototype.init=function(e,n,i){var r=Lp(e);t.prototype.init.apply(this,arguments),CE(e,r)},e.prototype.mergeOption=function(e){t.prototype.mergeOption.apply(this,arguments),CE(this.option,e)},e.prototype.getCellSize=function(){return this.option.cellSize},e.type="calendar",e.defaultOption={z:2,left:80,top:60,cellSize:20,orient:"horizontal",splitLine:{show:!0,lineStyle:{color:"#000",width:1,type:"solid"}},itemStyle:{color:"#fff",borderWidth:1,borderColor:"#ccc"},dayLabel:{show:!0,firstDay:0,position:"start",margin:"50%",color:"#000"},monthLabel:{show:!0,position:"start",margin:5,align:"center",formatter:null,color:"#000"},yearLabel:{show:!0,position:null,margin:30,formatter:null,color:"#ccc",fontFamily:"sans-serif",fontWeight:"bolder",fontSize:20}},e}(Rp);function CE(t,e){var n,i=t.cellSize;1===(n=Y(i)?i:t.cellSize=[i,i]).length&&(n[1]=n[0]);var r=z([0,1],(function(t){return function(t,e){return null!=t[Mp[e][0]]||null!=t[Mp[e][1]]&&null!=t[Mp[e][2]]}(e,t)&&(n[t]="auto"),null!=n[t]&&"auto"!==n[t]}));kp(t,e,{type:"box",ignoreSize:r})}var DE=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.prototype.render=function(t,e,n){var i=this.group;i.removeAll();var r=t.coordinateSystem,o=r.getRangeInfo(),a=r.getOrient(),s=e.getLocaleModel();this._renderDayRect(t,o,i),this._renderLines(t,o,a,i),this._renderYearText(t,o,a,i),this._renderMonthText(t,s,a,i),this._renderWeekText(t,s,o,a,i)},e.prototype._renderDayRect=function(t,e,n){for(var i=t.coordinateSystem,r=t.getModel("itemStyle").getItemStyle(),o=i.getCellWidth(),a=i.getCellHeight(),s=e.start.time;s<=e.end.time;s=i.getNextNDay(s,1).time){var l=i.dataToRect([s],!1).tl,u=new zs({shape:{x:l[0],y:l[1],width:o,height:a},cursor:"default",style:r});n.add(u)}},e.prototype._renderLines=function(t,e,n,i){var r=this,o=t.coordinateSystem,a=t.getModel(["splitLine","lineStyle"]).getLineStyle(),s=t.get(["splitLine","show"]),l=a.lineWidth;this._tlpoints=[],this._blpoints=[],this._firstDayOfMonth=[],this._firstDayPoints=[];for(var u=e.start,h=0;u.time<=e.end.time;h++){p(u.formatedDate),0===h&&(u=o.getDateInfo(e.start.y+"-"+e.start.m));var c=u.date;c.setMonth(c.getMonth()+1),u=o.getDateInfo(c)}function p(e){r._firstDayOfMonth.push(o.getDateInfo(e)),r._firstDayPoints.push(o.dataToRect([e],!1).tl);var l=r._getLinePointsOfOneWeek(t,e,n);r._tlpoints.push(l[0]),r._blpoints.push(l[l.length-1]),s&&r._drawSplitline(l,a,i)}p(o.getNextNDay(e.end.time,1).formatedDate),s&&this._drawSplitline(r._getEdgesPoints(r._tlpoints,l,n),a,i),s&&this._drawSplitline(r._getEdgesPoints(r._blpoints,l,n),a,i)},e.prototype._getEdgesPoints=function(t,e,n){var i=[t[0].slice(),t[t.length-1].slice()],r="horizontal"===n?0:1;return i[0][r]=i[0][r]-e/2,i[1][r]=i[1][r]+e/2,i},e.prototype._drawSplitline=function(t,e,n){var i=new Yu({z2:20,shape:{points:t},style:e});n.add(i)},e.prototype._getLinePointsOfOneWeek=function(t,e,n){for(var i=t.coordinateSystem,r=i.getDateInfo(e),o=[],a=0;a<7;a++){var s=i.getNextNDay(r.time,a),l=i.dataToRect([s.time],!1);o[2*s.day]=l.tl,o[2*s.day+1]=l["horizontal"===n?"bl":"tr"]}return o},e.prototype._formatterLabel=function(t,e){return U(t)&&t?(n=t,E(e,(function(t,e){n=n.replace("{"+e+"}",i?re(t):t)})),n):X(t)?t(e):e.nameMap;var n,i},e.prototype._yearTextPositionControl=function(t,e,n,i,r){var o=e[0],a=e[1],s=["center","bottom"];"bottom"===i?(a+=r,s=["center","top"]):"left"===i?o-=r:"right"===i?(o+=r,s=["center","top"]):a-=r;var l=0;return"left"!==i&&"right"!==i||(l=Math.PI/2),{rotation:l,x:o,y:a,style:{align:s[0],verticalAlign:s[1]}}},e.prototype._renderYearText=function(t,e,n,i){var r=t.getModel("yearLabel");if(r.get("show")){var o=r.get("margin"),a=r.get("position");a||(a="horizontal"!==n?"top":"left");var s=[this._tlpoints[this._tlpoints.length-1],this._blpoints[0]],l=(s[0][0]+s[1][0])/2,u=(s[0][1]+s[1][1])/2,h="horizontal"===n?0:1,c={top:[l,s[h][1]],bottom:[l,s[1-h][1]],left:[s[1-h][0],u],right:[s[h][0],u]},p=e.start.y;+e.end.y>+e.start.y&&(p=p+"-"+e.end.y);var d=r.get("formatter"),f={start:e.start.y,end:e.end.y,nameMap:p},g=this._formatterLabel(d,f),y=new Fs({z2:30,style:nc(r,{text:g})});y.attr(this._yearTextPositionControl(y,c[a],n,a,o)),i.add(y)}},e.prototype._monthTextPositionControl=function(t,e,n,i,r){var o="left",a="top",s=t[0],l=t[1];return"horizontal"===n?(l+=r,e&&(o="center"),"start"===i&&(a="bottom")):(s+=r,e&&(a="middle"),"start"===i&&(o="right")),{x:s,y:l,align:o,verticalAlign:a}},e.prototype._renderMonthText=function(t,e,n,i){var r=t.getModel("monthLabel");if(r.get("show")){var o=r.get("nameMap"),a=r.get("margin"),s=r.get("position"),l=r.get("align"),u=[this._tlpoints,this._blpoints];o&&!U(o)||(o&&(e=Nc(o)||e),o=e.get(["time","monthAbbr"])||[]);var h="start"===s?0:1,c="horizontal"===n?0:1;a="start"===s?-a:a;for(var p="center"===l,d=0;d=i.start.time&&n.timea.end.time&&t.reverse(),t},t.prototype._getRangeInfo=function(t){var e,n=[this.getDateInfo(t[0]),this.getDateInfo(t[1])];n[0].time>n[1].time&&(e=!0,n.reverse());var i=Math.floor(n[1].time/AE)-Math.floor(n[0].time/AE)+1,r=new Date(n[0].time),o=r.getDate(),a=n[1].date.getDate();r.setDate(o+i-1);var s=r.getDate();if(s!==a)for(var l=r.getTime()-n[1].time>0?1:-1;(s=r.getDate())!==a&&(r.getTime()-n[1].time)*l>0;)i-=l,r.setDate(s-l);var u=Math.floor((i+n[0].day+6)/7),h=e?1-u:u-1;return e&&n.reverse(),{range:[n[0].formatedDate,n[1].formatedDate],start:n[0],end:n[1],allDay:i,weeks:u,nthWeek:h,fweek:n[0].day,lweek:n[1].day}},t.prototype._getDateByWeeksAndDay=function(t,e,n){var i=this._getRangeInfo(n);if(t>i.weeks||0===t&&ei.lweek)return null;var r=7*(t-1)-i.fweek+e,o=new Date(i.start.time);return o.setDate(+i.start.d+r),this.getDateInfo(o)},t.create=function(e,n){var i=[];return e.eachComponent("calendar",(function(r){var o=new t(r,e,n);i.push(o),r.coordinateSystem=o})),e.eachSeries((function(t){"calendar"===t.get("coordinateSystem")&&(t.coordinateSystem=i[t.get("calendarIndex")||0])})),i},t.dimensions=["time","value"],t}();function LE(t){var e=t.calendarModel,n=t.seriesModel;return e?e.coordinateSystem:n?n.coordinateSystem:null}function PE(t,e){var n;return E(e,(function(e){null!=t[e]&&"auto"!==t[e]&&(n=!0)})),n}var OE=["transition","enterFrom","leaveTo"],RE=OE.concat(["enterAnimation","updateAnimation","leaveAnimation"]);function NE(t,e,n){if(n&&(!t[n]&&e[n]&&(t[n]={}),t=t[n],e=e[n]),t&&e)for(var i=n?OE:RE,r=0;r=0;l--){var p,d,f;if(f=null!=(d=Ao((p=n[l]).id,null))?r.get(d):null){var g=f.parent,y=(c=VE(g),{}),v=Dp(f,p,g===i?{width:o,height:a}:{width:c.width,height:c.height},null,{hv:p.hv,boundingMode:p.bounding},y);if(!VE(f).isNew&&v){for(var m=p.transition,x={},_=0;_=0)?x[b]=w:f[b]=w}fh(f,x,t,0)}else f.attr(y)}}},e.prototype._clear=function(){var t=this,e=this._elMap;e.each((function(n){WE(n,VE(n).option,e,t._lastGraphicModel)})),this._elMap=yt()},e.prototype.dispose=function(){this._clear()},e.type="graphic",e}(Tg);function FE(t){var e=_t(zE,t)?zE[t]:Dh(t);var n=new e({});return VE(n).type=t,n}function GE(t,e,n,i){var r=FE(n);return e.add(r),i.set(t,r),VE(r).id=t,VE(r).isNew=!0,r}function WE(t,e,n,i){t&&t.parent&&("group"===t.type&&t.traverse((function(t){WE(t,e,n,i)})),oR(t,e,i),n.removeKey(VE(t).id))}function HE(t,e,n,i){t.isGroup||E([["cursor",Sa.prototype.cursor],["zlevel",i||0],["z",n||0],["z2",0]],(function(n){var i=n[0];_t(e,i)?t[i]=rt(e[i],n[1]):null==t[i]&&(t[i]=n[1])})),E(G(e),(function(n){if(0===n.indexOf("on")){var i=e[n];t[n]=X(i)?i:null}})),_t(e,"draggable")&&(t.draggable=e.draggable),null!=e.name&&(t.name=e.name),null!=e.id&&(t.id=e.id)}var YE=["x","y","radius","angle","single"],XE=["cartesian2d","polar","singleAxis"];function UE(t){return t+"Axis"}function ZE(t,e){var n,i=yt(),r=[],o=yt();t.eachComponent({mainType:"dataZoom",query:e},(function(t){o.get(t.uid)||s(t)}));do{n=!1,t.eachComponent("dataZoom",a)}while(n);function a(t){!o.get(t.uid)&&function(t){var e=!1;return t.eachTargetAxis((function(t,n){var r=i.get(t);r&&r[n]&&(e=!0)})),e}(t)&&(s(t),n=!0)}function s(t){o.set(t.uid,!0),r.push(t),t.eachTargetAxis((function(t,e){(i.get(t)||i.set(t,[]))[e]=!0}))}return r}function jE(t){var e=t.ecModel,n={infoList:[],infoMap:yt()};return t.eachTargetAxis((function(t,i){var r=e.getComponent(UE(t),i);if(r){var o=r.getCoordSysModel();if(o){var a=o.uid,s=n.infoMap.get(a);s||(s={model:o,axisModels:[]},n.infoList.push(s),n.infoMap.set(a,s)),s.axisModels.push(r)}}})),n}var qE=function(){function t(){this.indexList=[],this.indexMap=[]}return t.prototype.add=function(t){this.indexMap[t]||(this.indexList.push(t),this.indexMap[t]=!0)},t}(),KE=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n._autoThrottle=!0,n._noTarget=!0,n._rangePropMode=["percent","percent"],n}return n(e,t),e.prototype.init=function(t,e,n){var i=$E(t);this.settledOption=i,this.mergeDefaultAndTheme(t,n),this._doInit(i)},e.prototype.mergeOption=function(t){var e=$E(t);C(this.option,t,!0),C(this.settledOption,e,!0),this._doInit(e)},e.prototype._doInit=function(t){var e=this.option;this._setDefaultThrottle(t),this._updateRangeUse(t);var n=this.settledOption;E([["start","startValue"],["end","endValue"]],(function(t,i){"value"===this._rangePropMode[i]&&(e[t[0]]=n[t[0]]=null)}),this),this._resetTarget()},e.prototype._resetTarget=function(){var t=this.get("orient",!0),e=this._targetAxisInfoMap=yt();this._fillSpecifiedTargetAxis(e)?this._orient=t||this._makeAutoOrientByTargetAxis():(this._orient=t||"horizontal",this._fillAutoTargetAxisByOrient(e,this._orient)),this._noTarget=!0,e.each((function(t){t.indexList.length&&(this._noTarget=!1)}),this)},e.prototype._fillSpecifiedTargetAxis=function(t){var e=!1;return E(YE,(function(n){var i=this.getReferringComponents(UE(n),Vo);if(i.specified){e=!0;var r=new qE;E(i.models,(function(t){r.add(t.componentIndex)})),t.set(n,r)}}),this),e},e.prototype._fillAutoTargetAxisByOrient=function(t,e){var n=this.ecModel,i=!0;if(i){var r="vertical"===e?"y":"x";o(n.findComponents({mainType:r+"Axis"}),r)}i&&o(n.findComponents({mainType:"singleAxis",filter:function(t){return t.get("orient",!0)===e}}),"single");function o(e,n){var r=e[0];if(r){var o=new qE;if(o.add(r.componentIndex),t.set(n,o),i=!1,"x"===n||"y"===n){var a=r.getReferringComponents("grid",zo).models[0];a&&E(e,(function(t){r.componentIndex!==t.componentIndex&&a===t.getReferringComponents("grid",zo).models[0]&&o.add(t.componentIndex)}))}}}i&&E(YE,(function(e){if(i){var r=n.findComponents({mainType:UE(e),filter:function(t){return"category"===t.get("type",!0)}});if(r[0]){var o=new qE;o.add(r[0].componentIndex),t.set(e,o),i=!1}}}),this)},e.prototype._makeAutoOrientByTargetAxis=function(){var t;return this.eachTargetAxis((function(e){!t&&(t=e)}),this),"y"===t?"vertical":"horizontal"},e.prototype._setDefaultThrottle=function(t){if(t.hasOwnProperty("throttle")&&(this._autoThrottle=!1),this._autoThrottle){var e=this.ecModel.option;this.option.throttle=e.animation&&e.animationDurationUpdate>0?100:20}},e.prototype._updateRangeUse=function(t){var e=this._rangePropMode,n=this.get("rangeMode");E([["start","startValue"],["end","endValue"]],(function(i,r){var o=null!=t[i[0]],a=null!=t[i[1]];o&&!a?e[r]="percent":!o&&a?e[r]="value":n?e[r]=n[r]:o&&(e[r]="percent")}))},e.prototype.noTarget=function(){return this._noTarget},e.prototype.getFirstTargetAxisModel=function(){var t;return this.eachTargetAxis((function(e,n){null==t&&(t=this.ecModel.getComponent(UE(e),n))}),this),t},e.prototype.eachTargetAxis=function(t,e){this._targetAxisInfoMap.each((function(n,i){E(n.indexList,(function(n){t.call(e,i,n)}))}))},e.prototype.getAxisProxy=function(t,e){var n=this.getAxisModel(t,e);if(n)return n.__dzAxisProxy},e.prototype.getAxisModel=function(t,e){var n=this._targetAxisInfoMap.get(t);if(n&&n.indexMap[e])return this.ecModel.getComponent(UE(t),e)},e.prototype.setRawRange=function(t){var e=this.option,n=this.settledOption;E([["start","startValue"],["end","endValue"]],(function(i){null==t[i[0]]&&null==t[i[1]]||(e[i[0]]=n[i[0]]=t[i[0]],e[i[1]]=n[i[1]]=t[i[1]])}),this),this._updateRangeUse(t)},e.prototype.setCalculatedRange=function(t){var e=this.option;E(["start","startValue","end","endValue"],(function(n){e[n]=t[n]}))},e.prototype.getPercentRange=function(){var t=this.findRepresentativeAxisProxy();if(t)return t.getDataPercentWindow()},e.prototype.getValueRange=function(t,e){if(null!=t||null!=e)return this.getAxisProxy(t,e).getDataValueWindow();var n=this.findRepresentativeAxisProxy();return n?n.getDataValueWindow():void 0},e.prototype.findRepresentativeAxisProxy=function(t){if(t)return t.__dzAxisProxy;for(var e,n=this._targetAxisInfoMap.keys(),i=0;i=0}(e)){var n=UE(this._dimName),i=e.getReferringComponents(n,zo).models[0];i&&this._axisIndex===i.componentIndex&&t.push(e)}}),this),t},t.prototype.getAxisModel=function(){return this.ecModel.getComponent(this._dimName+"Axis",this._axisIndex)},t.prototype.getMinMaxSpan=function(){return T(this._minMaxSpan)},t.prototype.calculateDataWindow=function(t){var e,n=this._dataExtent,i=this.getAxisModel().axis.scale,r=this._dataZoomModel.getRangePropMode(),o=[0,100],a=[],s=[];ez(["start","end"],(function(l,u){var h=t[l],c=t[l+"Value"];"percent"===r[u]?(null==h&&(h=o[u]),c=i.parse(Xr(h,o,n))):(e=!0,h=Xr(c=null==c?n[u]:i.parse(c),n,o)),s[u]=null==c||isNaN(c)?n[u]:c,a[u]=null==h||isNaN(h)?o[u]:h})),nz(s),nz(a);var l=this._minMaxSpan;function u(t,e,n,r,o){var a=o?"Span":"ValueSpan";Ck(0,t,n,"all",l["min"+a],l["max"+a]);for(var s=0;s<2;s++)e[s]=Xr(t[s],n,r,!0),o&&(e[s]=i.parse(e[s]))}return e?u(s,a,n,o,!1):u(a,s,o,n,!0),{valueWindow:s,percentWindow:a}},t.prototype.reset=function(t){if(t===this._dataZoomModel){var e=this.getTargetSeriesModels();this._dataExtent=function(t,e,n){var i=[1/0,-1/0];ez(n,(function(t){!function(t,e,n){e&&E(M_(e,n),(function(n){var i=e.getApproximateExtent(n);i[0]t[1]&&(t[1]=i[1])}))}(i,t.getData(),e)}));var r=t.getAxisModel(),o=f_(r.axis.scale,r,i).calculate();return[o.min,o.max]}(this,this._dimName,e),this._updateMinMaxSpan();var n=this.calculateDataWindow(t.settledOption);this._valueWindow=n.valueWindow,this._percentWindow=n.percentWindow,this._setAxisModel()}},t.prototype.filterData=function(t,e){if(t===this._dataZoomModel){var n=this._dimName,i=this.getTargetSeriesModels(),r=t.get("filterMode"),o=this._valueWindow;"none"!==r&&ez(i,(function(t){var e=t.getData(),i=e.mapDimensionsAll(n);if(i.length){if("weakFilter"===r){var a=e.getStore(),s=z(i,(function(t){return e.getDimensionIndex(t)}),e);e.filterSelf((function(t){for(var e,n,r,l=0;lo[1];if(h&&!c&&!p)return!0;h&&(r=!0),c&&(e=!0),p&&(n=!0)}return r&&e&&n}))}else ez(i,(function(n){if("empty"===r)t.setData(e=e.map(n,(function(t){return function(t){return t>=o[0]&&t<=o[1]}(t)?t:NaN})));else{var i={};i[n]=o,e.selectRange(i)}}));ez(i,(function(t){e.setApproximateExtent(o,t)}))}}))}},t.prototype._updateMinMaxSpan=function(){var t=this._minMaxSpan={},e=this._dataZoomModel,n=this._dataExtent;ez(["min","max"],(function(i){var r=e.get(i+"Span"),o=e.get(i+"ValueSpan");null!=o&&(o=this.getAxisModel().axis.scale.parse(o)),null!=o?r=Xr(n[0]+o,n,[0,100],!0):null!=r&&(o=Xr(r,[0,100],n,!0)-n[0]),t[i+"Span"]=r,t[i+"ValueSpan"]=o}),this)},t.prototype._setAxisModel=function(){var t=this.getAxisModel(),e=this._percentWindow,n=this._valueWindow;if(e){var i=$r(n,[0,500]);i=Math.min(i,20);var r=t.axis.scale.rawExtentInfo;0!==e[0]&&r.setDeterminedMinMax("min",+n[0].toFixed(i)),100!==e[1]&&r.setDeterminedMinMax("max",+n[1].toFixed(i)),r.freeze()}},t}();var rz={getTargetSeries:function(t){function e(e){t.eachComponent("dataZoom",(function(n){n.eachTargetAxis((function(i,r){var o=t.getComponent(UE(i),r);e(i,r,o,n)}))}))}e((function(t,e,n,i){n.__dzAxisProxy=null}));var n=[];e((function(e,i,r,o){r.__dzAxisProxy||(r.__dzAxisProxy=new iz(e,i,o,t),n.push(r.__dzAxisProxy))}));var i=yt();return E(n,(function(t){E(t.getTargetSeriesModels(),(function(t){i.set(t.uid,t)}))})),i},overallReset:function(t,e){t.eachComponent("dataZoom",(function(t){t.eachTargetAxis((function(e,n){t.getAxisProxy(e,n).reset(t)})),t.eachTargetAxis((function(n,i){t.getAxisProxy(n,i).filterData(t,e)}))})),t.eachComponent("dataZoom",(function(t){var e=t.findRepresentativeAxisProxy();if(e){var n=e.getDataPercentWindow(),i=e.getDataValueWindow();t.setCalculatedRange({start:n[0],end:n[1],startValue:i[0],endValue:i[1]})}}))}};var oz=!1;function az(t){oz||(oz=!0,t.registerProcessor(t.PRIORITY.PROCESSOR.FILTER,rz),function(t){t.registerAction("dataZoom",(function(t,e){E(ZE(e,t),(function(e){e.setRawRange({start:t.start,end:t.end,startValue:t.startValue,endValue:t.endValue})}))}))}(t),t.registerSubTypeDefaulter("dataZoom",(function(){return"slider"})))}function sz(t){t.registerComponentModel(JE),t.registerComponentView(tz),az(t)}var lz=function(){},uz={};function hz(t,e){uz[t]=e}function cz(t){return uz[t]}var pz=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.prototype.optionUpdated=function(){t.prototype.optionUpdated.apply(this,arguments);var e=this.ecModel;E(this.option.feature,(function(t,n){var i=cz(n);i&&(i.getDefaultOption&&(i.defaultOption=i.getDefaultOption(e)),C(t,i.defaultOption))}))},e.type="toolbox",e.layoutMode={type:"box",ignoreSize:!0},e.defaultOption={show:!0,z:6,orient:"horizontal",left:"right",top:"top",backgroundColor:"transparent",borderColor:"#ccc",borderRadius:0,borderWidth:0,padding:5,itemSize:15,itemGap:8,showTitle:!0,iconStyle:{borderColor:"#666",color:"none"},emphasis:{iconStyle:{borderColor:"#3E98C5"}},tooltip:{show:!1,position:"bottom"}},e}(Rp);function dz(t,e){var n=fp(e.get("padding")),i=e.getItemStyle(["color","opacity"]);return i.fill=e.get("backgroundColor"),t=new zs({shape:{x:t.x-n[3],y:t.y-n[0],width:t.width+n[1]+n[3],height:t.height+n[0]+n[2],r:e.get("borderRadius")},style:i,silent:!0,z2:-1})}var fz=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return n(e,t),e.prototype.render=function(t,e,n,i){var r=this.group;if(r.removeAll(),t.get("show")){var o=+t.get("itemSize"),a="vertical"===t.get("orient"),s=t.get("feature")||{},l=this._features||(this._features={}),u=[];E(s,(function(t,e){u.push(e)})),new Vm(this._featureNames||[],u).add(h).update(h).remove(H(h,null)).execute(),this._featureNames=u,function(t,e,n){var i=e.getBoxLayoutParams(),r=e.get("padding"),o={width:n.getWidth(),height:n.getHeight()},a=Cp(i,o,r);Tp(e.get("orient"),t,e.get("itemGap"),a.width,a.height),Dp(t,i,o,r)}(r,t,n),r.add(dz(r.getBoundingRect(),t)),a||r.eachChild((function(t){var e=t.__title,i=t.ensureState("emphasis"),a=i.textConfig||(i.textConfig={}),s=t.getTextContent(),l=s&&s.ensureState("emphasis");if(l&&!X(l)&&e){var u=l.style||(l.style={}),h=br(e,Fs.makeFont(u)),c=t.x+r.x,p=!1;t.y+r.y+o+h.height>n.getHeight()&&(a.position="top",p=!0);var d=p?-5-h.height:o+10;c+h.width/2>n.getWidth()?(a.position=["100%",d],u.align="right"):c-h.width/2<0&&(a.position=[0,d],u.align="left")}}))}function h(h,c){var p,d=u[h],f=u[c],g=s[d],y=new Mc(g,t,t.ecModel);if(i&&null!=i.newTitle&&i.featureName===d&&(g.title=i.newTitle),d&&!f){if(function(t){return 0===t.indexOf("my")}(d))p={onclick:y.option.onclick,featureName:d};else{var v=cz(d);if(!v)return;p=new v}l[d]=p}else if(!(p=l[f]))return;p.uid=Tc("toolbox-feature"),p.model=y,p.ecModel=e,p.api=n;var m=p instanceof lz;d||!f?!y.get("show")||m&&p.unusable?m&&p.remove&&p.remove(e,n):(!function(i,s,l){var u,h,c=i.getModel("iconStyle"),p=i.getModel(["emphasis","iconStyle"]),d=s instanceof lz&&s.getIcons?s.getIcons():i.get("icon"),f=i.get("title")||{};U(d)?(u={})[l]=d:u=d;U(f)?(h={})[l]=f:h=f;var g=i.iconPaths={};E(u,(function(l,u){var d=Hh(l,{},{x:-o/2,y:-o/2,width:o,height:o});d.setStyle(c.getItemStyle()),d.ensureState("emphasis").style=p.getItemStyle();var f=new Fs({style:{text:h[u],align:p.get("textAlign"),borderRadius:p.get("textBorderRadius"),padding:p.get("textPadding"),fill:null},ignore:!0});d.setTextContent(f),Zh({el:d,componentModel:t,itemName:u,formatterParamsExtra:{title:h[u]}}),d.__title=h[u],d.on("mouseover",(function(){var e=p.getItemStyle(),i=a?null==t.get("right")&&"right"!==t.get("left")?"right":"left":null==t.get("bottom")&&"bottom"!==t.get("top")?"bottom":"top";f.setStyle({fill:p.get("textFill")||e.fill||e.stroke||"#000",backgroundColor:p.get("textBackgroundColor")}),d.setTextConfig({position:p.get("textPosition")||i}),f.ignore=!t.get("showTitle"),n.enterEmphasis(this)})).on("mouseout",(function(){"emphasis"!==i.get(["iconStatus",u])&&n.leaveEmphasis(this),f.hide()})),("emphasis"===i.get(["iconStatus",u])?kl:Ll)(d),r.add(d),d.on("click",W(s.onclick,s,e,n,u)),g[u]=d}))}(y,p,d),y.setIconStatus=function(t,e){var n=this.option,i=this.iconPaths;n.iconStatus=n.iconStatus||{},n.iconStatus[t]=e,i[t]&&("emphasis"===e?kl:Ll)(i[t])},p instanceof lz&&p.render&&p.render(y,e,n,i)):m&&p.dispose&&p.dispose(e,n)}},e.prototype.updateView=function(t,e,n,i){E(this._features,(function(t){t instanceof lz&&t.updateView&&t.updateView(t.model,e,n,i)}))},e.prototype.remove=function(t,e){E(this._features,(function(n){n instanceof lz&&n.remove&&n.remove(t,e)})),this.group.removeAll()},e.prototype.dispose=function(t,e){E(this._features,(function(n){n instanceof lz&&n.dispose&&n.dispose(t,e)}))},e.type="toolbox",e}(Tg);var gz=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return n(e,t),e.prototype.onclick=function(t,e){var n=this.model,i=n.get("name")||t.get("title.0.text")||"echarts",o="svg"===e.getZr().painter.getType(),a=o?"svg":n.get("type",!0)||"png",s=e.getConnectedDataURL({type:a,backgroundColor:n.get("backgroundColor",!0)||t.get("backgroundColor")||"#fff",connectedBackgroundColor:n.get("connectedBackgroundColor"),excludeComponents:n.get("excludeComponents"),pixelRatio:n.get("pixelRatio")}),l=r.browser;if(X(MouseEvent)&&(l.newEdge||!l.ie&&!l.edge)){var u=document.createElement("a");u.download=i+"."+a,u.target="_blank",u.href=s;var h=new MouseEvent("click",{view:document.defaultView,bubbles:!0,cancelable:!1});u.dispatchEvent(h)}else if(window.navigator.msSaveOrOpenBlob||o){var c=s.split(","),p=c[0].indexOf("base64")>-1,d=o?decodeURIComponent(c[1]):c[1];p&&(d=window.atob(d));var f=i+"."+a;if(window.navigator.msSaveOrOpenBlob){for(var g=d.length,y=new Uint8Array(g);g--;)y[g]=d.charCodeAt(g);var v=new Blob([y]);window.navigator.msSaveOrOpenBlob(v,f)}else{var m=document.createElement("iframe");document.body.appendChild(m);var x=m.contentWindow,_=x.document;_.open("image/svg+xml","replace"),_.write(d),_.close(),x.focus(),_.execCommand("SaveAs",!0,f),document.body.removeChild(m)}}else{var b=n.get("lang"),w='',S=window.open();S.document.write(w),S.document.title=i}},e.getDefaultOption=function(t){return{show:!0,icon:"M4.7,22.9L29.3,45.5L54.7,23.4M4.6,43.6L4.6,58L53.8,58L53.8,43.6M29.2,45.1L29.2,0",title:t.getLocaleModel().get(["toolbox","saveAsImage","title"]),type:"png",connectedBackgroundColor:"#fff",name:"",excludeComponents:["toolbox"],lang:t.getLocaleModel().get(["toolbox","saveAsImage","lang"])}},e}(lz),yz="__ec_magicType_stack__",vz=[["line","bar"],["stack"]],mz=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return n(e,t),e.prototype.getIcons=function(){var t=this.model,e=t.get("icon"),n={};return E(t.get("type"),(function(t){e[t]&&(n[t]=e[t])})),n},e.getDefaultOption=function(t){return{show:!0,type:[],icon:{line:"M4.1,28.9h7.1l9.3-22l7.4,38l9.7-19.7l3,12.8h14.9M4.1,58h51.4",bar:"M6.7,22.9h10V48h-10V22.9zM24.9,13h10v35h-10V13zM43.2,2h10v46h-10V2zM3.1,58h53.7",stack:"M8.2,38.4l-8.4,4.1l30.6,15.3L60,42.5l-8.1-4.1l-21.5,11L8.2,38.4z M51.9,30l-8.1,4.2l-13.4,6.9l-13.9-6.9L8.2,30l-8.4,4.2l8.4,4.2l22.2,11l21.5-11l8.1-4.2L51.9,30z M51.9,21.7l-8.1,4.2L35.7,30l-5.3,2.8L24.9,30l-8.4-4.1l-8.3-4.2l-8.4,4.2L8.2,30l8.3,4.2l13.9,6.9l13.4-6.9l8.1-4.2l8.1-4.1L51.9,21.7zM30.4,2.2L-0.2,17.5l8.4,4.1l8.3,4.2l8.4,4.2l5.5,2.7l5.3-2.7l8.1-4.2l8.1-4.2l8.1-4.1L30.4,2.2z"},title:t.getLocaleModel().get(["toolbox","magicType","title"]),option:{},seriesIndex:{}}},e.prototype.onclick=function(t,e,n){var i=this.model,r=i.get(["seriesIndex",n]);if(xz[n]){var o,a={series:[]};E(vz,(function(t){P(t,n)>=0&&E(t,(function(t){i.setIconStatus(t,"normal")}))})),i.setIconStatus(n,"emphasis"),t.eachComponent({mainType:"series",query:null==r?null:{seriesIndex:r}},(function(t){var e=t.subType,r=t.id,o=xz[n](e,r,t,i);o&&(k(o,t.option),a.series.push(o));var s=t.coordinateSystem;if(s&&"cartesian2d"===s.type&&("line"===n||"bar"===n)){var l=s.getAxesByScale("ordinal")[0];if(l){var u=l.dim+"Axis",h=t.getReferringComponents(u,zo).models[0].componentIndex;a[u]=a[u]||[];for(var c=0;c<=h;c++)a[u][h]=a[u][h]||{};a[u][h].boundaryGap="bar"===n}}}));var s=n;"stack"===n&&(o=C({stack:i.option.title.tiled,tiled:i.option.title.stack},i.option.title),"emphasis"!==i.get(["iconStatus",n])&&(s="tiled")),e.dispatchAction({type:"changeMagicType",currentType:s,newOption:a,newTitle:o,featureName:"magicType"})}},e}(lz),xz={line:function(t,e,n,i){if("bar"===t)return C({id:e,type:"line",data:n.get("data"),stack:n.get("stack"),markPoint:n.get("markPoint"),markLine:n.get("markLine")},i.get(["option","line"])||{},!0)},bar:function(t,e,n,i){if("line"===t)return C({id:e,type:"bar",data:n.get("data"),stack:n.get("stack"),markPoint:n.get("markPoint"),markLine:n.get("markLine")},i.get(["option","bar"])||{},!0)},stack:function(t,e,n,i){var r=n.get("stack")===yz;if("line"===t||"bar"===t)return i.setIconStatus("stack",r?"normal":"emphasis"),C({id:e,stack:r?"":yz},i.get(["option","stack"])||{},!0)}};Mm({type:"changeMagicType",event:"magicTypeChanged",update:"prepareAndUpdate"},(function(t,e){e.mergeOption(t.newOption)}));var _z=new Array(60).join("-"),bz="\t";function wz(t){return t.replace(/^\s\s*/,"").replace(/\s\s*$/,"")}var Sz=new RegExp("[\t]+","g");function Mz(t,e){var n=t.split(new RegExp("\n*"+_z+"\n*","g")),i={series:[]};return E(n,(function(t,n){if(function(t){if(t.slice(0,t.indexOf("\n")).indexOf(bz)>=0)return!0}(t)){var r=function(t){for(var e=t.split(/\n+/g),n=[],i=z(wz(e.shift()).split(Sz),(function(t){return{name:t,data:[]}})),r=0;r=0)&&t(r,i._targetInfoList)}))}return t.prototype.setOutputRanges=function(t,e){return this.matchOutputRanges(t,e,(function(t,e,n){if((t.coordRanges||(t.coordRanges=[])).push(e),!t.coordRange){t.coordRange=e;var i=Vz[t.brushType](0,n,e);t.__rangeOffset={offset:Fz[t.brushType](i.values,t.range,[1,1]),xyMinMax:i.xyMinMax}}})),t},t.prototype.matchOutputRanges=function(t,e,n){E(t,(function(t){var i=this.findTargetInfo(t,e);i&&!0!==i&&E(i.coordSyses,(function(i){var r=Vz[t.brushType](1,i,t.range,!0);n(t,r.values,i,e)}))}),this)},t.prototype.setInputRanges=function(t,e){E(t,(function(t){var n,i,r,o,a,s=this.findTargetInfo(t,e);if(t.range=t.range||[],s&&!0!==s){t.panelId=s.panelId;var l=Vz[t.brushType](0,s.coordSys,t.coordRange),u=t.__rangeOffset;t.range=u?Fz[t.brushType](l.values,u.offset,(n=l.xyMinMax,i=u.xyMinMax,r=Wz(n),o=Wz(i),a=[r[0]/o[0],r[1]/o[1]],isNaN(a[0])&&(a[0]=1),isNaN(a[1])&&(a[1]=1),a)):l.values}}),this)},t.prototype.makePanelOpts=function(t,e){return z(this._targetInfoList,(function(n){var i=n.getPanelRect();return{panelId:n.panelId,defaultBrushType:e?e(n):null,clipPath:AL(i),isTargetByCursor:LL(i,t,n.coordSysModel),getLinearBrushOtherExtent:kL(i)}}))},t.prototype.controlSeries=function(t,e,n){var i=this.findTargetInfo(t,n);return!0===i||i&&P(i.coordSyses,e.coordinateSystem)>=0},t.prototype.findTargetInfo=function(t,e){for(var n=this._targetInfoList,i=Rz(e,t),r=0;rt[1]&&t.reverse(),t}function Rz(t,e){return No(t,e,{includeMainTypes:Lz})}var Nz={grid:function(t,e){var n=t.xAxisModels,i=t.yAxisModels,r=t.gridModels,o=yt(),a={},s={};(n||i||r)&&(E(n,(function(t){var e=t.axis.grid.model;o.set(e.id,e),a[e.id]=!0})),E(i,(function(t){var e=t.axis.grid.model;o.set(e.id,e),s[e.id]=!0})),E(r,(function(t){o.set(t.id,t),a[t.id]=!0,s[t.id]=!0})),o.each((function(t){var r=t.coordinateSystem,o=[];E(r.getCartesians(),(function(t,e){(P(n,t.getAxis("x").model)>=0||P(i,t.getAxis("y").model)>=0)&&o.push(t)})),e.push({panelId:"grid--"+t.id,gridModel:t,coordSysModel:t,coordSys:o[0],coordSyses:o,getPanelRect:zz.grid,xAxisDeclared:a[t.id],yAxisDeclared:s[t.id]})})))},geo:function(t,e){E(t.geoModels,(function(t){var n=t.coordinateSystem;e.push({panelId:"geo--"+t.id,geoModel:t,coordSysModel:t,coordSys:n,coordSyses:[n],getPanelRect:zz.geo})}))}},Ez=[function(t,e){var n=t.xAxisModel,i=t.yAxisModel,r=t.gridModel;return!r&&n&&(r=n.axis.grid.model),!r&&i&&(r=i.axis.grid.model),r&&r===e.gridModel},function(t,e){var n=t.geoModel;return n&&n===e.geoModel}],zz={grid:function(){return this.coordSys.master.getRect().clone()},geo:function(){var t=this.coordSys,e=t.getBoundingRect().clone();return e.applyTransform(Eh(t)),e}},Vz={lineX:H(Bz,0),lineY:H(Bz,1),rect:function(t,e,n,i){var r=t?e.pointToData([n[0][0],n[1][0]],i):e.dataToPoint([n[0][0],n[1][0]],i),o=t?e.pointToData([n[0][1],n[1][1]],i):e.dataToPoint([n[0][1],n[1][1]],i),a=[Oz([r[0],o[0]]),Oz([r[1],o[1]])];return{values:a,xyMinMax:a}},polygon:function(t,e,n,i){var r=[[1/0,-1/0],[1/0,-1/0]];return{values:z(n,(function(n){var o=t?e.pointToData(n,i):e.dataToPoint(n,i);return r[0][0]=Math.min(r[0][0],o[0]),r[1][0]=Math.min(r[1][0],o[1]),r[0][1]=Math.max(r[0][1],o[0]),r[1][1]=Math.max(r[1][1],o[1]),o})),xyMinMax:r}}};function Bz(t,e,n,i){var r=n.getAxis(["x","y"][t]),o=Oz(z([0,1],(function(t){return e?r.coordToData(r.toLocalCoord(i[t]),!0):r.toGlobalCoord(r.dataToCoord(i[t]))}))),a=[];return a[t]=o,a[1-t]=[NaN,NaN],{values:o,xyMinMax:a}}var Fz={lineX:H(Gz,0),lineY:H(Gz,1),rect:function(t,e,n){return[[t[0][0]-n[0]*e[0][0],t[0][1]-n[0]*e[0][1]],[t[1][0]-n[1]*e[1][0],t[1][1]-n[1]*e[1][1]]]},polygon:function(t,e,n){return z(t,(function(t,i){return[t[0]-n[0]*e[i][0],t[1]-n[1]*e[i][1]]}))}};function Gz(t,e,n,i){return[e[0]-i[t]*n[0],e[1]-i[t]*n[1]]}function Wz(t){return t?[t[0][1]-t[0][0],t[1][1]-t[1][0]]:[NaN,NaN]}var Hz,Yz,Xz=E,Uz=_o+"toolbox-dataZoom_",Zz=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return n(e,t),e.prototype.render=function(t,e,n,i){this._brushController||(this._brushController=new Jk(n.getZr()),this._brushController.on("brush",W(this._onBrush,this)).mount()),function(t,e,n,i,r){var o=n._isZoomActive;i&&"takeGlobalCursor"===i.type&&(o="dataZoomSelect"===i.key&&i.dataZoomSelectActive);n._isZoomActive=o,t.setIconStatus("zoom",o?"emphasis":"normal");var a=new Pz(qz(t),e,{include:["grid"]}),s=a.makePanelOpts(r,(function(t){return t.xAxisDeclared&&!t.yAxisDeclared?"lineX":!t.xAxisDeclared&&t.yAxisDeclared?"lineY":"rect"}));n._brushController.setPanels(s).enableBrush(!(!o||!s.length)&&{brushType:"auto",brushStyle:t.getModel("brushStyle").getItemStyle()})}(t,e,this,i,n),function(t,e){t.setIconStatus("back",function(t){return Az(t).length}(e)>1?"emphasis":"normal")}(t,e)},e.prototype.onclick=function(t,e,n){jz[n].call(this)},e.prototype.remove=function(t,e){this._brushController&&this._brushController.unmount()},e.prototype.dispose=function(t,e){this._brushController&&this._brushController.dispose()},e.prototype._onBrush=function(t){var e=t.areas;if(t.isEnd&&e.length){var n={},i=this.ecModel;this._brushController.updateCovers([]),new Pz(qz(this.model),i,{include:["grid"]}).matchOutputRanges(e,i,(function(t,e,n){if("cartesian2d"===n.type){var i=t.brushType;"rect"===i?(r("x",n,e[0]),r("y",n,e[1])):r({lineX:"x",lineY:"y"}[i],n,e)}})),function(t,e){var n=Az(t);Cz(e,(function(e,i){for(var r=n.length-1;r>=0&&!n[r][i];r--);if(r<0){var o=t.queryComponents({mainType:"dataZoom",subType:"select",id:i})[0];if(o){var a=o.getPercentRange();n[0][i]={dataZoomId:i,start:a[0],end:a[1]}}}})),n.push(e)}(i,n),this._dispatchZoomAction(n)}function r(t,e,r){var o=e.getAxis(t),a=o.model,s=function(t,e,n){var i;return n.eachComponent({mainType:"dataZoom",subType:"select"},(function(n){n.getAxisModel(t,e.componentIndex)&&(i=n)})),i}(t,a,i),l=s.findRepresentativeAxisProxy(a).getMinMaxSpan();null==l.minValueSpan&&null==l.maxValueSpan||(r=Ck(0,r.slice(),o.scale.getExtent(),0,l.minValueSpan,l.maxValueSpan)),s&&(n[s.id]={dataZoomId:s.id,startValue:r[0],endValue:r[1]})}},e.prototype._dispatchZoomAction=function(t){var e=[];Xz(t,(function(t,n){e.push(T(t))})),e.length&&this.api.dispatchAction({type:"dataZoom",from:this.uid,batch:e})},e.getDefaultOption=function(t){return{show:!0,filterMode:"filter",icon:{zoom:"M0,13.5h26.9 M13.5,26.9V0 M32.1,13.5H58V58H13.5 V32.1",back:"M22,1.4L9.9,13.5l12.3,12.3 M10.3,13.5H54.9v44.6 H10.3v-26"},title:t.getLocaleModel().get(["toolbox","dataZoom","title"]),brushStyle:{borderWidth:0,color:"rgba(210,219,238,0.2)"}}},e}(lz),jz={zoom:function(){var t=!this._isZoomActive;this.api.dispatchAction({type:"takeGlobalCursor",key:"dataZoomSelect",dataZoomSelectActive:t})},back:function(){this._dispatchZoomAction(function(t){var e=Az(t),n=e[e.length-1];e.length>1&&e.pop();var i={};return Cz(n,(function(t,n){for(var r=e.length-1;r>=0;r--)if(t=e[r][n]){i[n]=t;break}})),i}(this.ecModel))}};function qz(t){var e={xAxisIndex:t.get("xAxisIndex",!0),yAxisIndex:t.get("yAxisIndex",!0),xAxisId:t.get("xAxisId",!0),yAxisId:t.get("yAxisId",!0)};return null==e.xAxisIndex&&null==e.xAxisId&&(e.xAxisIndex="all"),null==e.yAxisIndex&&null==e.yAxisId&&(e.yAxisIndex="all"),e}Hz="dataZoom",Yz=function(t){var e=t.getComponent("toolbox",0),n=["feature","dataZoom"];if(e&&null!=e.get(n)){var i=e.getModel(n),r=[],o=No(t,qz(i));return Xz(o.xAxisModels,(function(t){return a(t,"xAxis","xAxisIndex")})),Xz(o.yAxisModels,(function(t){return a(t,"yAxis","yAxisIndex")})),r}function a(t,e,n){var o=t.componentIndex,a={type:"select",$fromToolbox:!0,filterMode:i.get("filterMode",!0)||"filter",id:Uz+e+o};a[n]=o,r.push(a)}},lt(null==nd.get(Hz)&&Yz),nd.set(Hz,Yz);var Kz=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.type="tooltip",e.dependencies=["axisPointer"],e.defaultOption={z:60,show:!0,showContent:!0,trigger:"item",triggerOn:"mousemove|click",alwaysShowContent:!1,displayMode:"single",renderMode:"auto",confine:null,showDelay:0,hideDelay:100,transitionDuration:.4,enterable:!1,backgroundColor:"#fff",shadowBlur:10,shadowColor:"rgba(0, 0, 0, .2)",shadowOffsetX:1,shadowOffsetY:2,borderRadius:4,borderWidth:1,padding:null,extraCssText:"",axisPointer:{type:"line",axis:"auto",animation:"auto",animationDurationUpdate:200,animationEasingUpdate:"exponentialOut",crossStyle:{color:"#999",width:1,type:"dashed",textStyle:{}}},textStyle:{color:"#666",fontSize:14}},e}(Rp);function $z(t){var e=t.get("confine");return null!=e?!!e:"richText"===t.get("renderMode")}function Jz(t){if(r.domSupported)for(var e=document.documentElement.style,n=0,i=t.length;n-1?(u+="top:50%",h+="translateY(-50%) rotate("+(a="left"===s?-225:-45)+"deg)"):(u+="left:50%",h+="translateX(-50%) rotate("+(a="top"===s?225:45)+"deg)");var c=a*Math.PI/180,p=l+r,d=p*Math.abs(Math.cos(c))+p*Math.abs(Math.sin(c)),f=e+" solid "+r+"px;";return'
'}(n,i,r)),U(t))o.innerHTML=t+a;else if(t){o.innerHTML="",Y(t)||(t=[t]);for(var s=0;s=0?this._tryShow(n,i):"leave"===e&&this._hide(i))}),this))},e.prototype._keepShow=function(){var t=this._tooltipModel,e=this._ecModel,n=this._api,i=t.get("triggerOn");if(null!=this._lastX&&null!=this._lastY&&"none"!==i&&"click"!==i){var r=this;clearTimeout(this._refreshUpdateTimeout),this._refreshUpdateTimeout=setTimeout((function(){!n.isDisposed()&&r.manuallyShowTip(t,e,n,{x:r._lastX,y:r._lastY,dataByCoordSys:r._lastDataByCoordSys})}))}},e.prototype.manuallyShowTip=function(t,e,n,i){if(i.from!==this.uid&&!r.node&&n.getDom()){var o=gV(i,n);this._ticket="";var a=i.dataByCoordSys,s=function(t,e,n){var i=Eo(t).queryOptionMap,r=i.keys()[0];if(!r||"series"===r)return;var o=Bo(e,r,i.get(r),{useDefault:!1,enableAll:!1,enableNone:!1}),a=o.models[0];if(!a)return;var s,l=n.getViewOfComponentModel(a);if(l.group.traverse((function(e){var n=Qs(e).tooltipConfig;if(n&&n.name===t.name)return s=e,!0})),s)return{componentMainType:r,componentIndex:a.componentIndex,el:s}}(i,e,n);if(s){var l=s.el.getBoundingRect().clone();l.applyTransform(s.el.transform),this._tryShow({offsetX:l.x+l.width/2,offsetY:l.y+l.height/2,target:s.el,position:i.position,positionDefault:"bottom"},o)}else if(i.tooltip&&null!=i.x&&null!=i.y){var u=pV;u.x=i.x,u.y=i.y,u.update(),Qs(u).tooltipConfig={name:null,option:i.tooltip},this._tryShow({offsetX:i.x,offsetY:i.y,target:u},o)}else if(a)this._tryShow({offsetX:i.x,offsetY:i.y,position:i.position,dataByCoordSys:a,tooltipOption:i.tooltipOption},o);else if(null!=i.seriesIndex){if(this._manuallyAxisShowTip(t,e,n,i))return;var h=wN(i,e),c=h.point[0],p=h.point[1];null!=c&&null!=p&&this._tryShow({offsetX:c,offsetY:p,target:h.el,position:i.position,positionDefault:"bottom"},o)}else null!=i.x&&null!=i.y&&(n.dispatchAction({type:"updateAxisPointer",x:i.x,y:i.y}),this._tryShow({offsetX:i.x,offsetY:i.y,position:i.position,target:n.getZr().findHover(i.x,i.y).target},o))}},e.prototype.manuallyHideTip=function(t,e,n,i){var r=this._tooltipContent;this._tooltipModel&&r.hideLater(this._tooltipModel.get("hideDelay")),this._lastX=this._lastY=this._lastDataByCoordSys=null,i.from!==this.uid&&this._hide(gV(i,n))},e.prototype._manuallyAxisShowTip=function(t,e,n,i){var r=i.seriesIndex,o=i.dataIndex,a=e.getComponent("axisPointer").coordSysAxesInfo;if(null!=r&&null!=o&&null!=a){var s=e.getSeriesByIndex(r);if(s)if("axis"===fV([s.getData().getItemModel(o),s,(s.coordinateSystem||{}).model],this._tooltipModel).get("trigger"))return n.dispatchAction({type:"updateAxisPointer",seriesIndex:r,dataIndex:o,position:i.position}),!0}},e.prototype._tryShow=function(t,e){var n=t.target;if(this._tooltipModel){this._lastX=t.offsetX,this._lastY=t.offsetY;var i=t.dataByCoordSys;if(i&&i.length)this._showAxisTooltip(i,t);else if(n){var r,o;this._lastDataByCoordSys=null,ky(n,(function(t){return null!=Qs(t).dataIndex?(r=t,!0):null!=Qs(t).tooltipConfig?(o=t,!0):void 0}),!0),r?this._showSeriesItemTooltip(t,r,e):o?this._showComponentItemTooltip(t,o,e):this._hide(e)}else this._lastDataByCoordSys=null,this._hide(e)}},e.prototype._showOrMove=function(t,e){var n=t.get("showDelay");e=W(e,this),clearTimeout(this._showTimout),n>0?this._showTimout=setTimeout(e,n):e()},e.prototype._showAxisTooltip=function(t,e){var n=this._ecModel,i=this._tooltipModel,r=[e.offsetX,e.offsetY],o=fV([e.tooltipOption],i),a=this._renderMode,s=[],l=ng("section",{blocks:[],noHeader:!0}),u=[],h=new dg;E(t,(function(t){E(t.dataByAxis,(function(t){var e=n.getComponent(t.axisDim+"Axis",t.axisIndex),r=t.value;if(e&&null!=r){var o=rN(r,e.axis,n,t.seriesDataIndices,t.valueLabelOpt),c=ng("section",{header:o,noHeader:!ut(o),sortBlocks:!0,blocks:[]});l.blocks.push(c),E(t.seriesDataIndices,(function(l){var p=n.getSeriesByIndex(l.seriesIndex),d=l.dataIndexInside,f=p.getDataParams(d);if(!(f.dataIndex<0)){f.axisDim=t.axisDim,f.axisIndex=t.axisIndex,f.axisType=t.axisType,f.axisId=t.axisId,f.axisValue=__(e.axis,{value:r}),f.axisValueLabel=o,f.marker=h.makeTooltipMarker("item",_p(f.color),a);var g=mf(p.formatTooltip(d,!0,null)),y=g.frag;if(y){var v=fV([p],i).get("valueFormatter");c.blocks.push(v?A({valueFormatter:v},y):y)}g.text&&u.push(g.text),s.push(f)}}))}}))})),l.blocks.reverse(),u.reverse();var c=e.position,p=o.get("order"),d=lg(l,h,a,p,n.get("useUTC"),o.get("textStyle"));d&&u.unshift(d);var f="richText"===a?"\n\n":"
",g=u.join(f);this._showOrMove(o,(function(){this._updateContentNotChangedOnAxis(t,s)?this._updatePosition(o,c,r[0],r[1],this._tooltipContent,s):this._showTooltipContent(o,g,s,Math.random()+"",r[0],r[1],c,null,h)}))},e.prototype._showSeriesItemTooltip=function(t,e,n){var i=this._ecModel,r=Qs(e),o=r.seriesIndex,a=i.getSeriesByIndex(o),s=r.dataModel||a,l=r.dataIndex,u=r.dataType,h=s.getData(u),c=this._renderMode,p=t.positionDefault,d=fV([h.getItemModel(l),s,a&&(a.coordinateSystem||{}).model],this._tooltipModel,p?{position:p}:null),f=d.get("trigger");if(null==f||"item"===f){var g=s.getDataParams(l,u),y=new dg;g.marker=y.makeTooltipMarker("item",_p(g.color),c);var v=mf(s.formatTooltip(l,!1,u)),m=d.get("order"),x=d.get("valueFormatter"),_=v.frag,b=_?lg(x?A({valueFormatter:x},_):_,y,c,m,i.get("useUTC"),d.get("textStyle")):v.text,w="item_"+s.name+"_"+l;this._showOrMove(d,(function(){this._showTooltipContent(d,b,g,w,t.offsetX,t.offsetY,t.position,t.target,y)})),n({type:"showTip",dataIndexInside:l,dataIndex:h.getRawIndex(l),seriesIndex:o,from:this.uid})}},e.prototype._showComponentItemTooltip=function(t,e,n){var i=Qs(e),r=i.tooltipConfig.option||{};if(U(r)){r={content:r,formatter:r}}var o=[r],a=this._ecModel.getComponent(i.componentMainType,i.componentIndex);a&&o.push(a),o.push({formatter:r.content});var s=t.positionDefault,l=fV(o,this._tooltipModel,s?{position:s}:null),u=l.get("content"),h=Math.random()+"",c=new dg;this._showOrMove(l,(function(){var n=T(l.get("formatterParams")||{});this._showTooltipContent(l,u,n,h,t.offsetX,t.offsetY,t.position,e,c)})),n({type:"showTip",from:this.uid})},e.prototype._showTooltipContent=function(t,e,n,i,r,o,a,s,l){if(this._ticket="",t.get("showContent")&&t.get("show")){var u=this._tooltipContent;u.setEnterable(t.get("enterable"));var h=t.get("formatter");a=a||t.get("position");var c=e,p=this._getNearestPoint([r,o],n,t.get("trigger"),t.get("borderColor")).color;if(h)if(U(h)){var d=t.ecModel.get("useUTC"),f=Y(n)?n[0]:n;c=h,f&&f.axisType&&f.axisType.indexOf("time")>=0&&(c=qc(f.axisValue,c,d)),c=mp(c,n,!0)}else if(X(h)){var g=W((function(e,i){e===this._ticket&&(u.setContent(i,l,t,p,a),this._updatePosition(t,a,r,o,u,n,s))}),this);this._ticket=i,c=h(n,i,g)}else c=h;u.setContent(c,l,t,p,a),u.show(t,p),this._updatePosition(t,a,r,o,u,n,s)}},e.prototype._getNearestPoint=function(t,e,n,i){return"axis"===n||Y(e)?{color:i||("html"===this._renderMode?"#fff":"none")}:Y(e)?void 0:{color:i||e.color||e.borderColor}},e.prototype._updatePosition=function(t,e,n,i,r,o,a){var s=this._api.getWidth(),l=this._api.getHeight();e=e||t.get("position");var u=r.getSize(),h=t.get("align"),c=t.get("verticalAlign"),p=a&&a.getBoundingRect().clone();if(a&&p.applyTransform(a.transform),X(e)&&(e=e([n,i],o,r.el,p,{viewSize:[s,l],contentSize:u.slice()})),Y(e))n=Ur(e[0],s),i=Ur(e[1],l);else if(q(e)){var d=e;d.width=u[0],d.height=u[1];var f=Cp(d,{width:s,height:l});n=f.x,i=f.y,h=null,c=null}else if(U(e)&&a){var g=function(t,e,n,i){var r=n[0],o=n[1],a=Math.ceil(Math.SQRT2*i)+8,s=0,l=0,u=e.width,h=e.height;switch(t){case"inside":s=e.x+u/2-r/2,l=e.y+h/2-o/2;break;case"top":s=e.x+u/2-r/2,l=e.y-o-a;break;case"bottom":s=e.x+u/2-r/2,l=e.y+h+a;break;case"left":s=e.x-r-a,l=e.y+h/2-o/2;break;case"right":s=e.x+u+a,l=e.y+h/2-o/2}return[s,l]}(e,p,u,t.get("borderWidth"));n=g[0],i=g[1]}else{g=function(t,e,n,i,r,o,a){var s=n.getSize(),l=s[0],u=s[1];null!=o&&(t+l+o+2>i?t-=l+o:t+=o);null!=a&&(e+u+a>r?e-=u+a:e+=a);return[t,e]}(n,i,r,s,l,h?null:20,c?null:20);n=g[0],i=g[1]}if(h&&(n-=yV(h)?u[0]/2:"right"===h?u[0]:0),c&&(i-=yV(c)?u[1]/2:"bottom"===c?u[1]:0),$z(t)){g=function(t,e,n,i,r){var o=n.getSize(),a=o[0],s=o[1];return t=Math.min(t+a,i)-a,e=Math.min(e+s,r)-s,t=Math.max(t,0),e=Math.max(e,0),[t,e]}(n,i,r,s,l);n=g[0],i=g[1]}r.moveTo(n,i)},e.prototype._updateContentNotChangedOnAxis=function(t,e){var n=this._lastDataByCoordSys,i=this._cbParamsList,r=!!n&&n.length===t.length;return r&&E(n,(function(n,o){var a=n.dataByAxis||[],s=(t[o]||{}).dataByAxis||[];(r=r&&a.length===s.length)&&E(a,(function(t,n){var o=s[n]||{},a=t.seriesDataIndices||[],l=o.seriesDataIndices||[];(r=r&&t.value===o.value&&t.axisType===o.axisType&&t.axisId===o.axisId&&a.length===l.length)&&E(a,(function(t,e){var n=l[e];r=r&&t.seriesIndex===n.seriesIndex&&t.dataIndex===n.dataIndex})),i&&E(t.seriesDataIndices,(function(t){var n=t.seriesIndex,o=e[n],a=i[n];o&&a&&a.data!==o.data&&(r=!1)}))}))})),this._lastDataByCoordSys=t,this._cbParamsList=e,!!r},e.prototype._hide=function(t){this._lastDataByCoordSys=null,t({type:"hideTip",from:this.uid})},e.prototype.dispose=function(t,e){!r.node&&e.getDom()&&(Gg(this,"_updatePosition"),this._tooltipContent.dispose(),_N("itemTooltip",e))},e.type="tooltip",e}(Tg);function fV(t,e,n){var i,r=e.ecModel;n?(i=new Mc(n,r,r),i=new Mc(e.option,i,r)):i=e;for(var o=t.length-1;o>=0;o--){var a=t[o];a&&(a instanceof Mc&&(a=a.get("tooltip",!0)),U(a)&&(a={formatter:a}),a&&(i=new Mc(a,i,r)))}return i}function gV(t,e){return t.dispatchAction||W(e.dispatchAction,e)}function yV(t){return"center"===t||"middle"===t}var vV=["rect","polygon","keep","clear"];function mV(t,e){var n=bo(t?t.brush:[]);if(n.length){var i=[];E(n,(function(t){var e=t.hasOwnProperty("toolbox")?t.toolbox:[];e instanceof Array&&(i=i.concat(e))}));var r=t&&t.toolbox;Y(r)&&(r=r[0]),r||(r={feature:{}},t.toolbox=[r]);var o=r.feature||(r.feature={}),a=o.brush||(o.brush={}),s=a.type||(a.type=[]);s.push.apply(s,i),function(t){var e={};E(t,(function(t){e[t]=1})),t.length=0,E(e,(function(e,n){t.push(n)}))}(s),e&&!s.length&&s.push.apply(s,vV)}}var xV=E;function _V(t){if(t)for(var e in t)if(t.hasOwnProperty(e))return!0}function bV(t,e,n){var i={};return xV(e,(function(e){var r,o=i[e]=((r=function(){}).prototype.__hidden=r.prototype,new r);xV(t[e],(function(t,i){if(_D.isValidType(i)){var r={type:i,visual:t};n&&n(r,e),o[i]=new _D(r),"opacity"===i&&((r=T(r)).type="colorAlpha",o.__hidden.__alphaForOpacity=new _D(r))}}))})),i}function wV(t,e,n){var i;E(n,(function(t){e.hasOwnProperty(t)&&_V(e[t])&&(i=!0)})),i&&E(n,(function(n){e.hasOwnProperty(n)&&_V(e[n])?t[n]=T(e[n]):delete t[n]}))}var SV={lineX:MV(0),lineY:MV(1),rect:{point:function(t,e,n){return t&&n.boundingRect.contain(t[0],t[1])},rect:function(t,e,n){return t&&n.boundingRect.intersect(t)}},polygon:{point:function(t,e,n){return t&&n.boundingRect.contain(t[0],t[1])&&A_(n.range,t[0],t[1])},rect:function(t,e,n){var i=n.range;if(!t||i.length<=1)return!1;var r=t.x,o=t.y,a=t.width,s=t.height,l=i[0];return!!(A_(i,r,o)||A_(i,r+a,o)||A_(i,r,o+s)||A_(i,r+a,o+s)||ze.create(t).contain(l[0],l[1])||Yh(r,o,r+a,o,i)||Yh(r,o,r,o+s,i)||Yh(r+a,o,r+a,o+s,i)||Yh(r,o+s,r+a,o+s,i))||void 0}}};function MV(t){var e=["x","y"],n=["width","height"];return{point:function(e,n,i){if(e){var r=i.range;return IV(e[t],r)}},rect:function(i,r,o){if(i){var a=o.range,s=[i[e[t]],i[e[t]]+i[n[t]]];return s[1]e[0][1]&&(e[0][1]=o[0]),o[1]e[1][1]&&(e[1][1]=o[1])}return e&&RV(e)}};function RV(t){return new ze(t[0][0],t[1][0],t[0][1]-t[0][0],t[1][1]-t[1][0])}var NV=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.prototype.init=function(t,e){this.ecModel=t,this.api=e,this.model,(this._brushController=new Jk(e.getZr())).on("brush",W(this._onBrush,this)).mount()},e.prototype.render=function(t,e,n,i){this.model=t,this._updateController(t,e,n,i)},e.prototype.updateTransform=function(t,e,n,i){AV(e),this._updateController(t,e,n,i)},e.prototype.updateVisual=function(t,e,n,i){this.updateTransform(t,e,n,i)},e.prototype.updateView=function(t,e,n,i){this._updateController(t,e,n,i)},e.prototype._updateController=function(t,e,n,i){(!i||i.$from!==t.id)&&this._brushController.setPanels(t.brushTargetManager.makePanelOpts(n)).enableBrush(t.brushOption).updateCovers(t.areas.slice())},e.prototype.dispose=function(){this._brushController.dispose()},e.prototype._onBrush=function(t){var e=this.model.id,n=this.model.brushTargetManager.setOutputRanges(t.areas,this.ecModel);(!t.isEnd||t.removeOnClick)&&this.api.dispatchAction({type:"brush",brushId:e,areas:T(n),$from:e}),t.isEnd&&this.api.dispatchAction({type:"brushEnd",brushId:e,areas:T(n),$from:e})},e.type="brush",e}(Tg),EV=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.areas=[],n.brushOption={},n}return n(e,t),e.prototype.optionUpdated=function(t,e){var n=this.option;!e&&wV(n,t,["inBrush","outOfBrush"]);var i=n.inBrush=n.inBrush||{};n.outOfBrush=n.outOfBrush||{color:"#ddd"},i.hasOwnProperty("liftZ")||(i.liftZ=5)},e.prototype.setAreas=function(t){t&&(this.areas=z(t,(function(t){return zV(this.option,t)}),this))},e.prototype.setBrushOption=function(t){this.brushOption=zV(this.option,t),this.brushType=this.brushOption.brushType},e.type="brush",e.dependencies=["geo","grid","xAxis","yAxis","parallel","series"],e.defaultOption={seriesIndex:"all",brushType:"rect",brushMode:"single",transformable:!0,brushStyle:{borderWidth:1,color:"rgba(210,219,238,0.3)",borderColor:"#D2DBEE"},throttleType:"fixRate",throttleDelay:0,removeOnClick:!0,z:1e4},e}(Rp);function zV(t,e){return C({brushType:t.brushType,brushMode:t.brushMode,transformable:t.transformable,brushStyle:new Mc(t.brushStyle).getItemStyle(),removeOnClick:t.removeOnClick,z:t.z},e,!0)}var VV=["rect","polygon","lineX","lineY","keep","clear"],BV=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return n(e,t),e.prototype.render=function(t,e,n){var i,r,o;e.eachComponent({mainType:"brush"},(function(t){i=t.brushType,r=t.brushOption.brushMode||"single",o=o||!!t.areas.length})),this._brushType=i,this._brushMode=r,E(t.get("type",!0),(function(e){t.setIconStatus(e,("keep"===e?"multiple"===r:"clear"===e?o:e===i)?"emphasis":"normal")}))},e.prototype.updateView=function(t,e,n){this.render(t,e,n)},e.prototype.getIcons=function(){var t=this.model,e=t.get("icon",!0),n={};return E(t.get("type",!0),(function(t){e[t]&&(n[t]=e[t])})),n},e.prototype.onclick=function(t,e,n){var i=this._brushType,r=this._brushMode;"clear"===n?(e.dispatchAction({type:"axisAreaSelect",intervals:[]}),e.dispatchAction({type:"brush",command:"clear",areas:[]})):e.dispatchAction({type:"takeGlobalCursor",key:"brush",brushOption:{brushType:"keep"===n?i:i!==n&&n,brushMode:"keep"===n?"multiple"===r?"single":"multiple":r}})},e.getDefaultOption=function(t){return{show:!0,type:VV.slice(),icon:{rect:"M7.3,34.7 M0.4,10V-0.2h9.8 M89.6,10V-0.2h-9.8 M0.4,60v10.2h9.8 M89.6,60v10.2h-9.8 M12.3,22.4V10.5h13.1 M33.6,10.5h7.8 M49.1,10.5h7.8 M77.5,22.4V10.5h-13 M12.3,31.1v8.2 M77.7,31.1v8.2 M12.3,47.6v11.9h13.1 M33.6,59.5h7.6 M49.1,59.5 h7.7 M77.5,47.6v11.9h-13",polygon:"M55.2,34.9c1.7,0,3.1,1.4,3.1,3.1s-1.4,3.1-3.1,3.1 s-3.1-1.4-3.1-3.1S53.5,34.9,55.2,34.9z M50.4,51c1.7,0,3.1,1.4,3.1,3.1c0,1.7-1.4,3.1-3.1,3.1c-1.7,0-3.1-1.4-3.1-3.1 C47.3,52.4,48.7,51,50.4,51z M55.6,37.1l1.5-7.8 M60.1,13.5l1.6-8.7l-7.8,4 M59,19l-1,5.3 M24,16.1l6.4,4.9l6.4-3.3 M48.5,11.6 l-5.9,3.1 M19.1,12.8L9.7,5.1l1.1,7.7 M13.4,29.8l1,7.3l6.6,1.6 M11.6,18.4l1,6.1 M32.8,41.9 M26.6,40.4 M27.3,40.2l6.1,1.6 M49.9,52.1l-5.6-7.6l-4.9-1.2",lineX:"M15.2,30 M19.7,15.6V1.9H29 M34.8,1.9H40.4 M55.3,15.6V1.9H45.9 M19.7,44.4V58.1H29 M34.8,58.1H40.4 M55.3,44.4 V58.1H45.9 M12.5,20.3l-9.4,9.6l9.6,9.8 M3.1,29.9h16.5 M62.5,20.3l9.4,9.6L62.3,39.7 M71.9,29.9H55.4",lineY:"M38.8,7.7 M52.7,12h13.2v9 M65.9,26.6V32 M52.7,46.3h13.2v-9 M24.9,12H11.8v9 M11.8,26.6V32 M24.9,46.3H11.8v-9 M48.2,5.1l-9.3-9l-9.4,9.2 M38.9-3.9V12 M48.2,53.3l-9.3,9l-9.4-9.2 M38.9,62.3V46.4",keep:"M4,10.5V1h10.3 M20.7,1h6.1 M33,1h6.1 M55.4,10.5V1H45.2 M4,17.3v6.6 M55.6,17.3v6.6 M4,30.5V40h10.3 M20.7,40 h6.1 M33,40h6.1 M55.4,30.5V40H45.2 M21,18.9h62.9v48.6H21V18.9z",clear:"M22,14.7l30.9,31 M52.9,14.7L22,45.7 M4.7,16.8V4.2h13.1 M26,4.2h7.8 M41.6,4.2h7.8 M70.3,16.8V4.2H57.2 M4.7,25.9v8.6 M70.3,25.9v8.6 M4.7,43.2v12.6h13.1 M26,55.8h7.8 M41.6,55.8h7.8 M70.3,43.2v12.6H57.2"},title:t.getLocaleModel().get(["toolbox","brush","title"])}},e}(lz);var FV=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.layoutMode={type:"box",ignoreSize:!0},n}return n(e,t),e.type="title",e.defaultOption={z:6,show:!0,text:"",target:"blank",subtext:"",subtarget:"blank",left:0,top:0,backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderWidth:0,padding:5,itemGap:10,textStyle:{fontSize:18,fontWeight:"bold",color:"#464646"},subtextStyle:{fontSize:12,color:"#6E7079"}},e}(Rp),GV=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.prototype.render=function(t,e,n){if(this.group.removeAll(),t.get("show")){var i=this.group,r=t.getModel("textStyle"),o=t.getModel("subtextStyle"),a=t.get("textAlign"),s=rt(t.get("textBaseline"),t.get("textVerticalAlign")),l=new Fs({style:nc(r,{text:t.get("text"),fill:r.getTextColor()},{disableBox:!0}),z2:10}),u=l.getBoundingRect(),h=t.get("subtext"),c=new Fs({style:nc(o,{text:h,fill:o.getTextColor(),y:u.height+t.get("itemGap"),verticalAlign:"top"},{disableBox:!0}),z2:10}),p=t.get("link"),d=t.get("sublink"),f=t.get("triggerEvent",!0);l.silent=!p&&!f,c.silent=!d&&!f,p&&l.on("click",(function(){bp(p,"_"+t.get("target"))})),d&&c.on("click",(function(){bp(d,"_"+t.get("subtarget"))})),Qs(l).eventData=Qs(c).eventData=f?{componentType:"title",componentIndex:t.componentIndex}:null,i.add(l),h&&i.add(c);var g=i.getBoundingRect(),y=t.getBoxLayoutParams();y.width=g.width,y.height=g.height;var v=Cp(y,{width:n.getWidth(),height:n.getHeight()},t.get("padding"));a||("middle"===(a=t.get("left")||t.get("right"))&&(a="center"),"right"===a?v.x+=v.width:"center"===a&&(v.x+=v.width/2)),s||("center"===(s=t.get("top")||t.get("bottom"))&&(s="middle"),"bottom"===s?v.y+=v.height:"middle"===s&&(v.y+=v.height/2),s=s||"top"),i.x=v.x,i.y=v.y,i.markRedraw();var m={align:a,verticalAlign:s};l.setStyle(m),c.setStyle(m),g=i.getBoundingRect();var x=v.margin,_=t.getItemStyle(["color","opacity"]);_.fill=t.get("backgroundColor");var b=new zs({shape:{x:g.x-x[3],y:g.y-x[0],width:g.width+x[1]+x[3],height:g.height+x[0]+x[2],r:t.get("borderRadius")},style:_,subPixelOptimize:!0,silent:!0});i.add(b)}},e.type="title",e}(Tg);var WV=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.layoutMode="box",n}return n(e,t),e.prototype.init=function(t,e,n){this.mergeDefaultAndTheme(t,n),this._initData()},e.prototype.mergeOption=function(e){t.prototype.mergeOption.apply(this,arguments),this._initData()},e.prototype.setCurrentIndex=function(t){null==t&&(t=this.option.currentIndex);var e=this._data.count();this.option.loop?t=(t%e+e)%e:(t>=e&&(t=e-1),t<0&&(t=0)),this.option.currentIndex=t},e.prototype.getCurrentIndex=function(){return this.option.currentIndex},e.prototype.isIndexMax=function(){return this.getCurrentIndex()>=this._data.count()-1},e.prototype.setPlayState=function(t){this.option.autoPlay=!!t},e.prototype.getPlayState=function(){return!!this.option.autoPlay},e.prototype._initData=function(){var t,e=this.option,n=e.data||[],i=e.axisType,r=this._names=[];"category"===i?(t=[],E(n,(function(e,n){var i,o=Ao(Mo(e),"");q(e)?(i=T(e)).value=n:i=n,t.push(i),r.push(o)}))):t=n;var o={category:"ordinal",time:"time",value:"number"}[i]||"number";(this._data=new lx([{name:"value",type:o}],this)).initData(t,r)},e.prototype.getData=function(){return this._data},e.prototype.getCategories=function(){if("category"===this.get("axisType"))return this._names.slice()},e.type="timeline",e.defaultOption={z:4,show:!0,axisType:"time",realtime:!0,left:"20%",top:null,right:"20%",bottom:0,width:null,height:40,padding:5,controlPosition:"left",autoPlay:!1,rewind:!1,loop:!0,playInterval:2e3,currentIndex:0,itemStyle:{},label:{color:"#000"},data:[]},e}(Rp),HV=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.type="timeline.slider",e.defaultOption=Cc(WV.defaultOption,{backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderWidth:0,orient:"horizontal",inverse:!1,tooltip:{trigger:"item"},symbol:"circle",symbolSize:12,lineStyle:{show:!0,width:2,color:"#DAE1F5"},label:{position:"auto",show:!0,interval:"auto",rotate:0,color:"#A4B1D7"},itemStyle:{color:"#A4B1D7",borderWidth:1},checkpointStyle:{symbol:"circle",symbolSize:15,color:"#316bf3",borderColor:"#fff",borderWidth:2,shadowBlur:2,shadowOffsetX:1,shadowOffsetY:1,shadowColor:"rgba(0, 0, 0, 0.3)",animation:!0,animationDuration:300,animationEasing:"quinticInOut"},controlStyle:{show:!0,showPlayBtn:!0,showPrevBtn:!0,showNextBtn:!0,itemSize:24,itemGap:12,position:"left",playIcon:"path://M31.6,53C17.5,53,6,41.5,6,27.4S17.5,1.8,31.6,1.8C45.7,1.8,57.2,13.3,57.2,27.4S45.7,53,31.6,53z M31.6,3.3 C18.4,3.3,7.5,14.1,7.5,27.4c0,13.3,10.8,24.1,24.1,24.1C44.9,51.5,55.7,40.7,55.7,27.4C55.7,14.1,44.9,3.3,31.6,3.3z M24.9,21.3 c0-2.2,1.6-3.1,3.5-2l10.5,6.1c1.899,1.1,1.899,2.9,0,4l-10.5,6.1c-1.9,1.1-3.5,0.2-3.5-2V21.3z",stopIcon:"path://M30.9,53.2C16.8,53.2,5.3,41.7,5.3,27.6S16.8,2,30.9,2C45,2,56.4,13.5,56.4,27.6S45,53.2,30.9,53.2z M30.9,3.5C17.6,3.5,6.8,14.4,6.8,27.6c0,13.3,10.8,24.1,24.101,24.1C44.2,51.7,55,40.9,55,27.6C54.9,14.4,44.1,3.5,30.9,3.5z M36.9,35.8c0,0.601-0.4,1-0.9,1h-1.3c-0.5,0-0.9-0.399-0.9-1V19.5c0-0.6,0.4-1,0.9-1H36c0.5,0,0.9,0.4,0.9,1V35.8z M27.8,35.8 c0,0.601-0.4,1-0.9,1h-1.3c-0.5,0-0.9-0.399-0.9-1V19.5c0-0.6,0.4-1,0.9-1H27c0.5,0,0.9,0.4,0.9,1L27.8,35.8L27.8,35.8z",nextIcon:"M2,18.5A1.52,1.52,0,0,1,.92,18a1.49,1.49,0,0,1,0-2.12L7.81,9.36,1,3.11A1.5,1.5,0,1,1,3,.89l8,7.34a1.48,1.48,0,0,1,.49,1.09,1.51,1.51,0,0,1-.46,1.1L3,18.08A1.5,1.5,0,0,1,2,18.5Z",prevIcon:"M10,.5A1.52,1.52,0,0,1,11.08,1a1.49,1.49,0,0,1,0,2.12L4.19,9.64,11,15.89a1.5,1.5,0,1,1-2,2.22L1,10.77A1.48,1.48,0,0,1,.5,9.68,1.51,1.51,0,0,1,1,8.58L9,.92A1.5,1.5,0,0,1,10,.5Z",prevBtnSize:18,nextBtnSize:18,color:"#A4B1D7",borderColor:"#A4B1D7",borderWidth:1},emphasis:{label:{show:!0,color:"#6f778d"},itemStyle:{color:"#316BF3"},controlStyle:{color:"#316BF3",borderColor:"#316BF3",borderWidth:2}},progress:{lineStyle:{color:"#316BF3"},itemStyle:{color:"#316BF3"},label:{color:"#6f778d"}},data:[]}),e}(WV);R(HV,vf.prototype);var YV=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.type="timeline",e}(Tg),XV=function(t){function e(e,n,i,r){var o=t.call(this,e,n,i)||this;return o.type=r||"value",o}return n(e,t),e.prototype.getLabelModel=function(){return this.model.getModel("label")},e.prototype.isHorizontal=function(){return"horizontal"===this.model.get("orient")},e}(nb),UV=Math.PI,ZV=Oo(),jV=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.prototype.init=function(t,e){this.api=e},e.prototype.render=function(t,e,n){if(this.model=t,this.api=n,this.ecModel=e,this.group.removeAll(),t.get("show",!0)){var i=this._layout(t,n),r=this._createGroup("_mainGroup"),o=this._createGroup("_labelGroup"),a=this._axis=this._createAxis(i,t);t.formatTooltip=function(t){return ng("nameValue",{noName:!0,value:a.scale.getLabel({value:t})})},E(["AxisLine","AxisTick","Control","CurrentPointer"],(function(e){this["_render"+e](i,r,a,t)}),this),this._renderAxisLabel(i,o,a,t),this._position(i,t)}this._doPlayStop(),this._updateTicksStatus()},e.prototype.remove=function(){this._clearTimer(),this.group.removeAll()},e.prototype.dispose=function(){this._clearTimer()},e.prototype._layout=function(t,e){var n,i,r,o,a=t.get(["label","position"]),s=t.get("orient"),l=function(t,e){return Cp(t.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()},t.get("padding"))}(t,e),u={horizontal:"center",vertical:(n=null==a||"auto"===a?"horizontal"===s?l.y+l.height/2=0||"+"===n?"left":"right"},h={horizontal:n>=0||"+"===n?"top":"bottom",vertical:"middle"},c={horizontal:0,vertical:UV/2},p="vertical"===s?l.height:l.width,d=t.getModel("controlStyle"),f=d.get("show",!0),g=f?d.get("itemSize"):0,y=f?d.get("itemGap"):0,v=g+y,m=t.get(["label","rotate"])||0;m=m*UV/180;var x=d.get("position",!0),_=f&&d.get("showPlayBtn",!0),b=f&&d.get("showPrevBtn",!0),w=f&&d.get("showNextBtn",!0),S=0,M=p;"left"===x||"bottom"===x?(_&&(i=[0,0],S+=v),b&&(r=[S,0],S+=v),w&&(o=[M-g,0],M-=v)):(_&&(i=[M-g,0],M-=v),b&&(r=[0,0],S+=v),w&&(o=[M-g,0],M-=v));var I=[S,M];return t.get("inverse")&&I.reverse(),{viewRect:l,mainLength:p,orient:s,rotation:c[s],labelRotation:m,labelPosOpt:n,labelAlign:t.get(["label","align"])||u[s],labelBaseline:t.get(["label","verticalAlign"])||t.get(["label","baseline"])||h[s],playPosition:i,prevBtnPosition:r,nextBtnPosition:o,axisExtent:I,controlSize:g,controlGap:y}},e.prototype._position=function(t,e){var n=this._mainGroup,i=this._labelGroup,r=t.viewRect;if("vertical"===t.orient){var o=[1,0,0,1,0,0],a=r.x,s=r.y+r.height;we(o,o,[-a,-s]),Se(o,o,-UV/2),we(o,o,[a,s]),(r=r.clone()).applyTransform(o)}var l=y(r),u=y(n.getBoundingRect()),h=y(i.getBoundingRect()),c=[n.x,n.y],p=[i.x,i.y];p[0]=c[0]=l[0][0];var d,f=t.labelPosOpt;null==f||U(f)?(v(c,u,l,1,d="+"===f?0:1),v(p,h,l,1,1-d)):(v(c,u,l,1,d=f>=0?0:1),p[1]=c[1]+f);function g(t){t.originX=l[0][0]-t.x,t.originY=l[1][0]-t.y}function y(t){return[[t.x,t.x+t.width],[t.y,t.y+t.height]]}function v(t,e,n,i,r){t[i]+=n[i][r]-e[i][r]}n.setPosition(c),i.setPosition(p),n.rotation=i.rotation=t.rotation,g(n),g(i)},e.prototype._createAxis=function(t,e){var n=e.getData(),i=e.get("axisType"),r=function(t,e){if(e=e||t.get("type"),e)switch(e){case"category":return new Lx({ordinalMeta:t.getCategories(),extent:[1/0,-1/0]});case"time":return new Zx({locale:t.ecModel.getLocaleModel(),useUTC:t.ecModel.get("useUTC")});default:return new Ox}}(e,i);r.getTicks=function(){return n.mapArray(["value"],(function(t){return{value:t}}))};var o=n.getDataExtent("value");r.setExtent(o[0],o[1]),r.calcNiceTicks();var a=new XV("value",r,t.axisExtent,i);return a.model=e,a},e.prototype._createGroup=function(t){var e=this[t]=new zr;return this.group.add(e),e},e.prototype._renderAxisLine=function(t,e,n,i){var r=n.getExtent();if(i.get(["lineStyle","show"])){var o=new Zu({shape:{x1:r[0],y1:0,x2:r[1],y2:0},style:A({lineCap:"round"},i.getModel("lineStyle").getLineStyle()),silent:!0,z2:1});e.add(o);var a=this._progressLine=new Zu({shape:{x1:r[0],x2:this._currentPointer?this._currentPointer.x:r[0],y1:0,y2:0},style:k({lineCap:"round",lineWidth:o.style.lineWidth},i.getModel(["progress","lineStyle"]).getLineStyle()),silent:!0,z2:1});e.add(a)}},e.prototype._renderAxisTick=function(t,e,n,i){var r=this,o=i.getData(),a=n.scale.getTicks();this._tickSymbols=[],E(a,(function(t){var a=n.dataToCoord(t.value),s=o.getItemModel(t.value),l=s.getModel("itemStyle"),u=s.getModel(["emphasis","itemStyle"]),h=s.getModel(["progress","itemStyle"]),c={x:a,y:0,onclick:W(r._changeTimeline,r,t.value)},p=qV(s,l,e,c);p.ensureState("emphasis").style=u.getItemStyle(),p.ensureState("progress").style=h.getItemStyle(),Hl(p);var d=Qs(p);s.get("tooltip")?(d.dataIndex=t.value,d.dataModel=i):d.dataIndex=d.dataModel=null,r._tickSymbols.push(p)}))},e.prototype._renderAxisLabel=function(t,e,n,i){var r=this;if(n.getLabelModel().get("show")){var o=i.getData(),a=n.getViewLabels();this._tickLabels=[],E(a,(function(i){var a=i.tickValue,s=o.getItemModel(a),l=s.getModel("label"),u=s.getModel(["emphasis","label"]),h=s.getModel(["progress","label"]),c=n.dataToCoord(i.tickValue),p=new Fs({x:c,y:0,rotation:t.labelRotation-t.rotation,onclick:W(r._changeTimeline,r,a),silent:!1,style:nc(l,{text:i.formattedLabel,align:t.labelAlign,verticalAlign:t.labelBaseline})});p.ensureState("emphasis").style=nc(u),p.ensureState("progress").style=nc(h),e.add(p),Hl(p),ZV(p).dataIndex=a,r._tickLabels.push(p)}))}},e.prototype._renderControl=function(t,e,n,i){var r=t.controlSize,o=t.rotation,a=i.getModel("controlStyle").getItemStyle(),s=i.getModel(["emphasis","controlStyle"]).getItemStyle(),l=i.getPlayState(),u=i.get("inverse",!0);function h(t,n,l,u){if(t){var h=Ir(rt(i.get(["controlStyle",n+"BtnSize"]),r),r),c=function(t,e,n,i){var r=i.style,o=Hh(t.get(["controlStyle",e]),i||{},new ze(n[0],n[1],n[2],n[3]));r&&o.setStyle(r);return o}(i,n+"Icon",[0,-h/2,h,h],{x:t[0],y:t[1],originX:r/2,originY:0,rotation:u?-o:0,rectHover:!0,style:a,onclick:l});c.ensureState("emphasis").style=s,e.add(c),Hl(c)}}h(t.nextBtnPosition,"next",W(this._changeTimeline,this,u?"-":"+")),h(t.prevBtnPosition,"prev",W(this._changeTimeline,this,u?"+":"-")),h(t.playPosition,l?"stop":"play",W(this._handlePlayClick,this,!l),!0)},e.prototype._renderCurrentPointer=function(t,e,n,i){var r=i.getData(),o=i.getCurrentIndex(),a=r.getItemModel(o).getModel("checkpointStyle"),s=this,l={onCreate:function(t){t.draggable=!0,t.drift=W(s._handlePointerDrag,s),t.ondragend=W(s._handlePointerDragend,s),KV(t,s._progressLine,o,n,i,!0)},onUpdate:function(t){KV(t,s._progressLine,o,n,i)}};this._currentPointer=qV(a,a,this._mainGroup,{},this._currentPointer,l)},e.prototype._handlePlayClick=function(t){this._clearTimer(),this.api.dispatchAction({type:"timelinePlayChange",playState:t,from:this.uid})},e.prototype._handlePointerDrag=function(t,e,n){this._clearTimer(),this._pointerChangeTimeline([n.offsetX,n.offsetY])},e.prototype._handlePointerDragend=function(t){this._pointerChangeTimeline([t.offsetX,t.offsetY],!0)},e.prototype._pointerChangeTimeline=function(t,e){var n=this._toAxisCoord(t)[0],i=jr(this._axis.getExtent().slice());n>i[1]&&(n=i[1]),n=0&&(a[o]=+a[o].toFixed(c)),[a,h]}var sB={min:H(aB,"min"),max:H(aB,"max"),average:H(aB,"average"),median:H(aB,"median")};function lB(t,e){if(e){var n=t.getData(),i=t.coordinateSystem,r=i&&i.dimensions;if(!function(t){return!isNaN(parseFloat(t.x))&&!isNaN(parseFloat(t.y))}(e)&&!Y(e.coord)&&Y(r)){var o=uB(e,n,i,t);if((e=T(e)).type&&sB[e.type]&&o.baseAxis&&o.valueAxis){var a=P(r,o.baseAxis.dim),s=P(r,o.valueAxis.dim),l=sB[e.type](n,o.baseDataDim,o.valueDataDim,a,s);e.coord=l[0],e.value=l[1]}else e.coord=[null!=e.xAxis?e.xAxis:e.radiusAxis,null!=e.yAxis?e.yAxis:e.angleAxis]}if(null!=e.coord&&Y(r))for(var u=e.coord,h=0;h<2;h++)sB[u[h]]&&(u[h]=pB(n,n.mapDimension(r[h]),u[h]));else e.coord=[];return e}}function uB(t,e,n,i){var r={};return null!=t.valueIndex||null!=t.valueDim?(r.valueDataDim=null!=t.valueIndex?e.getDimension(t.valueIndex):t.valueDim,r.valueAxis=n.getAxis(function(t,e){var n=t.getData().getDimensionInfo(e);return n&&n.coordDim}(i,r.valueDataDim)),r.baseAxis=n.getOtherAxis(r.valueAxis),r.baseDataDim=e.mapDimension(r.baseAxis.dim)):(r.baseAxis=i.getBaseAxis(),r.valueAxis=n.getOtherAxis(r.baseAxis),r.baseDataDim=e.mapDimension(r.baseAxis.dim),r.valueDataDim=e.mapDimension(r.valueAxis.dim)),r}function hB(t,e){return!(t&&t.containData&&e.coord&&!oB(e))||t.containData(e.coord)}function cB(t,e){return t?function(t,n,i,r){return wf(r<2?t.coord&&t.coord[r]:t.value,e[r])}:function(t,n,i,r){return wf(t.value,e[r])}}function pB(t,e,n){if("average"===n){var i=0,r=0;return t.each(e,(function(t,e){isNaN(t)||(i+=t,r++)})),i/r}return"median"===n?t.getMedian(e):t.getDataExtent(e)["max"===n?1:0]}var dB=Oo(),fB=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.prototype.init=function(){this.markerGroupMap=yt()},e.prototype.render=function(t,e,n){var i=this,r=this.markerGroupMap;r.each((function(t){dB(t).keep=!1})),e.eachSeries((function(t){var r=iB.getMarkerModelFromSeries(t,i.type);r&&i.renderSeries(t,r,e,n)})),r.each((function(t){!dB(t).keep&&i.group.remove(t.group)}))},e.prototype.markKeep=function(t){dB(t).keep=!0},e.prototype.toggleBlurSeries=function(t,e){var n=this;E(t,(function(t){var i=iB.getMarkerModelFromSeries(t,n.type);i&&i.getData().eachItemGraphicEl((function(t){t&&(e?Pl(t):Ol(t))}))}))},e.type="marker",e}(Tg);function gB(t,e,n){var i=e.coordinateSystem;t.each((function(r){var o,a=t.getItemModel(r),s=Ur(a.get("x"),n.getWidth()),l=Ur(a.get("y"),n.getHeight());if(isNaN(s)||isNaN(l)){if(e.getMarkerPosition)o=e.getMarkerPosition(t.getValues(t.dimensions,r));else if(i){var u=t.get(i.dimensions[0],r),h=t.get(i.dimensions[1],r);o=i.dataToPoint([u,h])}}else o=[s,l];isNaN(s)||(o[0]=s),isNaN(l)||(o[1]=l),t.setItemLayout(r,o)}))}var yB=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.prototype.updateTransform=function(t,e,n){e.eachSeries((function(t){var e=iB.getMarkerModelFromSeries(t,"markPoint");e&&(gB(e.getData(),t,n),this.markerGroupMap.get(t.id).updateLayout())}),this)},e.prototype.renderSeries=function(t,e,n,i){var r=t.coordinateSystem,o=t.id,a=t.getData(),s=this.markerGroupMap,l=s.get(o)||s.set(o,new hS),u=function(t,e,n){var i;i=t?z(t&&t.dimensions,(function(t){return A(A({},e.getData().getDimensionInfo(e.getData().mapDimension(t))||{}),{name:t,ordinalMeta:null})})):[{name:"value",type:"float"}];var r=new lx(i,n),o=z(n.get("data"),H(lB,e));t&&(o=B(o,H(hB,t)));var a=cB(!!t,i);return r.initData(o,null,a),r}(r,t,e);e.setData(u),gB(e.getData(),t,i),u.each((function(t){var n=u.getItemModel(t),i=n.getShallow("symbol"),r=n.getShallow("symbolSize"),o=n.getShallow("symbolRotate"),s=n.getShallow("symbolOffset"),l=n.getShallow("symbolKeepAspect");if(X(i)||X(r)||X(o)||X(s)){var h=e.getRawValue(t),c=e.getDataParams(t);X(i)&&(i=i(h,c)),X(r)&&(r=r(h,c)),X(o)&&(o=o(h,c)),X(s)&&(s=s(h,c))}var p=n.getModel("itemStyle").getItemStyle(),d=Ty(a,"color");p.fill||(p.fill=d),u.setItemVisual(t,{symbol:i,symbolSize:r,symbolRotate:o,symbolOffset:s,symbolKeepAspect:l,style:p})})),l.updateData(u),this.group.add(l.group),u.eachItemGraphicEl((function(t){t.traverse((function(t){Qs(t).dataModel=e}))})),this.markKeep(l),l.group.silent=e.get("silent")||t.get("silent")},e.type="markPoint",e}(fB);var vB=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.prototype.createMarkerModelFromSeries=function(t,n,i){return new e(t,n,i)},e.type="markLine",e.defaultOption={z:5,symbol:["circle","arrow"],symbolSize:[8,16],symbolOffset:0,precision:2,tooltip:{trigger:"item"},label:{show:!0,position:"end",distance:5},lineStyle:{type:"dashed"},emphasis:{label:{show:!0},lineStyle:{width:3}},animationEasing:"linear"},e}(iB),mB=Oo(),xB=function(t,e,n,i){var r,o=t.getData();if(Y(i))r=i;else{var a=i.type;if("min"===a||"max"===a||"average"===a||"median"===a||null!=i.xAxis||null!=i.yAxis){var s=void 0,l=void 0;if(null!=i.yAxis||null!=i.xAxis)s=e.getAxis(null!=i.yAxis?"y":"x"),l=it(i.yAxis,i.xAxis);else{var u=uB(i,o,e,t);s=u.valueAxis,l=pB(o,yx(o,u.valueDataDim),a)}var h="x"===s.dim?0:1,c=1-h,p=T(i),d={coord:[]};p.type=null,p.coord=[],p.coord[c]=-1/0,d.coord[c]=1/0;var f=n.get("precision");f>=0&&j(l)&&(l=+l.toFixed(Math.min(f,20))),p.coord[h]=d.coord[h]=l,r=[p,d,{type:a,valueIndex:i.valueIndex,value:l}]}else r=[]}var g=[lB(t,r[0]),lB(t,r[1]),A({},r[2])];return g[2].type=g[2].type||null,C(g[2],g[0]),C(g[2],g[1]),g};function _B(t){return!isNaN(t)&&!isFinite(t)}function bB(t,e,n,i){var r=1-t,o=i.dimensions[t];return _B(e[r])&&_B(n[r])&&e[t]===n[t]&&i.getAxis(o).containData(e[t])}function wB(t,e){if("cartesian2d"===t.type){var n=e[0].coord,i=e[1].coord;if(n&&i&&(bB(1,n,i,t)||bB(0,n,i,t)))return!0}return hB(t,e[0])&&hB(t,e[1])}function SB(t,e,n,i,r){var o,a=i.coordinateSystem,s=t.getItemModel(e),l=Ur(s.get("x"),r.getWidth()),u=Ur(s.get("y"),r.getHeight());if(isNaN(l)||isNaN(u)){if(i.getMarkerPosition)o=i.getMarkerPosition(t.getValues(t.dimensions,e));else{var h=a.dimensions,c=t.get(h[0],e),p=t.get(h[1],e);o=a.dataToPoint([c,p])}if(MS(a,"cartesian2d")){var d=a.getAxis("x"),f=a.getAxis("y");h=a.dimensions;_B(t.get(h[0],e))?o[0]=d.toGlobalCoord(d.getExtent()[n?0:1]):_B(t.get(h[1],e))&&(o[1]=f.toGlobalCoord(f.getExtent()[n?0:1]))}isNaN(l)||(o[0]=l),isNaN(u)||(o[1]=u)}else o=[l,u];t.setItemLayout(e,o)}var MB=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.prototype.updateTransform=function(t,e,n){e.eachSeries((function(t){var e=iB.getMarkerModelFromSeries(t,"markLine");if(e){var i=e.getData(),r=mB(e).from,o=mB(e).to;r.each((function(e){SB(r,e,!0,t,n),SB(o,e,!1,t,n)})),i.each((function(t){i.setItemLayout(t,[r.getItemLayout(t),o.getItemLayout(t)])})),this.markerGroupMap.get(t.id).updateLayout()}}),this)},e.prototype.renderSeries=function(t,e,n,i){var r=t.coordinateSystem,o=t.id,a=t.getData(),s=this.markerGroupMap,l=s.get(o)||s.set(o,new RA);this.group.add(l.group);var u=function(t,e,n){var i;i=t?z(t&&t.dimensions,(function(t){return A(A({},e.getData().getDimensionInfo(e.getData().mapDimension(t))||{}),{name:t,ordinalMeta:null})})):[{name:"value",type:"float"}];var r=new lx(i,n),o=new lx(i,n),a=new lx([],n),s=z(n.get("data"),H(xB,e,t,n));t&&(s=B(s,H(wB,t)));var l=cB(!!t,i);return r.initData(z(s,(function(t){return t[0]})),null,l),o.initData(z(s,(function(t){return t[1]})),null,l),a.initData(z(s,(function(t){return t[2]}))),a.hasItemOption=!0,{from:r,to:o,line:a}}(r,t,e),h=u.from,c=u.to,p=u.line;mB(e).from=h,mB(e).to=c,e.setData(p);var d=e.get("symbol"),f=e.get("symbolSize"),g=e.get("symbolRotate"),y=e.get("symbolOffset");function v(e,n,r){var o=e.getItemModel(n);SB(e,n,r,t,i);var s=o.getModel("itemStyle").getItemStyle();null==s.fill&&(s.fill=Ty(a,"color")),e.setItemVisual(n,{symbolKeepAspect:o.get("symbolKeepAspect"),symbolOffset:rt(o.get("symbolOffset",!0),y[r?0:1]),symbolRotate:rt(o.get("symbolRotate",!0),g[r?0:1]),symbolSize:rt(o.get("symbolSize"),f[r?0:1]),symbol:rt(o.get("symbol",!0),d[r?0:1]),style:s})}Y(d)||(d=[d,d]),Y(f)||(f=[f,f]),Y(g)||(g=[g,g]),Y(y)||(y=[y,y]),u.from.each((function(t){v(h,t,!0),v(c,t,!1)})),p.each((function(t){var e=p.getItemModel(t).getModel("lineStyle").getLineStyle();p.setItemLayout(t,[h.getItemLayout(t),c.getItemLayout(t)]),null==e.stroke&&(e.stroke=h.getItemVisual(t,"style").fill),p.setItemVisual(t,{fromSymbolKeepAspect:h.getItemVisual(t,"symbolKeepAspect"),fromSymbolOffset:h.getItemVisual(t,"symbolOffset"),fromSymbolRotate:h.getItemVisual(t,"symbolRotate"),fromSymbolSize:h.getItemVisual(t,"symbolSize"),fromSymbol:h.getItemVisual(t,"symbol"),toSymbolKeepAspect:c.getItemVisual(t,"symbolKeepAspect"),toSymbolOffset:c.getItemVisual(t,"symbolOffset"),toSymbolRotate:c.getItemVisual(t,"symbolRotate"),toSymbolSize:c.getItemVisual(t,"symbolSize"),toSymbol:c.getItemVisual(t,"symbol"),style:e})})),l.updateData(p),u.line.eachItemGraphicEl((function(t){Qs(t).dataModel=e,t.traverse((function(t){Qs(t).dataModel=e}))})),this.markKeep(l),l.group.silent=e.get("silent")||t.get("silent")},e.type="markLine",e}(fB);var IB=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.prototype.createMarkerModelFromSeries=function(t,n,i){return new e(t,n,i)},e.type="markArea",e.defaultOption={z:1,tooltip:{trigger:"item"},animation:!1,label:{show:!0,position:"top"},itemStyle:{borderWidth:0},emphasis:{label:{show:!0,position:"top"}}},e}(iB),TB=Oo(),CB=function(t,e,n,i){var r=i[0],o=i[1];if(r&&o){var a=lB(t,r),s=lB(t,o),l=a.coord,u=s.coord;l[0]=it(l[0],-1/0),l[1]=it(l[1],-1/0),u[0]=it(u[0],1/0),u[1]=it(u[1],1/0);var h=D([{},a,s]);return h.coord=[a.coord,s.coord],h.x0=a.x,h.y0=a.y,h.x1=s.x,h.y1=s.y,h}};function DB(t){return!isNaN(t)&&!isFinite(t)}function AB(t,e,n,i){var r=1-t;return DB(e[r])&&DB(n[r])}function kB(t,e){var n=e.coord[0],i=e.coord[1],r={coord:n,x:e.x0,y:e.y0},o={coord:i,x:e.x1,y:e.y1};return MS(t,"cartesian2d")?!(!n||!i||!AB(1,n,i)&&!AB(0,n,i))||function(t,e,n){return!(t&&t.containZone&&e.coord&&n.coord&&!oB(e)&&!oB(n))||t.containZone(e.coord,n.coord)}(t,r,o):hB(t,r)||hB(t,o)}function LB(t,e,n,i,r){var o,a=i.coordinateSystem,s=t.getItemModel(e),l=Ur(s.get(n[0]),r.getWidth()),u=Ur(s.get(n[1]),r.getHeight());if(isNaN(l)||isNaN(u)){if(i.getMarkerPosition){var h=t.getValues(["x0","y0"],e),c=t.getValues(["x1","y1"],e),p=a.clampData(h),d=a.clampData(c),f=[];"x0"===n[0]?f[0]=p[0]>d[0]?c[0]:h[0]:f[0]=p[0]>d[0]?h[0]:c[0],"y0"===n[1]?f[1]=p[1]>d[1]?c[1]:h[1]:f[1]=p[1]>d[1]?h[1]:c[1],o=i.getMarkerPosition(f,n,!0)}else{var g=[m=t.get(n[0],e),x=t.get(n[1],e)];a.clampData&&a.clampData(g,g),o=a.dataToPoint(g,!0)}if(MS(a,"cartesian2d")){var y=a.getAxis("x"),v=a.getAxis("y"),m=t.get(n[0],e),x=t.get(n[1],e);DB(m)?o[0]=y.toGlobalCoord(y.getExtent()["x0"===n[0]?0:1]):DB(x)&&(o[1]=v.toGlobalCoord(v.getExtent()["y0"===n[1]?0:1]))}isNaN(l)||(o[0]=l),isNaN(u)||(o[1]=u)}else o=[l,u];return o}var PB=[["x0","y0"],["x1","y0"],["x1","y1"],["x0","y1"]],OB=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.prototype.updateTransform=function(t,e,n){e.eachSeries((function(t){var e=iB.getMarkerModelFromSeries(t,"markArea");if(e){var i=e.getData();i.each((function(e){var r=z(PB,(function(r){return LB(i,e,r,t,n)}));i.setItemLayout(e,r),i.getItemGraphicEl(e).setShape("points",r)}))}}),this)},e.prototype.renderSeries=function(t,e,n,i){var r=t.coordinateSystem,o=t.id,a=t.getData(),s=this.markerGroupMap,l=s.get(o)||s.set(o,{group:new zr});this.group.add(l.group),this.markKeep(l);var u=function(t,e,n){var i,r,o=["x0","y0","x1","y1"];if(t){var a=z(t&&t.dimensions,(function(t){var n=e.getData();return A(A({},n.getDimensionInfo(n.mapDimension(t))||{}),{name:t,ordinalMeta:null})}));r=z(o,(function(t,e){return{name:t,type:a[e%2].type}})),i=new lx(r,n)}else i=new lx(r=[{name:"value",type:"float"}],n);var s=z(n.get("data"),H(CB,e,t,n));t&&(s=B(s,H(kB,t)));var l=t?function(t,e,n,i){return wf(t.coord[Math.floor(i/2)][i%2],r[i])}:function(t,e,n,i){return wf(t.value,r[i])};return i.initData(s,null,l),i.hasItemOption=!0,i}(r,t,e);e.setData(u),u.each((function(e){var n=z(PB,(function(n){return LB(u,e,n,t,i)})),o=r.getAxis("x").scale,s=r.getAxis("y").scale,l=o.getExtent(),h=s.getExtent(),c=[o.parse(u.get("x0",e)),o.parse(u.get("x1",e))],p=[s.parse(u.get("y0",e)),s.parse(u.get("y1",e))];jr(c),jr(p);var d=!!(l[0]>c[1]||l[1]p[1]||h[1]=0},e.prototype.getOrient=function(){return"vertical"===this.get("orient")?{index:1,name:"vertical"}:{index:0,name:"horizontal"}},e.type="legend.plain",e.dependencies=["series"],e.defaultOption={z:4,show:!0,orient:"horizontal",left:"center",top:0,align:"auto",backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderRadius:0,borderWidth:0,padding:5,itemGap:10,itemWidth:25,itemHeight:14,symbolRotate:"inherit",symbolKeepAspect:!0,inactiveColor:"#ccc",inactiveBorderColor:"#ccc",inactiveBorderWidth:"auto",itemStyle:{color:"inherit",opacity:"inherit",borderColor:"inherit",borderWidth:"auto",borderCap:"inherit",borderJoin:"inherit",borderDashOffset:"inherit",borderMiterLimit:"inherit"},lineStyle:{width:"auto",color:"inherit",inactiveColor:"#ccc",inactiveWidth:2,opacity:"inherit",type:"inherit",cap:"inherit",join:"inherit",dashOffset:"inherit",miterLimit:"inherit"},textStyle:{color:"#333"},selectedMode:!0,selector:!1,selectorLabel:{show:!0,borderRadius:10,padding:[3,5,3,5],fontSize:12,fontFamily:"sans-serif",color:"#666",borderWidth:1,borderColor:"#666"},emphasis:{selectorLabel:{show:!0,color:"#eee",backgroundColor:"#666"}},selectorPosition:"auto",selectorItemGap:7,selectorButtonGap:10,tooltip:{show:!1}},e}(Rp),NB=H,EB=E,zB=zr,VB=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.newlineDisabled=!1,n}return n(e,t),e.prototype.init=function(){this.group.add(this._contentGroup=new zB),this.group.add(this._selectorGroup=new zB),this._isFirstRender=!0},e.prototype.getContentGroup=function(){return this._contentGroup},e.prototype.getSelectorGroup=function(){return this._selectorGroup},e.prototype.render=function(t,e,n){var i=this._isFirstRender;if(this._isFirstRender=!1,this.resetInner(),t.get("show",!0)){var r=t.get("align"),o=t.get("orient");r&&"auto"!==r||(r="right"===t.get("left")&&"vertical"===o?"right":"left");var a=t.get("selector",!0),s=t.get("selectorPosition",!0);!a||s&&"auto"!==s||(s="horizontal"===o?"end":"start"),this.renderInner(r,t,e,n,a,o,s);var l=t.getBoxLayoutParams(),u={width:n.getWidth(),height:n.getHeight()},h=t.get("padding"),c=Cp(l,u,h),p=this.layoutInner(t,r,c,i,a,s),d=Cp(k({width:p.width,height:p.height},l),u,h);this.group.x=d.x-p.x,this.group.y=d.y-p.y,this.group.markRedraw(),this.group.add(this._backgroundEl=dz(p,t))}},e.prototype.resetInner=function(){this.getContentGroup().removeAll(),this._backgroundEl&&this.group.remove(this._backgroundEl),this.getSelectorGroup().removeAll()},e.prototype.renderInner=function(t,e,n,i,r,o,a){var s=this.getContentGroup(),l=yt(),u=e.get("selectedMode"),h=[];n.eachRawSeries((function(t){!t.get("legendHoverLink")&&h.push(t.id)})),EB(e.getData(),(function(r,o){var a=r.get("name");if(!this.newlineDisabled&&(""===a||"\n"===a)){var c=new zB;return c.newline=!0,void s.add(c)}var p=n.getSeriesByName(a)[0];if(!l.get(a)){if(p){var d=p.getData(),f=d.getVisual("legendLineStyle")||{},g=d.getVisual("legendIcon"),y=d.getVisual("style");this._createItem(p,a,o,r,e,t,f,y,g,u,i).on("click",NB(BB,a,null,i,h)).on("mouseover",NB(GB,p.name,null,i,h)).on("mouseout",NB(WB,p.name,null,i,h)),l.set(a,!0)}else n.eachRawSeries((function(n){if(!l.get(a)&&n.legendVisualProvider){var s=n.legendVisualProvider;if(!s.containName(a))return;var c=s.indexOfName(a),p=s.getItemVisual(c,"style"),d=s.getItemVisual(c,"legendIcon"),f=qn(p.fill);f&&0===f[3]&&(f[3]=.2,p=A(A({},p),{fill:ri(f,"rgba")})),this._createItem(n,a,o,r,e,t,{},p,d,u,i).on("click",NB(BB,null,a,i,h)).on("mouseover",NB(GB,null,a,i,h)).on("mouseout",NB(WB,null,a,i,h)),l.set(a,!0)}}),this);0}}),this),r&&this._createSelector(r,e,i,o,a)},e.prototype._createSelector=function(t,e,n,i,r){var o=this.getSelectorGroup();EB(t,(function(t){var i=t.type,r=new Fs({style:{x:0,y:0,align:"center",verticalAlign:"middle"},onclick:function(){n.dispatchAction({type:"all"===i?"legendAllSelect":"legendInverseSelect"})}});o.add(r),tc(r,{normal:e.getModel("selectorLabel"),emphasis:e.getModel(["emphasis","selectorLabel"])},{defaultText:t.title}),Hl(r)}))},e.prototype._createItem=function(t,e,n,i,r,o,a,s,l,u,h){var c=t.visualDrawType,p=r.get("itemWidth"),d=r.get("itemHeight"),f=r.isSelected(e),g=i.get("symbolRotate"),y=i.get("symbolKeepAspect"),v=i.get("icon"),m=function(t,e,n,i,r,o,a){function s(t,e){"auto"===t.lineWidth&&(t.lineWidth=e.lineWidth>0?2:0),EB(t,(function(n,i){"inherit"===t[i]&&(t[i]=e[i])}))}var l=e.getModel("itemStyle"),u=l.getItemStyle(),h=0===t.lastIndexOf("empty",0)?"fill":"stroke",c=l.getShallow("decal");u.decal=c&&"inherit"!==c?gv(c,a):i.decal,"inherit"===u.fill&&(u.fill=i[r]);"inherit"===u.stroke&&(u.stroke=i[h]);"inherit"===u.opacity&&(u.opacity=("fill"===r?i:n).opacity);s(u,i);var p=e.getModel("lineStyle"),d=p.getLineStyle();if(s(d,n),"auto"===u.fill&&(u.fill=i.fill),"auto"===u.stroke&&(u.stroke=i.fill),"auto"===d.stroke&&(d.stroke=i.fill),!o){var f=e.get("inactiveBorderWidth"),g=u[h];u.lineWidth="auto"===f?i.lineWidth>0&&g?2:0:u.lineWidth,u.fill=e.get("inactiveColor"),u.stroke=e.get("inactiveBorderColor"),d.stroke=p.get("inactiveColor"),d.lineWidth=p.get("inactiveWidth")}return{itemStyle:u,lineStyle:d}}(l=v||l||"roundRect",i,a,s,c,f,h),x=new zB,_=i.getModel("textStyle");if(!X(t.getLegendIcon)||v&&"inherit"!==v){var b="inherit"===v&&t.getData().getVisual("symbol")?"inherit"===g?t.getData().getVisual("symbolRotate"):g:0;x.add(function(t){var e=t.icon||"roundRect",n=Wy(e,0,0,t.itemWidth,t.itemHeight,t.itemStyle.fill,t.symbolKeepAspect);n.setStyle(t.itemStyle),n.rotation=(t.iconRotate||0)*Math.PI/180,n.setOrigin([t.itemWidth/2,t.itemHeight/2]),e.indexOf("empty")>-1&&(n.style.stroke=n.style.fill,n.style.fill="#fff",n.style.lineWidth=2);return n}({itemWidth:p,itemHeight:d,icon:l,iconRotate:b,itemStyle:m.itemStyle,lineStyle:m.lineStyle,symbolKeepAspect:y}))}else x.add(t.getLegendIcon({itemWidth:p,itemHeight:d,icon:l,iconRotate:g,itemStyle:m.itemStyle,lineStyle:m.lineStyle,symbolKeepAspect:y}));var w="left"===o?p+5:-5,S=o,M=r.get("formatter"),I=e;U(M)&&M?I=M.replace("{name}",null!=e?e:""):X(M)&&(I=M(e));var T=f?_.getTextColor():i.get("inactiveColor");x.add(new Fs({style:nc(_,{text:I,x:w,y:d/2,fill:T,align:S,verticalAlign:"middle"},{inheritColor:T})}));var C=new zs({shape:x.getBoundingRect(),invisible:!0}),D=i.getModel("tooltip");return D.get("show")&&Zh({el:C,componentModel:r,itemName:e,itemTooltipOption:D.option}),x.add(C),x.eachChild((function(t){t.silent=!0})),C.silent=!u,this.getContentGroup().add(x),Hl(x),x.__legendDataIndex=n,x},e.prototype.layoutInner=function(t,e,n,i,r,o){var a=this.getContentGroup(),s=this.getSelectorGroup();Tp(t.get("orient"),a,t.get("itemGap"),n.width,n.height);var l=a.getBoundingRect(),u=[-l.x,-l.y];if(s.markRedraw(),a.markRedraw(),r){Tp("horizontal",s,t.get("selectorItemGap",!0));var h=s.getBoundingRect(),c=[-h.x,-h.y],p=t.get("selectorButtonGap",!0),d=t.getOrient().index,f=0===d?"width":"height",g=0===d?"height":"width",y=0===d?"y":"x";"end"===o?c[d]+=l[f]+p:u[d]+=h[f]+p,c[1-d]+=l[g]/2-h[g]/2,s.x=c[0],s.y=c[1],a.x=u[0],a.y=u[1];var v={x:0,y:0};return v[f]=l[f]+p+h[f],v[g]=Math.max(l[g],h[g]),v[y]=Math.min(0,h[y]+c[1-d]),v}return a.x=u[0],a.y=u[1],this.group.getBoundingRect()},e.prototype.remove=function(){this.getContentGroup().removeAll(),this._isFirstRender=!0},e.type="legend.plain",e}(Tg);function BB(t,e,n,i){WB(t,e,n,i),n.dispatchAction({type:"legendToggleSelect",name:null!=t?t:e}),GB(t,e,n,i)}function FB(t){for(var e,n=t.getZr().storage.getDisplayList(),i=0,r=n.length;in[r],f=[-c.x,-c.y];e||(f[i]=l[s]);var g=[0,0],y=[-p.x,-p.y],v=rt(t.get("pageButtonGap",!0),t.get("itemGap",!0));d&&("end"===t.get("pageButtonPosition",!0)?y[i]+=n[r]-p[r]:g[i]+=p[r]+v);y[1-i]+=c[o]/2-p[o]/2,l.setPosition(f),u.setPosition(g),h.setPosition(y);var m={x:0,y:0};if(m[r]=d?n[r]:c[r],m[o]=Math.max(c[o],p[o]),m[a]=Math.min(0,p[a]+y[1-i]),u.__rectSize=n[r],d){var x={x:0,y:0};x[r]=Math.max(n[r]-p[r]-v,0),x[o]=m[o],u.setClipPath(new zs({shape:x})),u.__rectSize=x[r]}else h.eachChild((function(t){t.attr({invisible:!0,silent:!0})}));var _=this._getPageInfo(t);return null!=_.pageIndex&&fh(l,{x:_.contentPosition[0],y:_.contentPosition[1]},d?t:null),this._updatePageInfoView(t,_),m},e.prototype._pageGo=function(t,e,n){var i=this._getPageInfo(e)[t];null!=i&&n.dispatchAction({type:"legendScroll",scrollDataIndex:i,legendId:e.id})},e.prototype._updatePageInfoView=function(t,e){var n=this._controllerGroup;E(["pagePrev","pageNext"],(function(i){var r=null!=e[i+"DataIndex"],o=n.childOfName(i);o&&(o.setStyle("fill",r?t.get("pageIconColor",!0):t.get("pageIconInactiveColor",!0)),o.cursor=r?"pointer":"default")}));var i=n.childOfName("pageText"),r=t.get("pageFormatter"),o=e.pageIndex,a=null!=o?o+1:0,s=e.pageCount;i&&r&&i.setStyle("text",U(r)?r.replace("{current}",null==a?"":a+"").replace("{total}",null==s?"":s+""):r({current:a,total:s}))},e.prototype._getPageInfo=function(t){var e=t.get("scrollDataIndex",!0),n=this.getContentGroup(),i=this._containerGroup.__rectSize,r=t.getOrient().index,o=qB[r],a=KB[r],s=this._findTargetItemIndex(e),l=n.children(),u=l[s],h=l.length,c=h?1:0,p={contentPosition:[n.x,n.y],pageCount:c,pageIndex:c-1,pagePrevDataIndex:null,pageNextDataIndex:null};if(!u)return p;var d=m(u);p.contentPosition[r]=-d.s;for(var f=s+1,g=d,y=d,v=null;f<=h;++f)(!(v=m(l[f]))&&y.e>g.s+i||v&&!x(v,g.s))&&(g=y.i>g.i?y:v)&&(null==p.pageNextDataIndex&&(p.pageNextDataIndex=g.i),++p.pageCount),y=v;for(f=s-1,g=d,y=d,v=null;f>=-1;--f)(v=m(l[f]))&&x(y,v.s)||!(g.i=e&&t.s<=e+i}},e.prototype._findTargetItemIndex=function(t){return this._showController?(this.getContentGroup().eachChild((function(i,r){var o=i.__legendDataIndex;null==n&&null!=o&&(n=r),o===t&&(e=r)})),null!=e?e:n):0;var e,n},e.type="legend.scroll",e}(VB);function JB(t){Nm(XB),t.registerComponentModel(UB),t.registerComponentView($B),function(t){t.registerAction("legendScroll","legendscroll",(function(t,e){var n=t.scrollDataIndex;null!=n&&e.eachComponent({mainType:"legend",subType:"scroll",query:t},(function(t){t.setScrollDataIndex(n)}))}))}(t)}var QB=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.type="dataZoom.inside",e.defaultOption=Cc(KE.defaultOption,{disabled:!1,zoomLock:!1,zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}),e}(KE),tF=Oo();function eF(t,e,n){tF(t).coordSysRecordMap.each((function(t){var i=t.dataZoomInfoMap.get(e.uid);i&&(i.getRange=n)}))}function nF(t,e){if(e){t.removeKey(e.model.uid);var n=e.controller;n&&n.dispose()}}function iF(t,e){t.isDisposed()||t.dispatchAction({type:"dataZoom",animation:{easing:"cubicOut",duration:100},batch:e})}function rF(t,e,n,i){return t.coordinateSystem.containPoint([n,i])}function oF(t){t.registerProcessor(t.PRIORITY.PROCESSOR.FILTER,(function(t,e){var n=tF(e),i=n.coordSysRecordMap||(n.coordSysRecordMap=yt());i.each((function(t){t.dataZoomInfoMap=null})),t.eachComponent({mainType:"dataZoom",subType:"inside"},(function(t){E(jE(t).infoList,(function(n){var r=n.model.uid,o=i.get(r)||i.set(r,function(t,e){var n={model:e,containsPoint:H(rF,e),dispatchAction:H(iF,t),dataZoomInfoMap:null,controller:null},i=n.controller=new UI(t.getZr());return E(["pan","zoom","scrollMove"],(function(t){i.on(t,(function(e){var i=[];n.dataZoomInfoMap.each((function(r){if(e.isAvailableBehavior(r.model.option)){var o=(r.getRange||{})[t],a=o&&o(r.dzReferCoordSysInfo,n.model.mainType,n.controller,e);!r.model.get("disabled",!0)&&a&&i.push({dataZoomId:r.model.id,start:a[0],end:a[1]})}})),i.length&&n.dispatchAction(i)}))})),n}(e,n.model));(o.dataZoomInfoMap||(o.dataZoomInfoMap=yt())).set(t.uid,{dzReferCoordSysInfo:n,model:t,getRange:null})}))})),i.each((function(t){var e,n=t.controller,r=t.dataZoomInfoMap;if(r){var o=r.keys()[0];null!=o&&(e=r.get(o))}if(e){var a=function(t){var e,n="type_",i={type_true:2,type_move:1,type_false:0,type_undefined:-1},r=!0;return t.each((function(t){var o=t.model,a=!o.get("disabled",!0)&&(!o.get("zoomLock",!0)||"move");i[n+a]>i[n+e]&&(e=a),r=r&&o.get("preventDefaultMouseMove",!0)})),{controlType:e,opt:{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!0,preventDefaultMouseMove:!!r}}}(r);n.enable(a.controlType,a.opt),n.setPointerChecker(t.containsPoint),Fg(t,"dispatchAction",e.model.get("throttle",!0),"fixRate")}else nF(i,t)}))}))}var aF=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="dataZoom.inside",e}return n(e,t),e.prototype.render=function(e,n,i){t.prototype.render.apply(this,arguments),e.noTarget()?this._clear():(this.range=e.getPercentRange(),eF(i,e,{pan:W(sF.pan,this),zoom:W(sF.zoom,this),scrollMove:W(sF.scrollMove,this)}))},e.prototype.dispose=function(){this._clear(),t.prototype.dispose.apply(this,arguments)},e.prototype._clear=function(){!function(t,e){for(var n=tF(t).coordSysRecordMap,i=n.keys(),r=0;r0?s.pixelStart+s.pixelLength-s.pixel:s.pixel-s.pixelStart)/s.pixelLength*(o[1]-o[0])+o[0],u=Math.max(1/i.scale,0);o[0]=(o[0]-l)*u+l,o[1]=(o[1]-l)*u+l;var h=this.dataZoomModel.findRepresentativeAxisProxy().getMinMaxSpan();return Ck(0,o,[0,100],0,h.minSpan,h.maxSpan),this.range=o,r[0]!==o[0]||r[1]!==o[1]?o:void 0}},pan:lF((function(t,e,n,i,r,o){var a=uF[i]([o.oldX,o.oldY],[o.newX,o.newY],e,r,n);return a.signal*(t[1]-t[0])*a.pixel/a.pixelLength})),scrollMove:lF((function(t,e,n,i,r,o){return uF[i]([0,0],[o.scrollDelta,o.scrollDelta],e,r,n).signal*(t[1]-t[0])*o.scrollDelta}))};function lF(t){return function(e,n,i,r){var o=this.range,a=o.slice(),s=e.axisModels[0];if(s)return Ck(t(a,s,e,n,i,r),a,[0,100],"all"),this.range=a,o[0]!==a[0]||o[1]!==a[1]?a:void 0}}var uF={grid:function(t,e,n,i,r){var o=n.axis,a={},s=r.model.coordinateSystem.getRect();return t=t||[0,0],"x"===o.dim?(a.pixel=e[0]-t[0],a.pixelLength=s.width,a.pixelStart=s.x,a.signal=o.inverse?1:-1):(a.pixel=e[1]-t[1],a.pixelLength=s.height,a.pixelStart=s.y,a.signal=o.inverse?-1:1),a},polar:function(t,e,n,i,r){var o=n.axis,a={},s=r.model.coordinateSystem,l=s.getRadiusAxis().getExtent(),u=s.getAngleAxis().getExtent();return t=t?s.pointToCoord(t):[0,0],e=s.pointToCoord(e),"radiusAxis"===n.mainType?(a.pixel=e[0]-t[0],a.pixelLength=l[1]-l[0],a.pixelStart=l[0],a.signal=o.inverse?1:-1):(a.pixel=e[1]-t[1],a.pixelLength=u[1]-u[0],a.pixelStart=u[0],a.signal=o.inverse?-1:1),a},singleAxis:function(t,e,n,i,r){var o=n.axis,a=r.model.coordinateSystem.getRect(),s={};return t=t||[0,0],"horizontal"===o.orient?(s.pixel=e[0]-t[0],s.pixelLength=a.width,s.pixelStart=a.x,s.signal=o.inverse?1:-1):(s.pixel=e[1]-t[1],s.pixelLength=a.height,s.pixelStart=a.y,s.signal=o.inverse?-1:1),s}};function hF(t){az(t),t.registerComponentModel(QB),t.registerComponentView(aF),oF(t)}var cF=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.type="dataZoom.slider",e.layoutMode="box",e.defaultOption=Cc(KE.defaultOption,{show:!0,right:"ph",top:"ph",width:"ph",height:"ph",left:null,bottom:null,borderColor:"#d2dbee",borderRadius:3,backgroundColor:"rgba(47,69,84,0)",dataBackground:{lineStyle:{color:"#d2dbee",width:.5},areaStyle:{color:"#d2dbee",opacity:.2}},selectedDataBackground:{lineStyle:{color:"#8fb0f7",width:.5},areaStyle:{color:"#8fb0f7",opacity:.2}},fillerColor:"rgba(135,175,274,0.2)",handleIcon:"path://M-9.35,34.56V42m0-40V9.5m-2,0h4a2,2,0,0,1,2,2v21a2,2,0,0,1-2,2h-4a2,2,0,0,1-2-2v-21A2,2,0,0,1-11.35,9.5Z",handleSize:"100%",handleStyle:{color:"#fff",borderColor:"#ACB8D1"},moveHandleSize:7,moveHandleIcon:"path://M-320.9-50L-320.9-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-348-41-339-50-320.9-50z M-212.3-50L-212.3-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-239.4-41-230.4-50-212.3-50z M-103.7-50L-103.7-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-130.9-41-121.8-50-103.7-50z",moveHandleStyle:{color:"#D2DBEE",opacity:.7},showDetail:!0,showDataShadow:"auto",realtime:!0,zoomLock:!1,textStyle:{color:"#6E7079"},brushSelect:!0,brushStyle:{color:"rgba(135,175,274,0.15)"},emphasis:{handleStyle:{borderColor:"#8FB0F7"},moveHandleStyle:{color:"#8FB0F7"}}}),e}(KE),pF=zs,dF="horizontal",fF="vertical",gF=["line","bar","candlestick","scatter"],yF={easing:"cubicOut",duration:100,delay:0},vF=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n._displayables={},n}return n(e,t),e.prototype.init=function(t,e){this.api=e,this._onBrush=W(this._onBrush,this),this._onBrushEnd=W(this._onBrushEnd,this)},e.prototype.render=function(e,n,i,r){if(t.prototype.render.apply(this,arguments),Fg(this,"_dispatchZoomAction",e.get("throttle"),"fixRate"),this._orient=e.getOrient(),!1!==e.get("show")){if(e.noTarget())return this._clear(),void this.group.removeAll();r&&"dataZoom"===r.type&&r.from===this.uid||this._buildView(),this._updateView()}else this.group.removeAll()},e.prototype.dispose=function(){this._clear(),t.prototype.dispose.apply(this,arguments)},e.prototype._clear=function(){Gg(this,"_dispatchZoomAction");var t=this.api.getZr();t.off("mousemove",this._onBrush),t.off("mouseup",this._onBrushEnd)},e.prototype._buildView=function(){var t=this.group;t.removeAll(),this._brushing=!1,this._displayables.brushRect=null,this._resetLocation(),this._resetInterval();var e=this._displayables.sliderGroup=new zr;this._renderBackground(),this._renderHandle(),this._renderDataShadow(),t.add(e),this._positionGroup()},e.prototype._resetLocation=function(){var t=this.dataZoomModel,e=this.api,n=t.get("brushSelect")?7:0,i=this._findCoordRect(),r={width:e.getWidth(),height:e.getHeight()},o=this._orient===dF?{right:r.width-i.x-i.width,top:r.height-30-7-n,width:i.width,height:30}:{right:7,top:i.y,width:30,height:i.height},a=Lp(t.option);E(["right","top","width","height"],(function(t){"ph"===a[t]&&(a[t]=o[t])}));var s=Cp(a,r);this._location={x:s.x,y:s.y},this._size=[s.width,s.height],this._orient===fF&&this._size.reverse()},e.prototype._positionGroup=function(){var t=this.group,e=this._location,n=this._orient,i=this.dataZoomModel.getFirstTargetAxisModel(),r=i&&i.get("inverse"),o=this._displayables.sliderGroup,a=(this._dataShadowInfo||{}).otherAxisInverse;o.attr(n!==dF||r?n===dF&&r?{scaleY:a?1:-1,scaleX:-1}:n!==fF||r?{scaleY:a?-1:1,scaleX:-1,rotation:Math.PI/2}:{scaleY:a?-1:1,scaleX:1,rotation:Math.PI/2}:{scaleY:a?1:-1,scaleX:1});var s=t.getBoundingRect([o]);t.x=e.x-s.x,t.y=e.y-s.y,t.markRedraw()},e.prototype._getViewExtent=function(){return[0,this._size[0]]},e.prototype._renderBackground=function(){var t=this.dataZoomModel,e=this._size,n=this._displayables.sliderGroup,i=t.get("brushSelect");n.add(new pF({silent:!0,shape:{x:0,y:0,width:e[0],height:e[1]},style:{fill:t.get("backgroundColor")},z2:-40}));var r=new pF({shape:{x:0,y:0,width:e[0],height:e[1]},style:{fill:"transparent"},z2:0,onclick:W(this._onClickPanel,this)}),o=this.api.getZr();i?(r.on("mousedown",this._onBrushStart,this),r.cursor="crosshair",o.on("mousemove",this._onBrush),o.on("mouseup",this._onBrushEnd)):(o.off("mousemove",this._onBrush),o.off("mouseup",this._onBrushEnd)),n.add(r)},e.prototype._renderDataShadow=function(){var t=this._dataShadowInfo=this._prepareDataShadowInfo();if(this._displayables.dataShadowSegs=[],t){var e=this._size,n=this._shadowSize||[],i=t.series,r=i.getRawData(),o=i.getShadowDim&&i.getShadowDim(),a=o&&r.getDimensionInfo(o)?i.getShadowDim():t.otherDim;if(null!=a){var s=this._shadowPolygonPts,l=this._shadowPolylinePts;if(r!==this._shadowData||a!==this._shadowDim||e[0]!==n[0]||e[1]!==n[1]){var u=r.getDataExtent(a),h=.3*(u[1]-u[0]);u=[u[0]-h,u[1]+h];var c,p=[0,e[1]],d=[0,e[0]],f=[[e[0],0],[0,0]],g=[],y=d[1]/(r.count()-1),v=0,m=Math.round(r.count()/e[0]);r.each([a],(function(t,e){if(m>0&&e%m)v+=y;else{var n=null==t||isNaN(t)||""===t,i=n?0:Xr(t,u,p,!0);n&&!c&&e?(f.push([f[f.length-1][0],0]),g.push([g[g.length-1][0],0])):!n&&c&&(f.push([v,0]),g.push([v,0])),f.push([v,i]),g.push([v,i]),v+=y,c=n}})),s=this._shadowPolygonPts=f,l=this._shadowPolylinePts=g}this._shadowData=r,this._shadowDim=a,this._shadowSize=[e[0],e[1]];for(var x=this.dataZoomModel,_=0;_<3;_++){var b=w(1===_);this._displayables.sliderGroup.add(b),this._displayables.dataShadowSegs.push(b)}}}function w(t){var e=x.getModel(t?"selectedDataBackground":"dataBackground"),n=new zr,i=new Wu({shape:{points:s},segmentIgnoreThreshold:1,style:e.getModel("areaStyle").getAreaStyle(),silent:!0,z2:-20}),r=new Yu({shape:{points:l},segmentIgnoreThreshold:1,style:e.getModel("lineStyle").getLineStyle(),silent:!0,z2:-19});return n.add(i),n.add(r),n}},e.prototype._prepareDataShadowInfo=function(){var t=this.dataZoomModel,e=t.get("showDataShadow");if(!1!==e){var n,i=this.ecModel;return t.eachTargetAxis((function(r,o){E(t.getAxisProxy(r,o).getTargetSeriesModels(),(function(t){if(!(n||!0!==e&&P(gF,t.get("type"))<0)){var a,s=i.getComponent(UE(r),o).axis,l=function(t){var e={x:"y",y:"x",radius:"angle",angle:"radius"};return e[t]}(r),u=t.coordinateSystem;null!=l&&u.getOtherAxis&&(a=u.getOtherAxis(s).inverse),l=t.getData().mapDimension(l),n={thisAxis:s,series:t,thisDim:r,otherDim:l,otherAxisInverse:a}}}),this)}),this),n}},e.prototype._renderHandle=function(){var t=this.group,e=this._displayables,n=e.handles=[null,null],i=e.handleLabels=[null,null],r=this._displayables.sliderGroup,o=this._size,a=this.dataZoomModel,s=this.api,l=a.get("borderRadius")||0,u=a.get("brushSelect"),h=e.filler=new pF({silent:u,style:{fill:a.get("fillerColor")},textConfig:{position:"inside"}});r.add(h),r.add(new pF({silent:!0,subPixelOptimize:!0,shape:{x:0,y:0,width:o[0],height:o[1],r:l},style:{stroke:a.get("dataBackgroundColor")||a.get("borderColor"),lineWidth:1,fill:"rgba(0,0,0,0)"}})),E([0,1],(function(e){var o=a.get("handleIcon");!By[o]&&o.indexOf("path://")<0&&o.indexOf("image://")<0&&(o="path://"+o);var s=Wy(o,-1,0,2,2,null,!0);s.attr({cursor:mF(this._orient),draggable:!0,drift:W(this._onDragMove,this,e),ondragend:W(this._onDragEnd,this),onmouseover:W(this._showDataInfo,this,!0),onmouseout:W(this._showDataInfo,this,!1),z2:5});var l=s.getBoundingRect(),u=a.get("handleSize");this._handleHeight=Ur(u,this._size[1]),this._handleWidth=l.width/l.height*this._handleHeight,s.setStyle(a.getModel("handleStyle").getItemStyle()),s.style.strokeNoScale=!0,s.rectHover=!0,s.ensureState("emphasis").style=a.getModel(["emphasis","handleStyle"]).getItemStyle(),Hl(s);var h=a.get("handleColor");null!=h&&(s.style.fill=h),r.add(n[e]=s);var c=a.getModel("textStyle");t.add(i[e]=new Fs({silent:!0,invisible:!0,style:nc(c,{x:0,y:0,text:"",verticalAlign:"middle",align:"center",fill:c.getTextColor(),font:c.getFont()}),z2:10}))}),this);var c=h;if(u){var p=Ur(a.get("moveHandleSize"),o[1]),d=e.moveHandle=new zs({style:a.getModel("moveHandleStyle").getItemStyle(),silent:!0,shape:{r:[0,0,2,2],y:o[1]-.5,height:p}}),f=.8*p,g=e.moveHandleIcon=Wy(a.get("moveHandleIcon"),-f/2,-f/2,f,f,"#fff",!0);g.silent=!0,g.y=o[1]+p/2-.5,d.ensureState("emphasis").style=a.getModel(["emphasis","moveHandleStyle"]).getItemStyle();var y=Math.min(o[1]/2,Math.max(p,10));(c=e.moveZone=new zs({invisible:!0,shape:{y:o[1]-y,height:p+y}})).on("mouseover",(function(){s.enterEmphasis(d)})).on("mouseout",(function(){s.leaveEmphasis(d)})),r.add(d),r.add(g),r.add(c)}c.attr({draggable:!0,cursor:mF(this._orient),drift:W(this._onDragMove,this,"all"),ondragstart:W(this._showDataInfo,this,!0),ondragend:W(this._onDragEnd,this),onmouseover:W(this._showDataInfo,this,!0),onmouseout:W(this._showDataInfo,this,!1)})},e.prototype._resetInterval=function(){var t=this._range=this.dataZoomModel.getPercentRange(),e=this._getViewExtent();this._handleEnds=[Xr(t[0],[0,100],e,!0),Xr(t[1],[0,100],e,!0)]},e.prototype._updateInterval=function(t,e){var n=this.dataZoomModel,i=this._handleEnds,r=this._getViewExtent(),o=n.findRepresentativeAxisProxy().getMinMaxSpan(),a=[0,100];Ck(e,i,r,n.get("zoomLock")?"all":t,null!=o.minSpan?Xr(o.minSpan,a,r,!0):null,null!=o.maxSpan?Xr(o.maxSpan,a,r,!0):null);var s=this._range,l=this._range=jr([Xr(i[0],r,a,!0),Xr(i[1],r,a,!0)]);return!s||s[0]!==l[0]||s[1]!==l[1]},e.prototype._updateView=function(t){var e=this._displayables,n=this._handleEnds,i=jr(n.slice()),r=this._size;E([0,1],(function(t){var i=e.handles[t],o=this._handleHeight;i.attr({scaleX:o/2,scaleY:o/2,x:n[t]+(t?-1:1),y:r[1]/2-o/2})}),this),e.filler.setShape({x:i[0],y:0,width:i[1]-i[0],height:r[1]});var o={x:i[0],width:i[1]-i[0]};e.moveHandle&&(e.moveHandle.setShape(o),e.moveZone.setShape(o),e.moveZone.getBoundingRect(),e.moveHandleIcon&&e.moveHandleIcon.attr("x",o.x+o.width/2));for(var a=e.dataShadowSegs,s=[0,i[0],i[1],r[0]],l=0;le[0]||n[1]<0||n[1]>e[1])){var i=this._handleEnds,r=(i[0]+i[1])/2,o=this._updateInterval("all",n[0]-r);this._updateView(),o&&this._dispatchZoomAction(!1)}},e.prototype._onBrushStart=function(t){var e=t.offsetX,n=t.offsetY;this._brushStart=new De(e,n),this._brushing=!0,this._brushStartTime=+new Date},e.prototype._onBrushEnd=function(t){if(this._brushing){var e=this._displayables.brushRect;if(this._brushing=!1,e){e.attr("ignore",!0);var n=e.shape;if(!(+new Date-this._brushStartTime<200&&Math.abs(n.width)<5)){var i=this._getViewExtent(),r=[0,100];this._range=jr([Xr(n.x,i,r,!0),Xr(n.x+n.width,i,r,!0)]),this._handleEnds=[n.x,n.x+n.width],this._updateView(),this._dispatchZoomAction(!1)}}}},e.prototype._onBrush=function(t){this._brushing&&(de(t.event),this._updateBrushRect(t.offsetX,t.offsetY))},e.prototype._updateBrushRect=function(t,e){var n=this._displayables,i=this.dataZoomModel,r=n.brushRect;r||(r=n.brushRect=new pF({silent:!0,style:i.getModel("brushStyle").getItemStyle()}),n.sliderGroup.add(r)),r.attr("ignore",!1);var o=this._brushStart,a=this._displayables.sliderGroup,s=a.transformCoordToLocal(t,e),l=a.transformCoordToLocal(o.x,o.y),u=this._size;s[0]=Math.max(Math.min(u[0],s[0]),0),r.setShape({x:l[0],y:0,width:s[0]-l[0],height:u[1]})},e.prototype._dispatchZoomAction=function(t){var e=this._range;this.api.dispatchAction({type:"dataZoom",from:this.uid,dataZoomId:this.dataZoomModel.id,animation:t?yF:null,start:e[0],end:e[1]})},e.prototype._findCoordRect=function(){var t,e=jE(this.dataZoomModel).infoList;if(!t&&e.length){var n=e[0].model.coordinateSystem;t=n.getRect&&n.getRect()}if(!t){var i=this.api.getWidth(),r=this.api.getHeight();t={x:.2*i,y:.2*r,width:.6*i,height:.6*r}}return t},e.type="dataZoom.slider",e}(QE);function mF(t){return"vertical"===t?"ns-resize":"ew-resize"}function xF(t){t.registerComponentModel(cF),t.registerComponentView(vF),az(t)}var _F=function(t,e,n){var i=T((bF[t]||{})[e]);return n&&Y(i)?i[i.length-1]:i},bF={color:{active:["#006edd","#e0ffff"],inactive:["rgba(0,0,0,0)"]},colorHue:{active:[0,360],inactive:[0,0]},colorSaturation:{active:[.3,1],inactive:[0,0]},colorLightness:{active:[.9,.5],inactive:[0,0]},colorAlpha:{active:[.3,1],inactive:[0,0]},opacity:{active:[.3,1],inactive:[0,0]},symbol:{active:["circle","roundRect","diamond"],inactive:["none"]},symbolSize:{active:[10,50],inactive:[0,0]}},wF=_D.mapVisual,SF=_D.eachVisual,MF=Y,IF=E,TF=jr,CF=Xr,DF=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n.stateList=["inRange","outOfRange"],n.replacableOptionKeys=["inRange","outOfRange","target","controller","color"],n.layoutMode={type:"box",ignoreSize:!0},n.dataBound=[-1/0,1/0],n.targetVisuals={},n.controllerVisuals={},n}return n(e,t),e.prototype.init=function(t,e,n){this.mergeDefaultAndTheme(t,n)},e.prototype.optionUpdated=function(t,e){var n=this.option;!e&&wV(n,t,this.replacableOptionKeys),this.textStyleModel=this.getModel("textStyle"),this.resetItemSize(),this.completeVisualOption()},e.prototype.resetVisual=function(t){var e=this.stateList;t=W(t,this),this.controllerVisuals=bV(this.option.controller,e,t),this.targetVisuals=bV(this.option.target,e,t)},e.prototype.getItemSymbol=function(){return null},e.prototype.getTargetSeriesIndices=function(){var t=this.option.seriesIndex,e=[];return null==t||"all"===t?this.ecModel.eachSeries((function(t,n){e.push(n)})):e=bo(t),e},e.prototype.eachTargetSeries=function(t,e){E(this.getTargetSeriesIndices(),(function(n){var i=this.ecModel.getSeriesByIndex(n);i&&t.call(e,i)}),this)},e.prototype.isTargetSeries=function(t){var e=!1;return this.eachTargetSeries((function(n){n===t&&(e=!0)})),e},e.prototype.formatValueText=function(t,e,n){var i,r=this.option,o=r.precision,a=this.dataBound,s=r.formatter;n=n||["<",">"],Y(t)&&(t=t.slice(),i=!0);var l=e?t:i?[u(t[0]),u(t[1])]:u(t);return U(s)?s.replace("{value}",i?l[0]:l).replace("{value2}",i?l[1]:l):X(s)?i?s(t[0],t[1]):s(t):i?t[0]===a[0]?n[0]+" "+l[1]:t[1]===a[1]?n[1]+" "+l[0]:l[0]+" - "+l[1]:l;function u(t){return t===a[0]?"min":t===a[1]?"max":(+t).toFixed(Math.min(o,20))}},e.prototype.resetExtent=function(){var t=this.option,e=TF([t.min,t.max]);this._dataExtent=e},e.prototype.getDataDimensionIndex=function(t){var e=this.option.dimension;if(null!=e)return t.getDimensionIndex(e);for(var n=t.dimensions,i=n.length-1;i>=0;i--){var r=n[i],o=t.getDimensionInfo(r);if(!o.isCalculationCoord)return o.storeDimIndex}},e.prototype.getExtent=function(){return this._dataExtent.slice()},e.prototype.completeVisualOption=function(){var t=this.ecModel,e=this.option,n={inRange:e.inRange,outOfRange:e.outOfRange},i=e.target||(e.target={}),r=e.controller||(e.controller={});C(i,n),C(r,n);var o=this.isCategory();function a(n){MF(e.color)&&!n.inRange&&(n.inRange={color:e.color.slice().reverse()}),n.inRange=n.inRange||{color:t.get("gradientColor")}}a.call(this,i),a.call(this,r),function(t,e,n){var i=t[e],r=t[n];i&&!r&&(r=t[n]={},IF(i,(function(t,e){if(_D.isValidType(e)){var n=_F(e,"inactive",o);null!=n&&(r[e]=n,"color"!==e||r.hasOwnProperty("opacity")||r.hasOwnProperty("colorAlpha")||(r.opacity=[0,0]))}})))}.call(this,i,"inRange","outOfRange"),function(t){var e=(t.inRange||{}).symbol||(t.outOfRange||{}).symbol,n=(t.inRange||{}).symbolSize||(t.outOfRange||{}).symbolSize,i=this.get("inactiveColor"),r=this.getItemSymbol()||"roundRect";IF(this.stateList,(function(a){var s=this.itemSize,l=t[a];l||(l=t[a]={color:o?i:[i]}),null==l.symbol&&(l.symbol=e&&T(e)||(o?r:[r])),null==l.symbolSize&&(l.symbolSize=n&&T(n)||(o?s[0]:[s[0],s[0]])),l.symbol=wF(l.symbol,(function(t){return"none"===t?r:t}));var u=l.symbolSize;if(null!=u){var h=-1/0;SF(u,(function(t){t>h&&(h=t)})),l.symbolSize=wF(u,(function(t){return CF(t,[0,h],[0,s[0]],!0)}))}}),this)}.call(this,r)},e.prototype.resetItemSize=function(){this.itemSize=[parseFloat(this.get("itemWidth")),parseFloat(this.get("itemHeight"))]},e.prototype.isCategory=function(){return!!this.option.categories},e.prototype.setSelected=function(t){},e.prototype.getSelected=function(){return null},e.prototype.getValueState=function(t){return null},e.prototype.getVisualMeta=function(t){return null},e.type="visualMap",e.dependencies=["series"],e.defaultOption={show:!0,z:4,seriesIndex:"all",min:0,max:200,left:0,right:null,top:null,bottom:0,itemWidth:null,itemHeight:null,inverse:!1,orient:"vertical",backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",contentColor:"#5793f3",inactiveColor:"#aaa",borderWidth:0,padding:5,textGap:10,precision:0,textStyle:{color:"#333"}},e}(Rp),AF=[20,140],kF=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.prototype.optionUpdated=function(e,n){t.prototype.optionUpdated.apply(this,arguments),this.resetExtent(),this.resetVisual((function(t){t.mappingMethod="linear",t.dataExtent=this.getExtent()})),this._resetRange()},e.prototype.resetItemSize=function(){t.prototype.resetItemSize.apply(this,arguments);var e=this.itemSize;(null==e[0]||isNaN(e[0]))&&(e[0]=AF[0]),(null==e[1]||isNaN(e[1]))&&(e[1]=AF[1])},e.prototype._resetRange=function(){var t=this.getExtent(),e=this.option.range;!e||e.auto?(t.auto=1,this.option.range=t):Y(e)&&(e[0]>e[1]&&e.reverse(),e[0]=Math.max(e[0],t[0]),e[1]=Math.min(e[1],t[1]))},e.prototype.completeVisualOption=function(){t.prototype.completeVisualOption.apply(this,arguments),E(this.stateList,(function(t){var e=this.option.controller[t].symbolSize;e&&e[0]!==e[1]&&(e[0]=e[1]/3)}),this)},e.prototype.setSelected=function(t){this.option.range=t.slice(),this._resetRange()},e.prototype.getSelected=function(){var t=this.getExtent(),e=jr((this.get("range")||[]).slice());return e[0]>t[1]&&(e[0]=t[1]),e[1]>t[1]&&(e[1]=t[1]),e[0]=n[1]||t<=e[1])?"inRange":"outOfRange"},e.prototype.findTargetDataIndices=function(t){var e=[];return this.eachTargetSeries((function(n){var i=[],r=n.getData();r.each(this.getDataDimensionIndex(r),(function(e,n){t[0]<=e&&e<=t[1]&&i.push(n)}),this),e.push({seriesId:n.id,dataIndex:i})}),this),e},e.prototype.getVisualMeta=function(t){var e=LF(this,"outOfRange",this.getExtent()),n=LF(this,"inRange",this.option.range.slice()),i=[];function r(e,n){i.push({value:e,color:t(e,n)})}for(var o=0,a=0,s=n.length,l=e.length;at[1])break;n.push({color:this.getControllerVisual(o,"color",e),offset:r/100})}return n.push({color:this.getControllerVisual(t[1],"color",e),offset:1}),n},e.prototype._createBarPoints=function(t,e){var n=this.visualMapModel.itemSize;return[[n[0]-e[0],t[0]],[n[0],t[0]],[n[0],t[1]],[n[0]-e[1],t[1]]]},e.prototype._createBarGroup=function(t){var e=this._orient,n=this.visualMapModel.get("inverse");return new zr("horizontal"!==e||n?"horizontal"===e&&n?{scaleX:"bottom"===t?-1:1,rotation:-Math.PI/2}:"vertical"!==e||n?{scaleX:"left"===t?1:-1}:{scaleX:"left"===t?1:-1,scaleY:-1}:{scaleX:"bottom"===t?1:-1,rotation:Math.PI/2})},e.prototype._updateHandle=function(t,e){if(this._useHandle){var n=this._shapes,i=this.visualMapModel,r=n.handleThumbs,o=n.handleLabels,a=i.itemSize,s=i.getExtent();zF([0,1],(function(l){var u=r[l];u.setStyle("fill",e.handlesColor[l]),u.y=t[l];var h=EF(t[l],[0,a[1]],s,!0),c=this.getControllerVisual(h,"symbolSize");u.scaleX=u.scaleY=c/a[0],u.x=a[0]-c/2;var p=zh(n.handleLabelPoints[l],Eh(u,this.group));o[l].setStyle({x:p[0],y:p[1],text:i.formatValueText(this._dataInterval[l]),verticalAlign:"middle",align:"vertical"===this._orient?this._applyTransform("left",n.mainGroup):"center"})}),this)}},e.prototype._showIndicator=function(t,e,n,i){var r=this.visualMapModel,o=r.getExtent(),a=r.itemSize,s=[0,a[1]],l=this._shapes,u=l.indicator;if(u){u.attr("invisible",!1);var h=this.getControllerVisual(t,"color",{convertOpacityToAlpha:!0}),c=this.getControllerVisual(t,"symbolSize"),p=EF(t,o,s,!0),d=a[0]-c/2,f={x:u.x,y:u.y};u.y=p,u.x=d;var g=zh(l.indicatorLabelPoint,Eh(u,this.group)),y=l.indicatorLabel;y.attr("invisible",!1);var v=this._applyTransform("left",l.mainGroup),m="horizontal"===this._orient;y.setStyle({text:(n||"")+r.formatValueText(e),verticalAlign:m?v:"middle",align:m?"center":v});var x={x:d,y:p,style:{fill:h}},_={style:{x:g[0],y:g[1]}};if(r.ecModel.isAnimationEnabled()&&!this._firstShowIndicator){var b={duration:100,easing:"cubicInOut",additive:!0};u.x=f.x,u.y=f.y,u.animateTo(x,b),y.animateTo(_,b)}else u.attr(x),y.attr(_);this._firstShowIndicator=!1;var w=this._shapes.handleLabels;if(w)for(var S=0;Sr[1]&&(u[1]=1/0),e&&(u[0]===-1/0?this._showIndicator(l,u[1],"< ",a):u[1]===1/0?this._showIndicator(l,u[0],"> ",a):this._showIndicator(l,l,"≈ ",a));var h=this._hoverLinkDataIndices,c=[];(e||WF(n))&&(c=this._hoverLinkDataIndices=n.findTargetDataIndices(u));var p=function(t,e){var n={},i={};return r(t||[],n),r(e||[],i,n),[o(n),o(i)];function r(t,e,n){for(var i=0,r=t.length;i=0&&(r.dimension=o,i.push(r))}})),t.getData().setVisual("visualMeta",i)}}];function ZF(t,e,n,i){for(var r=e.targetVisuals[i],o=_D.prepareVisualTypes(r),a={color:Ty(t.getData(),"color")},s=0,l=o.length;s0:t.splitNumber>0)&&!t.calculable?"piecewise":"continuous"})),t.registerAction(YF,XF),E(UF,(function(e){t.registerVisual(t.PRIORITY.VISUAL.COMPONENT,e)})),t.registerPreprocessor(qF))}function QF(t){t.registerComponentModel(kF),t.registerComponentView(FF),JF(t)}var tG=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n._pieceList=[],n}return n(e,t),e.prototype.optionUpdated=function(e,n){t.prototype.optionUpdated.apply(this,arguments),this.resetExtent();var i=this._mode=this._determineMode();this._pieceList=[],eG[this._mode].call(this,this._pieceList),this._resetSelected(e,n);var r=this.option.categories;this.resetVisual((function(t,e){"categories"===i?(t.mappingMethod="category",t.categories=T(r)):(t.dataExtent=this.getExtent(),t.mappingMethod="piecewise",t.pieceList=z(this._pieceList,(function(t){return t=T(t),"inRange"!==e&&(t.visual=null),t})))}))},e.prototype.completeVisualOption=function(){var e=this.option,n={},i=_D.listVisualTypes(),r=this.isCategory();function o(t,e,n){return t&&t[e]&&t[e].hasOwnProperty(n)}E(e.pieces,(function(t){E(i,(function(e){t.hasOwnProperty(e)&&(n[e]=1)}))})),E(n,(function(t,n){var i=!1;E(this.stateList,(function(t){i=i||o(e,t,n)||o(e.target,t,n)}),this),!i&&E(this.stateList,(function(t){(e[t]||(e[t]={}))[n]=_F(n,"inRange"===t?"active":"inactive",r)}))}),this),t.prototype.completeVisualOption.apply(this,arguments)},e.prototype._resetSelected=function(t,e){var n=this.option,i=this._pieceList,r=(e?n:t).selected||{};if(n.selected=r,E(i,(function(t,e){var n=this.getSelectedMapKey(t);r.hasOwnProperty(n)||(r[n]=!0)}),this),"single"===n.selectedMode){var o=!1;E(i,(function(t,e){var n=this.getSelectedMapKey(t);r[n]&&(o?r[n]=!1:o=!0)}),this)}},e.prototype.getItemSymbol=function(){return this.get("itemSymbol")},e.prototype.getSelectedMapKey=function(t){return"categories"===this._mode?t.value+"":t.index+""},e.prototype.getPieceList=function(){return this._pieceList},e.prototype._determineMode=function(){var t=this.option;return t.pieces&&t.pieces.length>0?"pieces":this.option.categories?"categories":"splitNumber"},e.prototype.setSelected=function(t){this.option.selected=T(t)},e.prototype.getValueState=function(t){var e=_D.findPieceIndex(t,this._pieceList);return null!=e&&this.option.selected[this.getSelectedMapKey(this._pieceList[e])]?"inRange":"outOfRange"},e.prototype.findTargetDataIndices=function(t){var e=[],n=this._pieceList;return this.eachTargetSeries((function(i){var r=[],o=i.getData();o.each(this.getDataDimensionIndex(o),(function(e,i){_D.findPieceIndex(e,n)===t&&r.push(i)}),this),e.push({seriesId:i.id,dataIndex:r})}),this),e},e.prototype.getRepresentValue=function(t){var e;if(this.isCategory())e=t.value;else if(null!=t.value)e=t.value;else{var n=t.interval||[];e=n[0]===-1/0&&n[1]===1/0?0:(n[0]+n[1])/2}return e},e.prototype.getVisualMeta=function(t){if(!this.isCategory()){var e=[],n=["",""],i=this,r=this._pieceList.slice();if(r.length){var o=r[0].interval[0];o!==-1/0&&r.unshift({interval:[-1/0,o]}),(o=r[r.length-1].interval[1])!==1/0&&r.push({interval:[o,1/0]})}else r.push({interval:[-1/0,1/0]});var a=-1/0;return E(r,(function(t){var e=t.interval;e&&(e[0]>a&&s([a,e[0]],"outOfRange"),s(e.slice()),a=e[1])}),this),{stops:e,outerColors:n}}function s(r,o){var a=i.getRepresentValue({interval:r});o||(o=i.getValueState(a));var s=t(a,o);r[0]===-1/0?n[0]=s:r[1]===1/0?n[1]=s:e.push({value:r[0],color:s},{value:r[1],color:s})}},e.type="visualMap.piecewise",e.defaultOption=Cc(DF.defaultOption,{selected:null,minOpen:!1,maxOpen:!1,align:"auto",itemWidth:20,itemHeight:14,itemSymbol:"roundRect",pieces:null,categories:null,splitNumber:5,selectedMode:"multiple",itemGap:10,hoverLink:!0}),e}(DF),eG={splitNumber:function(t){var e=this.option,n=Math.min(e.precision,20),i=this.getExtent(),r=e.splitNumber;r=Math.max(parseInt(r,10),1),e.splitNumber=r;for(var o=(i[1]-i[0])/r;+o.toFixed(n)!==o&&n<5;)n++;e.precision=n,o=+o.toFixed(n),e.minOpen&&t.push({interval:[-1/0,i[0]],close:[0,0]});for(var a=0,s=i[0];a","≥"][e[0]]];t.text=t.text||this.formatValueText(null!=t.value?t.value:t.interval,!1,n)}),this)}};function nG(t,e){var n=t.inverse;("vertical"===t.orient?!n:n)&&e.reverse()}var iG=function(t){function e(){var n=null!==t&&t.apply(this,arguments)||this;return n.type=e.type,n}return n(e,t),e.prototype.doRender=function(){var t=this.group;t.removeAll();var e=this.visualMapModel,n=e.get("textGap"),i=e.textStyleModel,r=i.getFont(),o=i.getTextColor(),a=this._getItemAlign(),s=e.itemSize,l=this._getViewData(),u=l.endsText,h=it(e.get("showLabel",!0),!u);u&&this._renderEndsText(t,u[0],s,h,a),E(l.viewPieceList,(function(i){var l=i.piece,u=new zr;u.onclick=W(this._onItemClick,this,l),this._enableHoverLink(u,i.indexInModelPieceList);var c=e.getRepresentValue(l);if(this._createItemSymbol(u,c,[0,0,s[0],s[1]]),h){var p=this.visualMapModel.getValueState(c);u.add(new Fs({style:{x:"right"===a?-n:s[0]+n,y:s[1]/2,text:l.text,verticalAlign:"middle",align:a,font:r,fill:o,opacity:"outOfRange"===p?.5:1}}))}t.add(u)}),this),u&&this._renderEndsText(t,u[1],s,h,a),Tp(e.get("orient"),t,e.get("itemGap")),this.renderBackground(t),this.positionGroup(t)},e.prototype._enableHoverLink=function(t,e){var n=this;t.on("mouseover",(function(){return i("highlight")})).on("mouseout",(function(){return i("downplay")}));var i=function(t){var i=n.visualMapModel;i.option.hoverLink&&n.api.dispatchAction({type:t,batch:NF(i.findTargetDataIndices(e),i)})}},e.prototype._getItemAlign=function(){var t=this.visualMapModel,e=t.option;if("vertical"===e.orient)return RF(t,this.api,t.itemSize);var n=e.align;return n&&"auto"!==n||(n="left"),n},e.prototype._renderEndsText=function(t,e,n,i,r){if(e){var o=new zr,a=this.visualMapModel.textStyleModel;o.add(new Fs({style:nc(a,{x:i?"right"===r?n[0]:0:n[0]/2,y:n[1]/2,verticalAlign:"middle",align:i?r:"center",text:e})})),t.add(o)}},e.prototype._getViewData=function(){var t=this.visualMapModel,e=z(t.getPieceList(),(function(t,e){return{piece:t,indexInModelPieceList:e}})),n=t.get("text"),i=t.get("orient"),r=t.get("inverse");return("horizontal"===i?r:!r)?e.reverse():n&&(n=n.slice().reverse()),{viewPieceList:e,endsText:n}},e.prototype._createItemSymbol=function(t,e,n){t.add(Wy(this.getControllerVisual(e,"symbol"),n[0],n[1],n[2],n[3],this.getControllerVisual(e,"color")))},e.prototype._onItemClick=function(t){var e=this.visualMapModel,n=e.option,i=n.selectedMode;if(i){var r=T(n.selected),o=e.getSelectedMapKey(t);"single"===i||!0===i?(r[o]=!0,E(r,(function(t,e){r[e]=e===o}))):r[o]=!r[o],this.api.dispatchAction({type:"selectDataRange",from:this.uid,visualMapId:this.visualMapModel.id,selected:r})}},e.type="visualMap.piecewise",e}(PF);function rG(t){t.registerComponentModel(tG),t.registerComponentView(iG),JF(t)}var oG={label:{enabled:!0},decal:{show:!1}},aG=Oo(),sG={};function lG(t,e){var n=t.getModel("aria");if(n.get("enabled")){var i=T(oG);C(i.label,t.getLocaleModel().get("aria"),!1),C(n.option,i,!1),function(){if(n.getModel("decal").get("show")){var e=yt();t.eachSeries((function(t){if(!t.isColorBySeries()){var n=e.get(t.type);n||(n={},e.set(t.type,n)),aG(t).scope=n}})),t.eachRawSeries((function(e){if(!t.isSeriesFiltered(e))if(X(e.enableAriaDecal))e.enableAriaDecal();else{var n=e.getData();if(e.isColorBySeries()){var i=ud(e.ecModel,e.name,sG,t.getSeriesCount()),r=n.getVisual("decal");n.setVisual("decal",u(r,i))}else{var o=e.getRawData(),a={},s=aG(e).scope;n.each((function(t){var e=n.getRawIndex(t);a[e]=t}));var l=o.count();o.each((function(t){var i=a[t],r=o.getName(t)||t+"",h=ud(e.ecModel,r,s,l),c=n.getItemVisual(i,"decal");n.setItemVisual(i,"decal",u(c,h))}))}}function u(t,e){var n=t?A(A({},e),t):e;return n.dirty=!0,n}}))}}(),function(){var i=t.getLocaleModel().get("aria"),o=n.getModel("label");if(o.option=k(o.option,i),!o.get("enabled"))return;var a=e.getZr().dom;if(o.get("description"))return void a.setAttribute("aria-label",o.get("description"));var s,l=t.getSeriesCount(),u=o.get(["data","maxCount"])||10,h=o.get(["series","maxCount"])||10,c=Math.min(l,h);if(l<1)return;var p=function(){var e=t.get("title");e&&e.length&&(e=e[0]);return e&&e.text}();s=p?r(o.get(["general","withTitle"]),{title:p}):o.get(["general","withoutTitle"]);var d=[];s+=r(l>1?o.get(["series","multiple","prefix"]):o.get(["series","single","prefix"]),{seriesCount:l}),t.eachSeries((function(e,n){if(n1?o.get(["series","multiple",a]):o.get(["series","single",a]),{seriesId:e.seriesIndex,seriesName:e.get("name"),seriesType:(x=e.subType,t.getLocaleModel().get(["series","typeNames"])[x]||"自定义图")});var s=e.getData();if(s.count()>u)i+=r(o.get(["data","partialData"]),{displayCnt:u});else i+=o.get(["data","allData"]);for(var h=o.get(["data","separator","middle"]),p=o.get(["data","separator","end"]),f=[],g=0;g":"gt",">=":"gte","=":"eq","!=":"ne","<>":"ne"},cG=function(){function t(t){if(null==(this._condVal=U(t)?new RegExp(t):et(t)?t:null)){var e="";0,vo(e)}}return t.prototype.evaluate=function(t){var e=typeof t;return U(e)?this._condVal.test(t):!!j(e)&&this._condVal.test(t+"")},t}(),pG=function(){function t(){}return t.prototype.evaluate=function(){return this.value},t}(),dG=function(){function t(){}return t.prototype.evaluate=function(){for(var t=this.children,e=0;e2&&l.push(e),e=[t,n]}function f(t,n,i,r){TG(t,i)&&TG(n,r)||e.push(t,n,i,r,i,r)}function g(t,n,i,r,o,a){var s=Math.abs(n-t),l=4*Math.tan(s/4)/3,u=nM:C2&&l.push(e),l}function DG(t,e,n,i,r,o,a,s,l,u){if(TG(t,n)&&TG(e,i)&&TG(r,a)&&TG(o,s))l.push(a,s);else{var h=2/u,c=h*h,p=a-t,d=s-e,f=Math.sqrt(p*p+d*d);p/=f,d/=f;var g=n-t,y=i-e,v=r-a,m=o-s,x=g*g+y*y,_=v*v+m*m;if(x=0&&_-w*w=0)l.push(a,s);else{var S=[],M=[];wn(t,n,r,a,.5,S),wn(e,i,o,s,.5,M),DG(S[0],M[0],S[1],M[1],S[2],M[2],S[3],M[3],l,u),DG(S[4],M[4],S[5],M[5],S[6],M[6],S[7],M[7],l,u)}}}}function AG(t,e,n){var i=t[e],r=t[1-e],o=Math.abs(i/r),a=Math.ceil(Math.sqrt(o*n)),s=Math.floor(n/a);0===s&&(s=1,a=n);for(var l=[],u=0;u0)for(u=0;uMath.abs(u),c=AG([l,u],h?0:1,e),p=(h?s:u)/c.length,d=0;d1?null:new De(d*l+t,d*u+e)}function OG(t,e,n){var i=new De;De.sub(i,n,e),i.normalize();var r=new De;return De.sub(r,t,e),r.dot(i)}function RG(t,e){var n=t[t.length-1];n&&n[0]===e[0]&&n[1]===e[1]||t.push(e)}function NG(t){var e=t.points,n=[],i=[];Ra(e,n,i);var r=new ze(n[0],n[1],i[0]-n[0],i[1]-n[1]),o=r.width,a=r.height,s=r.x,l=r.y,u=new De,h=new De;return o>a?(u.x=h.x=s+o/2,u.y=l,h.y=l+a):(u.y=h.y=l+a/2,u.x=s,h.x=s+o),function(t,e,n){for(var i=t.length,r=[],o=0;or,a=AG([i,r],o?0:1,e),s=o?"width":"height",l=o?"height":"width",u=o?"x":"y",h=o?"y":"x",c=t[s]/a.length,p=0;p0)for(var b=i/n,w=-i/2;w<=i/2;w+=b){var S=Math.sin(w),M=Math.cos(w),I=0;for(x=0;x0;l/=2){var u=0,h=0;(t&l)>0&&(u=1),(e&l)>0&&(h=1),s+=l*l*(3*u^h),0===h&&(1===u&&(t=l-1-t,e=l-1-e),a=t,t=e,e=a)}return s}function JG(t){var e=1/0,n=1/0,i=-1/0,r=-1/0,o=z(t,(function(t){var o=t.getBoundingRect(),a=t.getComputedTransform(),s=o.x+o.width/2+(a?a[4]:0),l=o.y+o.height/2+(a?a[5]:0);return e=Math.min(s,e),n=Math.min(l,n),i=Math.max(s,i),r=Math.max(l,r),[s,l]}));return z(o,(function(o,a){return{cp:o,z:$G(o[0],o[1],e,n,i,r),path:t[a]}})).sort((function(t,e){return t.z-e.z})).map((function(t){return t.path}))}function QG(t){return VG(t.path,t.count)}function tW(t){return Y(t[0])}function eW(t,e){for(var n=[],i=t.length,r=0;r=0;r--)if(!n[r].many.length){var l=n[s].many;if(l.length<=1){if(!s)return n;s=0}o=l.length;var u=Math.ceil(o/2);n[r].many=l.slice(u,o),n[s].many=l.slice(0,u),s++}return n}var nW={clone:function(t){for(var e=[],n=1-Math.pow(1-t.path.style.opacity,1/t.count),i=0;i0){var s,l,u=i.getModel("universalTransition").get("delay"),h=Object.assign({setToFinal:!0},a);tW(t)&&(s=t,l=e),tW(e)&&(s=e,l=t);for(var c=s?s===t:t.length>e.length,p=s?eW(l,s):eW(c?e:t,[c?t:e]),d=0,f=0;f1e4))for(var i=n.getIndices(),r=function(t){for(var e=t.dimensions,n=0;n0&&i.group.traverse((function(t){t instanceof Is&&!t.animators.length&&t.animateFrom({style:{opacity:0}},r)}))}))}function pW(t){var e=t.getModel("universalTransition").get("seriesKey");return e||t.id}function dW(t){return Y(t)?t.sort().join(","):t}function fW(t){if(t.hostModel)return t.hostModel.getModel("universalTransition").get("divideShape")}function gW(t,e){for(var n=0;n=0&&r.push({dataGroupId:e.oldDataGroupIds[n],data:e.oldData[n],divide:fW(e.oldData[n]),dim:t.dimension})})),E(bo(t.to),(function(t){var i=gW(n.updatedSeries,t);if(i>=0){var r=n.updatedSeries[i].getData();o.push({dataGroupId:e.oldDataGroupIds[i],data:r,divide:fW(r),dim:t.dimension})}})),r.length>0&&o.length>0&&cW(r,o,i)}(t,i,n,e)}));else{var o=function(t,e){var n=yt(),i=yt(),r=yt();return E(t.oldSeries,(function(e,n){var o=t.oldDataGroupIds[n],a=t.oldData[n],s=pW(e),l=dW(s);i.set(l,{dataGroupId:o,data:a}),Y(s)&&E(s,(function(t){r.set(t,{key:l,dataGroupId:o,data:a})}))})),E(e.updatedSeries,(function(t){if(t.isUniversalTransitionEnabled()&&t.isAnimationEnabled()){var e=t.get("dataGroupId"),o=t.getData(),a=pW(t),s=dW(a),l=i.get(s);if(l)n.set(s,{oldSeries:[{dataGroupId:l.dataGroupId,divide:fW(l.data),data:l.data}],newSeries:[{dataGroupId:e,divide:fW(o),data:o}]});else if(Y(a)){var u=[];E(a,(function(t){var e=i.get(t);e.data&&u.push({dataGroupId:e.dataGroupId,divide:fW(e.data),data:e.data})})),u.length&&n.set(s,{oldSeries:u,newSeries:[{dataGroupId:e,data:o,divide:fW(o)}]})}else{var h=r.get(a);if(h){var c=n.get(h.key);c||(c={oldSeries:[{dataGroupId:h.dataGroupId,data:h.data,divide:fW(h.data)}],newSeries:[]},n.set(h.key,c)),c.newSeries.push({dataGroupId:e,data:o,divide:fW(o)})}}}})),n}(i,n);E(o.keys(),(function(t){var n=o.get(t);cW(n.oldSeries,n.newSeries,e)}))}E(n.updatedSeries,(function(t){t[vg]&&(t[vg]=!1)}))}for(var a=t.getSeries(),s=i.oldSeries=[],l=i.oldDataGroupIds=[],u=i.oldData=[],h=0;h /dev/null + ) + local ver=$(git_latest_tag "$dir") + echo "$name $ver" + if [ "$name" = "echarts" ]; then + echo "$ver" > "$SRC/version.txt" + fi +} + +git_checkout_reset echarts "https://github.com/${REPO_E}.git" "master" +git_checkout_reset echarts-examples "https://github.com/${REPO_X}.git" "gh-pages" + +(set -x; + cp $WORKDIR/echarts/dist/echarts.min.js $SRC +) + +pushd $WORKDIR/echarts-examples &> /dev/null +(set -x; + pnpm install + pnpm add -D typescript +) +popd &> /dev/null + +pushd $WORKDIR/echarts-examples/public/examples &> /dev/null +(set -x; + rm -rf js out + npx tsc -p tsconfig.json || : + rsync \ + -rvP \ + --exclude gl \ + --exclude archive \ + --delete \ + ./js/. $SRC/testdata/. +) +popd &> /dev/null diff --git a/go.mod b/go.mod new file mode 100644 index 0000000..afce224 --- /dev/null +++ b/go.mod @@ -0,0 +1,15 @@ +module github.com/xo/echartsgoja + +go 1.20 + +require ( + github.com/dop251/goja v0.0.0-20231027120936-b396bb4c349d + github.com/dop251/goja_nodejs v0.0.0-20231122114759-e84d9a924c5c +) + +require ( + github.com/dlclark/regexp2 v1.10.0 // indirect + github.com/go-sourcemap/sourcemap v2.1.3+incompatible // indirect + github.com/google/pprof v0.0.0-20230926050212-f7f687d19a98 // indirect + golang.org/x/text v0.13.0 // indirect +) diff --git a/go.sum b/go.sum new file mode 100644 index 0000000..afc8f4f --- /dev/null +++ b/go.sum @@ -0,0 +1,62 @@ +github.com/chzyer/logex v1.2.0/go.mod h1:9+9sk7u7pGNWYMkh0hdiL++6OeibzJccyQU4p4MedaY= +github.com/chzyer/readline v1.5.0/go.mod h1:x22KAscuvRqlLoK9CsoYsmxoXZMMFVyOl86cAH8qUic= +github.com/chzyer/test v0.0.0-20210722231415-061457976a23/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU= +github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= +github.com/dlclark/regexp2 v1.4.1-0.20201116162257-a2a8dda75c91/go.mod h1:2pZnwuY/m+8K6iRw6wQdMtk+rH5tNGR1i55kozfMjCc= +github.com/dlclark/regexp2 v1.7.0/go.mod h1:DHkYz0B9wPfa6wondMfaivmHpzrQ3v9q8cnmRbL6yW8= +github.com/dlclark/regexp2 v1.10.0 h1:+/GIL799phkJqYW+3YbOd8LCcbHzT0Pbo8zl70MHsq0= +github.com/dlclark/regexp2 v1.10.0/go.mod h1:DHkYz0B9wPfa6wondMfaivmHpzrQ3v9q8cnmRbL6yW8= +github.com/dop251/goja v0.0.0-20211022113120-dc8c55024d06/go.mod h1:R9ET47fwRVRPZnOGvHxxhuZcbrMCuiqOz3Rlrh4KSnk= +github.com/dop251/goja v0.0.0-20231027120936-b396bb4c349d h1:wi6jN5LVt/ljaBG4ue79Ekzb12QfJ52L9Q98tl8SWhw= +github.com/dop251/goja v0.0.0-20231027120936-b396bb4c349d/go.mod h1:QMWlm50DNe14hD7t24KEqZuUdC9sOTy8W6XbCU1mlw4= +github.com/dop251/goja_nodejs v0.0.0-20210225215109-d91c329300e7/go.mod h1:hn7BA7c8pLvoGndExHudxTDKZ84Pyvv+90pbBjbTz0Y= +github.com/dop251/goja_nodejs v0.0.0-20211022123610-8dd9abb0616d/go.mod h1:DngW8aVqWbuLRMHItjPUyqdj+HWPvnQe8V8y1nDpIbM= +github.com/dop251/goja_nodejs v0.0.0-20231122114759-e84d9a924c5c h1:hLoodLRD4KLWIH8eyAQCLcH8EqIrjac7fCkp/fHnvuQ= +github.com/dop251/goja_nodejs v0.0.0-20231122114759-e84d9a924c5c/go.mod h1:bhGPmCgCCTSRfiMYWjpS46IDo9EUZXlsuUaPXSWGbv0= +github.com/go-sourcemap/sourcemap v2.1.3+incompatible h1:W1iEw64niKVGogNgBN3ePyLFfuisuzeidWPMPWmECqU= +github.com/go-sourcemap/sourcemap v2.1.3+incompatible/go.mod h1:F8jJfvm2KbVjc5NqelyYJmf/v5J0dwNLS2mL4sNA1Jg= +github.com/google/pprof v0.0.0-20230207041349-798e818bf904/go.mod h1:uglQLonpP8qtYCYyzA+8c/9qtqgA3qsXGYqCPKARAFg= +github.com/google/pprof v0.0.0-20230926050212-f7f687d19a98 h1:pUa4ghanp6q4IJHwE9RwLgmVFfReJN+KbQ8ExNEUUoQ= +github.com/google/pprof v0.0.0-20230926050212-f7f687d19a98/go.mod h1:czg5+yv1E0ZGTi6S6vVK1mke0fV+FaUhNGcd6VRS9Ik= +github.com/ianlancetaylor/demangle v0.0.0-20220319035150-800ac71e25c2/go.mod h1:aYm2/VgdVmcIU8iMfdMvDMsRAQjcfZSKFby6HOFvi/w= +github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= +github.com/kr/pretty v0.2.1/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI= +github.com/kr/pretty v0.3.0/go.mod h1:640gp4NfQd8pI5XOwp5fnNeVWj67G7CFk/SaSQn7NBk= +github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= +github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= +github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= +github.com/rogpeppe/go-internal v1.6.1/go.mod h1:xXDCJY+GAPziupqXw64V24skbSoqbTEfhy4qGm1nDQc= +github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY= +golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= +golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= +golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4= +golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= +golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= +golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= +golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= +golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220310020820-b874c991c1a5/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= +golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= +golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= +golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= +golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= +golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= +golang.org/x/text v0.3.8/go.mod h1:E6s5w1FMmriuDzIBO73fBruAKo1PCIq6d2Q6DHfQ8WQ= +golang.org/x/text v0.13.0 h1:ablQoSUd0tRdKxZewP80B+BaqeKJuVhuRxj/dkrun3k= +golang.org/x/text v0.13.0/go.mod h1:TvPlkZtksWOMsz7fbANvkp4WM8x/WCo/om8BMLbz+aE= +golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= +golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= +golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc= +golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= +gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= +gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= +gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI= +gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= +gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= diff --git a/missing.sh b/missing.sh new file mode 100755 index 0000000..caade74 --- /dev/null +++ b/missing.sh @@ -0,0 +1,13 @@ +#/bin/bash + +SRC=$(realpath $(cd -P "$(dirname "${BASH_SOURCE[0]}")" && pwd)) + +pushd $SRC/testdata &> /dev/null + +for i in $(find -type f -iname \*.js|sort -h); do + if [ ! -f $i.svg ]; then + echo "TestRender/$(sed -e 's/\.js$//' <<< "$i"|sed -e 's/^\.\///')" + fi +done + +popd &> /dev/null diff --git a/testdata/area-basic.js b/testdata/area-basic.js new file mode 100644 index 0000000..75465b0 --- /dev/null +++ b/testdata/area-basic.js @@ -0,0 +1,24 @@ +/* +title: Basic area chart +titleCN: 基础面积图 +category: line +difficulty: 1 +*/ +option = { + xAxis: { + type: 'category', + boundaryGap: false, + data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'] + }, + yAxis: { + type: 'value' + }, + series: [ + { + data: [820, 932, 901, 934, 1290, 1330, 1320], + type: 'line', + areaStyle: {} + } + ] +}; +export {}; diff --git a/testdata/area-basic.js.svg b/testdata/area-basic.js.svg new file mode 100644 index 0000000..3c7d045 --- /dev/null +++ b/testdata/area-basic.js.svg @@ -0,0 +1,61 @@ + + + + + + + + + + + + + + + + +0 +300 +600 +900 +1,200 +1,500 +Mon +Tue +Wed +Thu +Fri +Sat +Sun + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/area-pieces.js b/testdata/area-pieces.js new file mode 100644 index 0000000..333d937 --- /dev/null +++ b/testdata/area-pieces.js @@ -0,0 +1,63 @@ +/* +title: Area Pieces +titleCN: 折线图区域高亮 +category: 'line, visualMap' +difficulty: 3 +*/ +option = { + xAxis: { + type: 'category', + boundaryGap: false + }, + yAxis: { + type: 'value', + boundaryGap: [0, '30%'] + }, + visualMap: { + type: 'piecewise', + show: false, + dimension: 0, + seriesIndex: 0, + pieces: [ + { + gt: 1, + lt: 3, + color: 'rgba(0, 0, 180, 0.4)' + }, + { + gt: 5, + lt: 7, + color: 'rgba(0, 0, 180, 0.4)' + } + ] + }, + series: [ + { + type: 'line', + smooth: 0.6, + symbol: 'none', + lineStyle: { + color: '#5470C6', + width: 5 + }, + markLine: { + symbol: ['none', 'none'], + label: { show: false }, + data: [{ xAxis: 1 }, { xAxis: 3 }, { xAxis: 5 }, { xAxis: 7 }] + }, + areaStyle: {}, + data: [ + ['2019-10-10', 200], + ['2019-10-11', 560], + ['2019-10-12', 750], + ['2019-10-13', 580], + ['2019-10-14', 250], + ['2019-10-15', 300], + ['2019-10-16', 450], + ['2019-10-17', 300], + ['2019-10-18', 100] + ] + } + ] +}; +export {}; diff --git a/testdata/area-pieces.js.svg b/testdata/area-pieces.js.svg new file mode 100644 index 0000000..970b2c1 --- /dev/null +++ b/testdata/area-pieces.js.svg @@ -0,0 +1,72 @@ + + + + + + + + + + + + + + + + + + +0 +200 +400 +600 +800 +1,000 +2019-10-10 +2019-10-11 +2019-10-12 +2019-10-13 +2019-10-14 +2019-10-15 +2019-10-16 +2019-10-17 +2019-10-18 + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/area-rainfall.js b/testdata/area-rainfall.js new file mode 100644 index 0000000..3af58ba --- /dev/null +++ b/testdata/area-rainfall.js @@ -0,0 +1,144 @@ +/* +title: Rainfall +titleCN: 雨量流量关系图 +category: line +difficulty: 5 +*/ +option = { + title: { + text: 'Rainfall and Flow Relationship', + left: 'center' + }, + grid: { + bottom: 80 + }, + toolbox: { + feature: { + dataZoom: { + yAxisIndex: 'none' + }, + restore: {}, + saveAsImage: {} + } + }, + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'cross', + animation: false, + label: { + backgroundColor: '#505765' + } + } + }, + legend: { + data: ['Flow', 'Rainfall'], + left: 10 + }, + dataZoom: [ + { + show: true, + realtime: true, + start: 65, + end: 85 + }, + { + type: 'inside', + realtime: true, + start: 65, + end: 85 + } + ], + xAxis: [ + { + type: 'category', + boundaryGap: false, + axisLine: { onZero: false }, + // prettier-ignore + data: [ + '2009/6/12 2:00', '2009/6/12 3:00', '2009/6/12 4:00', '2009/6/12 5:00', '2009/6/12 6:00', '2009/6/12 7:00', '2009/6/12 8:00', '2009/6/12 9:00', '2009/6/12 10:00', '2009/6/12 11:00', '2009/6/12 12:00', '2009/6/12 13:00', '2009/6/12 14:00', '2009/6/12 15:00', '2009/6/12 16:00', '2009/6/12 17:00', '2009/6/12 18:00', '2009/6/12 19:00', '2009/6/12 20:00', '2009/6/12 21:00', '2009/6/12 22:00', '2009/6/12 23:00', '2009/6/13 0:00', '2009/6/13 1:00', '2009/6/13 2:00', '2009/6/13 3:00', '2009/6/13 4:00', '2009/6/13 5:00', '2009/6/13 6:00', '2009/6/13 7:00', '2009/6/13 8:00', '2009/6/13 9:00', '2009/6/13 10:00', '2009/6/13 11:00', '2009/6/13 12:00', '2009/6/13 13:00', '2009/6/13 14:00', '2009/6/13 15:00', '2009/6/13 16:00', '2009/6/13 17:00', '2009/6/13 18:00', '2009/6/13 19:00', '2009/6/13 20:00', '2009/6/13 21:00', '2009/6/13 22:00', '2009/6/13 23:00', '2009/6/14 0:00', '2009/6/14 1:00', '2009/6/14 2:00', '2009/6/14 3:00', '2009/6/14 4:00', '2009/6/14 5:00', '2009/6/14 6:00', '2009/6/14 7:00', '2009/6/14 8:00', '2009/6/14 9:00', '2009/6/14 10:00', '2009/6/14 11:00', '2009/6/14 12:00', '2009/6/14 13:00', '2009/6/14 14:00', '2009/6/14 15:00', '2009/6/14 16:00', '2009/6/14 17:00', '2009/6/14 18:00', '2009/6/14 19:00', '2009/6/14 20:00', '2009/6/14 21:00', '2009/6/14 22:00', '2009/6/14 23:00', '2009/6/15 0:00', '2009/6/15 1:00', '2009/6/15 2:00', '2009/6/15 3:00', '2009/6/15 4:00', '2009/6/15 5:00', '2009/6/15 6:00', '2009/6/15 7:00', '2009/6/15 8:00', '2009/6/15 9:00', '2009/6/15 10:00', '2009/6/15 11:00', '2009/6/15 12:00', '2009/6/15 13:00', '2009/6/15 14:00', '2009/6/15 15:00', '2009/6/15 16:00', '2009/6/15 17:00', '2009/6/15 18:00', '2009/6/15 19:00', '2009/6/15 20:00', '2009/6/15 21:00', '2009/6/15 22:00', '2009/6/15 23:00', '2009/6/15 0:00', '2009/6/16 1:00', '2009/6/16 2:00', '2009/6/16 3:00', '2009/6/16 4:00', '2009/6/16 5:00', '2009/6/16 6:00', '2009/6/16 7:00', '2009/6/16 8:00', '2009/6/16 9:00', '2009/6/16 10:00', '2009/6/16 11:00', '2009/6/16 12:00', '2009/6/16 13:00', '2009/6/16 14:00', '2009/6/16 15:00', '2009/6/16 16:00', '2009/6/16 17:00', '2009/6/16 18:00', '2009/6/16 19:00', '2009/6/16 20:00', '2009/6/16 21:00', '2009/6/16 22:00', '2009/6/16 23:00', '2009/6/15 0:00', '2009/6/17 1:00', '2009/6/17 2:00', '2009/6/17 3:00', '2009/6/17 4:00', '2009/6/17 5:00', '2009/6/17 6:00', '2009/6/17 7:00', '2009/6/17 8:00', '2009/6/17 9:00', '2009/6/17 10:00', '2009/6/17 11:00', '2009/6/17 12:00', '2009/6/17 13:00', '2009/6/17 14:00', '2009/6/17 15:00', '2009/6/17 16:00', '2009/6/17 17:00', '2009/6/17 18:00', '2009/6/17 19:00', '2009/6/17 20:00', '2009/6/17 21:00', '2009/6/17 22:00', '2009/6/17 23:00', '2009/6/18 0:00', '2009/6/18 1:00', '2009/6/18 2:00', '2009/6/18 3:00', '2009/6/18 4:00', '2009/6/18 5:00', '2009/6/18 6:00', '2009/6/18 7:00', '2009/6/18 8:00', '2009/6/18 9:00', '2009/6/18 10:00', '2009/6/18 11:00', '2009/6/18 12:00', '2009/6/18 13:00', '2009/6/18 14:00', '2009/6/18 15:00', '2009/6/18 16:00', '2009/6/18 17:00', '2009/6/18 18:00', '2009/6/18 19:00', '2009/6/18 20:00', '2009/6/18 21:00', '2009/6/18 22:00', '2009/6/18 23:00', '2009/6/15 0:00', '2009/6/19 1:00', '2009/6/19 2:00', '2009/6/19 3:00', '2009/6/19 4:00', '2009/6/19 5:00', '2009/6/19 6:00', '2009/6/19 7:00', '2009/6/19 8:00', '2009/6/19 9:00', '2009/6/19 10:00', '2009/6/19 11:00', '2009/6/19 12:00', '2009/6/19 13:00', '2009/6/19 14:00', '2009/6/19 15:00', '2009/6/19 16:00', '2009/6/19 17:00', '2009/6/19 18:00', '2009/6/19 19:00', '2009/6/19 20:00', '2009/6/19 21:00', '2009/6/19 22:00', '2009/6/19 23:00', '2009/6/20 0:00', '2009/6/20 1:00', '2009/6/20 2:00', '2009/6/20 3:00', '2009/6/20 4:00', '2009/6/20 5:00', '2009/6/20 6:00', '2009/6/20 7:00', '2009/6/20 8:00', '2009/6/20 9:00', '2009/6/20 10:00', '2009/6/20 11:00', '2009/6/20 12:00', '2009/6/20 13:00', '2009/6/20 14:00', '2009/6/20 15:00', '2009/6/20 16:00', '2009/6/20 17:00', '2009/6/20 18:00', '2009/6/20 19:00', '2009/6/20 20:00', '2009/6/20 21:00', '2009/6/20 22:00', '2009/6/20 23:00', '2009/6/21 0:00', '2009/6/21 1:00', '2009/6/21 2:00', '2009/6/21 3:00', '2009/6/21 4:00', '2009/6/21 5:00', '2009/6/21 6:00', '2009/6/21 7:00', '2009/6/21 8:00', '2009/6/21 9:00', '2009/6/21 10:00', '2009/6/21 11:00', '2009/6/21 12:00', '2009/6/21 13:00', '2009/6/21 14:00', '2009/6/21 15:00', '2009/6/21 16:00', '2009/6/21 17:00', '2009/6/21 18:00', '2009/6/21 19:00', '2009/6/21 20:00', '2009/6/21 21:00', '2009/6/21 22:00', '2009/6/21 23:00', '2009/6/22 0:00', '2009/6/22 1:00', '2009/6/22 2:00', '2009/6/22 3:00', '2009/6/22 4:00', '2009/6/22 5:00', '2009/6/22 6:00', '2009/6/22 7:00', '2009/6/22 8:00', '2009/6/22 9:00', '2009/6/22 10:00', '2009/6/22 11:00', '2009/6/22 12:00', '2009/6/22 13:00', '2009/6/22 14:00', '2009/6/22 15:00', '2009/6/22 16:00', '2009/6/22 17:00', '2009/6/22 18:00', '2009/6/22 19:00', '2009/6/22 20:00', '2009/6/22 21:00', '2009/6/22 22:00', '2009/6/22 23:00', '2009/6/23 0:00', '2009/6/23 1:00', '2009/6/23 2:00', '2009/6/23 3:00', '2009/6/23 4:00', '2009/6/23 5:00', '2009/6/23 6:00', '2009/6/23 7:00', '2009/6/23 8:00', '2009/6/23 9:00', '2009/6/23 10:00', '2009/6/23 11:00', '2009/6/23 12:00', '2009/6/23 13:00', '2009/6/23 14:00', '2009/6/23 15:00', '2009/6/23 16:00', '2009/6/23 17:00', '2009/6/23 18:00', '2009/6/23 19:00', '2009/6/23 20:00', '2009/6/23 21:00', '2009/6/23 22:00', '2009/6/23 23:00', '2009/6/24 0:00', '2009/6/24 1:00', '2009/6/24 2:00', '2009/6/24 3:00', '2009/6/24 4:00', '2009/6/24 5:00', '2009/6/24 6:00', '2009/6/24 7:00', '2009/6/24 8:00', '2009/6/24 9:00', '2009/6/24 10:00', '2009/6/24 11:00', '2009/6/24 12:00', '2009/6/24 13:00', '2009/6/24 14:00', '2009/6/24 15:00', '2009/6/24 16:00', '2009/6/24 17:00', '2009/6/24 18:00', '2009/6/24 19:00', '2009/6/24 20:00', '2009/6/24 21:00', '2009/6/24 22:00', '2009/6/24 23:00', '2009/6/25 0:00', '2009/6/25 1:00', '2009/6/25 2:00', '2009/6/25 3:00', '2009/6/25 4:00', '2009/6/25 5:00', '2009/6/25 6:00', '2009/6/25 7:00', '2009/6/25 8:00', '2009/6/25 9:00', '2009/6/25 10:00', '2009/6/25 11:00', '2009/6/25 12:00', '2009/6/25 13:00', '2009/6/25 14:00', '2009/6/25 15:00', '2009/6/25 16:00', '2009/6/25 17:00', '2009/6/25 18:00', '2009/6/25 19:00', '2009/6/25 20:00', '2009/6/25 21:00', '2009/6/25 22:00', '2009/6/25 23:00', '2009/6/26 0:00', '2009/6/26 1:00', '2009/6/26 2:00', '2009/6/26 3:00', '2009/6/26 4:00', '2009/6/26 5:00', '2009/6/26 6:00', '2009/6/26 7:00', '2009/6/26 8:00', '2009/6/26 9:00', '2009/6/26 10:00', '2009/6/26 11:00', '2009/6/26 12:00', '2009/6/26 13:00', '2009/6/26 14:00', '2009/6/26 15:00', '2009/6/26 16:00', '2009/6/26 17:00', '2009/6/26 18:00', '2009/6/26 19:00', '2009/6/26 20:00', '2009/6/26 21:00', '2009/6/26 22:00', '2009/6/26 23:00', '2009/6/27 0:00', '2009/6/27 1:00', '2009/6/27 2:00', '2009/6/27 3:00', '2009/6/27 4:00', '2009/6/27 5:00', '2009/6/27 6:00', '2009/6/27 7:00', '2009/6/27 8:00', '2009/6/27 9:00', '2009/6/27 10:00', '2009/6/27 11:00', '2009/6/27 12:00', '2009/6/27 13:00', '2009/6/27 14:00', '2009/6/27 15:00', '2009/6/27 16:00', '2009/6/27 17:00', '2009/6/27 18:00', '2009/6/27 19:00', '2009/6/27 20:00', '2009/6/27 21:00', '2009/6/27 22:00', '2009/6/27 23:00', '2009/6/28 0:00', '2009/6/28 1:00', '2009/6/28 2:00', '2009/6/28 3:00', '2009/6/28 4:00', '2009/6/28 5:00', '2009/6/28 6:00', '2009/6/28 7:00', '2009/6/28 8:00', '2009/6/28 9:00', '2009/6/28 10:00', '2009/6/28 11:00', '2009/6/28 12:00', '2009/6/28 13:00', '2009/6/28 14:00', '2009/6/28 15:00', '2009/6/28 16:00', '2009/6/28 17:00', '2009/6/28 18:00', '2009/6/28 19:00', '2009/6/28 20:00', '2009/6/28 21:00', '2009/6/28 22:00', '2009/6/28 23:00', '2009/6/29 0:00', '2009/6/29 1:00', '2009/6/29 2:00', '2009/6/29 3:00', '2009/6/29 4:00', '2009/6/29 5:00', '2009/6/29 6:00', '2009/6/29 7:00', '2009/6/29 8:00', '2009/6/29 9:00', '2009/6/29 10:00', '2009/6/29 11:00', '2009/6/29 12:00', '2009/6/29 13:00', '2009/6/29 14:00', '2009/6/29 15:00', '2009/6/29 16:00', '2009/6/29 17:00', '2009/6/29 18:00', '2009/6/29 19:00', '2009/6/29 20:00', '2009/6/29 21:00', '2009/6/29 22:00', '2009/6/29 23:00', '2009/6/30 0:00', '2009/6/30 1:00', '2009/6/30 2:00', '2009/6/30 3:00', '2009/6/30 4:00', '2009/6/30 5:00', '2009/6/30 6:00', '2009/6/30 7:00', '2009/6/30 8:00', '2009/6/30 9:00', '2009/6/30 10:00', '2009/6/30 11:00', '2009/6/30 12:00', '2009/6/30 13:00', '2009/6/30 14:00', '2009/6/30 15:00', '2009/6/30 16:00', '2009/6/30 17:00', '2009/6/30 18:00', '2009/6/30 19:00', '2009/6/30 20:00', '2009/6/30 21:00', '2009/6/30 22:00', '2009/6/30 23:00', '2009/7/1 0:00', '2009/7/1 1:00', '2009/7/1 2:00', '2009/7/1 3:00', '2009/7/1 4:00', '2009/7/1 5:00', '2009/7/1 6:00', '2009/7/1 7:00', '2009/7/1 8:00', '2009/7/1 9:00', '2009/7/1 10:00', '2009/7/1 11:00', '2009/7/1 12:00', '2009/7/1 13:00', '2009/7/1 14:00', '2009/7/1 15:00', '2009/7/1 16:00', '2009/7/1 17:00', '2009/7/1 18:00', '2009/7/1 19:00', '2009/7/1 20:00', '2009/7/1 21:00', '2009/7/1 22:00', '2009/7/1 23:00', '2009/7/2 0:00', '2009/7/2 1:00', '2009/7/2 2:00', '2009/7/2 3:00', '2009/7/2 4:00', '2009/7/2 5:00', '2009/7/2 6:00', '2009/7/2 7:00', '2009/7/2 8:00', '2009/7/2 9:00', '2009/7/2 10:00', '2009/7/2 11:00', '2009/7/2 12:00', '2009/7/2 13:00', '2009/7/2 14:00', '2009/7/2 15:00', '2009/7/2 16:00', '2009/7/2 17:00', '2009/7/2 18:00', '2009/7/2 19:00', '2009/7/2 20:00', '2009/7/2 21:00', '2009/7/2 22:00', '2009/7/2 23:00', '2009/7/3 0:00', '2009/7/3 1:00', '2009/7/3 2:00', '2009/7/3 3:00', '2009/7/3 4:00', '2009/7/3 5:00', '2009/7/3 6:00', '2009/7/3 7:00', '2009/7/3 8:00', '2009/7/3 9:00', '2009/7/3 10:00', '2009/7/3 11:00', '2009/7/3 12:00', '2009/7/3 13:00', '2009/7/3 14:00', '2009/7/3 15:00', '2009/7/3 16:00', '2009/7/3 17:00', '2009/7/3 18:00', '2009/7/3 19:00', '2009/7/3 20:00', '2009/7/3 21:00', '2009/7/3 22:00', '2009/7/3 23:00', '2009/7/4 0:00', '2009/7/4 1:00', '2009/7/4 2:00', '2009/7/4 3:00', '2009/7/4 4:00', '2009/7/4 5:00', '2009/7/4 6:00', '2009/7/4 7:00', '2009/7/4 8:00', '2009/7/4 9:00', '2009/7/4 10:00', '2009/7/4 11:00', '2009/7/4 12:00', '2009/7/4 13:00', '2009/7/4 14:00', '2009/7/4 15:00', '2009/7/4 16:00', '2009/7/4 17:00', '2009/7/4 18:00', '2009/7/4 19:00', '2009/7/4 20:00', '2009/7/4 21:00', '2009/7/4 22:00', '2009/7/4 23:00', '2009/7/5 0:00', '2009/7/5 1:00', '2009/7/5 2:00', '2009/7/5 3:00', '2009/7/5 4:00', '2009/7/5 5:00', '2009/7/5 6:00', '2009/7/5 7:00', '2009/7/5 8:00', '2009/7/5 9:00', '2009/7/5 10:00', '2009/7/5 11:00', '2009/7/5 12:00', '2009/7/5 13:00', '2009/7/5 14:00', '2009/7/5 15:00', '2009/7/5 16:00', '2009/7/5 17:00', '2009/7/5 18:00', '2009/7/5 19:00', '2009/7/5 20:00', '2009/7/5 21:00', '2009/7/5 22:00', '2009/7/5 23:00', '2009/7/6 0:00', '2009/7/6 1:00', '2009/7/6 2:00', '2009/7/6 3:00', '2009/7/6 4:00', '2009/7/6 5:00', '2009/7/6 6:00', '2009/7/6 7:00', '2009/7/6 8:00', '2009/7/6 9:00', '2009/7/6 10:00', '2009/7/6 11:00', '2009/7/6 12:00', '2009/7/6 13:00', '2009/7/6 14:00', '2009/7/6 15:00', '2009/7/6 16:00', '2009/7/6 17:00', '2009/7/6 18:00', '2009/7/6 19:00', '2009/7/6 20:00', '2009/7/6 21:00', '2009/7/6 22:00', '2009/7/6 23:00', '2009/7/7 0:00', '2009/7/7 1:00', '2009/7/7 2:00', '2009/7/7 3:00', '2009/7/7 4:00', '2009/7/7 5:00', '2009/7/7 6:00', '2009/7/7 7:00', '2009/7/7 8:00', '2009/7/7 9:00', '2009/7/7 10:00', '2009/7/7 11:00', '2009/7/7 12:00', '2009/7/7 13:00', '2009/7/7 14:00', '2009/7/7 15:00', '2009/7/7 16:00', '2009/7/7 17:00', '2009/7/7 18:00', '2009/7/7 19:00', '2009/7/7 20:00', '2009/7/7 21:00', '2009/7/7 22:00', '2009/7/7 23:00', '2009/7/8 0:00', '2009/7/8 1:00', '2009/7/8 2:00', '2009/7/8 3:00', '2009/7/8 4:00', '2009/7/8 5:00', '2009/7/8 6:00', '2009/7/8 7:00', '2009/7/8 8:00', '2009/7/8 9:00', '2009/7/8 10:00', '2009/7/8 11:00', '2009/7/8 12:00', '2009/7/8 13:00', '2009/7/8 14:00', '2009/7/8 15:00', '2009/7/8 16:00', '2009/7/8 17:00', '2009/7/8 18:00', '2009/7/8 19:00', '2009/7/8 20:00', '2009/7/8 21:00', '2009/7/8 22:00', '2009/7/8 23:00', '2009/7/9 0:00', '2009/7/9 1:00', '2009/7/9 2:00', '2009/7/9 3:00', '2009/7/9 4:00', '2009/7/9 5:00', '2009/7/9 6:00', '2009/7/9 7:00', '2009/7/9 8:00', '2009/7/9 9:00', '2009/7/9 10:00', '2009/7/9 11:00', '2009/7/9 12:00', '2009/7/9 13:00', '2009/7/9 14:00', '2009/7/9 15:00', '2009/7/9 16:00', '2009/7/9 17:00', '2009/7/9 18:00', '2009/7/9 19:00', '2009/7/9 20:00', '2009/7/9 21:00', '2009/7/9 22:00', '2009/7/9 23:00', '2009/7/10 0:00', '2009/7/10 1:00', '2009/7/10 2:00', '2009/7/10 3:00', '2009/7/10 4:00', '2009/7/10 5:00', '2009/7/10 6:00', '2009/7/10 7:00', '2009/7/10 8:00', '2009/7/10 9:00', '2009/7/10 10:00', '2009/7/10 11:00', '2009/7/10 12:00', '2009/7/10 13:00', '2009/7/10 14:00', '2009/7/10 15:00', '2009/7/10 16:00', '2009/7/10 17:00', '2009/7/10 18:00', '2009/7/10 19:00', '2009/7/10 20:00', '2009/7/10 21:00', '2009/7/10 22:00', '2009/7/10 23:00', '2009/7/11 0:00', '2009/7/11 1:00', '2009/7/11 2:00', '2009/7/11 3:00', '2009/7/11 4:00', '2009/7/11 5:00', '2009/7/11 6:00', '2009/7/11 7:00', '2009/7/11 8:00', '2009/7/11 9:00', '2009/7/11 10:00', '2009/7/11 11:00', '2009/7/11 12:00', '2009/7/11 13:00', '2009/7/11 14:00', '2009/7/11 15:00', '2009/7/11 16:00', '2009/7/11 17:00', '2009/7/11 18:00', '2009/7/11 19:00', '2009/7/11 20:00', '2009/7/11 21:00', '2009/7/11 22:00', '2009/7/11 23:00', '2009/7/12 0:00', '2009/7/12 1:00', '2009/7/12 2:00', '2009/7/12 3:00', '2009/7/12 4:00', '2009/7/12 5:00', '2009/7/12 6:00', '2009/7/12 7:00', '2009/7/12 8:00', '2009/7/12 9:00', '2009/7/12 10:00', '2009/7/12 11:00', '2009/7/12 12:00', '2009/7/12 13:00', '2009/7/12 14:00', '2009/7/12 15:00', '2009/7/12 16:00', '2009/7/12 17:00', '2009/7/12 18:00', '2009/7/12 19:00', '2009/7/12 20:00', '2009/7/12 21:00', '2009/7/12 22:00', '2009/7/12 23:00', '2009/7/13 0:00', '2009/7/13 1:00', '2009/7/13 2:00', '2009/7/13 3:00', '2009/7/13 4:00', '2009/7/13 5:00', '2009/7/13 6:00', '2009/7/13 7:00', '2009/7/13 8:00', '2009/7/13 9:00', '2009/7/13 10:00', '2009/7/13 11:00', '2009/7/13 12:00', '2009/7/13 13:00', '2009/7/13 14:00', '2009/7/13 15:00', '2009/7/13 16:00', '2009/7/13 17:00', '2009/7/13 18:00', '2009/7/13 19:00', '2009/7/13 20:00', '2009/7/13 21:00', '2009/7/13 22:00', '2009/7/13 23:00', '2009/7/14 0:00', '2009/7/14 1:00', '2009/7/14 2:00', '2009/7/14 3:00', '2009/7/14 4:00', '2009/7/14 5:00', '2009/7/14 6:00', '2009/7/14 7:00', '2009/7/14 8:00', '2009/7/14 9:00', '2009/7/14 10:00', '2009/7/14 11:00', '2009/7/14 12:00', '2009/7/14 13:00', '2009/7/14 14:00', '2009/7/14 15:00', '2009/7/14 16:00', '2009/7/14 17:00', '2009/7/14 18:00', '2009/7/14 19:00', '2009/7/14 20:00', '2009/7/14 21:00', '2009/7/14 22:00', '2009/7/14 23:00', '2009/7/15 0:00', '2009/7/15 1:00', '2009/7/15 2:00', '2009/7/15 3:00', '2009/7/15 4:00', '2009/7/15 5:00', '2009/7/15 6:00', '2009/7/15 7:00', '2009/7/15 8:00', '2009/7/15 9:00', '2009/7/15 10:00', '2009/7/15 11:00', '2009/7/15 12:00', '2009/7/15 13:00', '2009/7/15 14:00', '2009/7/15 15:00', '2009/7/15 16:00', '2009/7/15 17:00', '2009/7/15 18:00', '2009/7/15 19:00', '2009/7/15 20:00', '2009/7/15 21:00', '2009/7/15 22:00', '2009/7/15 23:00', '2009/7/16 0:00', '2009/7/16 1:00', '2009/7/16 2:00', '2009/7/16 3:00', '2009/7/16 4:00', '2009/7/16 5:00', '2009/7/16 6:00', '2009/7/16 7:00', '2009/7/16 8:00', '2009/7/16 9:00', '2009/7/16 10:00', '2009/7/16 11:00', '2009/7/16 12:00', '2009/7/16 13:00', '2009/7/16 14:00', '2009/7/16 15:00', '2009/7/16 16:00', '2009/7/16 17:00', '2009/7/16 18:00', '2009/7/16 19:00', '2009/7/16 20:00', '2009/7/16 21:00', '2009/7/16 22:00', '2009/7/16 23:00', '2009/7/17 0:00', '2009/7/17 1:00', '2009/7/17 2:00', '2009/7/17 3:00', '2009/7/17 4:00', '2009/7/17 5:00', '2009/7/17 6:00', '2009/7/17 7:00', '2009/7/17 8:00', '2009/7/17 9:00', '2009/7/17 10:00', '2009/7/17 11:00', '2009/7/17 12:00', '2009/7/17 13:00', '2009/7/17 14:00', '2009/7/17 15:00', '2009/7/17 16:00', '2009/7/17 17:00', '2009/7/17 18:00', '2009/7/17 19:00', '2009/7/17 20:00', '2009/7/17 21:00', '2009/7/17 22:00', '2009/7/17 23:00', '2009/7/18 0:00', '2009/7/18 1:00', '2009/7/18 2:00', '2009/7/18 3:00', '2009/7/18 4:00', '2009/7/18 5:00', '2009/7/18 6:00', '2009/7/18 7:00', '2009/7/18 8:00', '2009/7/18 9:00', '2009/7/18 10:00', '2009/7/18 11:00', '2009/7/18 12:00', '2009/7/18 13:00', '2009/7/18 14:00', '2009/7/18 15:00', '2009/7/18 16:00', '2009/7/18 17:00', '2009/7/18 18:00', '2009/7/18 19:00', '2009/7/18 20:00', '2009/7/18 21:00', '2009/7/18 22:00', '2009/7/18 23:00', '2009/7/19 0:00', '2009/7/19 1:00', '2009/7/19 2:00', '2009/7/19 3:00', '2009/7/19 4:00', '2009/7/19 5:00', '2009/7/19 6:00', '2009/7/19 7:00', '2009/7/19 8:00', '2009/7/19 9:00', '2009/7/19 10:00', '2009/7/19 11:00', '2009/7/19 12:00', '2009/7/19 13:00', '2009/7/19 14:00', '2009/7/19 15:00', '2009/7/19 16:00', '2009/7/19 17:00', '2009/7/19 18:00', '2009/7/19 19:00', '2009/7/19 20:00', '2009/7/19 21:00', '2009/7/19 22:00', '2009/7/19 23:00', '2009/7/20 0:00', '2009/7/20 1:00', '2009/7/20 2:00', '2009/7/20 3:00', '2009/7/20 4:00', '2009/7/20 5:00', '2009/7/20 6:00', '2009/7/20 7:00', '2009/7/20 8:00', '2009/7/20 9:00', '2009/7/20 10:00', '2009/7/20 11:00', '2009/7/20 12:00', '2009/7/20 13:00', '2009/7/20 14:00', '2009/7/20 15:00', '2009/7/20 16:00', '2009/7/20 17:00', '2009/7/20 18:00', '2009/7/20 19:00', '2009/7/20 20:00', '2009/7/20 21:00', '2009/7/20 22:00', '2009/7/20 23:00', '2009/7/21 0:00', '2009/7/21 1:00', '2009/7/21 2:00', '2009/7/21 3:00', '2009/7/21 4:00', '2009/7/21 5:00', '2009/7/21 6:00', '2009/7/21 7:00', '2009/7/21 8:00', '2009/7/21 9:00', '2009/7/21 10:00', '2009/7/21 11:00', '2009/7/21 12:00', '2009/7/21 13:00', '2009/7/21 14:00', '2009/7/21 15:00', '2009/7/21 16:00', '2009/7/21 17:00', '2009/7/21 18:00', '2009/7/21 19:00', '2009/7/21 20:00', '2009/7/21 21:00', '2009/7/21 22:00', '2009/7/21 23:00', '2009/7/22 0:00', '2009/7/22 1:00', '2009/7/22 2:00', '2009/7/22 3:00', '2009/7/22 4:00', '2009/7/22 5:00', '2009/7/22 6:00', '2009/7/22 7:00', '2009/7/22 8:00', '2009/7/22 9:00', '2009/7/22 10:00', '2009/7/22 11:00', '2009/7/22 12:00', '2009/7/22 13:00', '2009/7/22 14:00', '2009/7/22 15:00', '2009/7/22 16:00', '2009/7/22 17:00', '2009/7/22 18:00', '2009/7/22 19:00', '2009/7/22 20:00', '2009/7/22 21:00', '2009/7/22 22:00', '2009/7/22 23:00', '2009/7/23 0:00', '2009/7/23 1:00', '2009/7/23 2:00', '2009/7/23 3:00', '2009/7/23 4:00', '2009/7/23 5:00', '2009/7/23 6:00', '2009/7/23 7:00', '2009/7/23 8:00', '2009/7/23 9:00', '2009/7/23 10:00', '2009/7/23 11:00', '2009/7/23 12:00', '2009/7/23 13:00', '2009/7/23 14:00', '2009/7/23 15:00', '2009/7/23 16:00', '2009/7/23 17:00', '2009/7/23 18:00', '2009/7/23 19:00', '2009/7/23 20:00', '2009/7/23 21:00', '2009/7/23 22:00', '2009/7/23 23:00', '2009/7/24 0:00', '2009/7/24 1:00', '2009/7/24 2:00', '2009/7/24 3:00', '2009/7/24 4:00', '2009/7/24 5:00', '2009/7/24 6:00', '2009/7/24 7:00', '2009/7/24 8:00', '2009/7/24 9:00', '2009/7/24 10:00', '2009/7/24 11:00', '2009/7/24 12:00', '2009/7/24 13:00', '2009/7/24 14:00', '2009/7/24 15:00', '2009/7/24 16:00', '2009/7/24 17:00', '2009/7/24 18:00', '2009/7/24 19:00', '2009/7/24 20:00', '2009/7/24 21:00', '2009/7/24 22:00', '2009/7/24 23:00', '2009/7/25 0:00', '2009/7/25 1:00', '2009/7/25 2:00', '2009/7/25 3:00', '2009/7/25 4:00', '2009/7/25 5:00', '2009/7/25 6:00', '2009/7/25 7:00', '2009/7/25 8:00', '2009/7/25 9:00', '2009/7/25 10:00', '2009/7/25 11:00', '2009/7/25 12:00', '2009/7/25 13:00', '2009/7/25 14:00', '2009/7/25 15:00', '2009/7/25 16:00', '2009/7/25 17:00', '2009/7/25 18:00', '2009/7/25 19:00', '2009/7/25 20:00', '2009/7/25 21:00', '2009/7/25 22:00', '2009/7/25 23:00', '2009/7/26 0:00', '2009/7/26 1:00', '2009/7/26 2:00', '2009/7/26 3:00', '2009/7/26 4:00', '2009/7/26 5:00', '2009/7/26 6:00', '2009/7/26 7:00', '2009/7/26 8:00', '2009/7/26 9:00', '2009/7/26 10:00', '2009/7/26 11:00', '2009/7/26 12:00', '2009/7/26 13:00', '2009/7/26 14:00', '2009/7/26 15:00', '2009/7/26 16:00', '2009/7/26 17:00', '2009/7/26 18:00', '2009/7/26 19:00', '2009/7/26 20:00', '2009/7/26 21:00', '2009/7/26 22:00', '2009/7/26 23:00', '2009/7/27 0:00', '2009/7/27 1:00', '2009/7/27 2:00', '2009/7/27 3:00', '2009/7/27 4:00', '2009/7/27 5:00', '2009/7/27 6:00', '2009/7/27 7:00', '2009/7/27 8:00', '2009/7/27 9:00', '2009/7/27 10:00', '2009/7/27 11:00', '2009/7/27 12:00', '2009/7/27 13:00', '2009/7/27 14:00', '2009/7/27 15:00', '2009/7/27 16:00', '2009/7/27 17:00', '2009/7/27 18:00', '2009/7/27 19:00', '2009/7/27 20:00', '2009/7/27 21:00', '2009/7/27 22:00', '2009/7/27 23:00', '2009/7/28 0:00', '2009/7/28 1:00', '2009/7/28 2:00', '2009/7/28 3:00', '2009/7/28 4:00', '2009/7/28 5:00', '2009/7/28 6:00', '2009/7/28 7:00', '2009/7/28 8:00', '2009/7/28 9:00', '2009/7/28 10:00', '2009/7/28 11:00', '2009/7/28 12:00', '2009/7/28 13:00', '2009/7/28 14:00', '2009/7/28 15:00', '2009/7/28 16:00', '2009/7/28 17:00', '2009/7/28 18:00', '2009/7/28 19:00', '2009/7/28 20:00', '2009/7/28 21:00', '2009/7/28 22:00', '2009/7/28 23:00', '2009/7/29 0:00', '2009/7/29 1:00', '2009/7/29 2:00', '2009/7/29 3:00', '2009/7/29 4:00', '2009/7/29 5:00', '2009/7/29 6:00', '2009/7/29 7:00', '2009/7/29 8:00', '2009/7/29 9:00', '2009/7/29 10:00', '2009/7/29 11:00', '2009/7/29 12:00', '2009/7/29 13:00', '2009/7/29 14:00', '2009/7/29 15:00', '2009/7/29 16:00', '2009/7/29 17:00', '2009/7/29 18:00', '2009/7/29 19:00', '2009/7/29 20:00', '2009/7/29 21:00', '2009/7/29 22:00', '2009/7/29 23:00', '2009/7/30 0:00', '2009/7/30 1:00', '2009/7/30 2:00', '2009/7/30 3:00', '2009/7/30 4:00', '2009/7/30 5:00', '2009/7/30 6:00', '2009/7/30 7:00', '2009/7/30 8:00', '2009/7/30 9:00', '2009/7/30 10:00', '2009/7/30 11:00', '2009/7/30 12:00', '2009/7/30 13:00', '2009/7/30 14:00', '2009/7/30 15:00', '2009/7/30 16:00', '2009/7/30 17:00', '2009/7/30 18:00', '2009/7/30 19:00', '2009/7/30 20:00', '2009/7/30 21:00', '2009/7/30 22:00', '2009/7/30 23:00', '2009/7/31 0:00', '2009/7/31 1:00', '2009/7/31 2:00', '2009/7/31 3:00', '2009/7/31 4:00', '2009/7/31 5:00', '2009/7/31 6:00', '2009/7/31 7:00', '2009/7/31 8:00', '2009/7/31 9:00', '2009/7/31 10:00', '2009/7/31 11:00', '2009/7/31 12:00', '2009/7/31 13:00', '2009/7/31 14:00', '2009/7/31 15:00', '2009/7/31 16:00', '2009/7/31 17:00', '2009/7/31 18:00', '2009/7/31 19:00', '2009/7/31 20:00', '2009/7/31 21:00', '2009/7/31 22:00', '2009/7/31 23:00', '2009/8/1 0:00', '2009/8/1 1:00', '2009/8/1 2:00', '2009/8/1 3:00', '2009/8/1 4:00', '2009/8/1 5:00', '2009/8/1 6:00', '2009/8/1 7:00', '2009/8/1 8:00', '2009/8/1 9:00', '2009/8/1 10:00', '2009/8/1 11:00', '2009/8/1 12:00', '2009/8/1 13:00', '2009/8/1 14:00', '2009/8/1 15:00', '2009/8/1 16:00', '2009/8/1 17:00', '2009/8/1 18:00', '2009/8/1 19:00', '2009/8/1 20:00', '2009/8/1 21:00', '2009/8/1 22:00', '2009/8/1 23:00', '2009/8/2 0:00', '2009/8/2 1:00', '2009/8/2 2:00', '2009/8/2 3:00', '2009/8/2 4:00', '2009/8/2 5:00', '2009/8/2 6:00', '2009/8/2 7:00', '2009/8/2 8:00', '2009/8/2 9:00', '2009/8/2 10:00', '2009/8/2 11:00', '2009/8/2 12:00', '2009/8/2 13:00', '2009/8/2 14:00', '2009/8/2 15:00', '2009/8/2 16:00', '2009/8/2 17:00', '2009/8/2 18:00', '2009/8/2 19:00', '2009/8/2 20:00', '2009/8/2 21:00', '2009/8/2 22:00', '2009/8/2 23:00', '2009/8/3 0:00', '2009/8/3 1:00', '2009/8/3 2:00', '2009/8/3 3:00', '2009/8/3 4:00', '2009/8/3 5:00', '2009/8/3 6:00', '2009/8/3 7:00', '2009/8/3 8:00', '2009/8/3 9:00', '2009/8/3 10:00', '2009/8/3 11:00', '2009/8/3 12:00', '2009/8/3 13:00', '2009/8/3 14:00', '2009/8/3 15:00', '2009/8/3 16:00', '2009/8/3 17:00', '2009/8/3 18:00', '2009/8/3 19:00', '2009/8/3 20:00', '2009/8/3 21:00', '2009/8/3 22:00', '2009/8/3 23:00', '2009/8/4 0:00', '2009/8/4 1:00', '2009/8/4 2:00', '2009/8/4 3:00', '2009/8/4 4:00', '2009/8/4 5:00', '2009/8/4 6:00', '2009/8/4 7:00', '2009/8/4 8:00', '2009/8/4 9:00', '2009/8/4 10:00', '2009/8/4 11:00', '2009/8/4 12:00', '2009/8/4 13:00', '2009/8/4 14:00', '2009/8/4 15:00', '2009/8/4 16:00', '2009/8/4 17:00', '2009/8/4 18:00', '2009/8/4 19:00', '2009/8/4 20:00', '2009/8/4 21:00', '2009/8/4 22:00', '2009/8/4 23:00', '2009/8/5 0:00', '2009/8/5 1:00', '2009/8/5 2:00', '2009/8/5 3:00', '2009/8/5 4:00', '2009/8/5 5:00', '2009/8/5 6:00', '2009/8/5 7:00', '2009/8/5 8:00', '2009/8/5 9:00', '2009/8/5 10:00', '2009/8/5 11:00', '2009/8/5 12:00', '2009/8/5 13:00', '2009/8/5 14:00', '2009/8/5 15:00', '2009/8/5 16:00', '2009/8/5 17:00', '2009/8/5 18:00', '2009/8/5 19:00', '2009/8/5 20:00', '2009/8/5 21:00', '2009/8/5 22:00', '2009/8/5 23:00', '2009/8/6 0:00', '2009/8/6 1:00', '2009/8/6 2:00', '2009/8/6 3:00', '2009/8/6 4:00', '2009/8/6 5:00', '2009/8/6 6:00', '2009/8/6 7:00', '2009/8/6 8:00', '2009/8/6 9:00', '2009/8/6 10:00', '2009/8/6 11:00', '2009/8/6 12:00', '2009/8/6 13:00', '2009/8/6 14:00', '2009/8/6 15:00', '2009/8/6 16:00', '2009/8/6 17:00', '2009/8/6 18:00', '2009/8/6 19:00', '2009/8/6 20:00', '2009/8/6 21:00', '2009/8/6 22:00', '2009/8/6 23:00', '2009/8/7 0:00', '2009/8/7 1:00', '2009/8/7 2:00', '2009/8/7 3:00', '2009/8/7 4:00', '2009/8/7 5:00', '2009/8/7 6:00', '2009/8/7 7:00', '2009/8/7 8:00', '2009/8/7 9:00', '2009/8/7 10:00', '2009/8/7 11:00', '2009/8/7 12:00', '2009/8/7 13:00', '2009/8/7 14:00', '2009/8/7 15:00', '2009/8/7 16:00', '2009/8/7 17:00', '2009/8/7 18:00', '2009/8/7 19:00', '2009/8/7 20:00', '2009/8/7 21:00', '2009/8/7 22:00', '2009/8/7 23:00', '2009/8/8 0:00', '2009/8/8 1:00', '2009/8/8 2:00', '2009/8/8 3:00', '2009/8/8 4:00', '2009/8/8 5:00', '2009/8/8 6:00', '2009/8/8 7:00', '2009/8/8 8:00', '2009/8/8 9:00', '2009/8/8 10:00', '2009/8/8 11:00', '2009/8/8 12:00', '2009/8/8 13:00', '2009/8/8 14:00', '2009/8/8 15:00', '2009/8/8 16:00', '2009/8/8 17:00', '2009/8/8 18:00', '2009/8/8 19:00', '2009/8/8 20:00', '2009/8/8 21:00', '2009/8/8 22:00', '2009/8/8 23:00', '2009/8/9 0:00', '2009/8/9 1:00', '2009/8/9 2:00', '2009/8/9 3:00', '2009/8/9 4:00', '2009/8/9 5:00', '2009/8/9 6:00', '2009/8/9 7:00', '2009/8/9 8:00', '2009/8/9 9:00', '2009/8/9 10:00', '2009/8/9 11:00', '2009/8/9 12:00', '2009/8/9 13:00', '2009/8/9 14:00', '2009/8/9 15:00', '2009/8/9 16:00', '2009/8/9 17:00', '2009/8/9 18:00', '2009/8/9 19:00', '2009/8/9 20:00', '2009/8/9 21:00', '2009/8/9 22:00', '2009/8/9 23:00', '2009/8/10 0:00', '2009/8/10 1:00', '2009/8/10 2:00', '2009/8/10 3:00', '2009/8/10 4:00', '2009/8/10 5:00', '2009/8/10 6:00', '2009/8/10 7:00', '2009/8/10 8:00', '2009/8/10 9:00', '2009/8/10 10:00', '2009/8/10 11:00', '2009/8/10 12:00', '2009/8/10 13:00', '2009/8/10 14:00', '2009/8/10 15:00', '2009/8/10 16:00', '2009/8/10 17:00', '2009/8/10 18:00', '2009/8/10 19:00', '2009/8/10 20:00', '2009/8/10 21:00', '2009/8/10 22:00', '2009/8/10 23:00', '2009/8/11 0:00', '2009/8/11 1:00', '2009/8/11 2:00', '2009/8/11 3:00', '2009/8/11 4:00', '2009/8/11 5:00', '2009/8/11 6:00', '2009/8/11 7:00', '2009/8/11 8:00', '2009/8/11 9:00', '2009/8/11 10:00', '2009/8/11 11:00', '2009/8/11 12:00', '2009/8/11 13:00', '2009/8/11 14:00', '2009/8/11 15:00', '2009/8/11 16:00', '2009/8/11 17:00', '2009/8/11 18:00', '2009/8/11 19:00', '2009/8/11 20:00', '2009/8/11 21:00', '2009/8/11 22:00', '2009/8/11 23:00', '2009/8/12 0:00', '2009/8/12 1:00', '2009/8/12 2:00', '2009/8/12 3:00', '2009/8/12 4:00', '2009/8/12 5:00', '2009/8/12 6:00', '2009/8/12 7:00', '2009/8/12 8:00', '2009/8/12 9:00', '2009/8/12 10:00', '2009/8/12 11:00', '2009/8/12 12:00', '2009/8/12 13:00', '2009/8/12 14:00', '2009/8/12 15:00', '2009/8/12 16:00', '2009/8/12 17:00', '2009/8/12 18:00', '2009/8/12 19:00', '2009/8/12 20:00', '2009/8/12 21:00', '2009/8/12 22:00', '2009/8/12 23:00', '2009/8/13 0:00', '2009/8/13 1:00', '2009/8/13 2:00', '2009/8/13 3:00', '2009/8/13 4:00', '2009/8/13 5:00', '2009/8/13 6:00', '2009/8/13 7:00', '2009/8/13 8:00', '2009/8/13 9:00', '2009/8/13 10:00', '2009/8/13 11:00', '2009/8/13 12:00', '2009/8/13 13:00', '2009/8/13 14:00', '2009/8/13 15:00', '2009/8/13 16:00', '2009/8/13 17:00', '2009/8/13 18:00', '2009/8/13 19:00', '2009/8/13 20:00', '2009/8/13 21:00', '2009/8/13 22:00', '2009/8/13 23:00', '2009/8/14 0:00', '2009/8/14 1:00', '2009/8/14 2:00', '2009/8/14 3:00', '2009/8/14 4:00', '2009/8/14 5:00', '2009/8/14 6:00', '2009/8/14 7:00', '2009/8/14 8:00', '2009/8/14 9:00', '2009/8/14 10:00', '2009/8/14 11:00', '2009/8/14 12:00', '2009/8/14 13:00', '2009/8/14 14:00', '2009/8/14 15:00', '2009/8/14 16:00', '2009/8/14 17:00', '2009/8/14 18:00', '2009/8/14 19:00', '2009/8/14 20:00', '2009/8/14 21:00', '2009/8/14 22:00', '2009/8/14 23:00', '2009/8/15 0:00', '2009/8/15 1:00', '2009/8/15 2:00', '2009/8/15 3:00', '2009/8/15 4:00', '2009/8/15 5:00', '2009/8/15 6:00', '2009/8/15 7:00', '2009/8/15 8:00', '2009/8/15 9:00', '2009/8/15 10:00', '2009/8/15 11:00', '2009/8/15 12:00', '2009/8/15 13:00', '2009/8/15 14:00', '2009/8/15 15:00', '2009/8/15 16:00', '2009/8/15 17:00', '2009/8/15 18:00', '2009/8/15 19:00', '2009/8/15 20:00', '2009/8/15 21:00', '2009/8/15 22:00', '2009/8/15 23:00', '2009/8/16 0:00', '2009/8/16 1:00', '2009/8/16 2:00', '2009/8/16 3:00', '2009/8/16 4:00', '2009/8/16 5:00', '2009/8/16 6:00', '2009/8/16 7:00', '2009/8/16 8:00', '2009/8/16 9:00', '2009/8/16 10:00', '2009/8/16 11:00', '2009/8/16 12:00', '2009/8/16 13:00', '2009/8/16 14:00', '2009/8/16 15:00', '2009/8/16 16:00', '2009/8/16 17:00', '2009/8/16 18:00', '2009/8/16 19:00', '2009/8/16 20:00', '2009/8/16 21:00', '2009/8/16 22:00', '2009/8/16 23:00', '2009/8/17 0:00', '2009/8/17 1:00', '2009/8/17 2:00', '2009/8/17 3:00', '2009/8/17 4:00', '2009/8/17 5:00', '2009/8/17 6:00', '2009/8/17 7:00', '2009/8/17 8:00', '2009/8/17 9:00', '2009/8/17 10:00', '2009/8/17 11:00', '2009/8/17 12:00', '2009/8/17 13:00', '2009/8/17 14:00', '2009/8/17 15:00', '2009/8/17 16:00', '2009/8/17 17:00', '2009/8/17 18:00', '2009/8/17 19:00', '2009/8/17 20:00', '2009/8/17 21:00', '2009/8/17 22:00', '2009/8/17 23:00', '2009/8/18 0:00', '2009/8/18 1:00', '2009/8/18 2:00', '2009/8/18 3:00', '2009/8/18 4:00', '2009/8/18 5:00', '2009/8/18 6:00', '2009/8/18 7:00', '2009/8/18 8:00', '2009/8/18 9:00', '2009/8/18 10:00', '2009/8/18 11:00', '2009/8/18 12:00', '2009/8/18 13:00', '2009/8/18 14:00', '2009/8/18 15:00', '2009/8/18 16:00', '2009/8/18 17:00', '2009/8/18 18:00', '2009/8/18 19:00', '2009/8/18 20:00', '2009/8/18 21:00', '2009/8/18 22:00', '2009/8/18 23:00', '2009/8/19 0:00', '2009/8/19 1:00', '2009/8/19 2:00', '2009/8/19 3:00', '2009/8/19 4:00', '2009/8/19 5:00', '2009/8/19 6:00', '2009/8/19 7:00', '2009/8/19 8:00', '2009/8/19 9:00', '2009/8/19 10:00', '2009/8/19 11:00', '2009/8/19 12:00', '2009/8/19 13:00', '2009/8/19 14:00', '2009/8/19 15:00', '2009/8/19 16:00', '2009/8/19 17:00', '2009/8/19 18:00', '2009/8/19 19:00', '2009/8/19 20:00', '2009/8/19 21:00', '2009/8/19 22:00', '2009/8/19 23:00', '2009/8/20 0:00', '2009/8/20 1:00', '2009/8/20 2:00', '2009/8/20 3:00', '2009/8/20 4:00', '2009/8/20 5:00', '2009/8/20 6:00', '2009/8/20 7:00', '2009/8/20 8:00', '2009/8/20 9:00', '2009/8/20 10:00', '2009/8/20 11:00', '2009/8/20 12:00', '2009/8/20 13:00', '2009/8/20 14:00', '2009/8/20 15:00', '2009/8/20 16:00', '2009/8/20 17:00', '2009/8/20 18:00', '2009/8/20 19:00', '2009/8/20 20:00', '2009/8/20 21:00', '2009/8/20 22:00', '2009/8/20 23:00', '2009/8/21 0:00', '2009/8/21 1:00', '2009/8/21 2:00', '2009/8/21 3:00', '2009/8/21 4:00', '2009/8/21 5:00', '2009/8/21 6:00', '2009/8/21 7:00', '2009/8/21 8:00', '2009/8/21 9:00', '2009/8/21 10:00', '2009/8/21 11:00', '2009/8/21 12:00', '2009/8/21 13:00', '2009/8/21 14:00', '2009/8/21 15:00', '2009/8/21 16:00', '2009/8/21 17:00', '2009/8/21 18:00', '2009/8/21 19:00', '2009/8/21 20:00', '2009/8/21 21:00', '2009/8/21 22:00', '2009/8/21 23:00', '2009/8/22 0:00', '2009/8/22 1:00', '2009/8/22 2:00', '2009/8/22 3:00', '2009/8/22 4:00', '2009/8/22 5:00', '2009/8/22 6:00', '2009/8/22 7:00', '2009/8/22 8:00', '2009/8/22 9:00', '2009/8/22 10:00', '2009/8/22 11:00', '2009/8/22 12:00', '2009/8/22 13:00', '2009/8/22 14:00', '2009/8/22 15:00', '2009/8/22 16:00', '2009/8/22 17:00', '2009/8/22 18:00', '2009/8/22 19:00', '2009/8/22 20:00', '2009/8/22 21:00', '2009/8/22 22:00', '2009/8/22 23:00', '2009/8/23 0:00', '2009/8/23 1:00', '2009/8/23 2:00', '2009/8/23 3:00', '2009/8/23 4:00', '2009/8/23 5:00', '2009/8/23 6:00', '2009/8/23 7:00', '2009/8/23 8:00', '2009/8/23 9:00', '2009/8/23 10:00', '2009/8/23 11:00', '2009/8/23 12:00', '2009/8/23 13:00', '2009/8/23 14:00', '2009/8/23 15:00', '2009/8/23 16:00', '2009/8/23 17:00', '2009/8/23 18:00', '2009/8/23 19:00', '2009/8/23 20:00', '2009/8/23 21:00', '2009/8/23 22:00', '2009/8/23 23:00', '2009/8/24 0:00', '2009/8/24 1:00', '2009/8/24 2:00', '2009/8/24 3:00', '2009/8/24 4:00', '2009/8/24 5:00', '2009/8/24 6:00', '2009/8/24 7:00', '2009/8/24 8:00', '2009/8/24 9:00', '2009/8/24 10:00', '2009/8/24 11:00', '2009/8/24 12:00', '2009/8/24 13:00', '2009/8/24 14:00', '2009/8/24 15:00', '2009/8/24 16:00', '2009/8/24 17:00', '2009/8/24 18:00', '2009/8/24 19:00', '2009/8/24 20:00', '2009/8/24 21:00', '2009/8/24 22:00', '2009/8/24 23:00', '2009/8/25 0:00', '2009/8/25 1:00', '2009/8/25 2:00', '2009/8/25 3:00', '2009/8/25 4:00', '2009/8/25 5:00', '2009/8/25 6:00', '2009/8/25 7:00', '2009/8/25 8:00', '2009/8/25 9:00', '2009/8/25 10:00', '2009/8/25 11:00', '2009/8/25 12:00', '2009/8/25 13:00', '2009/8/25 14:00', '2009/8/25 15:00', '2009/8/25 16:00', '2009/8/25 17:00', '2009/8/25 18:00', '2009/8/25 19:00', '2009/8/25 20:00', '2009/8/25 21:00', '2009/8/25 22:00', '2009/8/25 23:00', '2009/8/26 0:00', '2009/8/26 1:00', '2009/8/26 2:00', '2009/8/26 3:00', '2009/8/26 4:00', '2009/8/26 5:00', '2009/8/26 6:00', '2009/8/26 7:00', '2009/8/26 8:00', '2009/8/26 9:00', '2009/8/26 10:00', '2009/8/26 11:00', '2009/8/26 12:00', '2009/8/26 13:00', '2009/8/26 14:00', '2009/8/26 15:00', '2009/8/26 16:00', '2009/8/26 17:00', '2009/8/26 18:00', '2009/8/26 19:00', '2009/8/26 20:00', '2009/8/26 21:00', '2009/8/26 22:00', '2009/8/26 23:00', '2009/8/27 0:00', '2009/8/27 1:00', '2009/8/27 2:00', '2009/8/27 3:00', '2009/8/27 4:00', '2009/8/27 5:00', '2009/8/27 6:00', '2009/8/27 7:00', '2009/8/27 8:00', '2009/8/27 9:00', '2009/8/27 10:00', '2009/8/27 11:00', '2009/8/27 12:00', '2009/8/27 13:00', '2009/8/27 14:00', '2009/8/27 15:00', '2009/8/27 16:00', '2009/8/27 17:00', '2009/8/27 18:00', '2009/8/27 19:00', '2009/8/27 20:00', '2009/8/27 21:00', '2009/8/27 22:00', '2009/8/27 23:00', '2009/8/28 0:00', '2009/8/28 1:00', '2009/8/28 2:00', '2009/8/28 3:00', '2009/8/28 4:00', '2009/8/28 5:00', '2009/8/28 6:00', '2009/8/28 7:00', '2009/8/28 8:00', '2009/8/28 9:00', '2009/8/28 10:00', '2009/8/28 11:00', '2009/8/28 12:00', '2009/8/28 13:00', '2009/8/28 14:00', '2009/8/28 15:00', '2009/8/28 16:00', '2009/8/28 17:00', '2009/8/28 18:00', '2009/8/28 19:00', '2009/8/28 20:00', '2009/8/28 21:00', '2009/8/28 22:00', '2009/8/28 23:00', '2009/8/29 0:00', '2009/8/29 1:00', '2009/8/29 2:00', '2009/8/29 3:00', '2009/8/29 4:00', '2009/8/29 5:00', '2009/8/29 6:00', '2009/8/29 7:00', '2009/8/29 8:00', '2009/8/29 9:00', '2009/8/29 10:00', '2009/8/29 11:00', '2009/8/29 12:00', '2009/8/29 13:00', '2009/8/29 14:00', '2009/8/29 15:00', '2009/8/29 16:00', '2009/8/29 17:00', '2009/8/29 18:00', '2009/8/29 19:00', '2009/8/29 20:00', '2009/8/29 21:00', '2009/8/29 22:00', '2009/8/29 23:00', '2009/8/30 0:00', '2009/8/30 1:00', '2009/8/30 2:00', '2009/8/30 3:00', '2009/8/30 4:00', '2009/8/30 5:00', '2009/8/30 6:00', '2009/8/30 7:00', '2009/8/30 8:00', '2009/8/30 9:00', '2009/8/30 10:00', '2009/8/30 11:00', '2009/8/30 12:00', '2009/8/30 13:00', '2009/8/30 14:00', '2009/8/30 15:00', '2009/8/30 16:00', '2009/8/30 17:00', '2009/8/30 18:00', '2009/8/30 19:00', '2009/8/30 20:00', '2009/8/30 21:00', '2009/8/30 22:00', '2009/8/30 23:00', '2009/8/31 0:00', '2009/8/31 1:00', '2009/8/31 2:00', '2009/8/31 3:00', '2009/8/31 4:00', '2009/8/31 5:00', '2009/8/31 6:00', '2009/8/31 7:00', '2009/8/31 8:00', '2009/8/31 9:00', '2009/8/31 10:00', '2009/8/31 11:00', '2009/8/31 12:00', '2009/8/31 13:00', '2009/8/31 14:00', '2009/8/31 15:00', '2009/8/31 16:00', '2009/8/31 17:00', '2009/8/31 18:00', '2009/8/31 19:00', '2009/8/31 20:00', '2009/8/31 21:00', '2009/8/31 22:00', '2009/8/31 23:00', '2009/9/1 0:00', '2009/9/1 1:00', '2009/9/1 2:00', '2009/9/1 3:00', '2009/9/1 4:00', '2009/9/1 5:00', '2009/9/1 6:00', '2009/9/1 7:00', '2009/9/1 8:00', '2009/9/1 9:00', '2009/9/1 10:00', '2009/9/1 11:00', '2009/9/1 12:00', '2009/9/1 13:00', '2009/9/1 14:00', '2009/9/1 15:00', '2009/9/1 16:00', '2009/9/1 17:00', '2009/9/1 18:00', '2009/9/1 19:00', '2009/9/1 20:00', '2009/9/1 21:00', '2009/9/1 22:00', '2009/9/1 23:00', '2009/9/2 0:00', '2009/9/2 1:00', '2009/9/2 2:00', '2009/9/2 3:00', '2009/9/2 4:00', '2009/9/2 5:00', '2009/9/2 6:00', '2009/9/2 7:00', '2009/9/2 8:00', '2009/9/2 9:00', '2009/9/2 10:00', '2009/9/2 11:00', '2009/9/2 12:00', '2009/9/2 13:00', '2009/9/2 14:00', '2009/9/2 15:00', '2009/9/2 16:00', '2009/9/2 17:00', '2009/9/2 18:00', '2009/9/2 19:00', '2009/9/2 20:00', '2009/9/2 21:00', '2009/9/2 22:00', '2009/9/2 23:00', '2009/9/3 0:00', '2009/9/3 1:00', '2009/9/3 2:00', '2009/9/3 3:00', '2009/9/3 4:00', '2009/9/3 5:00', '2009/9/3 6:00', '2009/9/3 7:00', '2009/9/3 8:00', '2009/9/3 9:00', '2009/9/3 10:00', '2009/9/3 11:00', '2009/9/3 12:00', '2009/9/3 13:00', '2009/9/3 14:00', '2009/9/3 15:00', '2009/9/3 16:00', '2009/9/3 17:00', '2009/9/3 18:00', '2009/9/3 19:00', '2009/9/3 20:00', '2009/9/3 21:00', '2009/9/3 22:00', '2009/9/3 23:00', '2009/9/4 0:00', '2009/9/4 1:00', '2009/9/4 2:00', '2009/9/4 3:00', '2009/9/4 4:00', '2009/9/4 5:00', '2009/9/4 6:00', '2009/9/4 7:00', '2009/9/4 8:00', '2009/9/4 9:00', '2009/9/4 10:00', '2009/9/4 11:00', '2009/9/4 12:00', '2009/9/4 13:00', '2009/9/4 14:00', '2009/9/4 15:00', '2009/9/4 16:00', '2009/9/4 17:00', '2009/9/4 18:00', '2009/9/4 19:00', '2009/9/4 20:00', '2009/9/4 21:00', '2009/9/4 22:00', '2009/9/4 23:00', '2009/9/5 0:00', '2009/9/5 1:00', '2009/9/5 2:00', '2009/9/5 3:00', '2009/9/5 4:00', '2009/9/5 5:00', '2009/9/5 6:00', '2009/9/5 7:00', '2009/9/5 8:00', '2009/9/5 9:00', '2009/9/5 10:00', '2009/9/5 11:00', '2009/9/5 12:00', '2009/9/5 13:00', '2009/9/5 14:00', '2009/9/5 15:00', '2009/9/5 16:00', '2009/9/5 17:00', '2009/9/5 18:00', '2009/9/5 19:00', '2009/9/5 20:00', '2009/9/5 21:00', '2009/9/5 22:00', '2009/9/5 23:00', '2009/9/6 0:00', '2009/9/6 1:00', '2009/9/6 2:00', '2009/9/6 3:00', '2009/9/6 4:00', '2009/9/6 5:00', '2009/9/6 6:00', '2009/9/6 7:00', '2009/9/6 8:00', '2009/9/6 9:00', '2009/9/6 10:00', '2009/9/6 11:00', '2009/9/6 12:00', '2009/9/6 13:00', '2009/9/6 14:00', '2009/9/6 15:00', '2009/9/6 16:00', '2009/9/6 17:00', '2009/9/6 18:00', '2009/9/6 19:00', '2009/9/6 20:00', '2009/9/6 21:00', '2009/9/6 22:00', '2009/9/6 23:00', '2009/9/7 0:00', '2009/9/7 1:00', '2009/9/7 2:00', '2009/9/7 3:00', '2009/9/7 4:00', '2009/9/7 5:00', '2009/9/7 6:00', '2009/9/7 7:00', '2009/9/7 8:00', '2009/9/7 9:00', '2009/9/7 10:00', '2009/9/7 11:00', '2009/9/7 12:00', '2009/9/7 13:00', '2009/9/7 14:00', '2009/9/7 15:00', '2009/9/7 16:00', '2009/9/7 17:00', '2009/9/7 18:00', '2009/9/7 19:00', '2009/9/7 20:00', '2009/9/7 21:00', '2009/9/7 22:00', '2009/9/7 23:00', '2009/9/8 0:00', '2009/9/8 1:00', '2009/9/8 2:00', '2009/9/8 3:00', '2009/9/8 4:00', '2009/9/8 5:00', '2009/9/8 6:00', '2009/9/8 7:00', '2009/9/8 8:00', '2009/9/8 9:00', '2009/9/8 10:00', '2009/9/8 11:00', '2009/9/8 12:00', '2009/9/8 13:00', '2009/9/8 14:00', '2009/9/8 15:00', '2009/9/8 16:00', '2009/9/8 17:00', '2009/9/8 18:00', '2009/9/8 19:00', '2009/9/8 20:00', '2009/9/8 21:00', '2009/9/8 22:00', '2009/9/8 23:00', '2009/9/9 0:00', '2009/9/9 1:00', '2009/9/9 2:00', '2009/9/9 3:00', '2009/9/9 4:00', '2009/9/9 5:00', '2009/9/9 6:00', '2009/9/9 7:00', '2009/9/9 8:00', '2009/9/9 9:00', '2009/9/9 10:00', '2009/9/9 11:00', '2009/9/9 12:00', '2009/9/9 13:00', '2009/9/9 14:00', '2009/9/9 15:00', '2009/9/9 16:00', '2009/9/9 17:00', '2009/9/9 18:00', '2009/9/9 19:00', '2009/9/9 20:00', '2009/9/9 21:00', '2009/9/9 22:00', '2009/9/9 23:00', '2009/9/10 0:00', '2009/9/10 1:00', '2009/9/10 2:00', '2009/9/10 3:00', '2009/9/10 4:00', '2009/9/10 5:00', '2009/9/10 6:00', '2009/9/10 7:00', '2009/9/10 8:00', '2009/9/10 9:00', '2009/9/10 10:00', '2009/9/10 11:00', '2009/9/10 12:00', '2009/9/10 13:00', '2009/9/10 14:00', '2009/9/10 15:00', '2009/9/10 16:00', '2009/9/10 17:00', '2009/9/10 18:00', '2009/9/10 19:00', '2009/9/10 20:00', '2009/9/10 21:00', '2009/9/10 22:00', '2009/9/10 23:00', '2009/9/11 0:00', '2009/9/11 1:00', '2009/9/11 2:00', '2009/9/11 3:00', '2009/9/11 4:00', '2009/9/11 5:00', '2009/9/11 6:00', '2009/9/11 7:00', '2009/9/11 8:00', '2009/9/11 9:00', '2009/9/11 10:00', '2009/9/11 11:00', '2009/9/11 12:00', '2009/9/11 13:00', '2009/9/11 14:00', '2009/9/11 15:00', '2009/9/11 16:00', '2009/9/11 17:00', '2009/9/11 18:00', '2009/9/11 19:00', '2009/9/11 20:00', '2009/9/11 21:00', '2009/9/11 22:00', '2009/9/11 23:00', '2009/9/12 0:00', '2009/9/12 1:00', '2009/9/12 2:00', '2009/9/12 3:00', '2009/9/12 4:00', '2009/9/12 5:00', '2009/9/12 6:00', '2009/9/12 7:00', '2009/9/12 8:00', '2009/9/12 9:00', '2009/9/12 10:00', '2009/9/12 11:00', '2009/9/12 12:00', '2009/9/12 13:00', '2009/9/12 14:00', '2009/9/12 15:00', '2009/9/12 16:00', '2009/9/12 17:00', '2009/9/12 18:00', '2009/9/12 19:00', '2009/9/12 20:00', '2009/9/12 21:00', '2009/9/12 22:00', '2009/9/12 23:00', '2009/9/13 0:00', '2009/9/13 1:00', '2009/9/13 2:00', '2009/9/13 3:00', '2009/9/13 4:00', '2009/9/13 5:00', '2009/9/13 6:00', '2009/9/13 7:00', '2009/9/13 8:00', '2009/9/13 9:00', '2009/9/13 10:00', '2009/9/13 11:00', '2009/9/13 12:00', '2009/9/13 13:00', '2009/9/13 14:00', '2009/9/13 15:00', '2009/9/13 16:00', '2009/9/13 17:00', '2009/9/13 18:00', '2009/9/13 19:00', '2009/9/13 20:00', '2009/9/13 21:00', '2009/9/13 22:00', '2009/9/13 23:00', '2009/9/14 0:00', '2009/9/14 1:00', '2009/9/14 2:00', '2009/9/14 3:00', '2009/9/14 4:00', '2009/9/14 5:00', '2009/9/14 6:00', '2009/9/14 7:00', '2009/9/14 8:00', '2009/9/14 9:00', '2009/9/14 10:00', '2009/9/14 11:00', '2009/9/14 12:00', '2009/9/14 13:00', '2009/9/14 14:00', '2009/9/14 15:00', '2009/9/14 16:00', '2009/9/14 17:00', '2009/9/14 18:00', '2009/9/14 19:00', '2009/9/14 20:00', '2009/9/14 21:00', '2009/9/14 22:00', '2009/9/14 23:00', '2009/9/15 0:00', '2009/9/15 1:00', '2009/9/15 2:00', '2009/9/15 3:00', '2009/9/15 4:00', '2009/9/15 5:00', '2009/9/15 6:00', '2009/9/15 7:00', '2009/9/15 8:00', '2009/9/15 9:00', '2009/9/15 10:00', '2009/9/15 11:00', '2009/9/15 12:00', '2009/9/15 13:00', '2009/9/15 14:00', '2009/9/15 15:00', '2009/9/15 16:00', '2009/9/15 17:00', '2009/9/15 18:00', '2009/9/15 19:00', '2009/9/15 20:00', '2009/9/15 21:00', '2009/9/15 22:00', '2009/9/15 23:00', '2009/9/16 0:00', '2009/9/16 1:00', '2009/9/16 2:00', '2009/9/16 3:00', '2009/9/16 4:00', '2009/9/16 5:00', '2009/9/16 6:00', '2009/9/16 7:00', '2009/9/16 8:00', '2009/9/16 9:00', '2009/9/16 10:00', '2009/9/16 11:00', '2009/9/16 12:00', '2009/9/16 13:00', '2009/9/16 14:00', '2009/9/16 15:00', '2009/9/16 16:00', '2009/9/16 17:00', '2009/9/16 18:00', '2009/9/16 19:00', '2009/9/16 20:00', '2009/9/16 21:00', '2009/9/16 22:00', '2009/9/16 23:00', '2009/9/17 0:00', '2009/9/17 1:00', '2009/9/17 2:00', '2009/9/17 3:00', '2009/9/17 4:00', '2009/9/17 5:00', '2009/9/17 6:00', '2009/9/17 7:00', '2009/9/17 8:00', '2009/9/17 9:00', '2009/9/17 10:00', '2009/9/17 11:00', '2009/9/17 12:00', '2009/9/17 13:00', '2009/9/17 14:00', '2009/9/17 15:00', '2009/9/17 16:00', '2009/9/17 17:00', '2009/9/17 18:00', '2009/9/17 19:00', '2009/9/17 20:00', '2009/9/17 21:00', '2009/9/17 22:00', '2009/9/17 23:00', '2009/9/18 0:00', '2009/9/18 1:00', '2009/9/18 2:00', '2009/9/18 3:00', '2009/9/18 4:00', '2009/9/18 5:00', '2009/9/18 6:00', '2009/9/18 7:00', '2009/9/18 8:00', '2009/9/18 9:00', '2009/9/18 10:00', '2009/9/18 11:00', '2009/9/18 12:00', '2009/9/18 13:00', '2009/9/18 14:00', '2009/9/18 15:00', '2009/9/18 16:00', '2009/9/18 17:00', '2009/9/18 18:00', '2009/9/18 19:00', '2009/9/18 20:00', '2009/9/18 21:00', '2009/9/18 22:00', '2009/9/18 23:00', '2009/9/19 0:00', '2009/9/19 1:00', '2009/9/19 2:00', '2009/9/19 3:00', '2009/9/19 4:00', '2009/9/19 5:00', '2009/9/19 6:00', '2009/9/19 7:00', '2009/9/19 8:00', '2009/9/19 9:00', '2009/9/19 10:00', '2009/9/19 11:00', '2009/9/19 12:00', '2009/9/19 13:00', '2009/9/19 14:00', '2009/9/19 15:00', '2009/9/19 16:00', '2009/9/19 17:00', '2009/9/19 18:00', '2009/9/19 19:00', '2009/9/19 20:00', '2009/9/19 21:00', '2009/9/19 22:00', '2009/9/19 23:00', '2009/9/20 0:00', '2009/9/20 1:00', '2009/9/20 2:00', '2009/9/20 3:00', '2009/9/20 4:00', '2009/9/20 5:00', '2009/9/20 6:00', '2009/9/20 7:00', '2009/9/20 8:00', '2009/9/20 9:00', '2009/9/20 10:00', '2009/9/20 11:00', '2009/9/20 12:00', '2009/9/20 13:00', '2009/9/20 14:00', '2009/9/20 15:00', '2009/9/20 16:00', '2009/9/20 17:00', '2009/9/20 18:00', '2009/9/20 19:00', '2009/9/20 20:00', '2009/9/20 21:00', '2009/9/20 22:00', '2009/9/20 23:00', '2009/9/21 0:00', '2009/9/21 1:00', '2009/9/21 2:00', '2009/9/21 3:00', '2009/9/21 4:00', '2009/9/21 5:00', '2009/9/21 6:00', '2009/9/21 7:00', '2009/9/21 8:00', '2009/9/21 9:00', '2009/9/21 10:00', '2009/9/21 11:00', '2009/9/21 12:00', '2009/9/21 13:00', '2009/9/21 14:00', '2009/9/21 15:00', '2009/9/21 16:00', '2009/9/21 17:00', '2009/9/21 18:00', '2009/9/21 19:00', '2009/9/21 20:00', '2009/9/21 21:00', '2009/9/21 22:00', '2009/9/21 23:00', '2009/9/22 0:00', '2009/9/22 1:00', '2009/9/22 2:00', '2009/9/22 3:00', '2009/9/22 4:00', '2009/9/22 5:00', '2009/9/22 6:00', '2009/9/22 7:00', '2009/9/22 8:00', '2009/9/22 9:00', '2009/9/22 10:00', '2009/9/22 11:00', '2009/9/22 12:00', '2009/9/22 13:00', '2009/9/22 14:00', '2009/9/22 15:00', '2009/9/22 16:00', '2009/9/22 17:00', '2009/9/22 18:00', '2009/9/22 19:00', '2009/9/22 20:00', '2009/9/22 21:00', '2009/9/22 22:00', '2009/9/22 23:00', '2009/9/23 0:00', '2009/9/23 1:00', '2009/9/23 2:00', '2009/9/23 3:00', '2009/9/23 4:00', '2009/9/23 5:00', '2009/9/23 6:00', '2009/9/23 7:00', '2009/9/23 8:00', '2009/9/23 9:00', '2009/9/23 10:00', '2009/9/23 11:00', '2009/9/23 12:00', '2009/9/23 13:00', '2009/9/23 14:00', '2009/9/23 15:00', '2009/9/23 16:00', '2009/9/23 17:00', '2009/9/23 18:00', '2009/9/23 19:00', '2009/9/23 20:00', '2009/9/23 21:00', '2009/9/23 22:00', '2009/9/23 23:00', '2009/9/24 0:00', '2009/9/24 1:00', '2009/9/24 2:00', '2009/9/24 3:00', '2009/9/24 4:00', '2009/9/24 5:00', '2009/9/24 6:00', '2009/9/24 7:00', '2009/9/24 8:00', '2009/9/24 9:00', '2009/9/24 10:00', '2009/9/24 11:00', '2009/9/24 12:00', '2009/9/24 13:00', '2009/9/24 14:00', '2009/9/24 15:00', '2009/9/24 16:00', '2009/9/24 17:00', '2009/9/24 18:00', '2009/9/24 19:00', '2009/9/24 20:00', '2009/9/24 21:00', '2009/9/24 22:00', '2009/9/24 23:00', '2009/9/25 0:00', '2009/9/25 1:00', '2009/9/25 2:00', '2009/9/25 3:00', '2009/9/25 4:00', '2009/9/25 5:00', '2009/9/25 6:00', '2009/9/25 7:00', '2009/9/25 8:00', '2009/9/25 9:00', '2009/9/25 10:00', '2009/9/25 11:00', '2009/9/25 12:00', '2009/9/25 13:00', '2009/9/25 14:00', '2009/9/25 15:00', '2009/9/25 16:00', '2009/9/25 17:00', '2009/9/25 18:00', '2009/9/25 19:00', '2009/9/25 20:00', '2009/9/25 21:00', '2009/9/25 22:00', '2009/9/25 23:00', '2009/9/26 0:00', '2009/9/26 1:00', '2009/9/26 2:00', '2009/9/26 3:00', '2009/9/26 4:00', '2009/9/26 5:00', '2009/9/26 6:00', '2009/9/26 7:00', '2009/9/26 8:00', '2009/9/26 9:00', '2009/9/26 10:00', '2009/9/26 11:00', '2009/9/26 12:00', '2009/9/26 13:00', '2009/9/26 14:00', '2009/9/26 15:00', '2009/9/26 16:00', '2009/9/26 17:00', '2009/9/26 18:00', '2009/9/26 19:00', '2009/9/26 20:00', '2009/9/26 21:00', '2009/9/26 22:00', '2009/9/26 23:00', '2009/9/27 0:00', '2009/9/27 1:00', '2009/9/27 2:00', '2009/9/27 3:00', '2009/9/27 4:00', '2009/9/27 5:00', '2009/9/27 6:00', '2009/9/27 7:00', '2009/9/27 8:00', '2009/9/27 9:00', '2009/9/27 10:00', '2009/9/27 11:00', '2009/9/27 12:00', '2009/9/27 13:00', '2009/9/27 14:00', '2009/9/27 15:00', '2009/9/27 16:00', '2009/9/27 17:00', '2009/9/27 18:00', '2009/9/27 19:00', '2009/9/27 20:00', '2009/9/27 21:00', '2009/9/27 22:00', '2009/9/27 23:00', '2009/9/28 0:00', '2009/9/28 1:00', '2009/9/28 2:00', '2009/9/28 3:00', '2009/9/28 4:00', '2009/9/28 5:00', '2009/9/28 6:00', '2009/9/28 7:00', '2009/9/28 8:00', '2009/9/28 9:00', '2009/9/28 10:00', '2009/9/28 11:00', '2009/9/28 12:00', '2009/9/28 13:00', '2009/9/28 14:00', '2009/9/28 15:00', '2009/9/28 16:00', '2009/9/28 17:00', '2009/9/28 18:00', '2009/9/28 19:00', '2009/9/28 20:00', '2009/9/28 21:00', '2009/9/28 22:00', '2009/9/28 23:00', '2009/9/29 0:00', '2009/9/29 1:00', '2009/9/29 2:00', '2009/9/29 3:00', '2009/9/29 4:00', '2009/9/29 5:00', '2009/9/29 6:00', '2009/9/29 7:00', '2009/9/29 8:00', '2009/9/29 9:00', '2009/9/29 10:00', '2009/9/29 11:00', '2009/9/29 12:00', '2009/9/29 13:00', '2009/9/29 14:00', '2009/9/29 15:00', '2009/9/29 16:00', '2009/9/29 17:00', '2009/9/29 18:00', '2009/9/29 19:00', '2009/9/29 20:00', '2009/9/29 21:00', '2009/9/29 22:00', '2009/9/29 23:00', '2009/9/30 0:00', '2009/9/30 1:00', '2009/9/30 2:00', '2009/9/30 3:00', '2009/9/30 4:00', '2009/9/30 5:00', '2009/9/30 6:00', '2009/9/30 7:00', '2009/9/30 8:00', '2009/9/30 9:00', '2009/9/30 10:00', '2009/9/30 11:00', '2009/9/30 12:00', '2009/9/30 13:00', '2009/9/30 14:00', '2009/9/30 15:00', '2009/9/30 16:00', '2009/9/30 17:00', '2009/9/30 18:00', '2009/9/30 19:00', '2009/9/30 20:00', '2009/9/30 21:00', '2009/9/30 22:00', '2009/9/30 23:00', '2009/10/1 0:00', '2009/10/1 1:00', '2009/10/1 2:00', '2009/10/1 3:00', '2009/10/1 4:00', '2009/10/1 5:00', '2009/10/1 6:00', '2009/10/1 7:00', '2009/10/1 8:00', '2009/10/1 9:00', '2009/10/1 10:00', '2009/10/1 11:00', '2009/10/1 12:00', '2009/10/1 13:00', '2009/10/1 14:00', '2009/10/1 15:00', '2009/10/1 16:00', '2009/10/1 17:00', '2009/10/1 18:00', '2009/10/1 19:00', '2009/10/1 20:00', '2009/10/1 21:00', '2009/10/1 22:00', '2009/10/1 23:00', '2009/10/2 0:00', '2009/10/2 1:00', '2009/10/2 2:00', '2009/10/2 3:00', '2009/10/2 4:00', '2009/10/2 5:00', '2009/10/2 6:00', '2009/10/2 7:00', '2009/10/2 8:00', '2009/10/2 9:00', '2009/10/2 10:00', '2009/10/2 11:00', '2009/10/2 12:00', '2009/10/2 13:00', '2009/10/2 14:00', '2009/10/2 15:00', '2009/10/2 16:00', '2009/10/2 17:00', '2009/10/2 18:00', '2009/10/2 19:00', '2009/10/2 20:00', '2009/10/2 21:00', '2009/10/2 22:00', '2009/10/2 23:00', '2009/10/3 0:00', '2009/10/3 1:00', '2009/10/3 2:00', '2009/10/3 3:00', '2009/10/3 4:00', '2009/10/3 5:00', '2009/10/3 6:00', '2009/10/3 7:00', '2009/10/3 8:00', '2009/10/3 9:00', '2009/10/3 10:00', '2009/10/3 11:00', '2009/10/3 12:00', '2009/10/3 13:00', '2009/10/3 14:00', '2009/10/3 15:00', '2009/10/3 16:00', '2009/10/3 17:00', '2009/10/3 18:00', '2009/10/3 19:00', '2009/10/3 20:00', '2009/10/3 21:00', '2009/10/3 22:00', '2009/10/3 23:00', '2009/10/4 0:00', '2009/10/4 1:00', '2009/10/4 2:00', '2009/10/4 3:00', '2009/10/4 4:00', '2009/10/4 5:00', '2009/10/4 6:00', '2009/10/4 7:00', '2009/10/4 8:00', '2009/10/4 9:00', '2009/10/4 10:00', '2009/10/4 11:00', '2009/10/4 12:00', '2009/10/4 13:00', '2009/10/4 14:00', '2009/10/4 15:00', '2009/10/4 16:00', '2009/10/4 17:00', '2009/10/4 18:00', '2009/10/4 19:00', '2009/10/4 20:00', '2009/10/4 21:00', '2009/10/4 22:00', '2009/10/4 23:00', '2009/10/5 0:00', '2009/10/5 1:00', '2009/10/5 2:00', '2009/10/5 3:00', '2009/10/5 4:00', '2009/10/5 5:00', '2009/10/5 6:00', '2009/10/5 7:00', '2009/10/5 8:00', '2009/10/5 9:00', '2009/10/5 10:00', '2009/10/5 11:00', '2009/10/5 12:00', '2009/10/5 13:00', '2009/10/5 14:00', '2009/10/5 15:00', '2009/10/5 16:00', '2009/10/5 17:00', '2009/10/5 18:00', '2009/10/5 19:00', '2009/10/5 20:00', '2009/10/5 21:00', '2009/10/5 22:00', '2009/10/5 23:00', '2009/10/6 0:00', '2009/10/6 1:00', '2009/10/6 2:00', '2009/10/6 3:00', '2009/10/6 4:00', '2009/10/6 5:00', '2009/10/6 6:00', '2009/10/6 7:00', '2009/10/6 8:00', '2009/10/6 9:00', '2009/10/6 10:00', '2009/10/6 11:00', '2009/10/6 12:00', '2009/10/6 13:00', '2009/10/6 14:00', '2009/10/6 15:00', '2009/10/6 16:00', '2009/10/6 17:00', '2009/10/6 18:00', '2009/10/6 19:00', '2009/10/6 20:00', '2009/10/6 21:00', '2009/10/6 22:00', '2009/10/6 23:00', '2009/10/7 0:00', '2009/10/7 1:00', '2009/10/7 2:00', '2009/10/7 3:00', '2009/10/7 4:00', '2009/10/7 5:00', '2009/10/7 6:00', '2009/10/7 7:00', '2009/10/7 8:00', '2009/10/7 9:00', '2009/10/7 10:00', '2009/10/7 11:00', '2009/10/7 12:00', '2009/10/7 13:00', '2009/10/7 14:00', '2009/10/7 15:00', '2009/10/7 16:00', '2009/10/7 17:00', '2009/10/7 18:00', '2009/10/7 19:00', '2009/10/7 20:00', '2009/10/7 21:00', '2009/10/7 22:00', '2009/10/7 23:00', '2009/10/8 0:00', '2009/10/8 1:00', '2009/10/8 2:00', '2009/10/8 3:00', '2009/10/8 4:00', '2009/10/8 5:00', '2009/10/8 6:00', '2009/10/8 7:00', '2009/10/8 8:00', '2009/10/8 9:00', '2009/10/8 10:00', '2009/10/8 11:00', '2009/10/8 12:00', '2009/10/8 13:00', '2009/10/8 14:00', '2009/10/8 15:00', '2009/10/8 16:00', '2009/10/8 17:00', '2009/10/8 18:00', '2009/10/8 19:00', '2009/10/8 20:00', '2009/10/8 21:00', '2009/10/8 22:00', '2009/10/8 23:00', '2009/10/9 0:00', '2009/10/9 1:00', '2009/10/9 2:00', '2009/10/9 3:00', '2009/10/9 4:00', '2009/10/9 5:00', '2009/10/9 6:00', '2009/10/9 7:00', '2009/10/9 8:00', '2009/10/9 9:00', '2009/10/9 10:00', '2009/10/9 11:00', '2009/10/9 12:00', '2009/10/9 13:00', '2009/10/9 14:00', '2009/10/9 15:00', '2009/10/9 16:00', '2009/10/9 17:00', '2009/10/9 18:00', '2009/10/9 19:00', '2009/10/9 20:00', '2009/10/9 21:00', '2009/10/9 22:00', '2009/10/9 23:00', '2009/10/10 0:00', '2009/10/10 1:00', '2009/10/10 2:00', '2009/10/10 3:00', '2009/10/10 4:00', '2009/10/10 5:00', '2009/10/10 6:00', '2009/10/10 7:00', '2009/10/10 8:00', '2009/10/10 9:00', '2009/10/10 10:00', '2009/10/10 11:00', '2009/10/10 12:00', '2009/10/10 13:00', '2009/10/10 14:00', '2009/10/10 15:00', '2009/10/10 16:00', '2009/10/10 17:00', '2009/10/10 18:00', '2009/10/10 19:00', '2009/10/10 20:00', '2009/10/10 21:00', '2009/10/10 22:00', '2009/10/10 23:00', '2009/10/11 0:00', '2009/10/11 1:00', '2009/10/11 2:00', '2009/10/11 3:00', '2009/10/11 4:00', '2009/10/11 5:00', '2009/10/11 6:00', '2009/10/11 7:00', '2009/10/11 8:00', '2009/10/11 9:00', '2009/10/11 10:00', '2009/10/11 11:00', '2009/10/11 12:00', '2009/10/11 13:00', '2009/10/11 14:00', '2009/10/11 15:00', '2009/10/11 16:00', '2009/10/11 17:00', '2009/10/11 18:00', '2009/10/11 19:00', '2009/10/11 20:00', '2009/10/11 21:00', '2009/10/11 22:00', '2009/10/11 23:00', '2009/10/12 0:00', '2009/10/12 1:00', '2009/10/12 2:00', '2009/10/12 3:00', '2009/10/12 4:00', '2009/10/12 5:00', '2009/10/12 6:00', '2009/10/12 7:00', '2009/10/12 8:00', '2009/10/12 9:00', '2009/10/12 10:00', '2009/10/12 11:00', '2009/10/12 12:00', '2009/10/12 13:00', '2009/10/12 14:00', '2009/10/12 15:00', '2009/10/12 16:00', '2009/10/12 17:00', '2009/10/12 18:00', '2009/10/12 19:00', '2009/10/12 20:00', '2009/10/12 21:00', '2009/10/12 22:00', '2009/10/12 23:00', '2009/10/13 0:00', '2009/10/13 1:00', '2009/10/13 2:00', '2009/10/13 3:00', '2009/10/13 4:00', '2009/10/13 5:00', '2009/10/13 6:00', '2009/10/13 7:00', '2009/10/13 8:00', '2009/10/13 9:00', '2009/10/13 10:00', '2009/10/13 11:00', '2009/10/13 12:00', '2009/10/13 13:00', '2009/10/13 14:00', '2009/10/13 15:00', '2009/10/13 16:00', '2009/10/13 17:00', '2009/10/13 18:00', '2009/10/13 19:00', '2009/10/13 20:00', '2009/10/13 21:00', '2009/10/13 22:00', '2009/10/13 23:00', '2009/10/14 0:00', '2009/10/14 1:00', '2009/10/14 2:00', '2009/10/14 3:00', '2009/10/14 4:00', '2009/10/14 5:00', '2009/10/14 6:00', '2009/10/14 7:00', '2009/10/14 8:00', '2009/10/14 9:00', '2009/10/14 10:00', '2009/10/14 11:00', '2009/10/14 12:00', '2009/10/14 13:00', '2009/10/14 14:00', '2009/10/14 15:00', '2009/10/14 16:00', '2009/10/14 17:00', '2009/10/14 18:00', '2009/10/14 19:00', '2009/10/14 20:00', '2009/10/14 21:00', '2009/10/14 22:00', '2009/10/14 23:00', '2009/10/15 0:00', '2009/10/15 1:00', '2009/10/15 2:00', '2009/10/15 3:00', '2009/10/15 4:00', '2009/10/15 5:00', '2009/10/15 6:00', '2009/10/15 7:00', '2009/10/15 8:00', '2009/10/15 9:00', '2009/10/15 10:00', '2009/10/15 11:00', '2009/10/15 12:00', '2009/10/15 13:00', '2009/10/15 14:00', '2009/10/15 15:00', '2009/10/15 16:00', '2009/10/15 17:00', '2009/10/15 18:00', '2009/10/15 19:00', '2009/10/15 20:00', '2009/10/15 21:00', '2009/10/15 22:00', '2009/10/15 23:00', '2009/10/16 0:00', '2009/10/16 1:00', '2009/10/16 2:00', '2009/10/16 3:00', '2009/10/16 4:00', '2009/10/16 5:00', '2009/10/16 6:00', '2009/10/16 7:00', '2009/10/16 8:00', '2009/10/16 9:00', '2009/10/16 10:00', '2009/10/16 11:00', '2009/10/16 12:00', '2009/10/16 13:00', '2009/10/16 14:00', '2009/10/16 15:00', '2009/10/16 16:00', '2009/10/16 17:00', '2009/10/16 18:00', '2009/10/16 19:00', '2009/10/16 20:00', '2009/10/16 21:00', '2009/10/16 22:00', '2009/10/16 23:00', '2009/10/17 0:00', '2009/10/17 1:00', '2009/10/17 2:00', '2009/10/17 3:00', '2009/10/17 4:00', '2009/10/17 5:00', '2009/10/17 6:00', '2009/10/17 7:00', '2009/10/17 8:00', '2009/10/17 9:00', '2009/10/17 10:00', '2009/10/17 11:00', '2009/10/17 12:00', '2009/10/17 13:00', '2009/10/17 14:00', '2009/10/17 15:00', '2009/10/17 16:00', '2009/10/17 17:00', '2009/10/17 18:00', '2009/10/17 19:00', '2009/10/17 20:00', '2009/10/17 21:00', '2009/10/17 22:00', '2009/10/17 23:00', '2009/10/18 0:00', '2009/10/18 1:00', '2009/10/18 2:00', '2009/10/18 3:00', '2009/10/18 4:00', '2009/10/18 5:00', '2009/10/18 6:00', '2009/10/18 7:00', '2009/10/18 8:00' + ].map(function (str) { + return str.replace(' ', '\n'); + }) + } + ], + yAxis: [ + { + name: 'Flow(m³/s)', + type: 'value' + }, + { + name: 'Rainfall(mm)', + nameLocation: 'start', + alignTicks: true, + type: 'value', + inverse: true + } + ], + series: [ + { + name: 'Flow', + type: 'line', + areaStyle: {}, + lineStyle: { + width: 1 + }, + emphasis: { + focus: 'series' + }, + markArea: { + silent: true, + itemStyle: { + opacity: 0.3 + }, + data: [ + [ + { + xAxis: '2009/9/12\n7:00' + }, + { + xAxis: '2009/9/22\n7:00' + } + ] + ] + }, + // prettier-ignore + data: [ + 0.97, 0.96, 0.96, 0.95, 0.95, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.93, 0.92, 0.91, 0.9, 0.89, 0.88, 0.87, 0.87, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.87, 0.88, 0.9, 0.93, 0.96, 0.99, 1.03, 1.06, 1.1, 1.14, 1.17, 1.2, 1.23, 1.26, 1.29, 1.33, 1.36, 1.4, 1.43, 1.45, 1.48, 1.49, 1.51, 1.51, 1.5, 1.49, 1.47, 1.44, 1.41, 1.37, 1.34, 1.3, 1.27, 1.24, 1.22, 1.2, 1.19, 1.18, 1.16, 1.15, 1.14, 1.13, 1.12, 1.11, 1.11, 1.1, 1.1, 1.1, 1.1, 1.1, 1.1, 1.1, 1.1, 1.1, 1.1, 1.1, 1.1, 1.1, 1.1, 1.1, 1.1, 1.1, 1.09, 1.09, 1.08, 1.07, 1.06, 1.05, 1.04, 1.03, 1.03, 1.02, 1.01, 1.01, 1, 0.99, 0.98, 0.97, 0.96, 0.96, 0.95, 0.95, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.93, 0.92, 0.91, 0.9, 0.89, 0.88, 0.87, 0.87, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.85, 0.84, 0.83, 0.82, 0.81, 0.8, 0.8, 0.79, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.77, 0.75, 0.73, 0.71, 0.68, 0.65, 0.63, 0.61, 0.59, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.57, 0.57, 0.57, 0.56, 0.55, 0.55, 0.54, 0.54, 0.53, 0.52, 0.52, 0.51, 0.51, 0.5, 0.5, 0.49, 0.48, 0.48, 0.47, 0.47, 0.47, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.52, 0.67, 0.9, 1.19, 1.52, 1.87, 2.22, 2.55, 2.84, 3.07, 3.22, 3.28, 3.28, 3.28, 3.28, 3.28, 3.28, 3.28, 3.28, 3.28, 3.28, 3.28, 3.28, 3.28, 3.24, 3.13, 2.97, 2.77, 2.54, 2.3, 2.05, 1.82, 1.62, 1.46, 1.35, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.3, 1.26, 1.21, 1.14, 1.06, 0.97, 0.89, 0.81, 0.74, 0.69, 0.65, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.63, 0.63, 0.62, 0.62, 0.61, 0.6, 0.59, 0.59, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.59, 0.61, 0.63, 0.65, 0.68, 0.71, 0.73, 0.75, 0.77, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.77, 0.75, 0.73, 0.71, 0.68, 0.65, 0.63, 0.61, 0.59, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.59, 0.59, 0.6, 0.61, 0.62, 0.62, 0.63, 0.63, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.65, 0.66, 0.68, 0.69, 0.71, 0.73, 0.74, 0.76, 0.77, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.79, 0.81, 0.82, 0.84, 0.86, 0.88, 0.9, 0.92, 0.93, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.93, 0.92, 0.91, 0.9, 0.89, 0.88, 0.87, 0.87, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.85, 0.84, 0.82, 0.8, 0.78, 0.76, 0.75, 0.73, 0.72, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.72, 0.73, 0.74, 0.76, 0.78, 0.79, 0.82, 0.84, 0.86, 0.89, 0.91, 0.94, 0.97, 1, 1.02, 1.05, 1.08, 1.11, 1.14, 1.17, 1.19, 1.22, 1.25, 1.27, 1.29, 1.31, 1.33, 1.35, 1.36, 1.38, 1.39, 1.39, 1.4, 1.4, 1.4, 1.39, 1.37, 1.35, 1.32, 1.29, 1.26, 1.22, 1.18, 1.14, 1.1, 1.05, 1.01, 0.97, 0.93, 0.89, 0.85, 0.82, 0.78, 0.76, 0.74, 0.72, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.72, 0.73, 0.74, 0.75, 0.77, 0.78, 0.8, 0.82, 0.84, 0.87, 0.89, 0.92, 0.94, 0.97, 0.99, 1.02, 1.05, 1.08, 1.1, 1.13, 1.16, 1.18, 1.21, 1.23, 1.26, 1.28, 1.3, 1.32, 1.34, 1.35, 1.37, 1.38, 1.39, 1.4, 1.41, 1.41, 1.42, 1.42, 1.43, 1.43, 1.43, 1.44, 1.44, 1.44, 1.44, 1.45, 1.45, 1.45, 1.46, 1.46, 1.46, 1.47, 1.47, 1.48, 1.48, 1.49, 1.5, 1.51, 1.54, 1.62, 1.73, 1.88, 2.05, 2.24, 2.45, 2.67, 2.89, 3.11, 3.31, 3.51, 3.69, 3.86, 4.03, 4.18, 4.33, 4.48, 4.62, 4.76, 4.89, 5.02, 5.16, 5.29, 5.43, 5.57, 5.71, 5.86, 6.02, 6.18, 6.36, 6.54, 6.73, 6.93, 7.15, 7.38, 7.62, 7.88, 8.16, 8.46, 8.77, 9.11, 9.46, 9.84, 10.24, 10.67, 11.12, 11.6, 12.3, 13.66, 16, 38.43, 82.21, 146.6, 218.7, 226, 225.23, 223.08, 219.78, 212, 199.82, 184.6, 168, 151.65, 137.21, 126.31, 119.94, 115.52, 112.06, 108.92, 105.44, 101, 94.56, 86.36, 77.67, 69.76, 63.9, 60.38, 57.41, 54.84, 52.57, 50.56, 48.71, 46.97, 45.25, 43.48, 41.6, 39.5, 37.19, 34.81, 32.46, 30.27, 28.36, 26.85, 25.86, 25.5, 25.5, 25.5, 25.5, 25.5, 25.5, 25.5, 25.5, 25.5, 25.5, 25.5, 25.5, 25.5, 25.27, 24.65, 23.7, 22.52, 21.17, 19.75, 18.33, 16.98, 15.8, 14.85, 14.23, 14, 14.02, 14.08, 14.17, 14.29, 14.44, 14.61, 14.8, 15.01, 15.23, 15.47, 15.71, 15.95, 16.19, 16.43, 16.67, 16.89, 17.1, 17.29, 17.46, 17.61, 17.73, 17.82, 17.88, 17.9, 17.63, 16.88, 15.75, 14.33, 12.71, 10.98, 9.23, 7.56, 6.05, 4.81, 3.92, 3.47, 3.28, 3.1, 2.93, 2.76, 2.61, 2.46, 2.32, 2.19, 2.07, 1.96, 1.85, 1.75, 1.66, 1.58, 1.51, 1.44, 1.39, 1.34, 1.29, 1.26, 1.23, 1.22, 1.2, 1.2, 1.2, 1.2, 1.2, 1.2, 1.21, 1.21, 1.21, 1.21, 1.22, 1.22, 1.22, 1.23, 1.23, 1.23, 1.24, 1.24, 1.25, 1.25, 1.25, 1.26, 1.26, 1.27, 1.27, 1.27, 1.28, 1.28, 1.28, 1.29, 1.29, 1.29, 1.29, 1.3, 1.3, 1.3, 1.3, 1.3, 1.3, 1.3, 1.3, 1.3, 1.3, 1.3, 1.29, 1.29, 1.29, 1.29, 1.28, 1.28, 1.28, 1.27, 1.27, 1.26, 1.25, 1.25, 1.24, 1.23, 1.23, 1.22, 1.21, 1.2, 1.16, 1.06, 0.95, 0.83, 0.74, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.7, 0.7, 0.7, 0.7, 0.7, 0.7, 0.7, 0.7, 0.7, 0.7, 0.7, 0.69, 0.69, 0.69, 0.69, 0.69, 0.69, 0.69, 0.69, 0.68, 0.68, 0.68, 0.68, 0.68, 0.68, 0.67, 0.67, 0.67, 0.67, 0.67, 0.67, 0.67, 0.66, 0.66, 0.66, 0.66, 0.66, 0.66, 0.66, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.65, 0.66, 0.68, 0.69, 0.71, 0.73, 0.74, 0.76, 0.77, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.8, 0.86, 0.95, 1.08, 1.25, 1.46, 1.7, 1.97, 2.28, 2.63, 3.01, 3.42, 3.87, 4.35, 4.86, 5.4, 5.98, 6.59, 7.92, 10.49, 14.04, 18.31, 23.04, 27.98, 32.87, 37.45, 41.46, 44.64, 46.74, 47.5, 46.86, 45.16, 42.77, 40.04, 37.33, 35, 32.74, 30.21, 27.7, 25.5, 23.9, 23.2, 23.06, 22.94, 22.84, 22.77, 22.72, 22.7, 22.8, 23.23, 23.95, 24.91, 26.04, 27.3, 28.76, 30.7, 33.39, 37.12, 42.15, 48.77, 65.22, 252.1, 257, 237.32, 221.19, 212, 208.67, 206.89, 205.2, 202.15, 189.82, 172, 165.3, 160.49, 156.8, 153.44, 149.62, 144.6, 138.27, 131, 123.11, 114.9, 106.69, 98.79, 91.5, 85.13, 80, 75.53, 71.03, 66.65, 62.54, 58.85, 55.73, 53.31, 51.75, 51.2, 56.53, 68.25, 80, 91.01, 102.03, 109, 112.37, 115.29, 117.68, 119.48, 120.61, 121, 119.45, 115.57, 110.52, 105.47, 101.58, 100, 99.97, 99.94, 99.92, 99.9, 99.88, 99.86, 99.85, 99.84, 99.83, 99.82, 99.81, 99.81, 99.8, 99.8, 99.8, 122.15, 163.65, 186, 182.96, 175.15, 164.56, 153.18, 143, 136, 131.37, 126.98, 122.81, 118.85, 115.09, 111.52, 108.13, 104.9, 101.83, 98.9, 96.11, 93.44, 90.87, 88.41, 86.04, 83.74, 81.51, 79.33, 77.2, 75.1, 73.02, 70.95, 68.88, 66.8, 64.87, 63.14, 61.4, 59.53, 57.67, 56, 54.6, 53.36, 52.2, 51.05, 49.85, 48.5, 46.87, 44.92, 42.74, 40.42, 38.04, 35.69, 33.46, 31.44, 29.72, 28.38, 27.51, 27.2, 27.2, 27.2, 27.2, 27.2, 27.2, 27.2, 27.2, 27.2, 27.2, 27.2, 27.2, 27.2, 27.14, 26.97, 26.7, 26.35, 25.95, 25.49, 25.02, 24.53, 24.04, 23.58, 23.16, 22.8, 22.46, 22.11, 21.75, 21.39, 21.03, 20.69, 20.36, 20.05, 19.78, 19.54, 19.35, 19.2, 19.09, 19, 18.92, 18.85, 18.79, 18.74, 18.68, 18.62, 18.56, 18.49, 18.4, 18.3, 18.17, 18.02, 17.83, 17.63, 17.41, 17.18, 16.93, 16.68, 16.43, 16.18, 15.93, 15.7, 15.47, 15.22, 14.97, 14.71, 14.45, 14.18, 13.93, 13.68, 13.44, 13.21, 13, 12.8, 12.62, 12.46, 12.31, 12.16, 12.03, 11.89, 11.76, 11.62, 11.48, 11.33, 11.17, 11, 10.81, 10.59, 10.36, 10.12, 9.86, 9.61, 9.36, 9.12, 8.89, 8.68, 8.5, 8.35, 8.21, 8.08, 7.94, 7.81, 7.68, 7.56, 7.46, 7.36, 7.29, 7.23, 7.19, 7.18, 7.51, 8.42, 9.81, 11.58, 13.63, 15.86, 18.16, 20.44, 22.58, 24.49, 26.06, 27.2, 28.08, 28.95, 29.81, 30.65, 31.48, 32.28, 33.07, 33.82, 34.55, 35.25, 35.92, 36.56, 37.15, 37.71, 38.23, 38.7, 39.13, 39.5, 39.83, 40.1, 40.31, 40.47, 40.57, 40.6, 40.49, 40.16, 39.64, 38.94, 38.09, 37.1, 36, 34.79, 33.51, 32.17, 30.79, 29.39, 27.99, 26.6, 25.25, 23.96, 22.75, 21.63, 20.63, 19.76, 19.04, 18.49, 18.14, 18, 17.97, 17.95, 17.94, 17.92, 17.91, 17.9, 17.89, 17.88, 17.87, 17.85, 17.83, 17.8, 17.7, 17.46, 17.13, 16.7, 16.21, 15.68, 15.13, 14.57, 14.04, 13.56, 13.14, 12.8, 12.52, 12.27, 12.02, 11.79, 11.57, 11.37, 11.16, 10.97, 10.78, 10.59, 10.39, 10.2, 10.01, 9.81, 9.63, 9.44, 9.26, 9.08, 8.9, 8.73, 8.56, 8.39, 8.22, 8.06, 7.9, 7.73, 7.57, 7.41, 7.25, 7.09, 6.94, 6.79, 6.65, 6.52, 6.4, 6.28, 6.17, 6.08, 5.98, 5.9, 5.81, 5.73, 5.65, 5.57, 5.49, 5.41, 5.32, 5.23, 5.14, 5.04, 4.94, 4.84, 4.74, 4.63, 4.53, 4.43, 4.33, 4.23, 4.13, 4.03, 3.93, 3.81, 3.69, 3.57, 3.45, 3.33, 3.22, 3.12, 3.04, 2.98, 2.93, 2.92, 2.92, 2.92, 2.92, 2.92, 2.92, 2.92, 2.92, 2.92, 2.92, 2.92, 2.92, 2.92, 2.9, 2.86, 2.8, 2.71, 2.62, 2.52, 2.42, 2.33, 2.24, 2.18, 2.14, 2.12, 2.12, 2.12, 2.12, 2.12, 2.12, 2.12, 2.12, 2.12, 2.12, 2.12, 2.12, 2.12, 2.1, 2.06, 2, 1.91, 1.82, 1.71, 1.61, 1.5, 1.4, 1.32, 1.25, 1.2, 1.16, 1.13, 1.1, 1.06, 1.03, 1, 0.97, 0.93, 0.9, 0.87, 0.85, 0.82, 0.79, 0.77, 0.74, 0.72, 0.69, 0.67, 0.65, 0.63, 0.61, 0.59, 0.58, 0.56, 0.54, 0.53, 0.52, 0.51, 0.5, 0.49, 0.48, 0.48, 0.47, 0.47, 0.46, 0.46, 0.47, 0.48, 0.5, 0.53, 0.56, 0.59, 0.62, 0.64, 0.67, 0.69, 0.7, 0.71, 0.71, 0.71, 0.71, 0.7, 0.7, 0.7, 0.69, 0.69, 0.69, 0.68, 0.68, 0.67, 0.67, 0.67, 0.66, 0.66, 0.65, 0.65, 0.65, 0.65, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.65, 0.65, 0.65, 0.66, 0.66, 0.67, 0.68, 0.69, 0.69, 0.7, 0.71, 0.73, 0.74, 0.75, 0.76, 0.78, 0.8, 0.81, 0.83, 0.85, 0.87, 0.89, 0.92, 0.94, 0.97, 0.99, 1.02, 1.05, 1.08, 1.11, 1.15, 1.18, 1.32, 1.66, 2.21, 2.97, 3.94, 5.11, 6.5, 8.1, 9.9, 11.92, 14.15, 16.6, 22.3, 22.8, 24.48, 30.38, 35.74, 42.4, 57.14, 94.04, 112.9, 123.4, 130.4, 130, 119.4, 120.7, 116.8, 118.1, 119.4, 124.8, 143.5, 204, 294, 319.2, 328.4, 365, 350.8, 347.6, 347.6, 325, 331.6, 319.2, 308, 308, 308, 308, 296.8, 300, 281, 278.4, 270.6, 271, 253.6, 233.5, 219.2, 207.8, 205.9, 204, 189.6, 178.8, 173.4, 160, 154.4, 146, 145, 140.5, 130.4, 126.2, 116.8, 112.9, 106.5, 101.6, 98.51, 82.67, 67.3, 80.05, 76.12, 72.3, 71.02, 69.78, 67.3, 67.3, 68.54, 57.6, 71.02, 66.06, 59.12, 57.14, 55.16, 55.16, 52.19, 52.19, 51.2, 48.56, 44.16, 43, 45.92, 49.44, 44.16, 36.48, 35.74, 35, 32.36, 37.22, 32.36, 32.36, 32.36, 33.68, 32.36, 31.7, 35.74, 29.72, 32.36, 30.38, 29.72, 28.4, 28.4, 28.4, 27.28, 25.6, 25.04, 23.92, 22.3, 21.8, 21.8, 21.8, 22.8, 21.8, 25.6, 22.8, 22.8, 17.8, 16.04, 16.04, 16.04, 16.04, 16.04, 16.04, 16.04, 16.04, 16.04, 16.04, 15.02, 14, 14.03, 14.11, 14.25, 14.45, 14.72, 15.06, 15.46, 15.95, 16.51, 17.15, 17.87, 18.69, 19.59, 20.59, 21.69, 22.88, 24.18, 25.59, 27.1, 28.73, 30.48, 32.34, 34.33, 36.44, 38.69, 41.06, 43.57, 46.22, 49.01, 51.95, 55.04, 58.27, 61.66, 65.21, 68.92, 72.8, 88.09, 104.9, 105.7, 110.3, 111.6, 110.3, 106.5, 105.7, 103.3, 100, 97.02, 98.8, 91.07, 83.98, 88.09, 81.36, 78.74, 77.43, 77.43, 73.5, 74.81, 72.63, 68.58, 66.4, 68.54, 69.78, 67.3, 64.82, 61.1, 59.12, 56.15, 53.18, 50.32, 49.44, 44.16, 36.5, 42.4, 37.96, 37.22, 33.68, 36.48, 35.74, 35, 35, 37.22, 37.22, 39.44, 32.6, 34.54, 36.48, 35.74, 34.34, 33.68, 33.02, 31.04, 29.72, 29.72, 29.72, 26.16, 25.6, 29.72, 18.3, 22.3, 21.3, 21.8, 21.8, 20.3, 20.8, 25.04, 25.04, 25.6, 25.6, 25.04, 25.6, 25.04, 25.6, 23.92, 25.04, 21.3, 21.8, 22.3, 21.8, 20.8, 16.1, 20.3, 18.3, 13.22, 19.3, 19.3, 18.3, 14.4, 13.86, 13.36, 12.9, 12.48, 12.1, 11.75, 11.43, 11.15, 10.9, 10.67, 10.48, 10.31, 10.16, 10.04, 9.93, 9.85, 9.78, 9.73, 9.69, 9.67, 9.65, 9.65, 12.08, 8.67, 11.7, 11.38, 10.65, 9.84, 9.32, 9.07, 8.85, 8.66, 8.49, 8.35, 8.22, 8.1, 7.98, 7.86, 7.74, 7.61, 7.47, 7.31, 7.14, 6.96, 6.78, 6.58, 6.39, 6.19, 5.99, 5.78, 5.58, 5.39, 5.2, 5.01, 4.83, 4.67, 4.51, 4.37, 4.24, 4.12, 4.02, 3.95, 3.89, 3.85, 3.84, 4.41, 5.77, 7.39, 8.75, 9.32, 9.18, 9, 8.94, 8.88, 8.83, 8.78, 8.73, 8.68, 8.64, 8.6, 8.56, 8.53, 8.5, 8.47, 8.45, 8.42, 8.4, 8.39, 8.37, 8.36, 8.35, 8.35, 8.34, 8.34, 8.67, 9.65, 9.62, 9.53, 9.4, 9.21, 8.98, 8.7, 8.4, 8.06, 7.69, 7.3, 6.89, 6.47, 6.03, 5.59, 5.14, 4.7, 4.26, 3.83, 3.42, 3.02, 2.65, 2.3, 1.98, 1.7, 1.45, 1.25, 1.09, 0.99, 0.94, 0.92, 0.91, 0.89, 0.87, 0.85, 0.84, 0.82, 0.81, 0.79, 0.78, 0.77, 0.75, 0.74, 0.73, 0.72, 0.71, 0.7, 0.69, 0.68, 0.67, 0.66, 0.65, 0.64, 0.64, 0.63, 0.63, 0.62, 0.62, 0.61, 0.61, 0.61, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.61, 0.61, 0.61, 0.61, 0.61, 0.61, 0.62, 0.62, 0.62, 0.62, 0.63, 0.63, 0.63, 0.63, 0.63, 0.64, 0.64, 0.64, 0.64, 0.64, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.64, 0.63, 0.62, 0.6, 0.59, 0.57, 0.55, 0.54, 0.53, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.51, 0.51, 0.51, 0.5, 0.5, 0.49, 0.48, 0.47, 0.47, 0.46, 0.45, 0.45, 0.44, 0.43, 0.42, 0.42, 0.41, 0.41, 0.41, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.41, 0.42, 0.43, 0.44, 0.46, 0.48, 0.5, 0.53, 0.55, 0.58, 0.61, 0.64, 0.67, 0.7, 0.73, 0.77, 0.8, 0.83, 0.87, 0.9, 0.93, 0.96, 0.99, 1.02, 1.05, 1.08, 1.1, 1.12, 1.14, 1.16, 1.17, 1.18, 1.19, 1.2, 1.2, 1.2, 1.19, 1.17, 1.15, 1.12, 1.09, 1.06, 1.02, 0.98, 0.94, 0.9, 0.86, 0.82, 0.78, 0.74, 0.7, 0.66, 0.63, 0.6, 0.57, 0.55, 0.53, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.51, 0.51, 0.5, 0.5, 0.49, 0.49, 0.48, 0.47, 0.47, 0.47, 0.46, 0.46, 0.45, 0.45, 0.45, 0.44, 0.44, 0.44, 0.43, 0.43, 0.43, 0.42, 0.42, 0.42, 0.41, 0.41, 0.41, 0.41, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.41, 0.41, 0.41, 0.41, 0.41, 0.41, 0.41, 0.41, 0.41, 0.41, 0.41, 0.41, 0.41, 0.41, 0.41, 0.42, 0.42, 0.42, 0.42, 0.42, 0.42, 0.42, 0.42, 0.42, 0.43, 0.43, 0.43, 0.43, 0.43, 0.43, 0.44, 0.44, 0.44, 0.44, 0.44, 0.44, 0.45, 0.45, 0.45 + ] + }, + { + name: 'Rainfall', + type: 'line', + yAxisIndex: 1, + areaStyle: {}, + lineStyle: { + width: 1 + }, + emphasis: { + focus: 'series' + }, + markArea: { + silent: true, + itemStyle: { + opacity: 0.3 + }, + data: [ + [ + { + xAxis: '2009/9/10\n7:00' + }, + { + xAxis: '2009/9/20\n7:00' + } + ] + ] + }, + // prettier-ignore + data: [ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.005, 0.017, 0.017, 0.017, 0.017, 0.011, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.021, 0.026, 0.03, 0.036, 0.036, 0.195, 0.221, 0.019, 0.013, 0.017, 0.03, 0.03, 0.03, 0.046, 0.045, 0.038, 0.084, 0.045, 0.045, 0.037, 0.034, 0.035, 0.036, 0.044, 0.052, 0.048, 0.109, 0.033, 0.029, 0.04, 0.042, 0.042, 0.042, 0.073, 0.076, 0.062, 0.066, 0.066, 0.075, 0.096, 0.128, 0.121, 0.128, 0.14, 0.226, 0.143, 0.097, 0.018, 0, 0, 0, 0, 0, 0.018, 0.047, 0.054, 0.054, 0.054, 0.036, 0.185, 0.009, 0.038, 0.061, 0.077, 0.091, 0.126, 0.69, 0.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 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.018, 0.024, 0.024, 0.024, 0.024, 0.006, 0.003, 0.046, 0.046, 0.046, 0.046, 0.043, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.204, 0.303, 1.028, 1.328, 1.524, 1.41, 1.362, 1.292, 1.191, 0.529, 0.501, 0.944, 1.81, 2.899, 0.859, 0.126, 0.087, 0.047, 0, 0, 0, 0, 0.011, 0.028, 0.028, 0.028, 0.028, 0.017, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.099, 0.159, 0.297, 0.309, 0.309, 0.614, 0.818, 1.436, 1.195, 0.553, 0.542, 0.955, 0.898, 0.466, 0.386, 0.556, 0.388, 0.221, 0.192, 0.192, 0.187, 0.166, 0.18, 0.302, 0.158, 0.009, 0.009, 0.009, 0.009, 0.009, 0.007, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.004, 0.032, 0.032, 0.032, 0.032, 0.082, 0.149, 0.204, 0.247, 0.262, 0.49, 0.51, 0.533, 0.746, 0.847, 2.393, 1.188, 1.114, 0.475, 0.043, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.017, 0.017, 0.021, 0.042, 0.079, 0.111, 0.126, 0.122, 0.133, 0.846, 0.102, 0.077, 0.067, 0.056, 0.005, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.011, 0.017, 0.017, 0.017, 0.017, 0.006, 0, 0, 0, 0, 0, 0.01, 0.03, 0.054, 0.067, 0.07, 0.25, 0.251, 0.494, 0.065, 0.054, 0.054, 0.064, 0.084, 0.077, 0.101, 0.132, 0.248, 0.069, 0.117, 0.115, 0.087, 0.326, 0.036, 0.009, 0.009, 0.009, 0.009, 0.009, 0.004, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.02, 0.039, 0.04, 0.04, 0.04, 0.229, 0.079, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.023, 0.069, 0.082, 0.082, 0.082, 0.503, 0.774, 0.038, 0.012, 0.012, 0.012, 0.016, 0.02, 0.028, 0.051, 0.06, 0.064, 0.19, 0.15, 0.164, 0.139, 0.13, 0.085, 0.031, 0.023, 0.022, 0.007, 0.005, 0.005, 0.001, 0, 0.02, 0.048, 0.048, 0.053, 0.056, 0.036, 0.008, 0.008, 0.004, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.013, 0.017, 0.036, 0.068, 0.095, 0.233, 0.272, 0.377, 0.722, 1.494, 3.756, 0.954, 0.439, 0.442, 0.462, 0.373, 0.249, 0.214, 0.1, 0.044, 0.037, 0.023, 0.002, 0, 0, 0, 0, 0, 0, 0.02, 0.024, 0.024, 0.024, 0.024, 0.004, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.008, 0.017, 0.017, 0.045, 0.186, 0.308, 0.241, 0.241, 0.893, 4.067, 4.494, 5.015, 3.494, 2.057, 1.411, 0.718, 0.407, 0.313, 0.339, 1.537, 1.105, 0.218, 0.136, 0.03, 0.005, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.037, 0.448, 1.2, 1.309, 1.309, 1.425, 1.223, 0.471, 0.767, 0.423, 0.273, 0.412, 0.646, 0.481, 0.239, 0.131, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.044, 0.15, 0.223, 0.388, 0.513, 0.883, 2.828, 4.786, 5.959, 4.95, 6.434, 6.319, 3.35, 2.806, 4.204, 1.395, 1.015, 1.015, 0.836, 0.74, 0.72, 0.615, 0.477, 0.192, 0.046, 0.007, 0.007, 0.007, 0.007, 0.007, 0.007, 0.007, 0.008, 0.005, 0.005, 0.005, 0.005, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.001, 0.012, 0.012, 0.012, 0.012, 0.011, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.002, 0.012, 0.028, 0.028, 0.028, 0.138, 0.092, 0.082, 0.082, 0.096, 0.719, 0.155, 0.042, 0.047, 0.129, 0.021, 0.021, 0.014, 0.009, 0.029, 0.067, 0.088, 0.095, 0.095, 0.138, 0.091, 0.032, 0.025, 0.025, 0.003, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.002, 0.045, 0.228, 0.297, 0.325, 0.339, 0.581, 1.244, 0.796, 0.517, 0.227, 0.053, 0.006, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.003, 0.005, 0.005, 0.005, 0.005, 0.081, 0.129, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.014, 0.041, 0.041, 0.041, 0.041, 0.027, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.009, 0.017, 0.017, 0.017, 0.017, 0.355, 0.174, 0.009, 0.009, 0.012, 0.136, 0.208, 0.208, 0.208, 0.215, 7.359, 1.858, 0.458, 0.053, 0.053, 0.047, 0.045, 0.045, 0.059, 0.136, 0.188, 0.206, 0.21, 0.588, 1.517, 6.02, 4.688, 4.42, 0.624, 0.326, 0.359, 0.553, 0.899, 0.94, 2.95, 9.415, 5.752, 1.092, 0.096, 0.035, 0.026, 0.018, 0.015, 0.011, 0.011, 0.011, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.056, 0.27, 0.314, 0.351, 0.354, 0.609, 0.796, 1.857, 0.848, 0.538, 0.214, 0.178, 0.178, 0.201, 0.231, 0.227, 0.272, 0.397, 0.45, 1.014, 2.917, 1.675, 0.081, 0.059, 0.059, 0.148, 0.075, 0.075, 0.078, 0.236, 0.784, 0.784, 0.784, 0.784, 0.741, 0.115, 0.058, 0.058, 0.058, 0.029, 0.015, 0.015, 0.015, 0.015, 0.012, 0.008, 0.604, 0.985, 1.305, 2.273, 2.528, 2.336, 2.496, 2.281, 1.397, 1.713, 3.259, 1.167, 0.745, 0.548, 1.058, 0.684, 0.728, 0.392, 0.179, 0.283, 0.283, 0.46, 0.08, 0.099, 0.099, 0.099, 0.1, 0.143, 0.137, 0.238, 0.317, 0.262, 0.225, 0.792, 0.426, 0.332, 0.261, 0.11, 0.093, 0.102, 0.171, 0.292, 0.504, 0.605, 1.745, 2.485, 1.964, 0.33, 0.171, 0.259, 0.242, 0.215, 0.366, 0.354, 0.205, 0.203, 0.262, 0.153, 0.13, 0.137, 0.362, 0.691, 0.295, 0.433, 0.154, 0.056, 0.053, 0.053, 0.053, 0.051, 0.047, 0.065, 0.078, 0.091, 0.206, 0.813, 0.102, 0.151, 0.05, 0.024, 0.004, 0.001, 0, 0, 0, 0.021, 0.021, 0.021, 0.021, 0.021, 0.013, 0.013, 0.013, 0.013, 0.013, 0.013, 0.013, 0.013, 0.01, 0.01, 0.01, 0.01, 0.01, 0.01, 0.01, 0.01, 0.01, 0.01, 0.008, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.018, 0.021, 0.021, 0.021, 0.021, 0.003, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.024, 0.173, 0.261, 0.267, 0.267, 0.534, 1.354, 1.772, 0.72, 0.218, 0.018, 0.018, 0.028, 0.036, 0.032, 0.194, 0.082, 0.035, 0.286, 0.027, 0.038, 0.038, 0.027, 0.021, 0.014, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.016, 0.017, 0.017, 0.031, 0.047, 0.043, 0.056, 0.104, 0.149, 0.179, 0.205, 0.328, 0.998, 0.522, 1.851, 3.727, 3.273, 2.204, 1.169, 1.006, 1.179, 0.74, 0.741, 1.065, 0.925, 0.671, 0.497, 0.431, 0.327, 0.277, 0.126, 0.581, 0.207, 0.359, 2.485, 0.038, 0.036, 0.003, 0.003, 0.003, 0.003, 0.004, 0.098, 0.023, 0.021, 0.021, 0.022, 0.041, 0.041, 0.043, 0.045, 0.043, 0.014, 0.014, 0.014, 0.014, 0.014, 0.014, 0.014, 0.031, 0.046, 0.063, 0.119, 0.107, 0.092, 0.085, 0.065, 0.06, 0.054, 0.042, 0.039, 0.046, 0.044, 0.028, 0.028, 0.02, 0.013, 0.013, 0.013, 0.013, 0.016, 0.032, 0.031, 0.031, 0.031, 0.028, 0.011, 0.011, 0.011, 0.011, 0.011, 0.023, 0.024, 0.024, 0.024, 0.019, 0.015, 0.015, 0.015, 0.015, 0.015, 0.015, 0.013, 0.01, 0.01, 0.01, 0.01, 0.01, 0.01, 0.01, 0.01, 0.01, 0.01, 0.001, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.011, 0.017, 0.024, 0.026, 0.061, 0.172, 0.206, 0.213, 0.267, 0.511, 0.668, 0.157, 0.017, 0.017, 0.017, 0.046, 0.054, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.001, 0.017, 0.017, 0.017, 0.017, 0.016, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.01, 0.017, 0.017, 0.017, 0.017, 0.012, 0.017, 0.017, 0.017, 0.017, 0.012, 0, 0, 0, 0, 0, 0.003, 0.031, 0.066, 0.093, 0.112, 0.122, 0.202, 0.068, 0.041, 0.022, 0.011, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.002, 0.005, 0.012, 0.021, 0.021, 0.019, 0.033, 0.03, 0.026, 0.026, 0.034, 0.095, 0.024, 0.024, 0.024, 0.023, 0.019, 0.018, 0.018, 0.018, 0.011, 0.03, 0.045, 0.044, 0.044, 0.044, 0.022, 0.009, 0.024, 0.033, 0.033, 0.033, 0.024, 0.009, 0, 0, 0, 0, 0, 0, 0.003, 0.017, 0.017, 0.017, 0.017, 0.014, 0, 0, 0, 0, 0, 0.032, 0.032, 0.032, 0.032, 0.032, 0.005, 0.008, 0.009, 0.014, 0.014, 0.009, 0.005, 0.004, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.007, 0.009, 0.009, 0.009, 0.009, 0.043, 0.063, 0.084, 0.098, 0.101, 0.213, 0.334, 0.383, 0.43, 0.448, 0.511, 0.801, 0.835, 1.642, 1.614, 1.496, 1.496, 1.476, 1.068, 0.481, 0.22, 0.119, 0.099, 0.07, 0.072, 0.063, 0.076, 0.14, 0.205, 0.28, 0.297, 0.3, 0.479, 0.877, 1.098, 1.611, 1.629, 1.686, 1.686, 1.631, 1.528, 1.862, 1.703, 1.531, 2.196, 0.395, 0.416, 0.453, 0.728, 0.917, 0.986, 1.17, 2.171, 3.011, 2.909, 3.301, 1.377, 0.778, 0.799, 0.947, 1.039, 0.879, 0.76, 1.372, 1.674, 1.674, 1.68, 1.823, 1.793, 1.162, 0.783, 0.216, 0.152, 0.152, 0.152, 0.049, 0, 0, 0, 0.117, 0.127, 0.127, 0.127, 0.127, 0.127, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.001, 0.072, 0.29, 0.438, 0.53, 0.557, 0.873, 1.039, 1.04, 0.208, 0.049, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.03, 0.039, 0.039, 0.039, 0.039, 0.098, 0.008, 0.007, 0.007, 0.007, 0.007, 0.007, 0.007, 0.007, 0.007, 0.007, 0.056, 0.062, 0.065, 0.065, 0.065, 0.047, 0.216, 0.256, 0.315, 0.4, 0.502, 0.449, 0.47, 0.571, 0.814, 1.153, 0.774, 0.202, 0.086, 0.075, 0.071, 0.032, 0.019, 0.003, 0.004, 0.004, 0.004, 0.004, 0.004, 0.004, 0.007, 0.072, 0.153, 0.256, 0.306, 0.404, 0.698, 0.733, 0.823, 0.715, 0.563, 0.404, 0.293, 0.217, 0.213, 0.202, 0.202, 0.294, 0.704, 0.797, 1.359, 1.101, 0.72, 0.514, 0.539, 0.434, 0.389, 0.387, 0.386, 0.375, 0.369, 0.319, 0.239, 0.183, 0.136, 0.062, 0.052, 0.096, 0.119, 0.119, 0.114, 0.127, 0.132, 0.139, 0.169, 0.191, 0.278, 0.254, 0.214, 0.237, 0.221, 0.143, 0.129, 0.125, 0.109, 0.1, 0.087, 0.06, 0.038, 0.029, 0.029, 0.028, 0.048, 0.053, 0.053, 0.111, 0.125, 0.102, 0.097, 0.097, 0.039, 0.02, 0.02, 0.02, 0.014, 0.004, 0.031, 0.043, 0.047, 0.052, 0.08, 0.144, 0.182, 0.176, 0.171, 0.149, 0.112, 0.025, 0, 0, 0, 0, 0, 0, 0, 0.016, 0.031, 0.031, 0.031, 0.031, 0.015, 0, 0, 0, 0, 0, 0.005, 0.005, 0.005, 0.005, 0.005, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.005, 0.005, 0.005, 0.005, 0.005, 0.001, 0, 0, 0 + ] + } + ] +}; +export {}; diff --git a/testdata/area-rainfall.js.svg b/testdata/area-rainfall.js.svg new file mode 100644 index 0000000..6d4ee80 --- /dev/null +++ b/testdata/area-rainfall.js.svg @@ -0,0 +1,168 @@ + + + + + + + + + + + + +Flow(m³/s) +Rainfall(mm) + + + + + + + + + + +0 +100 +200 +300 +400 +0 +1 +2 +3 +4 +2009/9/5 +10:00 +2009/9/8 +2:00 +2009/9/10 +18:00 +2009/9/13 +10:00 +2009/9/16 +2:00 +2009/9/18 +18:00 +2009/9/21 +10:00 +2009/9/24 +2:00 +2009/9/26 +18:00 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Flow + + +Rainfall + + + + + + + + + + + + + +Rainfall and Flow Relationship + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/area-simple.js b/testdata/area-simple.js new file mode 100644 index 0000000..016c4a2 --- /dev/null +++ b/testdata/area-simple.js @@ -0,0 +1,81 @@ +/* +title: Large scale area chart +titleCN: 大数据量面积图 +category: 'line, dataZoom' +difficulty: 4 +*/ +let base = +new Date(1968, 9, 3); +let oneDay = 24 * 3600 * 1000; +let date = []; +let data = [Math.random() * 300]; +for (let i = 1; i < 20000; i++) { + var now = new Date((base += oneDay)); + date.push([now.getFullYear(), now.getMonth() + 1, now.getDate()].join('/')); + data.push(Math.round((Math.random() - 0.5) * 20 + data[i - 1])); +} +option = { + tooltip: { + trigger: 'axis', + position: function (pt) { + return [pt[0], '10%']; + } + }, + title: { + left: 'center', + text: 'Large Area Chart' + }, + toolbox: { + feature: { + dataZoom: { + yAxisIndex: 'none' + }, + restore: {}, + saveAsImage: {} + } + }, + xAxis: { + type: 'category', + boundaryGap: false, + data: date + }, + yAxis: { + type: 'value', + boundaryGap: [0, '100%'] + }, + dataZoom: [ + { + type: 'inside', + start: 0, + end: 10 + }, + { + start: 0, + end: 10 + } + ], + series: [ + { + name: 'Fake Data', + type: 'line', + symbol: 'none', + sampling: 'lttb', + itemStyle: { + color: 'rgb(255, 70, 131)' + }, + areaStyle: { + color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [ + { + offset: 0, + color: 'rgb(255, 158, 68)' + }, + { + offset: 1, + color: 'rgb(255, 70, 131)' + } + ]) + }, + data: data + } + ] +}; +export {}; diff --git a/testdata/area-simple.js.svg b/testdata/area-simple.js.svg new file mode 100644 index 0000000..d78a003 --- /dev/null +++ b/testdata/area-simple.js.svg @@ -0,0 +1,108 @@ + + + + + + + + + + + + + + + + + + + + +-600 +-400 +-200 +0 +200 +400 +600 +800 +1968/10/4 +1969/5/24 +1970/1/11 +1970/8/31 +1971/4/20 +1971/12/8 +1972/7/27 +1973/3/16 +1973/11/3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Large Area Chart + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/area-stack-gradient.js b/testdata/area-stack-gradient.js new file mode 100644 index 0000000..7b220e3 --- /dev/null +++ b/testdata/area-stack-gradient.js @@ -0,0 +1,189 @@ +/* +title: Gradient Stacked Area Chart +titleCN: 渐变堆叠面积图 +category: line +difficulty: 2 +*/ +option = { + color: ['#80FFA5', '#00DDFF', '#37A2FF', '#FF0087', '#FFBF00'], + title: { + text: 'Gradient Stacked Area Chart' + }, + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'cross', + label: { + backgroundColor: '#6a7985' + } + } + }, + legend: { + data: ['Line 1', 'Line 2', 'Line 3', 'Line 4', 'Line 5'] + }, + toolbox: { + feature: { + saveAsImage: {} + } + }, + grid: { + left: '3%', + right: '4%', + bottom: '3%', + containLabel: true + }, + xAxis: [ + { + type: 'category', + boundaryGap: false, + data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'] + } + ], + yAxis: [ + { + type: 'value' + } + ], + series: [ + { + name: 'Line 1', + type: 'line', + stack: 'Total', + smooth: true, + lineStyle: { + width: 0 + }, + showSymbol: false, + areaStyle: { + opacity: 0.8, + color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [ + { + offset: 0, + color: 'rgb(128, 255, 165)' + }, + { + offset: 1, + color: 'rgb(1, 191, 236)' + } + ]) + }, + emphasis: { + focus: 'series' + }, + data: [140, 232, 101, 264, 90, 340, 250] + }, + { + name: 'Line 2', + type: 'line', + stack: 'Total', + smooth: true, + lineStyle: { + width: 0 + }, + showSymbol: false, + areaStyle: { + opacity: 0.8, + color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [ + { + offset: 0, + color: 'rgb(0, 221, 255)' + }, + { + offset: 1, + color: 'rgb(77, 119, 255)' + } + ]) + }, + emphasis: { + focus: 'series' + }, + data: [120, 282, 111, 234, 220, 340, 310] + }, + { + name: 'Line 3', + type: 'line', + stack: 'Total', + smooth: true, + lineStyle: { + width: 0 + }, + showSymbol: false, + areaStyle: { + opacity: 0.8, + color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [ + { + offset: 0, + color: 'rgb(55, 162, 255)' + }, + { + offset: 1, + color: 'rgb(116, 21, 219)' + } + ]) + }, + emphasis: { + focus: 'series' + }, + data: [320, 132, 201, 334, 190, 130, 220] + }, + { + name: 'Line 4', + type: 'line', + stack: 'Total', + smooth: true, + lineStyle: { + width: 0 + }, + showSymbol: false, + areaStyle: { + opacity: 0.8, + color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [ + { + offset: 0, + color: 'rgb(255, 0, 135)' + }, + { + offset: 1, + color: 'rgb(135, 0, 157)' + } + ]) + }, + emphasis: { + focus: 'series' + }, + data: [220, 402, 231, 134, 190, 230, 120] + }, + { + name: 'Line 5', + type: 'line', + stack: 'Total', + smooth: true, + lineStyle: { + width: 0 + }, + showSymbol: false, + label: { + show: true, + position: 'top' + }, + areaStyle: { + opacity: 0.8, + color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [ + { + offset: 0, + color: 'rgb(255, 191, 0)' + }, + { + offset: 1, + color: 'rgb(224, 62, 76)' + } + ]) + }, + emphasis: { + focus: 'series' + }, + data: [220, 302, 181, 234, 210, 290, 150] + } + ] +}; +export {}; diff --git a/testdata/area-stack-gradient.js.svg b/testdata/area-stack-gradient.js.svg new file mode 100644 index 0000000..0dd41dc --- /dev/null +++ b/testdata/area-stack-gradient.js.svg @@ -0,0 +1,176 @@ + + + + + + + + + + + + + + + + +0 +300 +600 +900 +1,200 +1,500 +Mon +Tue +Wed +Thu +Fri +Sat +Sun + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Line 1 + + +Line 2 + + +Line 3 + + +Line 4 + + +Line 5 + + + +Gradient Stacked Area Chart + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/area-stack.js b/testdata/area-stack.js new file mode 100644 index 0000000..313d701 --- /dev/null +++ b/testdata/area-stack.js @@ -0,0 +1,103 @@ +/* +title: Stacked Area Chart +titleCN: 堆叠面积图 +category: line +difficulty: 2 +*/ +option = { + title: { + text: 'Stacked Area Chart' + }, + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'cross', + label: { + backgroundColor: '#6a7985' + } + } + }, + legend: { + data: ['Email', 'Union Ads', 'Video Ads', 'Direct', 'Search Engine'] + }, + toolbox: { + feature: { + saveAsImage: {} + } + }, + grid: { + left: '3%', + right: '4%', + bottom: '3%', + containLabel: true + }, + xAxis: [ + { + type: 'category', + boundaryGap: false, + data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'] + } + ], + yAxis: [ + { + type: 'value' + } + ], + series: [ + { + name: 'Email', + type: 'line', + stack: 'Total', + areaStyle: {}, + emphasis: { + focus: 'series' + }, + data: [120, 132, 101, 134, 90, 230, 210] + }, + { + name: 'Union Ads', + type: 'line', + stack: 'Total', + areaStyle: {}, + emphasis: { + focus: 'series' + }, + data: [220, 182, 191, 234, 290, 330, 310] + }, + { + name: 'Video Ads', + type: 'line', + stack: 'Total', + areaStyle: {}, + emphasis: { + focus: 'series' + }, + data: [150, 232, 201, 154, 190, 330, 410] + }, + { + name: 'Direct', + type: 'line', + stack: 'Total', + areaStyle: {}, + emphasis: { + focus: 'series' + }, + data: [320, 332, 301, 334, 390, 330, 320] + }, + { + name: 'Search Engine', + type: 'line', + stack: 'Total', + label: { + show: true, + position: 'top' + }, + areaStyle: {}, + emphasis: { + focus: 'series' + }, + data: [820, 932, 901, 934, 1290, 1330, 1320] + } + ] +}; +export {}; diff --git a/testdata/area-stack.js.svg b/testdata/area-stack.js.svg new file mode 100644 index 0000000..96c43d0 --- /dev/null +++ b/testdata/area-stack.js.svg @@ -0,0 +1,200 @@ + + + + + + + + + + + + + + + + + +0 +500 +1,000 +1,500 +2,000 +2,500 +3,000 +Mon +Tue +Wed +Thu +Fri +Sat +Sun + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +820 +932 +901 +934 +1290 +1330 +1320 + + + +Email + + +Union Ads + + +Video Ads + + +Direct + + +Search Engine + + + +Stacked Area Chart + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/area-time-axis.js b/testdata/area-time-axis.js new file mode 100644 index 0000000..c3fa5fe --- /dev/null +++ b/testdata/area-time-axis.js @@ -0,0 +1,64 @@ +/* +title: Area Chart with Time Axis +titleCN: 时间轴折线图 +category: line +difficulty: 5 +*/ +let base = +new Date(1988, 9, 3); +let oneDay = 24 * 3600 * 1000; +let data = [[base, Math.random() * 300]]; +for (let i = 1; i < 20000; i++) { + let now = new Date((base += oneDay)); + data.push([+now, Math.round((Math.random() - 0.5) * 20 + data[i - 1][1])]); +} +option = { + tooltip: { + trigger: 'axis', + position: function (pt) { + return [pt[0], '10%']; + } + }, + title: { + left: 'center', + text: 'Large Ara Chart' + }, + toolbox: { + feature: { + dataZoom: { + yAxisIndex: 'none' + }, + restore: {}, + saveAsImage: {} + } + }, + xAxis: { + type: 'time', + boundaryGap: false + }, + yAxis: { + type: 'value', + boundaryGap: [0, '100%'] + }, + dataZoom: [ + { + type: 'inside', + start: 0, + end: 20 + }, + { + start: 0, + end: 20 + } + ], + series: [ + { + name: 'Fake Data', + type: 'line', + smooth: true, + symbol: 'none', + areaStyle: {}, + data: data + } + ] +}; +export {}; diff --git a/testdata/area-time-axis.js.svg b/testdata/area-time-axis.js.svg new file mode 100644 index 0000000..bcb1346 --- /dev/null +++ b/testdata/area-time-axis.js.svg @@ -0,0 +1,81 @@ + + + + + + + + + + + + + + + + +-300 +0 +300 +600 +900 +1,200 +1,500 +1,800 +1990 +1992 +1994 +1996 +1998 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Large Ara Chart + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/bar-animation-delay.js b/testdata/bar-animation-delay.js new file mode 100644 index 0000000..730e3be --- /dev/null +++ b/testdata/bar-animation-delay.js @@ -0,0 +1,71 @@ +"use strict"; +/* +title: Animation Delay +titleCN: 柱状图动画延迟 +category: bar +difficulty: 5 +*/ +var xAxisData = []; +var data1 = []; +var data2 = []; +for (var i = 0; i < 100; i++) { + xAxisData.push('A' + i); + data1.push((Math.sin(i / 5) * (i / 5 - 10) + i / 6) * 5); + data2.push((Math.cos(i / 5) * (i / 5 - 10) + i / 6) * 5); +} +option = { + title: { + text: 'Bar Animation Delay' + }, + legend: { + data: ['bar', 'bar2'] + }, + toolbox: { + // y: 'bottom', + feature: { + magicType: { + type: ['stack'] + }, + dataView: {}, + saveAsImage: { + pixelRatio: 2 + } + } + }, + tooltip: {}, + xAxis: { + data: xAxisData, + splitLine: { + show: false + } + }, + yAxis: {}, + series: [ + { + name: 'bar', + type: 'bar', + data: data1, + emphasis: { + focus: 'series' + }, + animationDelay: function (idx) { + return idx * 10; + } + }, + { + name: 'bar2', + type: 'bar', + data: data2, + emphasis: { + focus: 'series' + }, + animationDelay: function (idx) { + return idx * 10 + 100; + } + } + ], + animationEasing: 'elasticOut', + animationDelayUpdate: function (idx) { + return idx * 5; + } +}; diff --git a/testdata/bar-animation-delay.js.svg b/testdata/bar-animation-delay.js.svg new file mode 100644 index 0000000..b77ffff --- /dev/null +++ b/testdata/bar-animation-delay.js.svg @@ -0,0 +1,2465 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +-60 +-30 +0 +30 +60 +90 +120 +150 +A0 +A5 +A10 +A15 +A20 +A25 +A30 +A35 +A40 +A45 +A50 +A55 +A60 +A65 +A70 +A75 +A80 +A85 +A90 +A95 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +bar + +bar2 + + + + + +Bar Animation Delay + + \ No newline at end of file diff --git a/testdata/bar-background.js b/testdata/bar-background.js new file mode 100644 index 0000000..5c64c72 --- /dev/null +++ b/testdata/bar-background.js @@ -0,0 +1,26 @@ +/* +title: Bar with Background +category: bar +titleCN: 带背景色的柱状图 +difficulty: 1 +*/ +option = { + xAxis: { + type: 'category', + data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'] + }, + yAxis: { + type: 'value' + }, + series: [ + { + data: [120, 200, 150, 80, 70, 110, 130], + type: 'bar', + showBackground: true, + backgroundStyle: { + color: 'rgba(180, 180, 180, 0.2)' + } + } + ] +}; +export {}; diff --git a/testdata/bar-background.js.svg b/testdata/bar-background.js.svg new file mode 100644 index 0000000..36b41f1 --- /dev/null +++ b/testdata/bar-background.js.svg @@ -0,0 +1,124 @@ + + + + + + + + + + + + + + + + +0 +50 +100 +150 +200 +Mon +Tue +Wed +Thu +Fri +Sat +Sun + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/bar-brush.js b/testdata/bar-brush.js new file mode 100644 index 0000000..344ff1e --- /dev/null +++ b/testdata/bar-brush.js @@ -0,0 +1,106 @@ +/* +title: Brush Select on Column Chart +titleCN: 柱状图框选 +category: bar +difficulty: 4 +*/ +let xAxisData = []; +let data1 = []; +let data2 = []; +let data3 = []; +let data4 = []; +for (let i = 0; i < 10; i++) { + xAxisData.push('Class' + i); + data1.push(+(Math.random() * 2).toFixed(2)); + data2.push(+(Math.random() * 5).toFixed(2)); + data3.push(+(Math.random() + 0.3).toFixed(2)); + data4.push(+Math.random().toFixed(2)); +} +var emphasisStyle = { + itemStyle: { + shadowBlur: 10, + shadowColor: 'rgba(0,0,0,0.3)' + } +}; +option = { + legend: { + data: ['bar', 'bar2', 'bar3', 'bar4'], + left: '10%' + }, + brush: { + toolbox: ['rect', 'polygon', 'lineX', 'lineY', 'keep', 'clear'], + xAxisIndex: 0 + }, + toolbox: { + feature: { + magicType: { + type: ['stack'] + }, + dataView: {} + } + }, + tooltip: {}, + xAxis: { + data: xAxisData, + name: 'X Axis', + axisLine: { onZero: true }, + splitLine: { show: false }, + splitArea: { show: false } + }, + yAxis: {}, + grid: { + bottom: 100 + }, + series: [ + { + name: 'bar', + type: 'bar', + stack: 'one', + emphasis: emphasisStyle, + data: data1 + }, + { + name: 'bar2', + type: 'bar', + stack: 'one', + emphasis: emphasisStyle, + data: data2 + }, + { + name: 'bar3', + type: 'bar', + stack: 'two', + emphasis: emphasisStyle, + data: data3 + }, + { + name: 'bar4', + type: 'bar', + stack: 'two', + emphasis: emphasisStyle, + data: data4 + } + ] +}; +myChart.on('brushSelected', function (params) { + var brushed = []; + var brushComponent = params.batch[0]; + for (var sIdx = 0; sIdx < brushComponent.selected.length; sIdx++) { + var rawIndices = brushComponent.selected[sIdx].dataIndex; + brushed.push('[Series ' + sIdx + '] ' + rawIndices.join(', ')); + } + myChart.setOption({ + title: { + backgroundColor: '#333', + text: 'SELECTED DATA INDICES: \n' + brushed.join('\n'), + bottom: 0, + right: '10%', + width: 100, + textStyle: { + fontSize: 12, + color: '#fff' + } + } + }); +}); +export {}; diff --git a/testdata/bar-data-color.js b/testdata/bar-data-color.js new file mode 100644 index 0000000..1e0b8b0 --- /dev/null +++ b/testdata/bar-data-color.js @@ -0,0 +1,35 @@ +/* +title: Set Style of Single Bar. +category: bar +titleCN: 自定义单个柱子颜色 +difficulty: 1 +*/ +option = { + xAxis: { + type: 'category', + data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'] + }, + yAxis: { + type: 'value' + }, + series: [ + { + data: [ + 120, + { + value: 200, + itemStyle: { + color: '#a90000' + } + }, + 150, + 80, + 70, + 110, + 130 + ], + type: 'bar' + } + ] +}; +export {}; diff --git a/testdata/bar-data-color.js.svg b/testdata/bar-data-color.js.svg new file mode 100644 index 0000000..e467596 --- /dev/null +++ b/testdata/bar-data-color.js.svg @@ -0,0 +1,117 @@ + + + + + + + + + + + + + + + + +0 +50 +100 +150 +200 +Mon +Tue +Wed +Thu +Fri +Sat +Sun + + + + + + + + + \ No newline at end of file diff --git a/testdata/bar-drilldown.js b/testdata/bar-drilldown.js new file mode 100644 index 0000000..3b36325 --- /dev/null +++ b/testdata/bar-drilldown.js @@ -0,0 +1,107 @@ +/* +title: Bar Chart Drilldown Animation. +category: bar +titleCN: 柱状图下钻动画 +difficulty: 5 +*/ +option = { + xAxis: { + data: ['Animals', 'Fruits', 'Cars'] + }, + yAxis: {}, + dataGroupId: '', + animationDurationUpdate: 500, + series: { + type: 'bar', + id: 'sales', + data: [ + { + value: 5, + groupId: 'animals' + }, + { + value: 2, + groupId: 'fruits' + }, + { + value: 4, + groupId: 'cars' + } + ], + universalTransition: { + enabled: true, + divideShape: 'clone' + } + } +}; +const drilldownData = [ + { + dataGroupId: 'animals', + data: [ + ['Cats', 4], + ['Dogs', 2], + ['Cows', 1], + ['Sheep', 2], + ['Pigs', 1] + ] + }, + { + dataGroupId: 'fruits', + data: [ + ['Apples', 4], + ['Oranges', 2] + ] + }, + { + dataGroupId: 'cars', + data: [ + ['Toyota', 4], + ['Opel', 2], + ['Volkswagen', 2] + ] + } +]; +myChart.on('click', function (event) { + if (event.data) { + var subData = drilldownData.find(function (data) { + return data.dataGroupId === event.data.groupId; + }); + if (!subData) { + return; + } + myChart.setOption({ + xAxis: { + data: subData.data.map(function (item) { + return item[0]; + }) + }, + series: { + type: 'bar', + id: 'sales', + dataGroupId: subData.dataGroupId, + data: subData.data.map(function (item) { + return item[1]; + }), + universalTransition: { + enabled: true, + divideShape: 'clone' + } + }, + graphic: [ + { + type: 'text', + left: 50, + top: 20, + style: { + text: 'Back', + fontSize: 18 + }, + onclick: function () { + myChart.setOption(option); + } + } + ] + }); + } +}); +export {}; diff --git a/testdata/bar-gradient.js b/testdata/bar-gradient.js new file mode 100644 index 0000000..4e2f5f6 --- /dev/null +++ b/testdata/bar-gradient.js @@ -0,0 +1,85 @@ +/* +title: Clickable Column Chart with Gradient +titleCN: 特性示例:渐变色 阴影 点击缩放 +category: bar +difficulty: 3 +*/ +// prettier-ignore +let dataAxis = ['点', '击', '柱', '子', '或', '者', '两', '指', '在', '触', '屏', '上', '滑', '动', '能', '够', '自', '动', '缩', '放']; +// prettier-ignore +let data = [220, 182, 191, 234, 290, 330, 310, 123, 442, 321, 90, 149, 210, 122, 133, 334, 198, 123, 125, 220]; +let yMax = 500; +let dataShadow = []; +for (let i = 0; i < data.length; i++) { + dataShadow.push(yMax); +} +option = { + title: { + text: '特性示例:渐变色 阴影 点击缩放', + subtext: 'Feature Sample: Gradient Color, Shadow, Click Zoom' + }, + xAxis: { + data: dataAxis, + axisLabel: { + inside: true, + color: '#fff' + }, + axisTick: { + show: false + }, + axisLine: { + show: false + }, + z: 10 + }, + yAxis: { + axisLine: { + show: false + }, + axisTick: { + show: false + }, + axisLabel: { + color: '#999' + } + }, + dataZoom: [ + { + type: 'inside' + } + ], + series: [ + { + type: 'bar', + showBackground: true, + itemStyle: { + color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [ + { offset: 0, color: '#83bff6' }, + { offset: 0.5, color: '#188df0' }, + { offset: 1, color: '#188df0' } + ]) + }, + emphasis: { + itemStyle: { + color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [ + { offset: 0, color: '#2378f7' }, + { offset: 0.7, color: '#2378f7' }, + { offset: 1, color: '#83bff6' } + ]) + } + }, + data: data + } + ] +}; +// Enable data zoom when user click bar. +const zoomSize = 6; +myChart.on('click', function (params) { + console.log(dataAxis[Math.max(params.dataIndex - zoomSize / 2, 0)]); + myChart.dispatchAction({ + type: 'dataZoom', + startValue: dataAxis[Math.max(params.dataIndex - zoomSize / 2, 0)], + endValue: dataAxis[Math.min(params.dataIndex + zoomSize / 2, data.length - 1)] + }); +}); +export {}; diff --git a/testdata/bar-histogram.js b/testdata/bar-histogram.js new file mode 100644 index 0000000..892a259 --- /dev/null +++ b/testdata/bar-histogram.js @@ -0,0 +1,145 @@ +"use strict"; +/* +title: Histogram with Custom Series +category: custom +titleCN: 直方图(自定义系列) +difficulty: 0 +*/ +// See https://github.com/ecomfe/echarts-stat +echarts.registerTransform(ecStat.transform.histogram); +option = { + dataset: [ + { + source: [ + [8.3, 143], + [8.6, 214], + [8.8, 251], + [10.5, 26], + [10.7, 86], + [10.8, 93], + [11.0, 176], + [11.0, 39], + [11.1, 221], + [11.2, 188], + [11.3, 57], + [11.4, 91], + [11.4, 191], + [11.7, 8], + [12.0, 196], + [12.9, 177], + [12.9, 153], + [13.3, 201], + [13.7, 199], + [13.8, 47], + [14.0, 81], + [14.2, 98], + [14.5, 121], + [16.0, 37], + [16.3, 12], + [17.3, 105], + [17.5, 168], + [17.9, 84], + [18.0, 197], + [18.0, 155], + [20.6, 125] + ] + }, + { + transform: { + type: 'ecStat:histogram', + config: {} + } + }, + { + transform: { + type: 'ecStat:histogram', + // print: true, + config: { dimensions: [1] } + } + } + ], + tooltip: {}, + grid: [ + { + top: '50%', + right: '50%' + }, + { + bottom: '52%', + right: '50%' + }, + { + top: '50%', + left: '52%' + } + ], + xAxis: [ + { + scale: true, + gridIndex: 0 + }, + { + type: 'category', + scale: true, + axisTick: { show: false }, + axisLabel: { show: false }, + axisLine: { show: false }, + gridIndex: 1 + }, + { + scale: true, + gridIndex: 2 + } + ], + yAxis: [ + { + gridIndex: 0 + }, + { + gridIndex: 1 + }, + { + type: 'category', + axisTick: { show: false }, + axisLabel: { show: false }, + axisLine: { show: false }, + gridIndex: 2 + } + ], + series: [ + { + name: 'origianl scatter', + type: 'scatter', + xAxisIndex: 0, + yAxisIndex: 0, + encode: { tooltip: [0, 1] }, + datasetIndex: 0 + }, + { + name: 'histogram', + type: 'bar', + xAxisIndex: 1, + yAxisIndex: 1, + barWidth: '99.3%', + label: { + show: true, + position: 'top' + }, + encode: { x: 0, y: 1, itemName: 4 }, + datasetIndex: 1 + }, + { + name: 'histogram', + type: 'bar', + xAxisIndex: 2, + yAxisIndex: 2, + barWidth: '99.3%', + label: { + show: true, + position: 'right' + }, + encode: { x: 1, y: 0, itemName: 4 }, + datasetIndex: 2 + } + ] +}; diff --git a/testdata/bar-label-rotation.js b/testdata/bar-label-rotation.js new file mode 100644 index 0000000..f0c06f1 --- /dev/null +++ b/testdata/bar-label-rotation.js @@ -0,0 +1,173 @@ +/* +title: Bar Label Rotation +titleCN: 柱状图标签旋转 +category: bar +difficulty: 3 +*/ +const posList = [ + 'left', + 'right', + 'top', + 'bottom', + 'inside', + 'insideTop', + 'insideLeft', + 'insideRight', + 'insideBottom', + 'insideTopLeft', + 'insideTopRight', + 'insideBottomLeft', + 'insideBottomRight' +]; +app.configParameters = { + rotate: { + min: -90, + max: 90 + }, + align: { + options: { + left: 'left', + center: 'center', + right: 'right' + } + }, + verticalAlign: { + options: { + top: 'top', + middle: 'middle', + bottom: 'bottom' + } + }, + position: { + options: posList.reduce(function (map, pos) { + map[pos] = pos; + return map; + }, {}) + }, + distance: { + min: 0, + max: 100 + } +}; +app.config = { + rotate: 90, + align: 'left', + verticalAlign: 'middle', + position: 'insideBottom', + distance: 15, + onChange: function () { + const labelOption = { + rotate: app.config.rotate, + align: app.config.align, + verticalAlign: app.config + .verticalAlign, + position: app.config.position, + distance: app.config.distance + }; + myChart.setOption({ + series: [ + { + label: labelOption + }, + { + label: labelOption + }, + { + label: labelOption + }, + { + label: labelOption + } + ] + }); + } +}; +const labelOption = { + show: true, + position: app.config.position, + distance: app.config.distance, + align: app.config.align, + verticalAlign: app.config.verticalAlign, + rotate: app.config.rotate, + formatter: '{c} {name|{a}}', + fontSize: 16, + rich: { + name: {} + } +}; +option = { + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'shadow' + } + }, + legend: { + data: ['Forest', 'Steppe', 'Desert', 'Wetland'] + }, + toolbox: { + show: true, + orient: 'vertical', + left: 'right', + top: 'center', + feature: { + mark: { show: true }, + dataView: { show: true, readOnly: false }, + magicType: { show: true, type: ['line', 'bar', 'stack'] }, + restore: { show: true }, + saveAsImage: { show: true } + } + }, + xAxis: [ + { + type: 'category', + axisTick: { show: false }, + data: ['2012', '2013', '2014', '2015', '2016'] + } + ], + yAxis: [ + { + type: 'value' + } + ], + series: [ + { + name: 'Forest', + type: 'bar', + barGap: 0, + label: labelOption, + emphasis: { + focus: 'series' + }, + data: [320, 332, 301, 334, 390] + }, + { + name: 'Steppe', + type: 'bar', + label: labelOption, + emphasis: { + focus: 'series' + }, + data: [220, 182, 191, 234, 290] + }, + { + name: 'Desert', + type: 'bar', + label: labelOption, + emphasis: { + focus: 'series' + }, + data: [150, 232, 201, 154, 190] + }, + { + name: 'Wetland', + type: 'bar', + label: labelOption, + emphasis: { + focus: 'series' + }, + data: [98, 77, 101, 99, 40] + } + ] +}; +export {}; diff --git a/testdata/bar-label-rotation.js.svg b/testdata/bar-label-rotation.js.svg new file mode 100644 index 0000000..d0ce06f --- /dev/null +++ b/testdata/bar-label-rotation.js.svg @@ -0,0 +1,319 @@ + + + + + + + + +0 +100 +200 +300 +400 +2012 +2013 +2014 +2015 +2016 + + + + + + + + + + + + + + + + + + + + +320 +Forest +332 +Forest +301 +Forest +334 +Forest +390 +Forest +220 +Steppe +182 +Steppe +191 +Steppe +234 +Steppe +290 +Steppe +150 +Desert +232 +Desert +201 +Desert +154 +Desert +190 +Desert +98 +Wetland +77 +Wetland +101 +Wetland +99 +Wetland +40 +Wetland + + +Forest + +Steppe + +Desert + +Wetland + + + + + + + + + \ No newline at end of file diff --git a/testdata/bar-large.js b/testdata/bar-large.js new file mode 100644 index 0000000..d71a9d1 --- /dev/null +++ b/testdata/bar-large.js @@ -0,0 +1,89 @@ +/* +title: Large Scale Bar Chart +category: bar +titleCN: 大数据量柱图 +difficulty: 5 +*/ +const dataCount = 5e5; +const data = generateData(dataCount); +option = { + title: { + text: echarts.format.addCommas(dataCount) + ' Data', + left: 10 + }, + toolbox: { + feature: { + dataZoom: { + yAxisIndex: false + }, + saveAsImage: { + pixelRatio: 2 + } + } + }, + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'shadow' + } + }, + grid: { + bottom: 90 + }, + dataZoom: [ + { + type: 'inside' + }, + { + type: 'slider' + } + ], + xAxis: { + data: data.categoryData, + silent: false, + splitLine: { + show: false + }, + splitArea: { + show: false + } + }, + yAxis: { + splitArea: { + show: false + } + }, + series: [ + { + type: 'bar', + data: data.valueData, + // Set `large` for large data amount + large: true + } + ] +}; +function generateData(count) { + let baseValue = Math.random() * 1000; + let time = +new Date(2011, 0, 1); + let smallBaseValue; + function next(idx) { + smallBaseValue = + idx % 30 === 0 + ? Math.random() * 700 + : smallBaseValue + Math.random() * 500 - 250; + baseValue += Math.random() * 20 - 10; + return Math.max(0, Math.round(baseValue + smallBaseValue) + 3000); + } + const categoryData = []; + const valueData = []; + for (let i = 0; i < count; i++) { + categoryData.push(echarts.format.formatTime('yyyy-MM-dd\nhh:mm:ss', time, false)); + valueData.push(next(i).toFixed(2)); + time += 1000; + } + return { + categoryData: categoryData, + valueData: valueData + }; +} +export {}; diff --git a/testdata/bar-large.js.svg b/testdata/bar-large.js.svg new file mode 100644 index 0000000..76115eb --- /dev/null +++ b/testdata/bar-large.js.svg @@ -0,0 +1,91 @@ + + + + + + + + + + + + + + + + + + +0 +2,000 +4,000 +6,000 +8,000 +2011-01-01 +00:00:00 +2011-01-01 +16:22:39 +2011-01-02 +08:45:18 +2011-01-03 +01:07:57 +2011-01-03 +17:30:36 +2011-01-04 +09:53:15 +2011-01-05 +02:15:54 +2011-01-05 +18:38:33 +2011-01-06 +11:01:12 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +500,000 Data + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/bar-negative.js b/testdata/bar-negative.js new file mode 100644 index 0000000..b9d13ff --- /dev/null +++ b/testdata/bar-negative.js @@ -0,0 +1,77 @@ +/* +title: Bar Chart with Negative Value +titleCN: 正负条形图 +category: bar +difficulty: 4 +*/ +option = { + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'shadow' + } + }, + legend: { + data: ['Profit', 'Expenses', 'Income'] + }, + grid: { + left: '3%', + right: '4%', + bottom: '3%', + containLabel: true + }, + xAxis: [ + { + type: 'value' + } + ], + yAxis: [ + { + type: 'category', + axisTick: { + show: false + }, + data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'] + } + ], + series: [ + { + name: 'Profit', + type: 'bar', + label: { + show: true, + position: 'inside' + }, + emphasis: { + focus: 'series' + }, + data: [200, 170, 240, 244, 200, 220, 210] + }, + { + name: 'Income', + type: 'bar', + stack: 'Total', + label: { + show: true + }, + emphasis: { + focus: 'series' + }, + data: [320, 302, 341, 374, 390, 450, 420] + }, + { + name: 'Expenses', + type: 'bar', + stack: 'Total', + label: { + show: true, + position: 'left' + }, + emphasis: { + focus: 'series' + }, + data: [-120, -132, -101, -134, -190, -230, -210] + } + ] +}; +export {}; diff --git a/testdata/bar-negative.js.svg b/testdata/bar-negative.js.svg new file mode 100644 index 0000000..9621a1b --- /dev/null +++ b/testdata/bar-negative.js.svg @@ -0,0 +1,313 @@ + + + + + + + + + + + + +Mon +Tue +Wed +Thu +Fri +Sat +Sun +-300 +-200 +-100 +0 +100 +200 +300 +400 +500 + + + + + + + + + + + + + + + + + + + + + +200 +170 +240 +244 +200 +220 +210 +320 +302 +341 +374 +390 +450 +420 +-120 +-132 +-101 +-134 +-190 +-230 +-210 + + +Profit + +Expenses + +Income + + \ No newline at end of file diff --git a/testdata/bar-negative2.js b/testdata/bar-negative2.js new file mode 100644 index 0000000..6f76a73 --- /dev/null +++ b/testdata/bar-negative2.js @@ -0,0 +1,76 @@ +/* +title: Bar Chart with Negative Value +titleCN: 交错正负轴标签 +category: bar +difficulty: 2 +*/ +const labelRight = { + position: 'right' +}; +option = { + title: { + text: 'Bar Chart with Negative Value' + }, + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'shadow' + } + }, + grid: { + top: 80, + bottom: 30 + }, + xAxis: { + type: 'value', + position: 'top', + splitLine: { + lineStyle: { + type: 'dashed' + } + } + }, + yAxis: { + type: 'category', + axisLine: { show: false }, + axisLabel: { show: false }, + axisTick: { show: false }, + splitLine: { show: false }, + data: [ + 'ten', + 'nine', + 'eight', + 'seven', + 'six', + 'five', + 'four', + 'three', + 'two', + 'one' + ] + }, + series: [ + { + name: 'Cost', + type: 'bar', + stack: 'Total', + label: { + show: true, + formatter: '{b}' + }, + data: [ + { value: -0.07, label: labelRight }, + { value: -0.09, label: labelRight }, + 0.2, + 0.44, + { value: -0.23, label: labelRight }, + 0.08, + { value: -0.17, label: labelRight }, + 0.47, + { value: -0.36, label: labelRight }, + 0.18 + ] + } + ] +}; +export {}; diff --git a/testdata/bar-negative2.js.svg b/testdata/bar-negative2.js.svg new file mode 100644 index 0000000..9a11b5a --- /dev/null +++ b/testdata/bar-negative2.js.svg @@ -0,0 +1,151 @@ + + + + + + + + +-0.4 +-0.2 +0 +0.2 +0.4 +0.6 + + + + + + + + + + +ten +nine +eight +seven +six +five +four +three +two +one + +Bar Chart with Negative Value + + \ No newline at end of file diff --git a/testdata/bar-polar-label-radial.js b/testdata/bar-polar-label-radial.js new file mode 100644 index 0000000..84e9a1d --- /dev/null +++ b/testdata/bar-polar-label-radial.js @@ -0,0 +1,37 @@ +/* +title: Radial Polar Bar Label Position +titleCN: 极坐标柱状图标签 +category: bar +difficulty: 2 +*/ +option = { + title: [ + { + text: 'Radial Polar Bar Label Position (middle)' + } + ], + polar: { + radius: [30, '80%'] + }, + radiusAxis: { + max: 4 + }, + angleAxis: { + type: 'category', + data: ['a', 'b', 'c', 'd'], + startAngle: 75 + }, + tooltip: {}, + series: { + type: 'bar', + data: [2, 1.2, 2.4, 3.6], + coordinateSystem: 'polar', + label: { + show: true, + position: 'middle', + formatter: '{b}: {c}' + } + }, + animation: false +}; +export {}; diff --git a/testdata/bar-polar-label-radial.js.svg b/testdata/bar-polar-label-radial.js.svg new file mode 100644 index 0000000..6a1d72c --- /dev/null +++ b/testdata/bar-polar-label-radial.js.svg @@ -0,0 +1,31 @@ + + + +a +b +c +d + + + + + + + + +0 +1 +2 +3 +4 + + + + +a: 2 +b: 1.2 +c: 2.4 +d: 3.6 + +Radial Polar Bar Label Position (middle) + \ No newline at end of file diff --git a/testdata/bar-polar-label-tangential.js b/testdata/bar-polar-label-tangential.js new file mode 100644 index 0000000..459a759 --- /dev/null +++ b/testdata/bar-polar-label-tangential.js @@ -0,0 +1,36 @@ +/* +title: Tangential Polar Bar Label Position +titleCN: 极坐标柱状图标签 +category: bar +difficulty: 2 +*/ +option = { + title: [ + { + text: 'Tangential Polar Bar Label Position (middle)' + } + ], + polar: { + radius: [30, '80%'] + }, + angleAxis: { + max: 4, + startAngle: 75 + }, + radiusAxis: { + type: 'category', + data: ['a', 'b', 'c', 'd'] + }, + tooltip: {}, + series: { + type: 'bar', + data: [2, 1.2, 2.4, 3.6], + coordinateSystem: 'polar', + label: { + show: true, + position: 'middle', + formatter: '{b}: {c}' + } + } +}; +export {}; diff --git a/testdata/bar-polar-label-tangential.js.svg b/testdata/bar-polar-label-tangential.js.svg new file mode 100644 index 0000000..4893d20 --- /dev/null +++ b/testdata/bar-polar-label-tangential.js.svg @@ -0,0 +1,40 @@ + + +0 +0.3 +0.6 +0.9 +1.2 +1.5 +1.8 +2.1 +2.4 +2.7 +3 +3.3 +3.6 +3.9 + + + + + + + + + +a +b +c +d + + + + +a: 2 +b: 1.2 +c: 2.4 +d: 3.6 + +Tangential Polar Bar Label Position (middle) + \ No newline at end of file diff --git a/testdata/bar-polar-real-estate.js b/testdata/bar-polar-real-estate.js new file mode 100644 index 0000000..34d8504 --- /dev/null +++ b/testdata/bar-polar-real-estate.js @@ -0,0 +1,111 @@ +/* +title: Bar Chart on Polar +category: bar +difficulty: 7 +shotWidth: 800 +*/ +const data = [ + [5000, 10000, 6785.71], + [4000, 10000, 6825], + [3000, 6500, 4463.33], + [2500, 5600, 3793.83], + [2000, 4000, 3060], + [2000, 4000, 3222.33], + [2500, 4000, 3133.33], + [1800, 4000, 3100], + [2000, 3500, 2750], + [2000, 3000, 2500], + [1800, 3000, 2433.33], + [2000, 2700, 2375], + [1500, 2800, 2150], + [1500, 2300, 2100], + [1600, 3500, 2057.14], + [1500, 2600, 2037.5], + [1500, 2417.54, 1905.85], + [1500, 2000, 1775], + [1500, 1800, 1650] +]; +// prettier-ignore +const cities = ['北京', '上海', '深圳', '广州', '苏州', '杭州', '南京', '福州', '青岛', '济南', '长春', '大连', '温州', '郑州', '武汉', '成都', '东莞', '沈阳', '烟台']; +const barHeight = 50; +option = { + title: { + text: 'How expensive is it to rent an apartment in China?', + subtext: 'Data from https://www.numbeo.com' + }, + legend: { + show: true, + top: 'bottom', + data: ['Range', 'Average'] + }, + grid: { + top: 100 + }, + angleAxis: { + type: 'category', + data: cities + }, + tooltip: { + show: true, + formatter: function (params) { + const id = params.dataIndex; + return (cities[id] + + '
Lowest:' + + data[id][0] + + '
Highest:' + + data[id][1] + + '
Average:' + + data[id][2]); + } + }, + radiusAxis: {}, + polar: {}, + series: [ + { + type: 'bar', + itemStyle: { + color: 'transparent' + }, + data: data.map(function (d) { + return d[0]; + }), + coordinateSystem: 'polar', + stack: 'Min Max', + silent: true + }, + { + type: 'bar', + data: data.map(function (d) { + return d[1] - d[0]; + }), + coordinateSystem: 'polar', + name: 'Range', + stack: 'Min Max' + }, + { + type: 'bar', + itemStyle: { + color: 'transparent' + }, + data: data.map(function (d) { + return d[2] - barHeight; + }), + coordinateSystem: 'polar', + stack: 'Average', + silent: true, + z: 10 + }, + { + type: 'bar', + data: data.map(function (d) { + return barHeight * 2; + }), + coordinateSystem: 'polar', + name: 'Average', + stack: 'Average', + barGap: '-100%', + z: 10 + } + ] +}; +export {}; diff --git a/testdata/bar-polar-real-estate.js.svg b/testdata/bar-polar-real-estate.js.svg new file mode 100644 index 0000000..ea70cdd --- /dev/null +++ b/testdata/bar-polar-real-estate.js.svg @@ -0,0 +1,544 @@ + + + +北京 +上海 +深圳 +广州 +苏州 +杭州 +南京 +福州 +青岛 +济南 +长春 +大连 +温州 +郑州 +武汉 +成都 +东莞 +沈阳 +烟台 + + + + + + + + + +0 +2,000 +4,000 +6,000 +8,000 +10,000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Range + +Average + +How expensive is it to rent an apartment in China? +Data from https://www.numbeo.com + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/bar-polar-stack-radial.js b/testdata/bar-polar-stack-radial.js new file mode 100644 index 0000000..a4d2189 --- /dev/null +++ b/testdata/bar-polar-stack-radial.js @@ -0,0 +1,51 @@ +/* +title: Stacked Bar Chart on Polar(Radial) +titleCN: 极坐标系下的堆叠柱状图 +category: bar +difficulty: 7 +*/ +option = { + angleAxis: { + type: 'category', + data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'] + }, + radiusAxis: {}, + polar: {}, + series: [ + { + type: 'bar', + data: [1, 2, 3, 4, 3, 5, 1], + coordinateSystem: 'polar', + name: 'A', + stack: 'a', + emphasis: { + focus: 'series' + } + }, + { + type: 'bar', + data: [2, 4, 6, 1, 3, 2, 1], + coordinateSystem: 'polar', + name: 'B', + stack: 'a', + emphasis: { + focus: 'series' + } + }, + { + type: 'bar', + data: [1, 2, 3, 4, 1, 2, 5], + coordinateSystem: 'polar', + name: 'C', + stack: 'a', + emphasis: { + focus: 'series' + } + } + ], + legend: { + show: true, + data: ['A', 'B', 'C'] + } +}; +export {}; diff --git a/testdata/bar-polar-stack-radial.js.svg b/testdata/bar-polar-stack-radial.js.svg new file mode 100644 index 0000000..88904a9 --- /dev/null +++ b/testdata/bar-polar-stack-radial.js.svg @@ -0,0 +1,214 @@ + + + +Mon +Tue +Wed +Thu +Fri +Sat +Sun + + + + + + + + + + +0 +2 +4 +6 +8 +10 +12 + + + + + + + + + + + + + + + + + + + + + + + +A + +B + +C + + \ No newline at end of file diff --git a/testdata/bar-polar-stack.js b/testdata/bar-polar-stack.js new file mode 100644 index 0000000..f2f5f02 --- /dev/null +++ b/testdata/bar-polar-stack.js @@ -0,0 +1,52 @@ +/* +title: Stacked Bar Chart on Polar +titleCN: 极坐标系下的堆叠柱状图 +category: bar +difficulty: 7 +*/ +option = { + angleAxis: {}, + radiusAxis: { + type: 'category', + data: ['Mon', 'Tue', 'Wed', 'Thu'], + z: 10 + }, + polar: {}, + series: [ + { + type: 'bar', + data: [1, 2, 3, 4], + coordinateSystem: 'polar', + name: 'A', + stack: 'a', + emphasis: { + focus: 'series' + } + }, + { + type: 'bar', + data: [2, 4, 6, 8], + coordinateSystem: 'polar', + name: 'B', + stack: 'a', + emphasis: { + focus: 'series' + } + }, + { + type: 'bar', + data: [1, 2, 3, 4], + coordinateSystem: 'polar', + name: 'C', + stack: 'a', + emphasis: { + focus: 'series' + } + } + ], + legend: { + show: true, + data: ['A', 'B', 'C'] + } +}; +export {}; diff --git a/testdata/bar-polar-stack.js.svg b/testdata/bar-polar-stack.js.svg new file mode 100644 index 0000000..e6c9f0e --- /dev/null +++ b/testdata/bar-polar-stack.js.svg @@ -0,0 +1,51 @@ + + +0 +1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 +12 +13 +14 +15 + + + + + + + + + + + + + + + + + +A + +B + +C + + + + + + +Mon +Tue +Wed +Thu + \ No newline at end of file diff --git a/testdata/bar-race-country.js b/testdata/bar-race-country.js new file mode 100644 index 0000000..62d2b3f --- /dev/null +++ b/testdata/bar-race-country.js @@ -0,0 +1,153 @@ +/* +title: Bar Race +titleCN: 动态排序柱状图 - 人均收入 +category: bar +difficulty: 6 +videoStart: 1000 +videoEnd: 6000 +*/ +const updateFrequency = 2000; +const dimension = 0; +const countryColors = { + Australia: '#00008b', + Canada: '#f00', + China: '#ffde00', + Cuba: '#002a8f', + Finland: '#003580', + France: '#ed2939', + Germany: '#000', + Iceland: '#003897', + India: '#f93', + Japan: '#bc002d', + 'North Korea': '#024fa2', + 'South Korea': '#000', + 'New Zealand': '#00247d', + Norway: '#ef2b2d', + Poland: '#dc143c', + Russia: '#d52b1e', + Turkey: '#e30a17', + 'United Kingdom': '#00247d', + 'United States': '#b22234' +}; +$.when($.getJSON('https://fastly.jsdelivr.net/npm/emoji-flags@1.3.0/data.json'), $.getJSON(ROOT_PATH + '/data/asset/data/life-expectancy-table.json')).done(function (res0, res1) { + const flags = res0[0]; + const data = res1[0]; + const years = []; + for (let i = 0; i < data.length; ++i) { + if (years.length === 0 || years[years.length - 1] !== data[i][4]) { + years.push(data[i][4]); + } + } + function getFlag(countryName) { + if (!countryName) { + return ''; + } + return (flags.find(function (item) { + return item.name === countryName; + }) || {}).emoji; + } + let startIndex = 10; + let startYear = years[startIndex]; + option = { + grid: { + top: 10, + bottom: 30, + left: 150, + right: 80 + }, + xAxis: { + max: 'dataMax', + axisLabel: { + formatter: function (n) { + return Math.round(n) + ''; + } + } + }, + dataset: { + source: data.slice(1).filter(function (d) { + return d[4] === startYear; + }) + }, + yAxis: { + type: 'category', + inverse: true, + max: 10, + axisLabel: { + show: true, + fontSize: 14, + formatter: function (value) { + return value + '{flag|' + getFlag(value) + '}'; + }, + rich: { + flag: { + fontSize: 25, + padding: 5 + } + } + }, + animationDuration: 300, + animationDurationUpdate: 300 + }, + series: [ + { + realtimeSort: true, + seriesLayoutBy: 'column', + type: 'bar', + itemStyle: { + color: function (param) { + return countryColors[param.value[3]] || '#5470c6'; + } + }, + encode: { + x: dimension, + y: 3 + }, + label: { + show: true, + precision: 1, + position: 'right', + valueAnimation: true, + fontFamily: 'monospace' + } + } + ], + // Disable init animation. + animationDuration: 0, + animationDurationUpdate: updateFrequency, + animationEasing: 'linear', + animationEasingUpdate: 'linear', + graphic: { + elements: [ + { + type: 'text', + right: 160, + bottom: 60, + style: { + text: startYear, + font: 'bolder 80px monospace', + fill: 'rgba(100, 100, 100, 0.25)' + }, + z: 100 + } + ] + } + }; + // console.log(option); + myChart.setOption(option); + for (let i = startIndex; i < years.length - 1; ++i) { + (function (i) { + setTimeout(function () { + updateYear(years[i + 1]); + }, (i - startIndex) * updateFrequency); + })(i); + } + function updateYear(year) { + let source = data.slice(1).filter(function (d) { + return d[4] === year; + }); + option.series[0].data = source; + option.graphic.elements[0].style.text = year; + myChart.setOption(option); + } +}); +export {}; diff --git a/testdata/bar-race.js b/testdata/bar-race.js new file mode 100644 index 0000000..7f4e352 --- /dev/null +++ b/testdata/bar-race.js @@ -0,0 +1,70 @@ +/* +title: Bar Race +titleCN: 动态排序柱状图 +category: bar +difficulty: 5 +videoStart: 1000 +videoEnd: 6000 +*/ +const data = []; +for (let i = 0; i < 5; ++i) { + data.push(Math.round(Math.random() * 200)); +} +option = { + xAxis: { + max: 'dataMax' + }, + yAxis: { + type: 'category', + data: ['A', 'B', 'C', 'D', 'E'], + inverse: true, + animationDuration: 300, + animationDurationUpdate: 300, + max: 2 // only the largest 3 bars will be displayed + }, + series: [ + { + realtimeSort: true, + name: 'X', + type: 'bar', + data: data, + label: { + show: true, + position: 'right', + valueAnimation: true + } + } + ], + legend: { + show: true + }, + animationDuration: 0, + animationDurationUpdate: 3000, + animationEasing: 'linear', + animationEasingUpdate: 'linear' +}; +function run() { + for (var i = 0; i < data.length; ++i) { + if (Math.random() > 0.9) { + data[i] += Math.round(Math.random() * 2000); + } + else { + data[i] += Math.round(Math.random() * 200); + } + } + myChart.setOption({ + series: [ + { + type: 'bar', + data + } + ] + }); +} +setTimeout(function () { + run(); +}, 0); +setInterval(function () { + run(); +}, 3000); +export {}; diff --git a/testdata/bar-race.js.svg b/testdata/bar-race.js.svg new file mode 100644 index 0000000..76b386b --- /dev/null +++ b/testdata/bar-race.js.svg @@ -0,0 +1,34 @@ + + + + + + + + + + + + + + +D +B +E +0 +20 +40 +60 +80 +100 +119 + + + +117 +119 +113 + + +X + \ No newline at end of file diff --git a/testdata/bar-rich-text.js b/testdata/bar-rich-text.js new file mode 100644 index 0000000..c90274a --- /dev/null +++ b/testdata/bar-rich-text.js @@ -0,0 +1,148 @@ +/* +title: Wheater Statistics +category: 'bar, rich' +titleCN: 天气统计(富文本) +difficulty: 6 +*/ +const weatherIcons = { + Sunny: ROOT_PATH + '/data/asset/img/weather/sunny_128.png', + Cloudy: ROOT_PATH + '/data/asset/img/weather/cloudy_128.png', + Showers: ROOT_PATH + '/data/asset/img/weather/showers_128.png' +}; +const seriesLabel = { + show: true +}; +option = { + title: { + text: 'Weather Statistics' + }, + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'shadow' + } + }, + legend: { + data: ['City Alpha', 'City Beta', 'City Gamma'] + }, + grid: { + left: 100 + }, + toolbox: { + show: true, + feature: { + saveAsImage: {} + } + }, + xAxis: { + type: 'value', + name: 'Days', + axisLabel: { + formatter: '{value}' + } + }, + yAxis: { + type: 'category', + inverse: true, + data: ['Sunny', 'Cloudy', 'Showers'], + axisLabel: { + formatter: function (value) { + return '{' + value + '| }\n{value|' + value + '}'; + }, + margin: 20, + rich: { + value: { + lineHeight: 30, + align: 'center' + }, + Sunny: { + height: 40, + align: 'center', + backgroundColor: { + image: weatherIcons.Sunny + } + }, + Cloudy: { + height: 40, + align: 'center', + backgroundColor: { + image: weatherIcons.Cloudy + } + }, + Showers: { + height: 40, + align: 'center', + backgroundColor: { + image: weatherIcons.Showers + } + } + } + } + }, + series: [ + { + name: 'City Alpha', + type: 'bar', + data: [165, 170, 30], + label: seriesLabel, + markPoint: { + symbolSize: 1, + symbolOffset: [0, '50%'], + label: { + formatter: '{a|{a}\n}{b|{b} }{c|{c}}', + backgroundColor: 'rgb(242,242,242)', + borderColor: '#aaa', + borderWidth: 1, + borderRadius: 4, + padding: [4, 10], + lineHeight: 26, + // shadowBlur: 5, + // shadowColor: '#000', + // shadowOffsetX: 0, + // shadowOffsetY: 1, + position: 'right', + distance: 20, + rich: { + a: { + align: 'center', + color: '#fff', + fontSize: 18, + textShadowBlur: 2, + textShadowColor: '#000', + textShadowOffsetX: 0, + textShadowOffsetY: 1, + textBorderColor: '#333', + textBorderWidth: 2 + }, + b: { + color: '#333' + }, + c: { + color: '#ff8811', + textBorderColor: '#000', + textBorderWidth: 1, + fontSize: 22 + } + } + }, + data: [ + { type: 'max', name: 'max days: ' }, + { type: 'min', name: 'min days: ' } + ] + } + }, + { + name: 'City Beta', + type: 'bar', + label: seriesLabel, + data: [150, 105, 110] + }, + { + name: 'City Gamma', + type: 'bar', + label: seriesLabel, + data: [220, 82, 63] + } + ] +}; +export {}; diff --git a/testdata/bar-simple.js b/testdata/bar-simple.js new file mode 100644 index 0000000..6a4ecea --- /dev/null +++ b/testdata/bar-simple.js @@ -0,0 +1,22 @@ +/* +title: Basic Bar +category: bar +titleCN: 基础柱状图 +difficulty: 0 +*/ +option = { + xAxis: { + type: 'category', + data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'] + }, + yAxis: { + type: 'value' + }, + series: [ + { + data: [120, 200, 150, 80, 70, 110, 130], + type: 'bar' + } + ] +}; +export {}; diff --git a/testdata/bar-simple.js.svg b/testdata/bar-simple.js.svg new file mode 100644 index 0000000..02ae60e --- /dev/null +++ b/testdata/bar-simple.js.svg @@ -0,0 +1,117 @@ + + + + + + + + + + + + + + + + +0 +50 +100 +150 +200 +Mon +Tue +Wed +Thu +Fri +Sat +Sun + + + + + + + + + \ No newline at end of file diff --git a/testdata/bar-stack-borderRadius.js b/testdata/bar-stack-borderRadius.js new file mode 100644 index 0000000..f9eb734 --- /dev/null +++ b/testdata/bar-stack-borderRadius.js @@ -0,0 +1,88 @@ +/* +title: Stacked Bar with borderRadius +category: bar +titleCN: 带圆角的堆积柱状图 +difficulty: 3 +*/ +var series = [ + { + data: [120, 200, 150, 80, 70, 110, 130], + type: 'bar', + stack: 'a', + name: 'a' + }, + { + data: [10, 46, 64, '-', 0, '-', 0], + type: 'bar', + stack: 'a', + name: 'b' + }, + { + data: [30, '-', 0, 20, 10, '-', 0], + type: 'bar', + stack: 'a', + name: 'c' + }, + { + data: [30, '-', 0, 20, 10, '-', 0], + type: 'bar', + stack: 'b', + name: 'd' + }, + { + data: [10, 20, 150, 0, '-', 50, 10], + type: 'bar', + stack: 'b', + name: 'e' + } +]; +const stackInfo = {}; +for (let i = 0; i < series[0].data.length; ++i) { + for (let j = 0; j < series.length; ++j) { + const stackName = series[j].stack; + if (!stackName) { + continue; + } + if (!stackInfo[stackName]) { + stackInfo[stackName] = { + stackStart: [], + stackEnd: [] + }; + } + const info = stackInfo[stackName]; + const data = series[j].data[i]; + if (data && data !== '-') { + if (info.stackStart[i] == null) { + info.stackStart[i] = j; + } + info.stackEnd[i] = j; + } + } +} +for (let i = 0; i < series.length; ++i) { + const data = series[i].data; + const info = stackInfo[series[i].stack]; + for (let j = 0; j < series[i].data.length; ++j) { + // const isStart = info.stackStart[j] === i; + const isEnd = info.stackEnd[j] === i; + const topBorder = isEnd ? 20 : 0; + const bottomBorder = 0; + data[j] = { + value: data[j], + itemStyle: { + borderRadius: [topBorder, topBorder, bottomBorder, bottomBorder] + } + }; + } +} +option = { + xAxis: { + type: 'category', + data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'] + }, + yAxis: { + type: 'value' + }, + series: series +}; +export {}; diff --git a/testdata/bar-stack-borderRadius.js.svg b/testdata/bar-stack-borderRadius.js.svg new file mode 100644 index 0000000..74854a2 --- /dev/null +++ b/testdata/bar-stack-borderRadius.js.svg @@ -0,0 +1,140 @@ + + + + + + + + + + + + + + + + + +0 +50 +100 +150 +200 +250 +Mon +Tue +Wed +Thu +Fri +Sat +Sun + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/bar-stack-normalization-and-variation.js b/testdata/bar-stack-normalization-and-variation.js new file mode 100644 index 0000000..2e3ba50 --- /dev/null +++ b/testdata/bar-stack-normalization-and-variation.js @@ -0,0 +1,100 @@ +/* +title: Stacked Bar Normalization and Variation +titleCN: 堆叠柱状图的归一化和变化 +category: bar +difficulty: 3 +*/ +// There should not be negative values in rawData +const rawData = [ + [100, 302, 301, 334, 390, 330, 320], + [320, 132, 101, 134, 90, 230, 210], + [220, 182, 191, 234, 290, 330, 310], + [150, 212, 201, 154, 190, 330, 410], + [820, 832, 901, 934, 1290, 1330, 1320] +]; +const totalData = []; +for (let i = 0; i < rawData[0].length; ++i) { + let sum = 0; + for (let j = 0; j < rawData.length; ++j) { + sum += rawData[j][i]; + } + totalData.push(sum); +} +const grid = { + left: 100, + right: 100, + top: 50, + bottom: 50 +}; +const gridWidth = myChart.getWidth() - grid.left - grid.right; +const gridHeight = myChart.getHeight() - grid.top - grid.bottom; +const categoryWidth = gridWidth / rawData[0].length; +const barWidth = categoryWidth * 0.6; +const barPadding = (categoryWidth - barWidth) / 2; +const series = [ + 'Direct', + 'Mail Ad', + 'Affiliate Ad', + 'Video Ad', + 'Search Engine' +].map((name, sid) => { + return { + name, + type: 'bar', + stack: 'total', + barWidth: '60%', + label: { + show: true, + formatter: (params) => Math.round(params.value * 1000) / 10 + '%' + }, + data: rawData[sid].map((d, did) => totalData[did] <= 0 ? 0 : d / totalData[did]) + }; +}); +const color = ['#5470c6', '#91cc75', '#fac858', '#ee6666', '#73c0de']; +const elements = []; +for (let j = 1, jlen = rawData[0].length; j < jlen; ++j) { + const leftX = grid.left + categoryWidth * j - barPadding; + const rightX = leftX + barPadding * 2; + let leftY = grid.top + gridHeight; + let rightY = leftY; + for (let i = 0, len = series.length; i < len; ++i) { + const points = []; + const leftBarHeight = (rawData[i][j - 1] / totalData[j - 1]) * gridHeight; + points.push([leftX, leftY]); + points.push([leftX, leftY - leftBarHeight]); + const rightBarHeight = (rawData[i][j] / totalData[j]) * gridHeight; + points.push([rightX, rightY - rightBarHeight]); + points.push([rightX, rightY]); + points.push([leftX, leftY]); + leftY -= leftBarHeight; + rightY -= rightBarHeight; + elements.push({ + type: 'polygon', + shape: { + points + }, + style: { + fill: color[i], + opacity: 0.25 + } + }); + } +} +option = { + legend: { + selectedMode: false + }, + grid, + yAxis: { + type: 'value' + }, + xAxis: { + type: 'category', + data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'] + }, + series, + graphic: { + elements + } +}; +export {}; diff --git a/testdata/bar-stack-normalization.js b/testdata/bar-stack-normalization.js new file mode 100644 index 0000000..d96ebb0 --- /dev/null +++ b/testdata/bar-stack-normalization.js @@ -0,0 +1,62 @@ +/* +title: Stacked Bar Normalization +titleCN: 堆叠柱状图的归一化 +category: bar +difficulty: 3 +*/ +// There should not be negative values in rawData +const rawData = [ + [100, 302, 301, 334, 390, 330, 320], + [320, 132, 101, 134, 90, 230, 210], + [220, 182, 191, 234, 290, 330, 310], + [150, 212, 201, 154, 190, 330, 410], + [820, 832, 901, 934, 1290, 1330, 1320] +]; +const totalData = []; +for (let i = 0; i < rawData[0].length; ++i) { + let sum = 0; + for (let j = 0; j < rawData.length; ++j) { + sum += rawData[j][i]; + } + totalData.push(sum); +} +const grid = { + left: 100, + right: 100, + top: 50, + bottom: 50 +}; +const series = [ + 'Direct', + 'Mail Ad', + 'Affiliate Ad', + 'Video Ad', + 'Search Engine' +].map((name, sid) => { + return { + name, + type: 'bar', + stack: 'total', + barWidth: '60%', + label: { + show: true, + formatter: (params) => Math.round(params.value * 1000) / 10 + '%' + }, + data: rawData[sid].map((d, did) => totalData[did] <= 0 ? 0 : d / totalData[did]) + }; +}); +option = { + legend: { + selectedMode: false + }, + grid, + yAxis: { + type: 'value' + }, + xAxis: { + type: 'category', + data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'] + }, + series +}; +export {}; diff --git a/testdata/bar-stack-normalization.js.svg b/testdata/bar-stack-normalization.js.svg new file mode 100644 index 0000000..a17de39 --- /dev/null +++ b/testdata/bar-stack-normalization.js.svg @@ -0,0 +1,501 @@ + + + + + + + + + + + + + + + + + +0 +0.2 +0.4 +0.6 +0.8 +1 +Mon +Tue +Wed +Thu +Fri +Sat +Sun + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +0.062111801242236024 +0.1819277108433735 +0.1775811209439528 +0.18659217877094972 +0.17333333333333334 +0.12941176470588237 +0.1245136186770428 +0.19875776397515527 +0.07951807228915662 +0.05958702064896755 +0.07486033519553073 +0.04 +0.09019607843137255 +0.08171206225680934 +0.13664596273291926 +0.10963855421686747 +0.11268436578171091 +0.13072625698324022 +0.1288888888888889 +0.12941176470588237 +0.12062256809338522 +0.09316770186335403 +0.12771084337349398 +0.11858407079646018 +0.08603351955307263 +0.08444444444444445 +0.12941176470588237 +0.15953307392996108 +0.5093167701863354 +0.5012048192771085 +0.5315634218289086 +0.5217877094972067 +0.5733333333333334 +0.5215686274509804 +0.5136186770428015 + + +Direct + +Mail Ad + +Affiliate Ad + +Video Ad + +Search Engine + + \ No newline at end of file diff --git a/testdata/bar-stack.js b/testdata/bar-stack.js new file mode 100644 index 0000000..337e72c --- /dev/null +++ b/testdata/bar-stack.js @@ -0,0 +1,121 @@ +/* +title: Stacked Column Chart +titleCN: 堆叠柱状图 +category: bar +difficulty: 3 +*/ +option = { + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'shadow' + } + }, + legend: {}, + grid: { + left: '3%', + right: '4%', + bottom: '3%', + containLabel: true + }, + xAxis: [ + { + type: 'category', + data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'] + } + ], + yAxis: [ + { + type: 'value' + } + ], + series: [ + { + name: 'Direct', + type: 'bar', + emphasis: { + focus: 'series' + }, + data: [320, 332, 301, 334, 390, 330, 320] + }, + { + name: 'Email', + type: 'bar', + stack: 'Ad', + emphasis: { + focus: 'series' + }, + data: [120, 132, 101, 134, 90, 230, 210] + }, + { + name: 'Union Ads', + type: 'bar', + stack: 'Ad', + emphasis: { + focus: 'series' + }, + data: [220, 182, 191, 234, 290, 330, 310] + }, + { + name: 'Video Ads', + type: 'bar', + stack: 'Ad', + emphasis: { + focus: 'series' + }, + data: [150, 232, 201, 154, 190, 330, 410] + }, + { + name: 'Search Engine', + type: 'bar', + data: [862, 1018, 964, 1026, 1679, 1600, 1570], + emphasis: { + focus: 'series' + }, + markLine: { + lineStyle: { + type: 'dashed' + }, + data: [[{ type: 'min' }, { type: 'max' }]] + } + }, + { + name: 'Baidu', + type: 'bar', + barWidth: 5, + stack: 'Search Engine', + emphasis: { + focus: 'series' + }, + data: [620, 732, 701, 734, 1090, 1130, 1120] + }, + { + name: 'Google', + type: 'bar', + stack: 'Search Engine', + emphasis: { + focus: 'series' + }, + data: [120, 132, 101, 134, 290, 230, 220] + }, + { + name: 'Bing', + type: 'bar', + stack: 'Search Engine', + emphasis: { + focus: 'series' + }, + data: [60, 72, 71, 74, 190, 130, 110] + }, + { + name: 'Others', + type: 'bar', + stack: 'Search Engine', + emphasis: { + focus: 'series' + }, + data: [62, 82, 91, 84, 109, 110, 120] + } + ] +}; +export {}; diff --git a/testdata/bar-stack.js.svg b/testdata/bar-stack.js.svg new file mode 100644 index 0000000..2539de6 --- /dev/null +++ b/testdata/bar-stack.js.svg @@ -0,0 +1,816 @@ + + + + + + + + + + + + + + + + + + +0 +300 +600 +900 +1,200 +1,500 +1,800 +Mon +Tue +Wed +Thu +Fri +Sat +Sun + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Direct + +Email + +Union Ads + +Video Ads + +Search Engine + +Baidu + +Google + +Bing + +Others + + + +862 + + \ No newline at end of file diff --git a/testdata/bar-tick-align.js b/testdata/bar-tick-align.js new file mode 100644 index 0000000..a6a204b --- /dev/null +++ b/testdata/bar-tick-align.js @@ -0,0 +1,43 @@ +"use strict"; +/* +title: Axis Align with Tick +titleCN: 坐标轴刻度与标签对齐 +category: bar +difficulty: 0 +*/ +option = { + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'shadow' + } + }, + grid: { + left: '3%', + right: '4%', + bottom: '3%', + containLabel: true + }, + xAxis: [ + { + type: 'category', + data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'], + axisTick: { + alignWithLabel: true + } + } + ], + yAxis: [ + { + type: 'value' + } + ], + series: [ + { + name: 'Direct', + type: 'bar', + barWidth: '60%', + data: [10, 52, 200, 334, 390, 330, 220] + } + ] +}; diff --git a/testdata/bar-tick-align.js.svg b/testdata/bar-tick-align.js.svg new file mode 100644 index 0000000..9d7a57a --- /dev/null +++ b/testdata/bar-tick-align.js.svg @@ -0,0 +1,116 @@ + + + + + + + + + + + + + + + +0 +100 +200 +300 +400 +Mon +Tue +Wed +Thu +Fri +Sat +Sun + + + + + + + + + \ No newline at end of file diff --git a/testdata/bar-waterfall.js b/testdata/bar-waterfall.js new file mode 100644 index 0000000..43efdea --- /dev/null +++ b/testdata/bar-waterfall.js @@ -0,0 +1,65 @@ +/* +title: Waterfall Chart +titleCN: 瀑布图(柱状图模拟) +category: bar +difficulty: 1 +*/ +option = { + title: { + text: 'Waterfall Chart', + subtext: 'Living Expenses in Shenzhen' + }, + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'shadow' + }, + formatter: function (params) { + var tar = params[1]; + return tar.name + '
' + tar.seriesName + ' : ' + tar.value; + } + }, + grid: { + left: '3%', + right: '4%', + bottom: '3%', + containLabel: true + }, + xAxis: { + type: 'category', + splitLine: { show: false }, + data: ['Total', 'Rent', 'Utilities', 'Transportation', 'Meals', 'Other'] + }, + yAxis: { + type: 'value' + }, + series: [ + { + name: 'Placeholder', + type: 'bar', + stack: 'Total', + itemStyle: { + borderColor: 'transparent', + color: 'transparent' + }, + emphasis: { + itemStyle: { + borderColor: 'transparent', + color: 'transparent' + } + }, + data: [0, 1700, 1400, 1200, 300, 0] + }, + { + name: 'Life Cost', + type: 'bar', + stack: 'Total', + label: { + show: true, + position: 'inside' + }, + data: [2900, 1200, 300, 200, 900, 300] + } + ] +}; +export {}; diff --git a/testdata/bar-waterfall.js.svg b/testdata/bar-waterfall.js.svg new file mode 100644 index 0000000..d7b580e --- /dev/null +++ b/testdata/bar-waterfall.js.svg @@ -0,0 +1,166 @@ + + + + + + + + + + + + + + + + + +0 +500 +1,000 +1,500 +2,000 +2,500 +3,000 +Total +Rent +Utilities +Transportation +Meals +Other + + + + + + + + + + + + +2900 +1200 +300 +200 +900 +300 + +Waterfall Chart +Living Expenses in Shenzhen + + \ No newline at end of file diff --git a/testdata/bar-waterfall2.js b/testdata/bar-waterfall2.js new file mode 100644 index 0000000..bf515f8 --- /dev/null +++ b/testdata/bar-waterfall2.js @@ -0,0 +1,89 @@ +/* +title: Waterfall Chart +titleCN: 阶梯瀑布图(柱状图模拟) +category: bar +difficulty: 3 +*/ +option = { + title: { + text: 'Accumulated Waterfall Chart' + }, + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'shadow' + }, + formatter: function (params) { + let tar; + if (params[1] && params[1].value !== '-') { + tar = params[1]; + } + else { + tar = params[2]; + } + return tar && tar.name + '
' + tar.seriesName + ' : ' + tar.value; + } + }, + legend: { + data: ['Expenses', 'Income'] + }, + grid: { + left: '3%', + right: '4%', + bottom: '3%', + containLabel: true + }, + xAxis: { + type: 'category', + data: (function () { + let list = []; + for (let i = 1; i <= 11; i++) { + list.push('Nov ' + i); + } + return list; + })() + }, + yAxis: { + type: 'value' + }, + series: [ + { + name: 'Placeholder', + type: 'bar', + stack: 'Total', + silent: true, + itemStyle: { + borderColor: 'transparent', + color: 'transparent' + }, + emphasis: { + itemStyle: { + borderColor: 'transparent', + color: 'transparent' + } + }, + data: [0, 900, 1245, 1530, 1376, 1376, 1511, 1689, 1856, 1495, 1292] + }, + { + name: 'Income', + type: 'bar', + stack: 'Total', + label: { + show: true, + position: 'top' + }, + data: [900, 345, 393, '-', '-', 135, 178, 286, '-', '-', '-'] + }, + { + name: 'Expenses', + type: 'bar', + stack: 'Total', + label: { + show: true, + position: 'bottom' + }, + data: ['-', '-', '-', 108, 154, '-', '-', '-', 119, 361, 203] + } + ] +}; +export {}; diff --git a/testdata/bar-waterfall2.js.svg b/testdata/bar-waterfall2.js.svg new file mode 100644 index 0000000..0222047 --- /dev/null +++ b/testdata/bar-waterfall2.js.svg @@ -0,0 +1,318 @@ + + + + + + + + + + + + + + + + + + + + + + + +0 +300 +600 +900 +1,200 +1,500 +1,800 +2,100 +Nov 1 +Nov 2 +Nov 3 +Nov 4 +Nov 5 +Nov 6 +Nov 7 +Nov 8 +Nov 9 +Nov 10 +Nov 11 + + + + + + + + + + + + + + + + + + + + + + +900 +345 +393 +135 +178 +286 +108 +154 +119 +361 +203 + + +Expenses + +Income + +Accumulated Waterfall Chart + + \ No newline at end of file diff --git a/testdata/bar-y-category-stack.js b/testdata/bar-y-category-stack.js new file mode 100644 index 0000000..ee5a172 --- /dev/null +++ b/testdata/bar-y-category-stack.js @@ -0,0 +1,92 @@ +/* +title: Stacked Horizontal Bar +titleCN: 堆叠条形图 +category: bar +difficulty: 3 +*/ +option = { + tooltip: { + trigger: 'axis', + axisPointer: { + // Use axis to trigger tooltip + type: 'shadow' // 'shadow' as default; can also be 'line' or 'shadow' + } + }, + legend: {}, + grid: { + left: '3%', + right: '4%', + bottom: '3%', + containLabel: true + }, + xAxis: { + type: 'value' + }, + yAxis: { + type: 'category', + data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'] + }, + series: [ + { + name: 'Direct', + type: 'bar', + stack: 'total', + label: { + show: true + }, + emphasis: { + focus: 'series' + }, + data: [320, 302, 301, 334, 390, 330, 320] + }, + { + name: 'Mail Ad', + type: 'bar', + stack: 'total', + label: { + show: true + }, + emphasis: { + focus: 'series' + }, + data: [120, 132, 101, 134, 90, 230, 210] + }, + { + name: 'Affiliate Ad', + type: 'bar', + stack: 'total', + label: { + show: true + }, + emphasis: { + focus: 'series' + }, + data: [220, 182, 191, 234, 290, 330, 310] + }, + { + name: 'Video Ad', + type: 'bar', + stack: 'total', + label: { + show: true + }, + emphasis: { + focus: 'series' + }, + data: [150, 212, 201, 154, 190, 330, 410] + }, + { + name: 'Search Engine', + type: 'bar', + stack: 'total', + label: { + show: true + }, + emphasis: { + focus: 'series' + }, + data: [820, 832, 901, 934, 1290, 1330, 1320] + } + ] +}; +export {}; diff --git a/testdata/bar-y-category-stack.js.svg b/testdata/bar-y-category-stack.js.svg new file mode 100644 index 0000000..d44e324 --- /dev/null +++ b/testdata/bar-y-category-stack.js.svg @@ -0,0 +1,503 @@ + + + + + + + + + + + + + + + + + + +Mon +Tue +Wed +Thu +Fri +Sat +Sun +0 +500 +1,000 +1,500 +2,000 +2,500 +3,000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +320 +302 +301 +334 +390 +330 +320 +120 +132 +101 +134 +90 +230 +210 +220 +182 +191 +234 +290 +330 +310 +150 +212 +201 +154 +190 +330 +410 +820 +832 +901 +934 +1290 +1330 +1320 + + +Direct + +Mail Ad + +Affiliate Ad + +Video Ad + +Search Engine + + \ No newline at end of file diff --git a/testdata/bar-y-category.js b/testdata/bar-y-category.js new file mode 100644 index 0000000..7813df0 --- /dev/null +++ b/testdata/bar-y-category.js @@ -0,0 +1,45 @@ +/* +title: World Population +category: bar +titleCN: 世界人口总量 - 条形图 +difficulty: 2 +*/ +option = { + title: { + text: 'World Population' + }, + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'shadow' + } + }, + legend: {}, + grid: { + left: '3%', + right: '4%', + bottom: '3%', + containLabel: true + }, + xAxis: { + type: 'value', + boundaryGap: [0, 0.01] + }, + yAxis: { + type: 'category', + data: ['Brazil', 'Indonesia', 'USA', 'India', 'China', 'World'] + }, + series: [ + { + name: '2011', + type: 'bar', + data: [18203, 23489, 29034, 104970, 131744, 630230] + }, + { + name: '2012', + type: 'bar', + data: [19325, 23438, 31000, 121594, 134141, 681807] + } + ] +}; +export {}; diff --git a/testdata/bar-y-category.js.svg b/testdata/bar-y-category.js.svg new file mode 100644 index 0000000..c0ea250 --- /dev/null +++ b/testdata/bar-y-category.js.svg @@ -0,0 +1,188 @@ + + + + + + + + + + + + + + + + + + +Brazil +Indonesia +USA +India +China +World +0 +100,000 +200,000 +300,000 +400,000 +500,000 +600,000 +700,000 + + + + + + + + + + + + + + +2011 + +2012 + +World Population + + \ No newline at end of file diff --git a/testdata/bar1.js b/testdata/bar1.js new file mode 100644 index 0000000..050a75b --- /dev/null +++ b/testdata/bar1.js @@ -0,0 +1,75 @@ +/* +title: Rainfall and Evaporation +category: bar +titleCN: 某地区蒸发量和降水量 +difficulty: 4 +*/ +option = { + title: { + text: 'Rainfall vs Evaporation', + subtext: 'Fake Data' + }, + tooltip: { + trigger: 'axis' + }, + legend: { + data: ['Rainfall', 'Evaporation'] + }, + toolbox: { + show: true, + feature: { + dataView: { show: true, readOnly: false }, + magicType: { show: true, type: ['line', 'bar'] }, + restore: { show: true }, + saveAsImage: { show: true } + } + }, + calculable: true, + xAxis: [ + { + type: 'category', + // prettier-ignore + data: ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'] + } + ], + yAxis: [ + { + type: 'value' + } + ], + series: [ + { + name: 'Rainfall', + type: 'bar', + data: [ + 2.0, 4.9, 7.0, 23.2, 25.6, 76.7, 135.6, 162.2, 32.6, 20.0, 6.4, 3.3 + ], + markPoint: { + data: [ + { type: 'max', name: 'Max' }, + { type: 'min', name: 'Min' } + ] + }, + markLine: { + data: [{ type: 'average', name: 'Avg' }] + } + }, + { + name: 'Evaporation', + type: 'bar', + data: [ + 2.6, 5.9, 9.0, 26.4, 28.7, 70.7, 175.6, 182.2, 48.7, 18.8, 6.0, 2.3 + ], + markPoint: { + data: [ + { name: 'Max', value: 182.2, xAxis: 7, yAxis: 183 }, + { name: 'Min', value: 2.3, xAxis: 11, yAxis: 3 } + ] + }, + markLine: { + data: [{ type: 'average', name: 'Avg' }] + } + } + ] +}; +export {}; diff --git a/testdata/bar1.js.svg b/testdata/bar1.js.svg new file mode 100644 index 0000000..c6d4f56 --- /dev/null +++ b/testdata/bar1.js.svg @@ -0,0 +1,367 @@ + + + + + + + + + + + + + + + + + + + + + + + + +0 +30 +60 +90 +120 +150 +180 +210 +Jan +Feb +Mar +Apr +May +Jun +Jul +Aug +Sep +Oct +Nov +Dec + + + + + + + + + + + + + + + + + + + + + + + + + + +Rainfall + +Evaporation + + + + + + +41.63 +48.07 + + + + +162.2 +2 +182.2 +2.3 + + + + + + + +Rainfall vs Evaporation +Fake Data + + \ No newline at end of file diff --git a/testdata/boxplot-light-velocity.js b/testdata/boxplot-light-velocity.js new file mode 100644 index 0000000..32964d7 --- /dev/null +++ b/testdata/boxplot-light-velocity.js @@ -0,0 +1,89 @@ +/* +title: Boxplot Light Velocity +category: boxplot +titleCN: 基础盒须图 +*/ +option = { + title: [ + { + text: 'Michelson-Morley Experiment', + left: 'center' + }, + { + text: 'upper: Q3 + 1.5 * IQR \nlower: Q1 - 1.5 * IQR', + borderColor: '#999', + borderWidth: 1, + textStyle: { + fontWeight: 'normal', + fontSize: 14, + lineHeight: 20 + }, + left: '10%', + top: '90%' + } + ], + dataset: [ + { + // prettier-ignore + source: [ + [850, 740, 900, 1070, 930, 850, 950, 980, 980, 880, 1000, 980, 930, 650, 760, 810, 1000, 1000, 960, 960], + [960, 940, 960, 940, 880, 800, 850, 880, 900, 840, 830, 790, 810, 880, 880, 830, 800, 790, 760, 800], + [880, 880, 880, 860, 720, 720, 620, 860, 970, 950, 880, 910, 850, 870, 840, 840, 850, 840, 840, 840], + [890, 810, 810, 820, 800, 770, 760, 740, 750, 760, 910, 920, 890, 860, 880, 720, 840, 850, 850, 780], + [890, 840, 780, 810, 760, 810, 790, 810, 820, 850, 870, 870, 810, 740, 810, 940, 950, 800, 810, 870] + ] + }, + { + transform: { + type: 'boxplot', + config: { itemNameFormatter: 'expr {value}' } + } + }, + { + fromDatasetIndex: 1, + fromTransformResult: 1 + } + ], + tooltip: { + trigger: 'item', + axisPointer: { + type: 'shadow' + } + }, + grid: { + left: '10%', + right: '10%', + bottom: '15%' + }, + xAxis: { + type: 'category', + boundaryGap: true, + nameGap: 30, + splitArea: { + show: false + }, + splitLine: { + show: false + } + }, + yAxis: { + type: 'value', + name: 'km/s minus 299,000', + splitArea: { + show: true + } + }, + series: [ + { + name: 'boxplot', + type: 'boxplot', + datasetIndex: 1 + }, + { + name: 'outlier', + type: 'scatter', + datasetIndex: 2 + } + ] +}; +export {}; diff --git a/testdata/boxplot-light-velocity.js.svg b/testdata/boxplot-light-velocity.js.svg new file mode 100644 index 0000000..6667a19 --- /dev/null +++ b/testdata/boxplot-light-velocity.js.svg @@ -0,0 +1,135 @@ + + + + + + + + + + + + + + + +km/s minus 299,000 + + + + + + + +0 +200 +400 +600 +800 +1,000 +1,200 +expr 0 +expr 1 +expr 2 +expr 3 +expr 4 + + + + + + + + + + + + + +Michelson-Morley Experiment + +upper: Q3 + 1.5 * IQR +lower: Q1 - 1.5 * IQR + + \ No newline at end of file diff --git a/testdata/boxplot-light-velocity2.js b/testdata/boxplot-light-velocity2.js new file mode 100644 index 0000000..c79ac64 --- /dev/null +++ b/testdata/boxplot-light-velocity2.js @@ -0,0 +1,92 @@ +/* +title: Boxplot Light Velocity2 +category: boxplot +titleCN: 垂直方向盒须图 +*/ +option = { + title: [ + { + text: 'Michelson-Morley Experiment', + left: 'center' + }, + { + text: 'upper: Q3 + 1.5 * IQR \nlower: Q1 - 1.5 * IQR', + borderColor: '#999', + borderWidth: 1, + textStyle: { + fontSize: 14 + }, + left: '10%', + top: '90%' + } + ], + dataset: [ + { + // prettier-ignore + source: [ + [850, 740, 900, 1070, 930, 850, 950, 980, 980, 880, 1000, 980, 930, 650, 760, 810, 1000, 1000, 960, 960], + [960, 940, 960, 940, 880, 800, 850, 880, 900, 840, 830, 790, 810, 880, 880, 830, 800, 790, 760, 800], + [880, 880, 880, 860, 720, 720, 620, 860, 970, 950, 880, 910, 850, 870, 840, 840, 850, 840, 840, 840], + [890, 810, 810, 820, 800, 770, 760, 740, 750, 760, 910, 920, 890, 860, 880, 720, 840, 850, 850, 780], + [890, 840, 780, 810, 760, 810, 790, 810, 820, 850, 870, 870, 810, 740, 810, 940, 950, 800, 810, 870] + ] + }, + { + transform: { + type: 'boxplot', + config: { + itemNameFormatter: function (params) { + return 'expr ' + params.value; + } + } + } + }, + { + fromDatasetIndex: 1, + fromTransformResult: 1 + } + ], + tooltip: { + trigger: 'item', + axisPointer: { + type: 'shadow' + } + }, + grid: { + left: '10%', + right: '10%', + bottom: '15%' + }, + yAxis: { + type: 'category', + boundaryGap: true, + nameGap: 30, + splitArea: { + show: false + }, + splitLine: { + show: false + } + }, + xAxis: { + type: 'value', + name: 'km/s minus 299,000', + splitArea: { + show: true + } + }, + series: [ + { + name: 'boxplot', + type: 'boxplot', + datasetIndex: 1 + }, + { + name: 'outlier', + type: 'scatter', + encode: { x: 1, y: 0 }, + datasetIndex: 2 + } + ] +}; +export {}; diff --git a/testdata/boxplot-light-velocity2.js.svg b/testdata/boxplot-light-velocity2.js.svg new file mode 100644 index 0000000..66993a7 --- /dev/null +++ b/testdata/boxplot-light-velocity2.js.svg @@ -0,0 +1,134 @@ + + + + + + + + + + + + + + + + +km/s minus 299,000 + + + + + + +0 +1 +2 +3 +4 +0 +200 +400 +600 +800 +1,000 +1,200 + + + + + + + + + + + + + +Michelson-Morley Experiment +upper: Q3 + 1.5 * IQR +lower: Q1 - 1.5 * IQR + + \ No newline at end of file diff --git a/testdata/boxplot-multi.js b/testdata/boxplot-multi.js new file mode 100644 index 0000000..a875f6d --- /dev/null +++ b/testdata/boxplot-multi.js @@ -0,0 +1,117 @@ +/* +title: Multiple Categories +category: boxplot +titleCN: 多系列盒须图 +*/ +// Generate data. +function makeData() { + let data = []; + for (let i = 0; i < 18; i++) { + let cate = []; + for (let j = 0; j < 100; j++) { + cate.push(Math.random() * 200); + } + data.push(cate); + } + return data; +} +const data0 = makeData(); +const data1 = makeData(); +const data2 = makeData(); +option = { + title: { + text: 'Multiple Categories', + left: 'center' + }, + dataset: [ + { + source: data0 + }, + { + source: data1 + }, + { + source: data2 + }, + { + fromDatasetIndex: 0, + transform: { type: 'boxplot' } + }, + { + fromDatasetIndex: 1, + transform: { type: 'boxplot' } + }, + { + fromDatasetIndex: 2, + transform: { type: 'boxplot' } + } + ], + legend: { + top: '10%' + }, + tooltip: { + trigger: 'item', + axisPointer: { + type: 'shadow' + } + }, + grid: { + left: '10%', + top: '20%', + right: '10%', + bottom: '15%' + }, + xAxis: { + type: 'category', + boundaryGap: true, + nameGap: 30, + splitArea: { + show: true + }, + splitLine: { + show: false + } + }, + yAxis: { + type: 'value', + name: 'Value', + min: -400, + max: 600, + splitArea: { + show: false + } + }, + dataZoom: [ + { + type: 'inside', + start: 0, + end: 20 + }, + { + show: true, + type: 'slider', + top: '90%', + xAxisIndex: [0], + start: 0, + end: 20 + } + ], + series: [ + { + name: 'category0', + type: 'boxplot', + datasetIndex: 3 + }, + { + name: 'category1', + type: 'boxplot', + datasetIndex: 4 + }, + { + name: 'category2', + type: 'boxplot', + datasetIndex: 5 + } + ] +}; +export {}; diff --git a/testdata/boxplot-multi.js.svg b/testdata/boxplot-multi.js.svg new file mode 100644 index 0000000..603aec4 --- /dev/null +++ b/testdata/boxplot-multi.js.svg @@ -0,0 +1,59 @@ + + + + + + + + + + + + +Value + + + + + + +-400 +-200 +0 +200 +400 +600 +0 +1 +2 +3 + + + + + + + + + + + + + + + +category0 + +category1 + +category2 + + + + + + + + +Multiple Categories + \ No newline at end of file diff --git a/testdata/bubble-gradient.js b/testdata/bubble-gradient.js new file mode 100644 index 0000000..7bc0009 --- /dev/null +++ b/testdata/bubble-gradient.js @@ -0,0 +1,160 @@ +/* +title: Bubble Chart +category: scatter +titleCN: 气泡图 +difficulty: 6 +*/ +const data = [ + [ + [28604, 77, 17096869, 'Australia', 1990], + [31163, 77.4, 27662440, 'Canada', 1990], + [1516, 68, 1154605773, 'China', 1990], + [13670, 74.7, 10582082, 'Cuba', 1990], + [28599, 75, 4986705, 'Finland', 1990], + [29476, 77.1, 56943299, 'France', 1990], + [31476, 75.4, 78958237, 'Germany', 1990], + [28666, 78.1, 254830, 'Iceland', 1990], + [1777, 57.7, 870601776, 'India', 1990], + [29550, 79.1, 122249285, 'Japan', 1990], + [2076, 67.9, 20194354, 'North Korea', 1990], + [12087, 72, 42972254, 'South Korea', 1990], + [24021, 75.4, 3397534, 'New Zealand', 1990], + [43296, 76.8, 4240375, 'Norway', 1990], + [10088, 70.8, 38195258, 'Poland', 1990], + [19349, 69.6, 147568552, 'Russia', 1990], + [10670, 67.3, 53994605, 'Turkey', 1990], + [26424, 75.7, 57110117, 'United Kingdom', 1990], + [37062, 75.4, 252847810, 'United States', 1990] + ], + [ + [44056, 81.8, 23968973, 'Australia', 2015], + [43294, 81.7, 35939927, 'Canada', 2015], + [13334, 76.9, 1376048943, 'China', 2015], + [21291, 78.5, 11389562, 'Cuba', 2015], + [38923, 80.8, 5503457, 'Finland', 2015], + [37599, 81.9, 64395345, 'France', 2015], + [44053, 81.1, 80688545, 'Germany', 2015], + [42182, 82.8, 329425, 'Iceland', 2015], + [5903, 66.8, 1311050527, 'India', 2015], + [36162, 83.5, 126573481, 'Japan', 2015], + [1390, 71.4, 25155317, 'North Korea', 2015], + [34644, 80.7, 50293439, 'South Korea', 2015], + [34186, 80.6, 4528526, 'New Zealand', 2015], + [64304, 81.6, 5210967, 'Norway', 2015], + [24787, 77.3, 38611794, 'Poland', 2015], + [23038, 73.13, 143456918, 'Russia', 2015], + [19360, 76.5, 78665830, 'Turkey', 2015], + [38225, 81.4, 64715810, 'United Kingdom', 2015], + [53354, 79.1, 321773631, 'United States', 2015] + ] +]; +option = { + backgroundColor: new echarts.graphic.RadialGradient(0.3, 0.3, 0.8, [ + { + offset: 0, + color: '#f7f8fa' + }, + { + offset: 1, + color: '#cdd0d5' + } + ]), + title: { + text: 'Life Expectancy and GDP by Country', + left: '5%', + top: '3%' + }, + legend: { + right: '10%', + top: '3%', + data: ['1990', '2015'] + }, + grid: { + left: '8%', + top: '10%' + }, + xAxis: { + splitLine: { + lineStyle: { + type: 'dashed' + } + } + }, + yAxis: { + splitLine: { + lineStyle: { + type: 'dashed' + } + }, + scale: true + }, + series: [ + { + name: '1990', + data: data[0], + type: 'scatter', + symbolSize: function (data) { + return Math.sqrt(data[2]) / 5e2; + }, + emphasis: { + focus: 'series', + label: { + show: true, + formatter: function (param) { + return param.data[3]; + }, + position: 'top' + } + }, + itemStyle: { + shadowBlur: 10, + shadowColor: 'rgba(120, 36, 50, 0.5)', + shadowOffsetY: 5, + color: new echarts.graphic.RadialGradient(0.4, 0.3, 1, [ + { + offset: 0, + color: 'rgb(251, 118, 123)' + }, + { + offset: 1, + color: 'rgb(204, 46, 72)' + } + ]) + } + }, + { + name: '2015', + data: data[1], + type: 'scatter', + symbolSize: function (data) { + return Math.sqrt(data[2]) / 5e2; + }, + emphasis: { + focus: 'series', + label: { + show: true, + formatter: function (param) { + return param.data[3]; + }, + position: 'top' + } + }, + itemStyle: { + shadowBlur: 10, + shadowColor: 'rgba(25, 100, 150, 0.5)', + shadowOffsetY: 5, + color: new echarts.graphic.RadialGradient(0.4, 0.3, 1, [ + { + offset: 0, + color: 'rgb(129, 227, 238)' + }, + { + offset: 1, + color: 'rgb(25, 183, 207)' + } + ]) + } + } + ] +}; +export {}; diff --git a/testdata/bubble-gradient.js.svg b/testdata/bubble-gradient.js.svg new file mode 100644 index 0000000..5c93962 --- /dev/null +++ b/testdata/bubble-gradient.js.svg @@ -0,0 +1,613 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +55 +60 +65 +70 +75 +80 +85 +0 +10,000 +20,000 +30,000 +40,000 +50,000 +60,000 +70,000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +1990 + +2015 + +Life Expectancy and GDP by Country + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/bump-chart.js b/testdata/bump-chart.js new file mode 100644 index 0000000..81eeda4 --- /dev/null +++ b/testdata/bump-chart.js @@ -0,0 +1,113 @@ +/* +title: Bump Chart (Ranking) +category: line +titleCN: 凹凸图 +difficulty: 2 +*/ +const names = [ + 'Orange', + 'Tomato', + 'Apple', + 'Sakana', + 'Banana', + 'Iwashi', + 'Snappy Fish', + 'Lemon', + 'Pasta' +]; +const years = ['2001', '2002', '2003', '2004', '2005', '2006']; +const shuffle = (array) => { + let currentIndex = array.length; + let randomIndex = 0; + while (currentIndex > 0) { + randomIndex = Math.floor(Math.random() * currentIndex); + currentIndex--; + [array[currentIndex], array[randomIndex]] = [ + array[randomIndex], + array[currentIndex] + ]; + } + return array; +}; +const generateRankingData = () => { + const map = new Map(); + const defaultRanking = Array.from({ length: names.length }, (_, i) => i + 1); + for (const _ of years) { + const shuffleArray = shuffle(defaultRanking); + names.forEach((name, i) => { + map.set(name, (map.get(name) || []).concat(shuffleArray[i])); + }); + } + return map; +}; +const generateSeriesList = () => { + const seriesList = []; + const rankingMap = generateRankingData(); + rankingMap.forEach((data, name) => { + const series = { + name, + symbolSize: 20, + type: 'line', + smooth: true, + emphasis: { + focus: 'series' + }, + endLabel: { + show: true, + formatter: '{a}', + distance: 20 + }, + lineStyle: { + width: 4 + }, + data + }; + seriesList.push(series); + }); + return seriesList; +}; +option = { + title: { + text: 'Bump Chart (Ranking)' + }, + tooltip: { + trigger: 'item' + }, + grid: { + left: 30, + right: 110, + bottom: 30, + containLabel: true + }, + toolbox: { + feature: { + saveAsImage: {} + } + }, + xAxis: { + type: 'category', + splitLine: { + show: true + }, + axisLabel: { + margin: 30, + fontSize: 16 + }, + boundaryGap: false, + data: years + }, + yAxis: { + type: 'value', + axisLabel: { + margin: 30, + fontSize: 16, + formatter: '#{value}' + }, + inverse: true, + interval: 1, + min: 1, + max: names.length + }, + series: generateSeriesList() +}; +export {}; diff --git a/testdata/bump-chart.js.svg b/testdata/bump-chart.js.svg new file mode 100644 index 0000000..4edf096 --- /dev/null +++ b/testdata/bump-chart.js.svg @@ -0,0 +1,266 @@ + + + + + + + + + + + + + + + + + + + + + + + + +#1 +#2 +#3 +#4 +#5 +#6 +#7 +#8 +#9 +2001 +2002 +2003 +2004 +2005 +2006 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Orange +Tomato +Apple +Sakana +Banana +Iwashi +Snappy Fish +Lemon +Pasta + + + +Bump Chart (Ranking) + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/calendar-charts.js b/testdata/calendar-charts.js new file mode 100644 index 0000000..e39c5d6 --- /dev/null +++ b/testdata/calendar-charts.js @@ -0,0 +1,173 @@ +/* +title: Calendar Charts +category: 'calendar, scatter' +titleCN: 日历图 +shotWidth: 1000 +difficulty: 11 +*/ +function getVirtualData(year) { + const date = +echarts.time.parse(year + '-01-01'); + const end = +echarts.time.parse(+year + 1 + '-01-01'); + const dayTime = 3600 * 24 * 1000; + const data = []; + for (let time = date; time < end; time += dayTime) { + data.push([ + echarts.time.format(time, '{yyyy}-{MM}-{dd}', false), + Math.floor(Math.random() * 1000) + ]); + } + return data; +} +const graphData = [ + ['2017-02-01', 260], + ['2017-02-04', 200], + ['2017-02-09', 279], + ['2017-02-13', 847], + ['2017-02-18', 241], + ['2017-02-23', 411], + ['2017-02-27', 985] +]; +const links = graphData.map(function (item, idx) { + return { + source: idx, + target: idx + 1 + }; +}); +links.pop(); +option = { + tooltip: { + position: 'top' + }, + visualMap: [ + { + min: 0, + max: 1000, + calculable: true, + seriesIndex: [2, 3, 4], + orient: 'horizontal', + left: '55%', + bottom: 20 + }, + { + min: 0, + max: 1000, + inRange: { + color: ['grey'], + opacity: [0, 0.3] + }, + controller: { + inRange: { + opacity: [0.3, 0.6] + }, + outOfRange: { + color: '#ccc' + } + }, + seriesIndex: [1], + orient: 'horizontal', + left: '10%', + bottom: 20 + } + ], + calendar: [ + { + orient: 'vertical', + yearLabel: { + margin: 40 + }, + monthLabel: { + nameMap: 'cn', + margin: 20 + }, + dayLabel: { + firstDay: 1, + nameMap: 'cn' + }, + cellSize: 40, + range: '2017-02' + }, + { + orient: 'vertical', + yearLabel: { + margin: 40 + }, + monthLabel: { + margin: 20 + }, + cellSize: 40, + left: 460, + range: '2017-01' + }, + { + orient: 'vertical', + yearLabel: { + margin: 40 + }, + monthLabel: { + margin: 20 + }, + cellSize: 40, + top: 350, + range: '2017-03' + }, + { + orient: 'vertical', + yearLabel: { + margin: 40 + }, + dayLabel: { + firstDay: 1, + nameMap: ['Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat'] + }, + monthLabel: { + nameMap: 'cn', + margin: 20 + }, + cellSize: 40, + top: 350, + left: 460, + range: '2017-04' + } + ], + series: [ + { + type: 'graph', + edgeSymbol: ['none', 'arrow'], + coordinateSystem: 'calendar', + links: links, + symbolSize: 10, + calendarIndex: 0, + data: graphData + }, + { + type: 'heatmap', + coordinateSystem: 'calendar', + data: getVirtualData('2017') + }, + { + type: 'effectScatter', + coordinateSystem: 'calendar', + calendarIndex: 1, + symbolSize: function (val) { + return val[1] / 40; + }, + data: getVirtualData('2017') + }, + { + type: 'scatter', + coordinateSystem: 'calendar', + calendarIndex: 2, + symbolSize: function (val) { + return val[1] / 60; + }, + data: getVirtualData('2017') + }, + { + type: 'heatmap', + coordinateSystem: 'calendar', + calendarIndex: 3, + data: getVirtualData('2017') + } + ] +}; +export {}; diff --git a/testdata/calendar-charts.js.svg b/testdata/calendar-charts.js.svg new file mode 100644 index 0000000..53dc9d7 --- /dev/null +++ b/testdata/calendar-charts.js.svg @@ -0,0 +1,3809 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +2017 +Feb +M +T +W +T +F +S +S +2017 +Jan +S +M +T +W +T +F +S +2017 +Mar +S +M +T +W +T +F +S +2017 +Apr +Mon +Tue +Wed +Thu +Fri +Sat +Sun + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +0 +1000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/calendar-effectscatter.js b/testdata/calendar-effectscatter.js new file mode 100644 index 0000000..70e5773 --- /dev/null +++ b/testdata/calendar-effectscatter.js @@ -0,0 +1,164 @@ +/* +title: Calendar EffectScatter +category: calendar +titleCN: 热力特效散点图 +difficulty:3 +*/ +function getVirtualData(year) { + const date = +echarts.time.parse(year + '-01-01'); + const end = +echarts.time.parse(+year + 1 + '-01-01'); + const dayTime = 3600 * 24 * 1000; + const data = []; + for (let time = date; time < end; time += dayTime) { + data.push([ + echarts.time.format(time, '{yyyy}-{MM}-{dd}', false), + Math.floor(Math.random() * 10000) + ]); + } + return data; +} +const data = getVirtualData('2016'); +option = { + backgroundColor: '#404a59', + title: { + top: 30, + text: 'Daily Step Count in 2016', + subtext: 'Fake Data', + left: 'center', + textStyle: { + color: '#fff' + } + }, + tooltip: { + trigger: 'item' + }, + legend: { + top: '30', + left: '100', + data: ['Steps', 'Top 12'], + textStyle: { + color: '#fff' + } + }, + calendar: [ + { + top: 100, + left: 'center', + range: ['2016-01-01', '2016-06-30'], + splitLine: { + show: true, + lineStyle: { + color: '#000', + width: 4, + type: 'solid' + } + }, + yearLabel: { + formatter: '{start} 1st', + color: '#fff' + }, + itemStyle: { + color: '#323c48', + borderWidth: 1, + borderColor: '#111' + } + }, + { + top: 340, + left: 'center', + range: ['2016-07-01', '2016-12-31'], + splitLine: { + show: true, + lineStyle: { + color: '#000', + width: 4, + type: 'solid' + } + }, + yearLabel: { + formatter: '{start} 2nd', + color: '#fff' + }, + itemStyle: { + color: '#323c48', + borderWidth: 1, + borderColor: '#111' + } + } + ], + series: [ + { + name: 'Steps', + type: 'scatter', + coordinateSystem: 'calendar', + data: data, + symbolSize: function (val) { + return val[1] / 500; + }, + itemStyle: { + color: '#ddb926' + } + }, + { + name: 'Steps', + type: 'scatter', + coordinateSystem: 'calendar', + calendarIndex: 1, + data: data, + symbolSize: function (val) { + return val[1] / 500; + }, + itemStyle: { + color: '#ddb926' + } + }, + { + name: 'Top 12', + type: 'effectScatter', + coordinateSystem: 'calendar', + calendarIndex: 1, + data: data + .sort(function (a, b) { + return b[1] - a[1]; + }) + .slice(0, 12), + symbolSize: function (val) { + return val[1] / 500; + }, + showEffectOn: 'render', + rippleEffect: { + brushType: 'stroke' + }, + itemStyle: { + color: '#f4e925', + shadowBlur: 10, + shadowColor: '#333' + }, + zlevel: 1 + }, + { + name: 'Top 12', + type: 'effectScatter', + coordinateSystem: 'calendar', + data: data + .sort(function (a, b) { + return b[1] - a[1]; + }) + .slice(0, 12), + symbolSize: function (val) { + return val[1] / 500; + }, + showEffectOn: 'render', + rippleEffect: { + brushType: 'stroke' + }, + itemStyle: { + color: '#f4e925', + shadowBlur: 10, + shadowColor: '#333' + }, + zlevel: 1 + } + ] +}; +export {}; diff --git a/testdata/calendar-effectscatter.js.svg b/testdata/calendar-effectscatter.js.svg new file mode 100644 index 0000000..b6407f5 --- /dev/null +++ b/testdata/calendar-effectscatter.js.svg @@ -0,0 +1,6300 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +2016 1st +Jan +Feb +Mar +Apr +May +Jun +S +M +T +W +T +F +S +2016 2nd +Jul +Aug +Sep +Oct +Nov +Dec +S +M +T +W +T +F +S + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Steps + +Top 12 + +Daily Step Count in 2016 +Fake Data + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/calendar-graph.js b/testdata/calendar-graph.js new file mode 100644 index 0000000..9a6347a --- /dev/null +++ b/testdata/calendar-graph.js @@ -0,0 +1,101 @@ +/* +title: Calendar Graph +category: 'calendar, graph' +titleCN: 日历关系图 +difficulty: 4 +*/ +const graphData = [ + ['2017-02-01', 260], + ['2017-02-04', 200], + ['2017-02-09', 279], + ['2017-02-13', 847], + ['2017-02-18', 241], + ['2017-02-23', 411], + ['2017-03-14', 985] +]; +const links = graphData.map(function (item, idx) { + return { + source: idx, + target: idx + 1 + }; +}); +links.pop(); +function getVirtualData(year) { + const date = +echarts.time.parse(year + '-01-01'); + const end = +echarts.time.parse(+year + 1 + '-01-01'); + const dayTime = 3600 * 24 * 1000; + const data = []; + for (let time = date; time < end; time += dayTime) { + data.push([ + echarts.time.format(time, '{yyyy}-{MM}-{dd}', false), + Math.floor(Math.random() * 1000) + ]); + } + return data; +} +option = { + tooltip: {}, + calendar: { + top: 'middle', + left: 'center', + orient: 'vertical', + cellSize: 40, + yearLabel: { + margin: 50, + fontSize: 30 + }, + dayLabel: { + firstDay: 1, + nameMap: 'cn' + }, + monthLabel: { + nameMap: 'cn', + margin: 15, + fontSize: 20, + color: '#999' + }, + range: ['2017-02', '2017-03-31'] + }, + visualMap: { + min: 0, + max: 1000, + type: 'piecewise', + left: 'center', + bottom: 20, + inRange: { + color: ['#5291FF', '#C7DBFF'] + }, + seriesIndex: [1], + orient: 'horizontal' + }, + series: [ + { + type: 'graph', + edgeSymbol: ['none', 'arrow'], + coordinateSystem: 'calendar', + links: links, + symbolSize: 15, + calendarIndex: 0, + itemStyle: { + color: 'yellow', + shadowBlur: 9, + shadowOffsetX: 1.5, + shadowOffsetY: 3, + shadowColor: '#555' + }, + lineStyle: { + color: '#D10E00', + width: 1, + opacity: 1 + }, + data: graphData, + z: 20 + }, + { + type: 'heatmap', + coordinateSystem: 'calendar', + data: getVirtualData('2017') + } + ] +}; +export {}; diff --git a/testdata/calendar-graph.js.svg b/testdata/calendar-graph.js.svg new file mode 100644 index 0000000..842319e --- /dev/null +++ b/testdata/calendar-graph.js.svg @@ -0,0 +1,572 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +2017 +Feb +Mar +M +T +W +T +F +S +S + + +0 - 200 + +200 - 400 + +400 - 600 + +600 - 800 + +800 - 1000 + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/calendar-heatmap.js b/testdata/calendar-heatmap.js new file mode 100644 index 0000000..41f0c81 --- /dev/null +++ b/testdata/calendar-heatmap.js @@ -0,0 +1,52 @@ +/* +title: Calendar Heatmap +category: 'calendar, heatmap' +titleCN: 日历热力图 +difficulty: 1 +*/ +function getVirtualData(year) { + const date = +echarts.time.parse(year + '-01-01'); + const end = +echarts.time.parse(+year + 1 + '-01-01'); + const dayTime = 3600 * 24 * 1000; + const data = []; + for (let time = date; time < end; time += dayTime) { + data.push([ + echarts.time.format(time, '{yyyy}-{MM}-{dd}', false), + Math.floor(Math.random() * 10000) + ]); + } + return data; +} +option = { + title: { + top: 30, + left: 'center', + text: 'Daily Step Count' + }, + tooltip: {}, + visualMap: { + min: 0, + max: 10000, + type: 'piecewise', + orient: 'horizontal', + left: 'center', + top: 65 + }, + calendar: { + top: 120, + left: 30, + right: 30, + cellSize: ['auto', 13], + range: '2016', + itemStyle: { + borderWidth: 0.5 + }, + yearLabel: { show: false } + }, + series: { + type: 'heatmap', + coordinateSystem: 'calendar', + data: getVirtualData('2016') + } +}; +export {}; diff --git a/testdata/calendar-heatmap.js.svg b/testdata/calendar-heatmap.js.svg new file mode 100644 index 0000000..db3b245 --- /dev/null +++ b/testdata/calendar-heatmap.js.svg @@ -0,0 +1,782 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Jan +Feb +Mar +Apr +May +Jun +Jul +Aug +Sep +Oct +Nov +Dec +S +M +T +W +T +F +S + + +0 - 2000 + +2000 - 4000 + +4000 - 6000 + +6000 - 8000 + +8000 - 10000 + +Daily Step Count + \ No newline at end of file diff --git a/testdata/calendar-horizontal.js b/testdata/calendar-horizontal.js new file mode 100644 index 0000000..fe85313 --- /dev/null +++ b/testdata/calendar-horizontal.js @@ -0,0 +1,71 @@ +"use strict"; +/* +title: Calendar Heatmap Horizontal +category: calendar +titleCN: 横向日历图 +shotWidth: 900 +difficulty: 2 +*/ +function getVirtualData(year) { + const date = +echarts.time.parse(year + '-01-01'); + const end = +echarts.time.parse(+year + 1 + '-01-01'); + const dayTime = 3600 * 24 * 1000; + const data = []; + for (let time = date; time < end; time += dayTime) { + data.push([ + echarts.time.format(time, '{yyyy}-{MM}-{dd}', false), + Math.floor(Math.random() * 1000) + ]); + } + return data; +} +option = { + tooltip: { + position: 'top' + }, + visualMap: { + min: 0, + max: 1000, + calculable: true, + orient: 'horizontal', + left: 'center', + top: 'top' + }, + calendar: [ + { + range: '2017', + cellSize: ['auto', 20] + }, + { + top: 260, + range: '2016', + cellSize: ['auto', 20] + }, + { + top: 450, + range: '2015', + cellSize: ['auto', 20], + right: 5 + } + ], + series: [ + { + type: 'heatmap', + coordinateSystem: 'calendar', + calendarIndex: 0, + data: getVirtualData('2017') + }, + { + type: 'heatmap', + coordinateSystem: 'calendar', + calendarIndex: 1, + data: getVirtualData('2016') + }, + { + type: 'heatmap', + coordinateSystem: 'calendar', + calendarIndex: 2, + data: getVirtualData('2015') + } + ] +}; diff --git a/testdata/calendar-horizontal.js.svg b/testdata/calendar-horizontal.js.svg new file mode 100644 index 0000000..8713c09 --- /dev/null +++ b/testdata/calendar-horizontal.js.svg @@ -0,0 +1,2520 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +2017 +Jan +Feb +Mar +Apr +May +Jun +Jul +Aug +Sep +Oct +Nov +Dec +S +M +T +W +T +F +S +2016 +Jan +Feb +Mar +Apr +May +Jun +Jul +Aug +Sep +Oct +Nov +Dec +S +M +T +W +T +F +S +2015 +Jan +Feb +Mar +Apr +May +Jun +Jul +Aug +Sep +Oct +Nov +Dec +S +M +T +W +T +F +S + +0 +1000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/calendar-lunar.js b/testdata/calendar-lunar.js new file mode 100644 index 0000000..af2f45f --- /dev/null +++ b/testdata/calendar-lunar.js @@ -0,0 +1,462 @@ +/* +title: Calendar Lunar +category: calendar +titleCN: 农历日历图 +difficulty: 4 +*/ +const dateList = [ + ['2017-1-1', '初四'], + ['2017-1-2', '初五'], + ['2017-1-3', '初六'], + ['2017-1-4', '初七'], + ['2017-1-5', '初八', '小寒'], + ['2017-1-6', '初九'], + ['2017-1-7', '初十'], + ['2017-1-8', '十一'], + ['2017-1-9', '十二'], + ['2017-1-10', '十三'], + ['2017-1-11', '十四'], + ['2017-1-12', '十五'], + ['2017-1-13', '十六'], + ['2017-1-14', '十七'], + ['2017-1-15', '十八'], + ['2017-1-16', '十九'], + ['2017-1-17', '二十'], + ['2017-1-18', '廿一'], + ['2017-1-19', '廿二'], + ['2017-1-20', '廿三', '大寒'], + ['2017-1-21', '廿四'], + ['2017-1-22', '廿五'], + ['2017-1-23', '廿六'], + ['2017-1-24', '廿七'], + ['2017-1-25', '廿八'], + ['2017-1-26', '廿九'], + ['2017-1-27', '三十'], + ['2017-1-28', '正月'], + ['2017-1-29', '初二'], + ['2017-1-30', '初三'], + ['2017-1-31', '初四'], + ['2017-2-1', '初五'], + ['2017-2-2', '初六'], + ['2017-2-3', '初七', '立春'], + ['2017-2-4', '初八'], + ['2017-2-5', '初九'], + ['2017-2-6', '初十'], + ['2017-2-7', '十一'], + ['2017-2-8', '十二'], + ['2017-2-9', '十三'], + ['2017-2-10', '十四'], + ['2017-2-11', '十五'], + ['2017-2-12', '十六'], + ['2017-2-13', '十七'], + ['2017-2-14', '十八'], + ['2017-2-15', '十九'], + ['2017-2-16', '二十'], + ['2017-2-17', '廿一'], + ['2017-2-18', '廿二', '雨水'], + ['2017-2-19', '廿三'], + ['2017-2-20', '廿四'], + ['2017-2-21', '廿五'], + ['2017-2-22', '廿六'], + ['2017-2-23', '廿七'], + ['2017-2-24', '廿八'], + ['2017-2-25', '廿九'], + ['2017-2-26', '二月'], + ['2017-2-27', '初二'], + ['2017-2-28', '初三'], + ['2017-3-1', '初四'], + ['2017-3-2', '初五'], + ['2017-3-3', '初六'], + ['2017-3-4', '初七'], + ['2017-3-5', '初八', '驚蟄'], + ['2017-3-6', '初九'], + ['2017-3-7', '初十'], + ['2017-3-8', '十一'], + ['2017-3-9', '十二'], + ['2017-3-10', '十三'], + ['2017-3-11', '十四'], + ['2017-3-12', '十五'], + ['2017-3-13', '十六'], + ['2017-3-14', '十七'], + ['2017-3-15', '十八'], + ['2017-3-16', '十九'], + ['2017-3-17', '二十'], + ['2017-3-18', '廿一'], + ['2017-3-19', '廿二'], + ['2017-3-20', '廿三', '春分'], + ['2017-3-21', '廿四'], + ['2017-3-22', '廿五'], + ['2017-3-23', '廿六'], + ['2017-3-24', '廿七'], + ['2017-3-25', '廿八'], + ['2017-3-26', '廿九'], + ['2017-3-27', '三十'], + ['2017-3-28', '三月'], + ['2017-3-29', '初二'], + ['2017-3-30', '初三'], + ['2017-3-31', '初四'], + ['2017-4-1', '初五'], + ['2017-4-2', '初六'], + ['2017-4-3', '初七'], + ['2017-4-4', '初八', '清明'], + ['2017-4-5', '初九'], + ['2017-4-6', '初十'], + ['2017-4-7', '十一'], + ['2017-4-8', '十二'], + ['2017-4-9', '十三'], + ['2017-4-10', '十四'], + ['2017-4-11', '十五'], + ['2017-4-12', '十六'], + ['2017-4-13', '十七'], + ['2017-4-14', '十八'], + ['2017-4-15', '十九'], + ['2017-4-16', '二十'], + ['2017-4-17', '廿一'], + ['2017-4-18', '廿二'], + ['2017-4-19', '廿三'], + ['2017-4-20', '廿四', '穀雨'], + ['2017-4-21', '廿五'], + ['2017-4-22', '廿六'], + ['2017-4-23', '廿七'], + ['2017-4-24', '廿八'], + ['2017-4-25', '廿九'], + ['2017-4-26', '四月'], + ['2017-4-27', '初二'], + ['2017-4-28', '初三'], + ['2017-4-29', '初四'], + ['2017-4-30', '初五'], + ['2017-5-1', '初六'], + ['2017-5-2', '初七'], + ['2017-5-3', '初八'], + ['2017-5-4', '初九'], + ['2017-5-5', '初十', '立夏'], + ['2017-5-6', '十一'], + ['2017-5-7', '十二'], + ['2017-5-8', '十三'], + ['2017-5-9', '十四'], + ['2017-5-10', '十五'], + ['2017-5-11', '十六'], + ['2017-5-12', '十七'], + ['2017-5-13', '十八'], + ['2017-5-14', '十九'], + ['2017-5-15', '二十'], + ['2017-5-16', '廿一'], + ['2017-5-17', '廿二'], + ['2017-5-18', '廿三'], + ['2017-5-19', '廿四'], + ['2017-5-20', '廿五'], + ['2017-5-21', '廿六', '小滿'], + ['2017-5-22', '廿七'], + ['2017-5-23', '廿八'], + ['2017-5-24', '廿九'], + ['2017-5-25', '三十'], + ['2017-5-26', '五月'], + ['2017-5-27', '初二'], + ['2017-5-28', '初三'], + ['2017-5-29', '初四'], + ['2017-5-30', '初五'], + ['2017-5-31', '初六'], + ['2017-6-1', '初七'], + ['2017-6-2', '初八'], + ['2017-6-3', '初九'], + ['2017-6-4', '初十'], + ['2017-6-5', '十一', '芒種'], + ['2017-6-6', '十二'], + ['2017-6-7', '十三'], + ['2017-6-8', '十四'], + ['2017-6-9', '十五'], + ['2017-6-10', '十六'], + ['2017-6-11', '十七'], + ['2017-6-12', '十八'], + ['2017-6-13', '十九'], + ['2017-6-14', '二十'], + ['2017-6-15', '廿一'], + ['2017-6-16', '廿二'], + ['2017-6-17', '廿三'], + ['2017-6-18', '廿四'], + ['2017-6-19', '廿五'], + ['2017-6-20', '廿六'], + ['2017-6-21', '廿七', '夏至'], + ['2017-6-22', '廿八'], + ['2017-6-23', '廿九'], + ['2017-6-24', '六月'], + ['2017-6-25', '初二'], + ['2017-6-26', '初三'], + ['2017-6-27', '初四'], + ['2017-6-28', '初五'], + ['2017-6-29', '初六'], + ['2017-6-30', '初七'], + ['2017-7-1', '初八'], + ['2017-7-2', '初九'], + ['2017-7-3', '初十'], + ['2017-7-4', '十一'], + ['2017-7-5', '十二'], + ['2017-7-6', '十三'], + ['2017-7-7', '十四', '小暑'], + ['2017-7-8', '十五'], + ['2017-7-9', '十六'], + ['2017-7-10', '十七'], + ['2017-7-11', '十八'], + ['2017-7-12', '十九'], + ['2017-7-13', '二十'], + ['2017-7-14', '廿一'], + ['2017-7-15', '廿二'], + ['2017-7-16', '廿三'], + ['2017-7-17', '廿四'], + ['2017-7-18', '廿五'], + ['2017-7-19', '廿六'], + ['2017-7-20', '廿七'], + ['2017-7-21', '廿八'], + ['2017-7-22', '廿九', '大暑'], + ['2017-7-23', '閏六'], + ['2017-7-24', '初二'], + ['2017-7-25', '初三'], + ['2017-7-26', '初四'], + ['2017-7-27', '初五'], + ['2017-7-28', '初六'], + ['2017-7-29', '初七'], + ['2017-7-30', '初八'], + ['2017-7-31', '初九'], + ['2017-8-1', '初十'], + ['2017-8-2', '十一'], + ['2017-8-3', '十二'], + ['2017-8-4', '十三'], + ['2017-8-5', '十四'], + ['2017-8-6', '十五'], + ['2017-8-7', '十六', '立秋'], + ['2017-8-8', '十七'], + ['2017-8-9', '十八'], + ['2017-8-10', '十九'], + ['2017-8-11', '二十'], + ['2017-8-12', '廿一'], + ['2017-8-13', '廿二'], + ['2017-8-14', '廿三'], + ['2017-8-15', '廿四'], + ['2017-8-16', '廿五'], + ['2017-8-17', '廿六'], + ['2017-8-18', '廿七'], + ['2017-8-19', '廿八'], + ['2017-8-20', '廿九'], + ['2017-8-21', '三十'], + ['2017-8-22', '七月'], + ['2017-8-23', '初二', '處暑'], + ['2017-8-24', '初三'], + ['2017-8-25', '初四'], + ['2017-8-26', '初五'], + ['2017-8-27', '初六'], + ['2017-8-28', '初七'], + ['2017-8-29', '初八'], + ['2017-8-30', '初九'], + ['2017-8-31', '初十'], + ['2017-9-1', '十一'], + ['2017-9-2', '十二'], + ['2017-9-3', '十三'], + ['2017-9-4', '十四'], + ['2017-9-5', '十五'], + ['2017-9-6', '十六'], + ['2017-9-7', '十七', '白露'], + ['2017-9-8', '十八'], + ['2017-9-9', '十九'], + ['2017-9-10', '二十'], + ['2017-9-11', '廿一'], + ['2017-9-12', '廿二'], + ['2017-9-13', '廿三'], + ['2017-9-14', '廿四'], + ['2017-9-15', '廿五'], + ['2017-9-16', '廿六'], + ['2017-9-17', '廿七'], + ['2017-9-18', '廿八'], + ['2017-9-19', '廿九'], + ['2017-9-20', '八月'], + ['2017-9-21', '初二'], + ['2017-9-22', '初三'], + ['2017-9-23', '初四', '秋分'], + ['2017-9-24', '初五'], + ['2017-9-25', '初六'], + ['2017-9-26', '初七'], + ['2017-9-27', '初八'], + ['2017-9-28', '初九'], + ['2017-9-29', '初十'], + ['2017-9-30', '十一'], + ['2017-10-1', '十二'], + ['2017-10-2', '十三'], + ['2017-10-3', '十四'], + ['2017-10-4', '十五'], + ['2017-10-5', '十六'], + ['2017-10-6', '十七'], + ['2017-10-7', '十八'], + ['2017-10-8', '十九', '寒露'], + ['2017-10-9', '二十'], + ['2017-10-10', '廿一'], + ['2017-10-11', '廿二'], + ['2017-10-12', '廿三'], + ['2017-10-13', '廿四'], + ['2017-10-14', '廿五'], + ['2017-10-15', '廿六'], + ['2017-10-16', '廿七'], + ['2017-10-17', '廿八'], + ['2017-10-18', '廿九'], + ['2017-10-19', '三十'], + ['2017-10-20', '九月'], + ['2017-10-21', '初二'], + ['2017-10-22', '初三'], + ['2017-10-23', '初四', '霜降'], + ['2017-10-24', '初五'], + ['2017-10-25', '初六'], + ['2017-10-26', '初七'], + ['2017-10-27', '初八'], + ['2017-10-28', '初九'], + ['2017-10-29', '初十'], + ['2017-10-30', '十一'], + ['2017-10-31', '十二'], + ['2017-11-1', '十三'], + ['2017-11-2', '十四'], + ['2017-11-3', '十五'], + ['2017-11-4', '十六'], + ['2017-11-5', '十七'], + ['2017-11-6', '十八'], + ['2017-11-7', '十九', '立冬'], + ['2017-11-8', '二十'], + ['2017-11-9', '廿一'], + ['2017-11-10', '廿二'], + ['2017-11-11', '廿三'], + ['2017-11-12', '廿四'], + ['2017-11-13', '廿五'], + ['2017-11-14', '廿六'], + ['2017-11-15', '廿七'], + ['2017-11-16', '廿八'], + ['2017-11-17', '廿九'], + ['2017-11-18', '十月'], + ['2017-11-19', '初二'], + ['2017-11-20', '初三'], + ['2017-11-21', '初四'], + ['2017-11-22', '初五', '小雪'], + ['2017-11-23', '初六'], + ['2017-11-24', '初七'], + ['2017-11-25', '初八'], + ['2017-11-26', '初九'], + ['2017-11-27', '初十'], + ['2017-11-28', '十一'], + ['2017-11-29', '十二'], + ['2017-11-30', '十三'], + ['2017-12-1', '十四'], + ['2017-12-2', '十五'], + ['2017-12-3', '十六'], + ['2017-12-4', '十七'], + ['2017-12-5', '十八'], + ['2017-12-6', '十九'], + ['2017-12-7', '二十', '大雪'], + ['2017-12-8', '廿一'], + ['2017-12-9', '廿二'], + ['2017-12-10', '廿三'], + ['2017-12-11', '廿四'], + ['2017-12-12', '廿五'], + ['2017-12-13', '廿六'], + ['2017-12-14', '廿七'], + ['2017-12-15', '廿八'], + ['2017-12-16', '廿九'], + ['2017-12-17', '三十'], + ['2017-12-18', '十一月'], + ['2017-12-19', '初二'], + ['2017-12-20', '初三'], + ['2017-12-21', '初四'], + ['2017-12-22', '初五', '冬至'], + ['2017-12-23', '初六'], + ['2017-12-24', '初七'], + ['2017-12-25', '初八'], + ['2017-12-26', '初九'], + ['2017-12-27', '初十'], + ['2017-12-28', '十一'], + ['2017-12-29', '十二'], + ['2017-12-30', '十三'], + ['2017-12-31', '十四'] +]; +const heatmapData = []; +const lunarData = []; +for (let i = 0; i < dateList.length; i++) { + heatmapData.push([dateList[i][0], Math.random() * 300]); + lunarData.push([dateList[i][0], 1, dateList[i][1], dateList[i][2]]); +} +option = { + tooltip: { + formatter: function (params) { + return '降雨量: ' + params.value[1].toFixed(2); + } + }, + visualMap: { + show: false, + min: 0, + max: 300, + calculable: true, + seriesIndex: [2], + orient: 'horizontal', + left: 'center', + bottom: 20, + inRange: { + color: ['#e0ffff', '#006edd'], + opacity: 0.3 + }, + controller: { + inRange: { + opacity: 0.5 + } + } + }, + calendar: [ + { + left: 'center', + top: 'middle', + cellSize: [70, 70], + yearLabel: { show: false }, + orient: 'vertical', + dayLabel: { + firstDay: 1, + nameMap: 'cn' + }, + monthLabel: { + show: false + }, + range: '2017-03' + } + ], + series: [ + { + type: 'scatter', + coordinateSystem: 'calendar', + symbolSize: 0, + label: { + show: true, + formatter: function (params) { + var d = echarts.number.parseDate(params.value[0]); + return d.getDate() + '\n\n' + params.value[2] + '\n\n'; + }, + color: '#000' + }, + data: lunarData, + silent: true + }, + { + type: 'scatter', + coordinateSystem: 'calendar', + symbolSize: 0, + label: { + show: true, + formatter: function (params) { + return '\n\n\n' + (params.value[3] || ''); + }, + fontSize: 14, + fontWeight: 700, + color: '#a00' + }, + data: lunarData, + silent: true + }, + { + name: '降雨量', + type: 'heatmap', + coordinateSystem: 'calendar', + data: heatmapData + } + ] +}; +export {}; diff --git a/testdata/calendar-lunar.js.svg b/testdata/calendar-lunar.js.svg new file mode 100644 index 0000000..c75ec50 --- /dev/null +++ b/testdata/calendar-lunar.js.svg @@ -0,0 +1,1220 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +M +T +W +T +F +S +S + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 +1 + + \ No newline at end of file diff --git a/testdata/calendar-pie.js b/testdata/calendar-pie.js new file mode 100644 index 0000000..9e96086 --- /dev/null +++ b/testdata/calendar-pie.js @@ -0,0 +1,86 @@ +/* +title: Calendar Pie +category: 'calendar, pie' +titleCN: 日历饼图 +difficulty: 6 +*/ +// This example requires ECharts v5.4.0 or later +const cellSize = [80, 80]; +const pieRadius = 30; +function getVirtualData() { + const date = +echarts.time.parse('2017-02-01'); + const end = +echarts.time.parse('2017-03-01'); + const dayTime = 3600 * 24 * 1000; + const data = []; + for (let time = date; time < end; time += dayTime) { + data.push([ + echarts.time.format(time, '{yyyy}-{MM}-{dd}', false), + Math.floor(Math.random() * 10000) + ]); + } + return data; +} +const scatterData = getVirtualData(); +const pieSeries = scatterData.map(function (item, index) { + return { + type: 'pie', + id: 'pie-' + index, + center: item[0], + radius: pieRadius, + coordinateSystem: 'calendar', + label: { + formatter: '{c}', + position: 'inside' + }, + data: [ + { name: 'Work', value: Math.round(Math.random() * 24) }, + { name: 'Entertainment', value: Math.round(Math.random() * 24) }, + { name: 'Sleep', value: Math.round(Math.random() * 24) } + ] + }; +}); +option = { + tooltip: {}, + legend: { + data: ['Work', 'Entertainment', 'Sleep'], + bottom: 20 + }, + calendar: { + top: 'middle', + left: 'center', + orient: 'vertical', + cellSize: cellSize, + yearLabel: { + show: false, + fontSize: 30 + }, + dayLabel: { + margin: 20, + firstDay: 1, + nameMap: ['Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'] + }, + monthLabel: { + show: false + }, + range: ['2017-02'] + }, + series: [ + { + id: 'label', + type: 'scatter', + coordinateSystem: 'calendar', + symbolSize: 0, + label: { + show: true, + formatter: function (params) { + return echarts.time.format(params.value[0], '{dd}', false); + }, + offset: [-cellSize[0] / 2 + 10, -cellSize[1] / 2 + 10], + fontSize: 14 + }, + data: scatterData + }, + ...pieSeries + ] +}; +export {}; diff --git a/testdata/calendar-pie.js.svg b/testdata/calendar-pie.js.svg new file mode 100644 index 0000000..0a9c89e --- /dev/null +++ b/testdata/calendar-pie.js.svg @@ -0,0 +1,1509 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +12 +9 +15 +15 +23 +10 +20 +4 +19 +2 +8 +1 +24 +3 +19 +13 +5 +6 +11 +4 +0 +9 +21 +8 +14 +2 +2 +22 +2 +18 +4 +2 +3 +3 +2 +23 +8 +11 +20 +11 +7 +2 +12 +3 +12 +23 +19 +2 +4 +8 +1 +15 +17 +17 +6 +5 +1 +12 +10 +4 +16 +12 +11 +6 +11 +16 +10 +13 +8 +1 +3 +13 +17 +5 +19 +8 +5 +9 +21 +6 +20 +9 +7 +20 + + + + +Mon +Tue +Wed +Thu +Fri +Sat +Sun + + + + + + + + + + + + + + + + + + + + + + + + + + + + +8820 +6026 +8818 +3838 +3228 +2794 +2724 +8839 +5515 +5291 +1202 +4142 +4296 +8049 +1523 +9673 +4726 +5929 +1914 +2107 +1375 +3217 +5062 +6726 +9867 +5808 +5503 +7492 + + +Work + +Entertainment + +Sleep + + \ No newline at end of file diff --git a/testdata/calendar-simple.js b/testdata/calendar-simple.js new file mode 100644 index 0000000..796fd5b --- /dev/null +++ b/testdata/calendar-simple.js @@ -0,0 +1,35 @@ +/* +title: Simple Calendar +titleCN: 基础日历图 +category: calendar +difficulty: 0 +*/ +function getVirtualData(year) { + const date = +echarts.time.parse(year + '-01-01'); + const end = +echarts.time.parse(year + '-12-31'); + const dayTime = 3600 * 24 * 1000; + const data = []; + for (let time = date; time <= end; time += dayTime) { + data.push([ + echarts.time.format(time, '{yyyy}-{MM}-{dd}', false), + Math.floor(Math.random() * 10000) + ]); + } + return data; +} +option = { + visualMap: { + show: false, + min: 0, + max: 10000 + }, + calendar: { + range: '2017' + }, + series: { + type: 'heatmap', + coordinateSystem: 'calendar', + data: getVirtualData('2017') + } +}; +export {}; diff --git a/testdata/calendar-simple.js.svg b/testdata/calendar-simple.js.svg new file mode 100644 index 0000000..ecf019e --- /dev/null +++ b/testdata/calendar-simple.js.svg @@ -0,0 +1,768 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +2017 +Jan +Feb +Mar +Apr +May +Jun +Jul +Aug +Sep +Oct +Nov +Dec +S +M +T +W +T +F +S + \ No newline at end of file diff --git a/testdata/calendar-vertical.js b/testdata/calendar-vertical.js new file mode 100644 index 0000000..b8863a2 --- /dev/null +++ b/testdata/calendar-vertical.js @@ -0,0 +1,79 @@ +/* +title: Calendar Heatmap Vertical +category: 'calendar, heatmap' +titleCN: 纵向日历图 +shotWidth: 900 +difficulty: 1 +*/ +function getVirtualData(year) { + const date = +echarts.time.parse(year + '-01-01'); + const end = +echarts.time.parse(+year + 1 + '-01-01'); + const dayTime = 3600 * 24 * 1000; + const data = []; + for (let time = date; time < end; time += dayTime) { + data.push([ + echarts.time.format(time, '{yyyy}-{MM}-{dd}', false), + Math.floor(Math.random() * 1000) + ]); + } + return data; +} +option = { + tooltip: { + position: 'top', + formatter: function (p) { + const format = echarts.time.format(p.data[0], '{yyyy}-{MM}-{dd}', false); + return format + ': ' + p.data[1]; + } + }, + visualMap: { + min: 0, + max: 1000, + calculable: true, + orient: 'vertical', + left: '670', + top: 'center' + }, + calendar: [ + { + orient: 'vertical', + range: '2015' + }, + { + left: 300, + orient: 'vertical', + range: '2016' + }, + { + left: 520, + cellSize: [20, 'auto'], + bottom: 10, + orient: 'vertical', + range: '2017', + dayLabel: { + margin: 5 + } + } + ], + series: [ + { + type: 'heatmap', + coordinateSystem: 'calendar', + calendarIndex: 0, + data: getVirtualData('2015') + }, + { + type: 'heatmap', + coordinateSystem: 'calendar', + calendarIndex: 1, + data: getVirtualData('2016') + }, + { + type: 'heatmap', + coordinateSystem: 'calendar', + calendarIndex: 2, + data: getVirtualData('2017') + } + ] +}; +export {}; diff --git a/testdata/calendar-vertical.js.svg b/testdata/calendar-vertical.js.svg new file mode 100644 index 0000000..f2447a0 --- /dev/null +++ b/testdata/calendar-vertical.js.svg @@ -0,0 +1,2520 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +2015 +Jan +Feb +Mar +Apr +May +Jun +Jul +Aug +Sep +Oct +Nov +Dec +S +M +T +W +T +F +S +2016 +Jan +Feb +Mar +Apr +May +Jun +Jul +Aug +Sep +Oct +Nov +Dec +S +M +T +W +T +F +S +2017 +Jan +Feb +Mar +Apr +May +Jun +Jul +Aug +Sep +Oct +Nov +Dec +S +M +T +W +T +F +S + +0 +1000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/candlestick-brush.js b/testdata/candlestick-brush.js new file mode 100644 index 0000000..d3c414a --- /dev/null +++ b/testdata/candlestick-brush.js @@ -0,0 +1,249 @@ +/* +title: Candlestick Brush +category: candlestick +titleCN: K 线图刷选 +*/ +const upColor = '#00da3c'; +const downColor = '#ec0000'; +function splitData(rawData) { + let categoryData = []; + let values = []; + let volumes = []; + for (let i = 0; i < rawData.length; i++) { + categoryData.push(rawData[i].splice(0, 1)[0]); + values.push(rawData[i]); + volumes.push([i, rawData[i][4], rawData[i][0] > rawData[i][1] ? 1 : -1]); + } + return { + categoryData: categoryData, + values: values, + volumes: volumes + }; +} +function calculateMA(dayCount, data) { + var result = []; + for (var i = 0, len = data.values.length; i < len; i++) { + if (i < dayCount) { + result.push('-'); + continue; + } + var sum = 0; + for (var j = 0; j < dayCount; j++) { + sum += data.values[i - j][1]; + } + result.push(+(sum / dayCount).toFixed(3)); + } + return result; +} +$.get(ROOT_PATH + '/data/asset/data/stock-DJI.json', function (rawData) { + var data = splitData(rawData); + myChart.setOption((option = { + animation: false, + legend: { + bottom: 10, + left: 'center', + data: ['Dow-Jones index', 'MA5', 'MA10', 'MA20', 'MA30'] + }, + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'cross' + }, + borderWidth: 1, + borderColor: '#ccc', + padding: 10, + textStyle: { + color: '#000' + }, + position: function (pos, params, el, elRect, size) { + const obj = { + top: 10 + }; + obj[['left', 'right'][+(pos[0] < size.viewSize[0] / 2)]] = 30; + return obj; + } + // extraCssText: 'width: 170px' + }, + axisPointer: { + link: [ + { + xAxisIndex: 'all' + } + ], + label: { + backgroundColor: '#777' + } + }, + toolbox: { + feature: { + dataZoom: { + yAxisIndex: false + }, + brush: { + type: ['lineX', 'clear'] + } + } + }, + brush: { + xAxisIndex: 'all', + brushLink: 'all', + outOfBrush: { + colorAlpha: 0.1 + } + }, + visualMap: { + show: false, + seriesIndex: 5, + dimension: 2, + pieces: [ + { + value: 1, + color: downColor + }, + { + value: -1, + color: upColor + } + ] + }, + grid: [ + { + left: '10%', + right: '8%', + height: '50%' + }, + { + left: '10%', + right: '8%', + top: '63%', + height: '16%' + } + ], + xAxis: [ + { + type: 'category', + data: data.categoryData, + boundaryGap: false, + axisLine: { onZero: false }, + splitLine: { show: false }, + min: 'dataMin', + max: 'dataMax', + axisPointer: { + z: 100 + } + }, + { + type: 'category', + gridIndex: 1, + data: data.categoryData, + boundaryGap: false, + axisLine: { onZero: false }, + axisTick: { show: false }, + splitLine: { show: false }, + axisLabel: { show: false }, + min: 'dataMin', + max: 'dataMax' + } + ], + yAxis: [ + { + scale: true, + splitArea: { + show: true + } + }, + { + scale: true, + gridIndex: 1, + splitNumber: 2, + axisLabel: { show: false }, + axisLine: { show: false }, + axisTick: { show: false }, + splitLine: { show: false } + } + ], + dataZoom: [ + { + type: 'inside', + xAxisIndex: [0, 1], + start: 98, + end: 100 + }, + { + show: true, + xAxisIndex: [0, 1], + type: 'slider', + top: '85%', + start: 98, + end: 100 + } + ], + series: [ + { + name: 'Dow-Jones index', + type: 'candlestick', + data: data.values, + itemStyle: { + color: upColor, + color0: downColor, + borderColor: undefined, + borderColor0: undefined + } + }, + { + name: 'MA5', + type: 'line', + data: calculateMA(5, data), + smooth: true, + lineStyle: { + opacity: 0.5 + } + }, + { + name: 'MA10', + type: 'line', + data: calculateMA(10, data), + smooth: true, + lineStyle: { + opacity: 0.5 + } + }, + { + name: 'MA20', + type: 'line', + data: calculateMA(20, data), + smooth: true, + lineStyle: { + opacity: 0.5 + } + }, + { + name: 'MA30', + type: 'line', + data: calculateMA(30, data), + smooth: true, + lineStyle: { + opacity: 0.5 + } + }, + { + name: 'Volume', + type: 'bar', + xAxisIndex: 1, + yAxisIndex: 1, + data: data.volumes + } + ] + }), true); + myChart.dispatchAction({ + type: 'brush', + areas: [ + { + brushType: 'lineX', + coordRange: ['2016-06-02', '2016-06-20'], + xAxisIndex: 0 + } + ] + }); +}); +export {}; diff --git a/testdata/candlestick-large.js b/testdata/candlestick-large.js new file mode 100644 index 0000000..2adfe03 --- /dev/null +++ b/testdata/candlestick-large.js @@ -0,0 +1,199 @@ +/* +title: Large Scale Candlestick +category: candlestick +titleCN: 大数据量K线图 +difficulty: 3 +*/ +const upColor = '#ec0000'; +const upBorderColor = '#8A0000'; +const downColor = '#00da3c'; +const downBorderColor = '#008F28'; +const dataCount = 2e5; +const data = generateOHLC(dataCount); +option = { + dataset: { + source: data + }, + title: { + text: 'Data Amount: ' + echarts.format.addCommas(dataCount) + }, + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'line' + } + }, + toolbox: { + feature: { + dataZoom: { + yAxisIndex: false + } + } + }, + grid: [ + { + left: '10%', + right: '10%', + bottom: 200 + }, + { + left: '10%', + right: '10%', + height: 80, + bottom: 80 + } + ], + xAxis: [ + { + type: 'category', + boundaryGap: false, + // inverse: true, + axisLine: { onZero: false }, + splitLine: { show: false }, + min: 'dataMin', + max: 'dataMax' + }, + { + type: 'category', + gridIndex: 1, + boundaryGap: false, + axisLine: { onZero: false }, + axisTick: { show: false }, + splitLine: { show: false }, + axisLabel: { show: false }, + min: 'dataMin', + max: 'dataMax' + } + ], + yAxis: [ + { + scale: true, + splitArea: { + show: true + } + }, + { + scale: true, + gridIndex: 1, + splitNumber: 2, + axisLabel: { show: false }, + axisLine: { show: false }, + axisTick: { show: false }, + splitLine: { show: false } + } + ], + dataZoom: [ + { + type: 'inside', + xAxisIndex: [0, 1], + start: 10, + end: 100 + }, + { + show: true, + xAxisIndex: [0, 1], + type: 'slider', + bottom: 10, + start: 10, + end: 100 + } + ], + visualMap: { + show: false, + seriesIndex: 1, + dimension: 6, + pieces: [ + { + value: 1, + color: upColor + }, + { + value: -1, + color: downColor + } + ] + }, + series: [ + { + type: 'candlestick', + itemStyle: { + color: upColor, + color0: downColor, + borderColor: upBorderColor, + borderColor0: downBorderColor + }, + encode: { + x: 0, + y: [1, 4, 3, 2] + } + }, + { + name: 'Volumn', + type: 'bar', + xAxisIndex: 1, + yAxisIndex: 1, + itemStyle: { + color: '#7fbe9e' + }, + large: true, + encode: { + x: 0, + y: 5 + } + } + ] +}; +function generateOHLC(count) { + let data = []; + let xValue = +new Date(2011, 0, 1); + let minute = 60 * 1000; + let baseValue = Math.random() * 12000; + let boxVals = new Array(4); + let dayRange = 12; + for (let i = 0; i < count; i++) { + baseValue = baseValue + Math.random() * 20 - 10; + for (let j = 0; j < 4; j++) { + boxVals[j] = (Math.random() - 0.5) * dayRange + baseValue; + } + boxVals.sort(); + let openIdx = Math.round(Math.random() * 3); + let closeIdx = Math.round(Math.random() * 2); + if (closeIdx === openIdx) { + closeIdx++; + } + let volumn = boxVals[3] * (1000 + Math.random() * 500); + // ['open', 'close', 'lowest', 'highest', 'volumn'] + // [1, 4, 3, 2] + data[i] = [ + echarts.format.formatTime('yyyy-MM-dd\nhh:mm:ss', (xValue += minute)), + +boxVals[openIdx].toFixed(2), + +boxVals[3].toFixed(2), + +boxVals[0].toFixed(2), + +boxVals[closeIdx].toFixed(2), + +volumn.toFixed(0), + getSign(data, i, +boxVals[openIdx], +boxVals[closeIdx], 4) // sign + ]; + } + return data; + function getSign(data, dataIndex, openVal, closeVal, closeDimIdx) { + var sign; + if (openVal > closeVal) { + sign = -1; + } + else if (openVal < closeVal) { + sign = 1; + } + else { + sign = + dataIndex > 0 + ? // If close === open, compare with close of last record + data[dataIndex - 1][closeDimIdx] <= closeVal + ? 1 + : -1 + : // No record of previous, set to be positive + 1; + } + return sign; + } +} +export {}; diff --git a/testdata/candlestick-large.js.svg b/testdata/candlestick-large.js.svg new file mode 100644 index 0000000..3f56b08 --- /dev/null +++ b/testdata/candlestick-large.js.svg @@ -0,0 +1,103 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + +3,500 +4,000 +4,500 +5,000 +5,500 +6,000 +6,500 +2011-01-15 +17:47:00 +2011-01-30 +11:33:00 +2011-02-14 +05:19:00 +2011-02-28 +23:05:00 +2011-03-15 +16:51:00 +2011-03-30 +10:37:00 +2011-04-14 +04:23:00 +2011-04-28 +22:09:00 +2011-05-13 +15:55:00 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Data Amount: 200,000 + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/candlestick-sh-2015.js b/testdata/candlestick-sh-2015.js new file mode 100644 index 0000000..ee8609a --- /dev/null +++ b/testdata/candlestick-sh-2015.js @@ -0,0 +1,134 @@ +/* +title: 'ShangHai Index, 2015' +category: candlestick +titleCN: 2015 年上证指数 +*/ +// prettier-ignore +const rawData = [['2015/12/31', '3570.47', '3539.18', '-33.69', '-0.94%', '3538.35', '3580.6', '176963664', '25403106', '-'], ['2015/12/30', '3566.73', '3572.88', '9.14', '0.26%', '3538.11', '3573.68', '187889600', '26778766', '-'], ['2015/12/29', '3528.4', '3563.74', '29.96', '0.85%', '3515.52', '3564.17', '182551920', '25093890', '-'], ['2015/12/28', '3635.77', '3533.78', '-94.13', '-2.59%', '3533.78', '3641.59', '269983264', '36904280', '-'], ['2015/12/25', '3614.05', '3627.91', '15.43', '0.43%', '3601.74', '3635.26', '198451120', '27466004', '-'], ['2015/12/24', '3631.31', '3612.49', '-23.6', '-0.65%', '3572.28', '3640.22', '227785216', '31542126', '-'], ['2015/12/23', '3653.28', '3636.09', '-15.68', '-0.43%', '3633.03', '3684.57', '298201792', '41990292', '-'], ['2015/12/22', '3645.99', '3651.77', '9.3', '0.26%', '3616.87', '3652.63', '261178752', '36084604', '-'], ['2015/12/21', '3568.58', '3642.47', '63.51', '1.77%', '3565.75', '3651.06', '299849280', '39831696', '-'], ['2015/12/18', '3574.94', '3578.96', '-1.03', '-0.03%', '3568.16', '3614.7', '273707904', '36538580', '-'], ['2015/12/17', '3533.63', '3580', '63.81', '1.81%', '3533.63', '3583.41', '283856480', '38143960', '-'], ['2015/12/16', '3522.09', '3516.19', '5.83', '0.17%', '3506.29', '3538.69', '193482304', '26528864', '-'], ['2015/12/15', '3518.13', '3510.35', '-10.31', '-0.29%', '3496.85', '3529.96', '200471344', '27627494', '-'], ['2015/12/14', '3403.51', '3520.67', '86.09', '2.51%', '3399.28', '3521.78', '215374624', '27921354', '-'], ['2015/12/11', '3441.6', '3434.58', '-20.91', '-0.61%', '3410.92', '3455.55', '182908880', '24507642', '-'], ['2015/12/10', '3469.81', '3455.5', '-16.94', '-0.49%', '3446.27', '3503.65', '200427520', '27949970', '-'], ['2015/12/9', '3462.58', '3472.44', '2.37', '0.07%', '3454.88', '3495.7', '195698848', '26785488', '-'], ['2015/12/8', '3518.65', '3470.07', '-66.86', '-1.89%', '3466.79', '3518.65', '224367312', '29782174', '-'], ['2015/12/7', '3529.81', '3536.93', '11.94', '0.34%', '3506.62', '3543.95', '208302576', '28056158', '-'], ['2015/12/4', '3558.15', '3524.99', '-59.83', '-1.67%', '3510.41', '3568.97', '251736416', '31976682', '-'], ['2015/12/3', '3525.73', '3584.82', '47.92', '1.35%', '3517.23', '3591.73', '281111232', '33885908', '-'], ['2015/12/2', '3450.28', '3536.91', '80.6', '2.33%', '3427.66', '3538.85', '301491488', '36918304', '-'], ['2015/12/1', '3442.44', '3456.31', '10.9', '0.32%', '3417.54', '3483.41', '252390752', '33025674', '-'], ['2015/11/30', '3433.85', '3445.4', '9.1', '0.26%', '3327.81', '3470.37', '304197888', '38750364', '-'], ['2015/11/27', '3616.54', '3436.3', '-199.25', '-5.48%', '3412.43', '3621.9', '354287520', '46431124', '-'], ['2015/11/26', '3659.57', '3635.55', '-12.38', '-0.34%', '3629.86', '3668.38', '306761600', '42624744', '-'], ['2015/11/25', '3614.07', '3647.93', '31.82', '0.88%', '3607.52', '3648.37', '273024864', '38080292', '-'], ['2015/11/24', '3602.89', '3616.11', '5.79', '0.16%', '3563.1', '3616.48', '248810512', '32775852', '-'], ['2015/11/23', '3630.87', '3610.31', '-20.18', '-0.56%', '3598.87', '3654.75', '315997472', '41414824', '-'], ['2015/11/20', '3620.79', '3630.5', '13.44', '0.37%', '3607.92', '3640.53', '310801984', '41391088', '-'], ['2015/11/19', '3573.78', '3617.06', '48.59', '1.36%', '3561.04', '3618.21', '247915584', '32844260', '-'], ['2015/11/18', '3605.06', '3568.47', '-36.33', '-1.01%', '3558.7', '3617.07', '297580736', '39233876', '-'], ['2015/11/17', '3629.98', '3604.8', '-2.16', '-0.06%', '3598.07', '3678.27', '383575456', '52152036', '-'], ['2015/11/16', '3522.46', '3606.96', '26.12', '0.73%', '3519.42', '3607.61', '276187040', '36942184', '-'], ['2015/11/13', '3600.76', '3580.84', '-52.06', '-1.43%', '3564.81', '3632.56', '345870944', '46866864', '-'], ['2015/11/12', '3656.82', '3632.9', '-17.35', '-0.48%', '3603.23', '3659.31', '361717600', '48283260', '-'], ['2015/11/11', '3635', '3650.25', '9.76', '0.27%', '3605.62', '3654.88', '360972672', '46782220', '-'], ['2015/11/10', '3617.4', '3640.49', '-6.4', '-0.18%', '3607.89', '3669.53', '429746592', '56005512', '-'], ['2015/11/9', '3588.5', '3646.88', '56.85', '1.58%', '3588.5', '3673.76', '503016704', '63618404', '-'], ['2015/11/6', '3514.44', '3590.03', '67.21', '1.91%', '3508.83', '3596.38', '429167040', '54328220', '-'], ['2015/11/5', '3459.22', '3522.82', '63.18', '1.83%', '3455.53', '3585.66', '553254976', '67867464', '-'], ['2015/11/4', '3325.62', '3459.64', '142.94', '4.31%', '3325.62', '3459.65', '339078752', '42610440', '-'], ['2015/11/3', '3330.32', '3316.7', '-8.39', '-0.25%', '3302.18', '3346.27', '192897440', '24436056', '-'], ['2015/11/2', '3337.58', '3325.08', '-57.48', '-1.70%', '3322.31', '3391.06', '230951136', '28601932', '-'], ['2015/10/30', '3380.28', '3382.56', '-4.75', '-0.14%', '3346.59', '3417.2', '243595120', '30726678', '-'], ['2015/10/29', '3387.77', '3387.32', '12.12', '0.36%', '3362.51', '3411.71', '235676016', '29450842', '-'], ['2015/10/28', '3417.01', '3375.2', '-59.14', '-1.72%', '3367.23', '3439.76', '293523296', '36165620', '-'], ['2015/10/27', '3409.14', '3434.34', '4.76', '0.14%', '3332.62', '3441.57', '328172768', '40888724', '-'], ['2015/10/26', '3448.65', '3429.58', '17.15', '0.50%', '3402', '3457.52', '365560864', '45394252', '-'], ['2015/10/23', '3377.55', '3412.43', '43.7', '1.30%', '3360.22', '3422.02', '347372864', '42526308', '-'], ['2015/10/22', '3292.29', '3368.74', '48.06', '1.45%', '3282.99', '3373.78', '323739328', '37545200', '-'], ['2015/10/21', '3428.56', '3320.68', '-104.65', '-3.06%', '3265.44', '3447.26', '458455424', '51850924', '-'], ['2015/10/20', '3377.55', '3425.33', '38.63', '1.14%', '3357.86', '3425.52', '318973760', '38358252', '-'], ['2015/10/19', '3401.63', '3386.7', '-4.65', '-0.14%', '3355.57', '3423.4', '378112160', '45330364', '-'], ['2015/10/16', '3358.3', '3391.35', '53.28', '1.60%', '3334.85', '3393.02', '395460576', '45944784', '-'], ['2015/10/15', '3255.03', '3338.07', '75.63', '2.32%', '3254.39', '3338.3', '316283840', '36256556', '-'], ['2015/10/14', '3280.02', '3262.44', '-30.79', '-0.93%', '3256.25', '3307.32', '295077760', '33027752', '-'], ['2015/10/13', '3262.16', '3293.23', '5.57', '0.17%', '3253.25', '3298.63', '297153120', '33480608', '-'], ['2015/10/12', '3193.54', '3287.66', '104.51', '3.28%', '3188.41', '3318.71', '386294688', '43554100', '-'], ['2015/10/9', '3146.64', '3183.15', '39.79', '1.27%', '3137.79', '3192.72', '234851456', '25637910', '-'], ['2015/10/8', '3156.07', '3143.36', '90.58', '2.97%', '3133.13', '3172.28', '234276048', '25883034', '-'], ['2015/9/30', '3052.84', '3052.78', '14.64', '0.48%', '3039.74', '3073.3', '146642448', '15656919', '-'], ['2015/9/29', '3055.22', '3038.14', '-62.62', '-2.02%', '3021.16', '3068.3', '163222672', '16968660', '-'], ['2015/9/28', '3085.57', '3100.76', '8.41', '0.27%', '3042.31', '3103.07', '156727536', '16642240', '-'], ['2015/9/25', '3130.85', '3092.35', '-50.34', '-1.60%', '3063', '3149.95', '236263872', '24897112', '-'], ['2015/9/24', '3126.49', '3142.69', '26.8', '0.86%', '3109.69', '3151.16', '212887712', '23136904', '-'], ['2015/9/23', '3137.72', '3115.89', '-69.73', '-2.19%', '3104.74', '3164.04', '236322672', '25756004', '-'], ['2015/9/22', '3161.32', '3185.62', '29.08', '0.92%', '3152.48', '3213.48', '274786176', '30507132', '-'], ['2015/9/21', '3072.09', '3156.54', '58.62', '1.89%', '3060.86', '3159.88', '239897360', '25979668', '-'], ['2015/9/18', '3100.28', '3097.92', '11.86', '0.38%', '3070.34', '3122.05', '209175392', '21844244', '-'], ['2015/9/17', '3131.98', '3086.06', '-66.2', '-2.10%', '3085.31', '3204.7', '317602912', '33739328', '-'], ['2015/9/16', '2998.04', '3152.26', '147.09', '4.89%', '2983.54', '3182.93', '277524512', '28199226', '-'], ['2015/9/15', '3043.8', '3005.17', '-109.63', '-3.52%', '2983.92', '3081.7', '249194448', '24390460', '-'], ['2015/9/14', '3221.17', '3114.8', '-85.44', '-2.67%', '3049.23', '3229.48', '346631168', '37357680', '-'], ['2015/9/11', '3189.48', '3200.23', '2.34', '0.07%', '3163.45', '3223.76', '224557808', '25276946', '-'], ['2015/9/10', '3190.55', '3197.89', '-45.2', '-1.39%', '3178.9', '3243.28', '273261760', '29958108', '-'], ['2015/9/9', '3182.55', '3243.09', '72.64', '2.29%', '3165.7', '3256.74', '375328000', '41299144', '-'], ['2015/9/8', '3054.44', '3170.45', '90.03', '2.92%', '3011.12', '3174.71', '255415456', '26391038', '-'], ['2015/9/7', '3149.38', '3080.42', '-79.75', '-2.52%', '3066.3', '3217.58', '296468096', '30268972', '-'], ['2015/9/2', '3027.68', '3160.17', '-6.46', '-0.20%', '3019.09', '3194.48', '438170176', '42326236', '-'], ['2015/9/1', '3157.83', '3166.62', '-39.36', '-1.23%', '3053.74', '3180.33', '432432448', '42041164', '-'], ['2015/8/31', '3203.56', '3205.99', '-26.36', '-0.82%', '3109.16', '3207.86', '397431392', '43106860', '-'], ['2015/8/28', '3125.26', '3232.35', '148.76', '4.82%', '3102.95', '3235.84', '443136928', '47463100', '-'], ['2015/8/27', '2978.03', '3083.59', '156.3', '5.34%', '2906.49', '3085.42', '400308384', '40428928', '-'], ['2015/8/26', '2980.79', '2927.29', '-37.68', '-1.27%', '2850.71', '3092.04', '466699680', '46178896', '-'], ['2015/8/25', '3004.13', '2964.97', '-244.94', '-7.63%', '2947.94', '3123.03', '352325088', '35873576', '-'], ['2015/8/24', '3373.48', '3209.91', '-297.84', '-8.49%', '3191.88', '3388.36', '334671776', '35881888', '-'], ['2015/8/21', '3609.96', '3507.74', '-156.55', '-4.27%', '3490.54', '3652.84', '369920480', '45061648', '-'], ['2015/8/20', '3754.57', '3664.29', '-129.82', '-3.42%', '3663.61', '3788.01', '390063072', '50119500', '-'], ['2015/8/19', '3646.8', '3794.11', '45.95', '1.23%', '3558.38', '3811.43', '475396224', '59951332', '-'], ['2015/8/18', '3999.13', '3748.16', '-245.5', '-6.15%', '3743.39', '4006.34', '543770816', '72246720', '-'], ['2015/8/17', '3947.84', '3993.67', '28.33', '0.71%', '3907.4', '3994.54', '460432064', '62632768', '-'], ['2015/8/14', '3976.41', '3965.33', '10.78', '0.27%', '3939.83', '4000.68', '467988224', '64746644', '-'], ['2015/8/13', '3869.91', '3954.56', '68.24', '1.76%', '3838.16', '3955.79', '430073280', '57868552', '-'], ['2015/8/12', '3881.23', '3886.32', '-41.59', '-1.06%', '3871.14', '3937.77', '442688256', '59705028', '-'], ['2015/8/11', '3928.81', '3927.91', '-0.51', '-0.01%', '3891.18', '3970.34', '538923456', '71228992', '-'], ['2015/8/10', '3786.03', '3928.42', '184.21', '4.92%', '3775.85', '3943.62', '497304320', '65262204', '-'], ['2015/8/7', '3692.61', '3744.2', '82.67', '2.26%', '3686.3', '3756.74', '340757184', '44548504', '-'], ['2015/8/6', '3625.5', '3661.54', '-33.03', '-0.89%', '3614.74', '3710.57', '274074656', '35751512', '-'], ['2015/8/5', '3745.65', '3694.57', '-61.97', '-1.65%', '3676.39', '3782.35', '366423008', '48385028', '-'], ['2015/8/4', '3621.85', '3756.54', '133.64', '3.69%', '3601.29', '3757.03', '362901664', '46403624', '-'], ['2015/8/3', '3614.99', '3622.91', '-40.82', '-1.11%', '3549.5', '3648.94', '363968704', '44599160', '-'], ['2015/7/31', '3655.67', '3663.73', '-42.04', '-1.13%', '3620.17', '3729.51', '350955712', '46047224', '-'], ['2015/7/30', '3773.79', '3705.77', '-83.4', '-2.20%', '3685.96', '3844.37', '457943232', '61597792', '-'], ['2015/7/29', '3689.82', '3789.17', '126.17', '3.44%', '3612.06', '3792.07', '434352096', '55749196', '-'], ['2015/7/28', '3573.14', '3663', '-62.56', '-1.68%', '3537.36', '3762.53', '563330048', '68505752', '-'], ['2015/7/27', '3985.57', '3725.56', '-345.35', '-8.48%', '3720.44', '4051.16', '556003264', '72129808', '-'], ['2015/7/24', '4124.75', '4070.91', '-53.02', '-1.29%', '4044.83', '4184.45', '627424896', '84302208', '-'], ['2015/7/23', '4022.27', '4123.92', '97.88', '2.43%', '4019.04', '4132.61', '563585984', '74353184', '-'], ['2015/7/22', '3996.43', '4026.04', '8.37', '0.21%', '3960.86', '4042.34', '520732224', '67883192', '-'], ['2015/7/21', '3939.9', '4017.67', '25.57', '0.64%', '3912.8', '4041.82', '504288000', '64641684', '-'], ['2015/7/20', '3948.42', '3992.11', '34.76', '0.88%', '3927.12', '4021.33', '539106688', '68825560', '-'], ['2015/7/17', '3831.42', '3957.35', '134.18', '3.51%', '3814.15', '3994.48', '481726272', '59306700', '-'], ['2015/7/16', '3758.5', '3823.18', '17.47', '0.46%', '3688.44', '3877.51', '492256224', '56985892', '-'], ['2015/7/15', '3874.97', '3805.7', '-118.78', '-3.03%', '3741.25', '3914.27', '601301312', '70053656', '-'], ['2015/7/14', '3958.37', '3924.49', '-45.9', '-1.16%', '3855.56', '4035.43', '670558784', '83007464', '-'], ['2015/7/13', '3918.99', '3970.39', '92.58', '2.39%', '3858.64', '4030.19', '643489024', '78243056', '-'], ['2015/7/10', '3707.46', '3877.8', '168.47', '4.54%', '3677.43', '3959.22', '586364288', '68043416', '-'], ['2015/7/9', '3432.45', '3709.33', '202.14', '5.76%', '3373.54', '3748.48', '656914624', '67331096', '-'], ['2015/7/8', '3467.4', '3507.19', '-219.93', '-5.90%', '3421.53', '3599.25', '680356928', '70024832', '-'], ['2015/7/7', '3654.78', '3727.12', '-48.79', '-1.29%', '3585.4', '3750.57', '698818752', '77607256', '-'], ['2015/7/6', '3975.21', '3775.91', '89', '2.41%', '3653.04', '3975.21', '831139264', '94342040', '-'], ['2015/7/3', '3793.71', '3686.92', '-225.85', '-5.77%', '3629.56', '3927.13', '548163072', '64805412', '-'], ['2015/7/2', '4058.62', '3912.77', '-140.93', '-3.48%', '3795.25', '4080.39', '586015616', '73600680', '-'], ['2015/7/1', '4214.15', '4053.7', '-223.52', '-5.23%', '4043.37', '4317.05', '598769408', '83807088', '-'], ['2015/6/30', '4006.75', '4277.22', '224.19', '5.53%', '3847.88', '4279.97', '709176576', '94152464', '-'], ['2015/6/29', '4289.77', '4053.03', '-139.84', '-3.34%', '3875.05', '4297.47', '673786368', '90427136', '-'], ['2015/6/26', '4399.93', '4192.87', '-334.91', '-7.40%', '4139.53', '4456.9', '565217920', '78783568', '-'], ['2015/6/25', '4711.76', '4527.78', '-162.37', '-3.46%', '4483.55', '4720.7', '572797568', '86537976', '-'], ['2015/6/24', '4604.58', '4690.15', '113.66', '2.48%', '4552.13', '4691.77', '543003712', '81506272', '-'], ['2015/6/23', '4471.61', '4576.49', '98.13', '2.19%', '4264.77', '4577.94', '473526112', '69361720', '-'], ['2015/6/19', '4689.93', '4478.36', '-306.99', '-6.42%', '4476.5', '4744.08', '452689632', '68545816', '-'], ['2015/6/18', '4942.52', '4785.36', '-182.54', '-3.67%', '4780.87', '4966.77', '507440896', '78584504', '-'], ['2015/6/17', '4890.55', '4967.9', '80.47', '1.65%', '4767.22', '4983.66', '537101120', '83026672', '-'], ['2015/6/16', '5004.41', '4887.43', '-175.56', '-3.47%', '4842.1', '5029.68', '550801408', '89542056', '-'], ['2015/6/15', '5174.42', '5062.99', '-103.36', '-2.00%', '5048.74', '5176.79', '637803968', '106499200', '-'], ['2015/6/12', '5143.34', '5166.35', '44.76', '0.87%', '5103.4', '5178.19', '625627904', '106016744', '-'], ['2015/6/11', '5101.44', '5121.59', '15.56', '0.30%', '5050.76', '5122.46', '563990528', '97467056', '-'], ['2015/6/10', '5049.2', '5106.04', '-7.5', '-0.15%', '5001.49', '5164.16', '596969024', '100642824', '-'], ['2015/6/9', '5145.98', '5113.53', '-18.35', '-0.36%', '5042.96', '5147.45', '729893824', '115080864', '-'], ['2015/6/8', '5045.69', '5131.88', '108.78', '2.17%', '4997.48', '5146.95', '855035072', '130992456', '-'], ['2015/6/5', '5016.09', '5023.1', '75.99', '1.54%', '4898.07', '5051.63', '772240832', '123230064', '-'], ['2015/6/4', '4912.95', '4947.1', '37.12', '0.76%', '4647.41', '4947.96', '674952384', '105227024', '-'], ['2015/6/3', '4924.38', '4909.98', '-0.55', '-0.01%', '4822.44', '4942.06', '611453824', '101018000', '-'], ['2015/6/2', '4844.7', '4910.53', '81.79', '1.69%', '4797.55', '4911.57', '623748096', '99874576', '-'], ['2015/6/1', '4633.1', '4828.74', '216.99', '4.71%', '4615.23', '4829.5', '593389056', '93445544', '-'], ['2015/5/29', '4603.47', '4611.74', '-8.52', '-0.18%', '4431.56', '4698.19', '611262400', '95536560', '-'], ['2015/5/28', '4943.74', '4620.27', '-321.45', '-6.50%', '4614.24', '4986.5', '782964544', '124792600', '-'], ['2015/5/27', '4932.85', '4941.71', '30.82', '0.63%', '4857.06', '4958.16', '681165376', '111626184', '-'], ['2015/5/26', '4854.85', '4910.9', '97.1', '2.02%', '4779.08', '4911.69', '704892864', '113850936', '-'], ['2015/5/25', '4660.08', '4813.8', '156.2', '3.35%', '4656.83', '4814.67', '682461376', '107929560', '-'], ['2015/5/22', '4584.98', '4657.6', '128.17', '2.83%', '4562.99', '4658.27', '655591296', '100717320', '-'], ['2015/5/21', '4456.44', '4529.42', '83.13', '1.87%', '4438.26', '4530.48', '464996512', '72908056', '-'], ['2015/5/20', '4434.98', '4446.29', '28.74', '0.65%', '4432.28', '4520.54', '514106208', '80608056', '-'], ['2015/5/19', '4285.78', '4417.55', '134.06', '3.13%', '4285.78', '4418.4', '436735232', '69381256', '-'], ['2015/5/18', '4277.9', '4283.49', '-25.2', '-0.58%', '4260.51', '4324.83', '380057440', '59455952', '-'], ['2015/5/15', '4366.82', '4308.69', '-69.62', '-1.59%', '4278.55', '4366.82', '439706208', '66596564', '-'], ['2015/5/14', '4372.82', '4378.31', '2.55', '0.06%', '4329.04', '4397.75', '449077952', '66988224', '-'], ['2015/5/13', '4402.38', '4375.76', '-25.46', '-0.58%', '4342.48', '4415.63', '510490464', '78075496', '-'], ['2015/5/12', '4342.37', '4401.22', '67.64', '1.56%', '4317.98', '4402.31', '521866400', '79346376', '-'], ['2015/5/11', '4231.27', '4333.58', '127.67', '3.04%', '4187.82', '4334.88', '488750528', '71524664', '-'], ['2015/5/8', '4152.98', '4205.92', '93.7', '2.28%', '4099.04', '4206.86', '397428096', '55964868', '-'], ['2015/5/7', '4197.9', '4112.21', '-117.05', '-2.77%', '4108.01', '4213.76', '394566656', '54020632', '-'], ['2015/5/6', '4311.64', '4229.27', '-69.44', '-1.62%', '4187.37', '4376.35', '481732992', '71653624', '-'], ['2015/5/5', '4479.85', '4298.71', '-181.76', '-4.06%', '4282.24', '4488.87', '572858624', '80556608', '-'], ['2015/5/4', '4441.34', '4480.46', '38.81', '0.87%', '4387.43', '4487.57', '494173376', '71754080', '-'], ['2015/4/30', '4483.01', '4441.65', '-34.96', '-0.78%', '4441.05', '4507.34', '526728000', '77434920', '-'], ['2015/4/29', '4446.12', '4476.62', '0.4', '0.01%', '4398.64', '4499.94', '519834208', '75240176', '-'], ['2015/4/28', '4527.63', '4476.21', '-51.18', '-1.13%', '4432.9', '4572.39', '767676416', '106117216', '-'], ['2015/4/27', '4441.93', '4527.4', '133.71', '3.04%', '4441.93', '4529.73', '671088512', '97524208', '-'], ['2015/4/24', '4355.95', '4393.69', '-20.82', '-0.47%', '4318.12', '4416.38', '628555008', '91687296', '-'], ['2015/4/23', '4414.48', '4414.51', '16.01', '0.36%', '4358.84', '4444.41', '667344640', '96302488', '-'], ['2015/4/22', '4304.6', '4398.49', '104.87', '2.44%', '4297.95', '4400.19', '680305088', '97687696', '-'], ['2015/4/21', '4212.19', '4293.62', '76.55', '1.82%', '4188.57', '4294.38', '634470656', '86244776', '-'], ['2015/4/20', '4301.35', '4217.08', '-70.22', '-1.64%', '4190.68', '4356', '857132800', '100000000', '-'], ['2015/4/17', '4254.72', '4287.3', '92.47', '2.20%', '4238.91', '4317.22', '701706240', '91563304', '-'], ['2015/4/16', '4055.92', '4194.82', '110.66', '2.71%', '4031.24', '4195.31', '551242944', '71208248', '-'], ['2015/4/15', '4135.65', '4084.16', '-51.4', '-1.24%', '4069.01', '4175.49', '613005824', '77312592', '-'], ['2015/4/14', '4125.78', '4135.56', '13.85', '0.34%', '4091.26', '4168.35', '610683520', '81464520', '-'], ['2015/4/13', '4072.72', '4121.71', '87.4', '2.17%', '4057.29', '4128.07', '589814208', '78166736', '-'], ['2015/4/10', '3947.49', '4034.31', '76.78', '1.94%', '3929.32', '4040.35', '484283648', '66850416', '-'], ['2015/4/9', '4006.13', '3957.53', '-37.28', '-0.93%', '3900.03', '4016.4', '585176832', '81671088', '-'], ['2015/4/8', '3976.53', '3994.81', '33.43', '0.84%', '3903.65', '4000.22', '618085440', '83915928', '-'], ['2015/4/7', '3899.42', '3961.38', '97.45', '2.52%', '3891.73', '3961.67', '570447552', '74642400', '-'], ['2015/4/3', '3803.38', '3863.93', '38.14', '1.00%', '3792.21', '3864.41', '473033312', '63565136', '-'], ['2015/4/2', '3827.69', '3825.78', '15.49', '0.41%', '3775.89', '3835.45', '479299680', '63202892', '-'], ['2015/4/1', '3748.34', '3810.29', '62.4', '1.66%', '3742.21', '3817.08', '447458304', '59241832', '-'], ['2015/3/31', '3822.99', '3747.9', '-38.67', '-1.02%', '3737.04', '3835.57', '561676032', '72129488', '-'], ['2015/3/30', '3710.61', '3786.57', '95.47', '2.59%', '3710.61', '3795.94', '564702400', '69212536', '-'], ['2015/3/27', '3686.13', '3691.1', '9', '0.24%', '3656.83', '3710.48', '408945184', '50929848', '-'], ['2015/3/26', '3641.94', '3682.09', '21.37', '0.58%', '3615.01', '3707.32', '488647200', '61951560', '-'], ['2015/3/25', '3680.95', '3660.73', '-30.68', '-0.83%', '3634.56', '3693.15', '521886336', '64549892', '-'], ['2015/3/24', '3692.57', '3691.41', '3.68', '0.10%', '3600.7', '3715.87', '639554688', '75488472', '-'], ['2015/3/23', '3640.1', '3687.73', '70.41', '1.95%', '3635.49', '3688.25', '536062816', '66157464', '-'], ['2015/3/20', '3587.08', '3617.32', '35.05', '0.98%', '3569.38', '3632.34', '516661664', '65177196', '-'], ['2015/3/19', '3576.02', '3582.27', '4.97', '0.14%', '3546.84', '3600.68', '537346624', '61224968', '-'], ['2015/3/18', '3510.5', '3577.3', '74.45', '2.13%', '3503.85', '3577.66', '545217152', '61736700', '-'], ['2015/3/17', '3469.6', '3502.85', '53.54', '1.55%', '3459.69', '3504.12', '520939520', '60150068', '-'], ['2015/3/16', '3391.16', '3449.3', '76.39', '2.26%', '3377.09', '3449.3', '399132416', '47935532', '-'], ['2015/3/13', '3359.49', '3372.91', '23.59', '0.70%', '3352.15', '3391.25', '328410144', '37404140', '-'], ['2015/3/12', '3314.81', '3349.32', '58.42', '1.78%', '3300.49', '3360.05', '357295104', '40719240', '-'], ['2015/3/11', '3289.59', '3290.9', '4.83', '0.15%', '3278.47', '3325.05', '282985536', '32757308', '-'], ['2015/3/10', '3289.08', '3286.07', '-16.34', '-0.49%', '3277.09', '3309.92', '285817568', '32995596', '-'], ['2015/3/9', '3224.31', '3302.41', '61.22', '1.89%', '3198.37', '3307.7', '321495456', '35992752', '-'], ['2015/3/6', '3248.04', '3241.19', '-7.29', '-0.22%', '3234.53', '3266.93', '282915808', '32834414', '-'], ['2015/3/5', '3264.08', '3248.48', '-31.06', '-0.95%', '3221.67', '3266.64', '320663584', '37358000', '-'], ['2015/3/4', '3264.18', '3279.53', '16.48', '0.51%', '3250.48', '3286.59', '293639520', '34678976', '-'], ['2015/3/3', '3317.7', '3263.05', '-73.23', '-2.20%', '3260.43', '3317.7', '382044608', '44159348', '-'], ['2015/3/2', '3332.72', '3336.28', '25.98', '0.78%', '3298.67', '3336.76', '346445664', '41025956', '-'], ['2015/2/27', '3296.83', '3310.3', '11.94', '0.36%', '3291.01', '3324.55', '299163712', '33501958', '-'], ['2015/2/26', '3222.15', '3298.36', '69.52', '2.15%', '3202.19', '3300.62', '301263872', '33434746', '-'], ['2015/2/25', '3256.48', '3228.84', '-18.06', '-0.56%', '3215.55', '3257.22', '233348096', '26514336', '-'], ['2015/2/17', '3230.88', '3246.91', '24.54', '0.76%', '3230.77', '3255.73', '228332624', '26334004', '-'], ['2015/2/16', '3206.14', '3222.36', '18.54', '0.58%', '3195.88', '3228.85', '223797440', '26595070', '-'], ['2015/2/13', '3186.81', '3203.83', '30.41', '0.96%', '3182.79', '3237.16', '261290432', '29301768', '-'], ['2015/2/12', '3157.96', '3173.42', '15.71', '0.50%', '3134.24', '3181.77', '194592320', '22969158', '-'], ['2015/2/11', '3145.76', '3157.7', '16.11', '0.51%', '3139.05', '3166.42', '172840096', '21086256', '-'], ['2015/2/10', '3090.49', '3141.59', '46.47', '1.50%', '3084.25', '3142.1', '193817136', '22508492', '-'], ['2015/2/9', '3063.51', '3095.12', '19.22', '0.62%', '3049.11', '3119.03', '206108384', '24071968', '-'], ['2015/2/6', '3120.09', '3075.91', '-60.62', '-1.93%', '3052.94', '3129.54', '246749680', '26650278', '-'], ['2015/2/5', '3251.21', '3136.53', '-37.6', '-1.18%', '3135.82', '3251.21', '306139296', '34826696', '-'], ['2015/2/4', '3212.82', '3174.13', '-30.78', '-0.96%', '3171.14', '3238.98', '249098080', '29015516', '-'], ['2015/2/3', '3156.09', '3204.91', '76.61', '2.45%', '3129.73', '3207.94', '248192160', '28335594', '-'], ['2015/2/2', '3148.14', '3128.3', '-82.06', '-2.56%', '3122.57', '3175.13', '250861632', '26684996', '-'], ['2015/1/30', '3273.75', '3210.36', '-51.94', '-1.59%', '3210.31', '3288.5', '258312544', '28426564', '-'], ['2015/1/29', '3259', '3262.3', '-43.43', '-1.31%', '3234.24', '3286.79', '274658624', '29642450', '-'], ['2015/1/28', '3325.72', '3305.74', '-47.22', '-1.41%', '3294.66', '3354.8', '301927104', '34156428', '-'], ['2015/1/27', '3389.85', '3352.96', '-30.22', '-0.89%', '3290.22', '3390.22', '374517568', '41829884', '-'], ['2015/1/26', '3347.26', '3383.18', '31.42', '0.94%', '3321.31', '3384.8', '317540992', '35842744', '-'], ['2015/1/23', '3357.1', '3351.76', '8.42', '0.25%', '3328.29', '3406.79', '366249248', '42097952', '-'], ['2015/1/22', '3327.32', '3343.34', '19.73', '0.59%', '3293.98', '3352.38', '353382976', '40787408', '-'], ['2015/1/21', '3189.08', '3323.61', '150.56', '4.74%', '3178.34', '3337', '410956032', '47375868', '-'], ['2015/1/20', '3114.56', '3173.05', '56.7', '1.82%', '3100.48', '3190.25', '357080800', '41629524', '-'], ['2015/1/19', '3189.73', '3116.35', '-260.14', '-7.70%', '3095.07', '3262.21', '401098784', '40988600', '-'], ['2015/1/16', '3343.6', '3376.5', '40.04', '1.20%', '3340.49', '3400.32', '339876768', '39225388', '-'], ['2015/1/15', '3224.07', '3336.46', '114.02', '3.54%', '3207.54', '3337.08', '282546240', '33061054', '-'], ['2015/1/14', '3242.34', '3222.44', '-12.86', '-0.40%', '3193.98', '3268.48', '240190752', '26720452', '-'], ['2015/1/13', '3223.54', '3235.3', '5.98', '0.19%', '3214.41', '3259.39', '230725760', '27358878', '-'], ['2015/1/12', '3258.21', '3229.32', '-56.1', '-1.71%', '3191.58', '3275.19', '322064672', '36627308', '-'], ['2015/1/9', '3276.97', '3285.41', '-8.04', '-0.24%', '3267.51', '3404.83', '410240864', '45864804', '-'], ['2015/1/8', '3371.96', '3293.46', '-80.5', '-2.39%', '3285.09', '3381.57', '371131200', '39923032', '-'], ['2015/1/7', '3326.65', '3373.95', '22.51', '0.67%', '3312.21', '3374.9', '391918880', '43641672', '-'], ['2015/1/6', '3330.8', '3351.45', '0.93', '0.03%', '3303.18', '3394.22', '501661696', '53239848', '-'], ['2015/1/5', '3258.63', '3350.52', '115.84', '3.58%', '3253.88', '3369.28', '531352384', '54976008', '-'], ['', '', '', '', '', '', '', '', '', ''], ['', '', '', '', '', '', '', '', '', '']].reverse(); +function calculateMA(dayCount, data) { + var result = []; + for (var i = 0, len = data.length; i < len; i++) { + if (i < dayCount) { + result.push('-'); + continue; + } + var sum = 0; + for (var j = 0; j < dayCount; j++) { + sum += +data[i - j][1]; + } + result.push(sum / dayCount); + } + return result; +} +const dates = rawData.map(function (item) { + return item[0]; +}); +const data = rawData.map(function (item) { + return [+item[1], +item[2], +item[5], +item[6]]; +}); +option = { + legend: { + data: ['日K', 'MA5', 'MA10', 'MA20', 'MA30'], + inactiveColor: '#777' + }, + tooltip: { + trigger: 'axis', + axisPointer: { + animation: false, + type: 'cross', + lineStyle: { + color: '#376df4', + width: 2, + opacity: 1 + } + } + }, + xAxis: { + type: 'category', + data: dates, + axisLine: { lineStyle: { color: '#8392A5' } } + }, + yAxis: { + scale: true, + axisLine: { lineStyle: { color: '#8392A5' } }, + splitLine: { show: false } + }, + grid: { + bottom: 80 + }, + dataZoom: [ + { + textStyle: { + color: '#8392A5' + }, + handleIcon: 'path://M10.7,11.9v-1.3H9.3v1.3c-4.9,0.3-8.8,4.4-8.8,9.4c0,5,3.9,9.1,8.8,9.4v1.3h1.3v-1.3c4.9-0.3,8.8-4.4,8.8-9.4C19.5,16.3,15.6,12.2,10.7,11.9z M13.3,24.4H6.7V23h6.6V24.4z M13.3,19.6H6.7v-1.4h6.6V19.6z', + dataBackground: { + areaStyle: { + color: '#8392A5' + }, + lineStyle: { + opacity: 0.8, + color: '#8392A5' + } + }, + brushSelect: true + }, + { + type: 'inside' + } + ], + series: [ + { + type: 'candlestick', + name: 'Day', + data: data, + itemStyle: { + color: '#FD1050', + color0: '#0CF49B', + borderColor: '#FD1050', + borderColor0: '#0CF49B' + } + }, + { + name: 'MA5', + type: 'line', + data: calculateMA(5, data), + smooth: true, + showSymbol: false, + lineStyle: { + width: 1 + } + }, + { + name: 'MA10', + type: 'line', + data: calculateMA(10, data), + smooth: true, + showSymbol: false, + lineStyle: { + width: 1 + } + }, + { + name: 'MA20', + type: 'line', + data: calculateMA(20, data), + smooth: true, + showSymbol: false, + lineStyle: { + width: 1 + } + }, + { + name: 'MA30', + type: 'line', + data: calculateMA(30, data), + smooth: true, + showSymbol: false, + lineStyle: { + width: 1 + } + } + ] +}; +export {}; diff --git a/testdata/candlestick-sh-2015.js.svg b/testdata/candlestick-sh-2015.js.svg new file mode 100644 index 0000000..f256978 --- /dev/null +++ b/testdata/candlestick-sh-2015.js.svg @@ -0,0 +1,397 @@ + + + + + + + + + + + + + +0 +1,000 +2,000 +3,000 +4,000 +5,000 +6,000 +2015/2/11 +2015/3/31 +2015/5/13 +2015/6/24 +2015/8/4 +2015/9/16 +2015/11/3 +2015/12/14 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +MA5 + + +MA10 + + +MA20 + + +MA30 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/candlestick-sh.js b/testdata/candlestick-sh.js new file mode 100644 index 0000000..b30c9a6 --- /dev/null +++ b/testdata/candlestick-sh.js @@ -0,0 +1,310 @@ +/* +title: ShangHai Index +category: candlestick +titleCN: 上证指数 +difficulty: 2 +*/ +const upColor = '#ec0000'; +const upBorderColor = '#8A0000'; +const downColor = '#00da3c'; +const downBorderColor = '#008F28'; +// Each item: open,close,lowest,highest +const data0 = splitData([ + ['2013/1/24', 2320.26, 2320.26, 2287.3, 2362.94], + ['2013/1/25', 2300, 2291.3, 2288.26, 2308.38], + ['2013/1/28', 2295.35, 2346.5, 2295.35, 2346.92], + ['2013/1/29', 2347.22, 2358.98, 2337.35, 2363.8], + ['2013/1/30', 2360.75, 2382.48, 2347.89, 2383.76], + ['2013/1/31', 2383.43, 2385.42, 2371.23, 2391.82], + ['2013/2/1', 2377.41, 2419.02, 2369.57, 2421.15], + ['2013/2/4', 2425.92, 2428.15, 2417.58, 2440.38], + ['2013/2/5', 2411, 2433.13, 2403.3, 2437.42], + ['2013/2/6', 2432.68, 2434.48, 2427.7, 2441.73], + ['2013/2/7', 2430.69, 2418.53, 2394.22, 2433.89], + ['2013/2/8', 2416.62, 2432.4, 2414.4, 2443.03], + ['2013/2/18', 2441.91, 2421.56, 2415.43, 2444.8], + ['2013/2/19', 2420.26, 2382.91, 2373.53, 2427.07], + ['2013/2/20', 2383.49, 2397.18, 2370.61, 2397.94], + ['2013/2/21', 2378.82, 2325.95, 2309.17, 2378.82], + ['2013/2/22', 2322.94, 2314.16, 2308.76, 2330.88], + ['2013/2/25', 2320.62, 2325.82, 2315.01, 2338.78], + ['2013/2/26', 2313.74, 2293.34, 2289.89, 2340.71], + ['2013/2/27', 2297.77, 2313.22, 2292.03, 2324.63], + ['2013/2/28', 2322.32, 2365.59, 2308.92, 2366.16], + ['2013/3/1', 2364.54, 2359.51, 2330.86, 2369.65], + ['2013/3/4', 2332.08, 2273.4, 2259.25, 2333.54], + ['2013/3/5', 2274.81, 2326.31, 2270.1, 2328.14], + ['2013/3/6', 2333.61, 2347.18, 2321.6, 2351.44], + ['2013/3/7', 2340.44, 2324.29, 2304.27, 2352.02], + ['2013/3/8', 2326.42, 2318.61, 2314.59, 2333.67], + ['2013/3/11', 2314.68, 2310.59, 2296.58, 2320.96], + ['2013/3/12', 2309.16, 2286.6, 2264.83, 2333.29], + ['2013/3/13', 2282.17, 2263.97, 2253.25, 2286.33], + ['2013/3/14', 2255.77, 2270.28, 2253.31, 2276.22], + ['2013/3/15', 2269.31, 2278.4, 2250, 2312.08], + ['2013/3/18', 2267.29, 2240.02, 2239.21, 2276.05], + ['2013/3/19', 2244.26, 2257.43, 2232.02, 2261.31], + ['2013/3/20', 2257.74, 2317.37, 2257.42, 2317.86], + ['2013/3/21', 2318.21, 2324.24, 2311.6, 2330.81], + ['2013/3/22', 2321.4, 2328.28, 2314.97, 2332], + ['2013/3/25', 2334.74, 2326.72, 2319.91, 2344.89], + ['2013/3/26', 2318.58, 2297.67, 2281.12, 2319.99], + ['2013/3/27', 2299.38, 2301.26, 2289, 2323.48], + ['2013/3/28', 2273.55, 2236.3, 2232.91, 2273.55], + ['2013/3/29', 2238.49, 2236.62, 2228.81, 2246.87], + ['2013/4/1', 2229.46, 2234.4, 2227.31, 2243.95], + ['2013/4/2', 2234.9, 2227.74, 2220.44, 2253.42], + ['2013/4/3', 2232.69, 2225.29, 2217.25, 2241.34], + ['2013/4/8', 2196.24, 2211.59, 2180.67, 2212.59], + ['2013/4/9', 2215.47, 2225.77, 2215.47, 2234.73], + ['2013/4/10', 2224.93, 2226.13, 2212.56, 2233.04], + ['2013/4/11', 2236.98, 2219.55, 2217.26, 2242.48], + ['2013/4/12', 2218.09, 2206.78, 2204.44, 2226.26], + ['2013/4/15', 2199.91, 2181.94, 2177.39, 2204.99], + ['2013/4/16', 2169.63, 2194.85, 2165.78, 2196.43], + ['2013/4/17', 2195.03, 2193.8, 2178.47, 2197.51], + ['2013/4/18', 2181.82, 2197.6, 2175.44, 2206.03], + ['2013/4/19', 2201.12, 2244.64, 2200.58, 2250.11], + ['2013/4/22', 2236.4, 2242.17, 2232.26, 2245.12], + ['2013/4/23', 2242.62, 2184.54, 2182.81, 2242.62], + ['2013/4/24', 2187.35, 2218.32, 2184.11, 2226.12], + ['2013/4/25', 2213.19, 2199.31, 2191.85, 2224.63], + ['2013/4/26', 2203.89, 2177.91, 2173.86, 2210.58], + ['2013/5/2', 2170.78, 2174.12, 2161.14, 2179.65], + ['2013/5/3', 2179.05, 2205.5, 2179.05, 2222.81], + ['2013/5/6', 2212.5, 2231.17, 2212.5, 2236.07], + ['2013/5/7', 2227.86, 2235.57, 2219.44, 2240.26], + ['2013/5/8', 2242.39, 2246.3, 2235.42, 2255.21], + ['2013/5/9', 2246.96, 2232.97, 2221.38, 2247.86], + ['2013/5/10', 2228.82, 2246.83, 2225.81, 2247.67], + ['2013/5/13', 2247.68, 2241.92, 2231.36, 2250.85], + ['2013/5/14', 2238.9, 2217.01, 2205.87, 2239.93], + ['2013/5/15', 2217.09, 2224.8, 2213.58, 2225.19], + ['2013/5/16', 2221.34, 2251.81, 2210.77, 2252.87], + ['2013/5/17', 2249.81, 2282.87, 2248.41, 2288.09], + ['2013/5/20', 2286.33, 2299.99, 2281.9, 2309.39], + ['2013/5/21', 2297.11, 2305.11, 2290.12, 2305.3], + ['2013/5/22', 2303.75, 2302.4, 2292.43, 2314.18], + ['2013/5/23', 2293.81, 2275.67, 2274.1, 2304.95], + ['2013/5/24', 2281.45, 2288.53, 2270.25, 2292.59], + ['2013/5/27', 2286.66, 2293.08, 2283.94, 2301.7], + ['2013/5/28', 2293.4, 2321.32, 2281.47, 2322.1], + ['2013/5/29', 2323.54, 2324.02, 2321.17, 2334.33], + ['2013/5/30', 2316.25, 2317.75, 2310.49, 2325.72], + ['2013/5/31', 2320.74, 2300.59, 2299.37, 2325.53], + ['2013/6/3', 2300.21, 2299.25, 2294.11, 2313.43], + ['2013/6/4', 2297.1, 2272.42, 2264.76, 2297.1], + ['2013/6/5', 2270.71, 2270.93, 2260.87, 2276.86], + ['2013/6/6', 2264.43, 2242.11, 2240.07, 2266.69], + ['2013/6/7', 2242.26, 2210.9, 2205.07, 2250.63], + ['2013/6/13', 2190.1, 2148.35, 2126.22, 2190.1] +]); +function splitData(rawData) { + const categoryData = []; + const values = []; + for (var i = 0; i < rawData.length; i++) { + categoryData.push(rawData[i].splice(0, 1)[0]); + values.push(rawData[i]); + } + return { + categoryData: categoryData, + values: values + }; +} +function calculateMA(dayCount) { + var result = []; + for (var i = 0, len = data0.values.length; i < len; i++) { + if (i < dayCount) { + result.push('-'); + continue; + } + var sum = 0; + for (var j = 0; j < dayCount; j++) { + sum += +data0.values[i - j][1]; + } + result.push(sum / dayCount); + } + return result; +} +option = { + title: { + text: '上证指数', + left: 0 + }, + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'cross' + } + }, + legend: { + data: ['日K', 'MA5', 'MA10', 'MA20', 'MA30'] + }, + grid: { + left: '10%', + right: '10%', + bottom: '15%' + }, + xAxis: { + type: 'category', + data: data0.categoryData, + boundaryGap: false, + axisLine: { onZero: false }, + splitLine: { show: false }, + min: 'dataMin', + max: 'dataMax' + }, + yAxis: { + scale: true, + splitArea: { + show: true + } + }, + dataZoom: [ + { + type: 'inside', + start: 50, + end: 100 + }, + { + show: true, + type: 'slider', + top: '90%', + start: 50, + end: 100 + } + ], + series: [ + { + name: '日K', + type: 'candlestick', + data: data0.values, + itemStyle: { + color: upColor, + color0: downColor, + borderColor: upBorderColor, + borderColor0: downBorderColor + }, + markPoint: { + label: { + formatter: function (param) { + return param != null ? Math.round(param.value) + '' : ''; + } + }, + data: [ + { + name: 'Mark', + coord: ['2013/5/31', 2300], + value: 2300, + itemStyle: { + color: 'rgb(41,60,85)' + } + }, + { + name: 'highest value', + type: 'max', + valueDim: 'highest' + }, + { + name: 'lowest value', + type: 'min', + valueDim: 'lowest' + }, + { + name: 'average value on close', + type: 'average', + valueDim: 'close' + } + ], + tooltip: { + formatter: function (param) { + return param.name + '
' + (param.data.coord || ''); + } + } + }, + markLine: { + symbol: ['none', 'none'], + data: [ + [ + { + name: 'from lowest to highest', + type: 'min', + valueDim: 'lowest', + symbol: 'circle', + symbolSize: 10, + label: { + show: false + }, + emphasis: { + label: { + show: false + } + } + }, + { + type: 'max', + valueDim: 'highest', + symbol: 'circle', + symbolSize: 10, + label: { + show: false + }, + emphasis: { + label: { + show: false + } + } + } + ], + { + name: 'min line on close', + type: 'min', + valueDim: 'close' + }, + { + name: 'max line on close', + type: 'max', + valueDim: 'close' + } + ] + } + }, + { + name: 'MA5', + type: 'line', + data: calculateMA(5), + smooth: true, + lineStyle: { + opacity: 0.5 + } + }, + { + name: 'MA10', + type: 'line', + data: calculateMA(10), + smooth: true, + lineStyle: { + opacity: 0.5 + } + }, + { + name: 'MA20', + type: 'line', + data: calculateMA(20), + smooth: true, + lineStyle: { + opacity: 0.5 + } + }, + { + name: 'MA30', + type: 'line', + data: calculateMA(30), + smooth: true, + lineStyle: { + opacity: 0.5 + } + } + ] +}; +export {}; diff --git a/testdata/candlestick-sh.js.svg b/testdata/candlestick-sh.js.svg new file mode 100644 index 0000000..02f5e65 --- /dev/null +++ b/testdata/candlestick-sh.js.svg @@ -0,0 +1,400 @@ + + + + + + + + + + + + + + + + + + + + + + + +2,100 +2,150 +2,200 +2,250 +2,300 +2,350 +2013/4/8 +2013/4/15 +2013/4/22 +2013/5/2 +2013/5/9 +2013/5/16 +2013/5/23 +2013/5/30 +2013/6/6 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +日K + + +MA5 + + +MA10 + + +MA20 + + +MA30 + + + + + + + + + + + + +2148.35 +2324.02 + + + + +2300 +2334.33 +2126.22 +2241.92 + +上证指数 + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/candlestick-simple.js b/testdata/candlestick-simple.js new file mode 100644 index 0000000..63a1a69 --- /dev/null +++ b/testdata/candlestick-simple.js @@ -0,0 +1,24 @@ +/* +title: Basic Candlestick +category: candlestick +titleCN: 基础 K 线图 +difficulty: 0 +*/ +option = { + xAxis: { + data: ['2017-10-24', '2017-10-25', '2017-10-26', '2017-10-27'] + }, + yAxis: {}, + series: [ + { + type: 'candlestick', + data: [ + [20, 34, 10, 38], + [40, 35, 30, 50], + [31, 38, 33, 44], + [38, 15, 5, 42] + ] + } + ] +}; +export {}; diff --git a/testdata/candlestick-simple.js.svg b/testdata/candlestick-simple.js.svg new file mode 100644 index 0000000..8b4465f --- /dev/null +++ b/testdata/candlestick-simple.js.svg @@ -0,0 +1,29 @@ + + + + + + + + + + + + + + +0 +10 +20 +30 +40 +50 +2017-10-24 +2017-10-25 +2017-10-26 +2017-10-27 + + + + + \ No newline at end of file diff --git a/testdata/candlestick-touch.js b/testdata/candlestick-touch.js new file mode 100644 index 0000000..e358bbb --- /dev/null +++ b/testdata/candlestick-touch.js @@ -0,0 +1,267 @@ +/* +title: Axis Pointer Link and Touch +category: candlestick +titleCN: 触屏上的坐标轴指示器 +difficulty: 4 +*/ +// prettier-ignore +const rawData = [["2015/1/5", "3258.63", "3350.52", "115.84", "3.58%", "3253.88", "3369.28", "531352384", "54976008", "-"], ["2015/1/6", "3330.8", "3351.45", "0.93", "0.03%", "3303.18", "3394.22", "501661696", "53239848", "-"], ["2015/1/7", "3326.65", "3373.95", "22.51", "0.67%", "3312.21", "3374.9", "391918880", "43641672", "-"], ["2015/1/8", "3371.96", "3293.46", "-80.5", "-2.39%", "3285.09", "3381.57", "371131200", "39923032", "-"], ["2015/1/9", "3276.97", "3285.41", "-8.04", "-0.24%", "3267.51", "3404.83", "410240864", "45864804", "-"], ["2015/1/12", "3258.21", "3229.32", "-56.1", "-1.71%", "3191.58", "3275.19", "322064672", "36627308", "-"], ["2015/1/13", "3223.54", "3235.3", "5.98", "0.19%", "3214.41", "3259.39", "230725760", "27358878", "-"], ["2015/1/14", "3242.34", "3222.44", "-12.86", "-0.40%", "3193.98", "3268.48", "240190752", "26720452", "-"], ["2015/1/15", "3224.07", "3336.46", "114.02", "3.54%", "3207.54", "3337.08", "282546240", "33061054", "-"], ["2015/1/16", "3343.6", "3376.5", "40.04", "1.20%", "3340.49", "3400.32", "339876768", "39225388", "-"], ["2015/1/19", "3189.73", "3116.35", "-260.14", "-7.70%", "3095.07", "3262.21", "401098784", "40988600", "-"], ["2015/1/20", "3114.56", "3173.05", "56.7", "1.82%", "3100.48", "3190.25", "357080800", "41629524", "-"], ["2015/1/21", "3189.08", "3323.61", "150.56", "4.74%", "3178.34", "3337", "410956032", "47375868", "-"], ["2015/1/22", "3327.32", "3343.34", "19.73", "0.59%", "3293.98", "3352.38", "353382976", "40787408", "-"], ["2015/1/23", "3357.1", "3351.76", "8.42", "0.25%", "3328.29", "3406.79", "366249248", "42097952", "-"], ["2015/1/26", "3347.26", "3383.18", "31.42", "0.94%", "3321.31", "3384.8", "317540992", "35842744", "-"], ["2015/1/27", "3389.85", "3352.96", "-30.22", "-0.89%", "3290.22", "3390.22", "374517568", "41829884", "-"], ["2015/1/28", "3325.72", "3305.74", "-47.22", "-1.41%", "3294.66", "3354.8", "301927104", "34156428", "-"], ["2015/1/29", "3259", "3262.3", "-43.43", "-1.31%", "3234.24", "3286.79", "274658624", "29642450", "-"], ["2015/1/30", "3273.75", "3210.36", "-51.94", "-1.59%", "3210.31", "3288.5", "258312544", "28426564", "-"], ["2015/2/2", "3148.14", "3128.3", "-82.06", "-2.56%", "3122.57", "3175.13", "250861632", "26684996", "-"], ["2015/2/3", "3156.09", "3204.91", "76.61", "2.45%", "3129.73", "3207.94", "248192160", "28335594", "-"], ["2015/2/4", "3212.82", "3174.13", "-30.78", "-0.96%", "3171.14", "3238.98", "249098080", "29015516", "-"], ["2015/2/5", "3251.21", "3136.53", "-37.6", "-1.18%", "3135.82", "3251.21", "306139296", "34826696", "-"], ["2015/2/6", "3120.09", "3075.91", "-60.62", "-1.93%", "3052.94", "3129.54", "246749680", "26650278", "-"], ["2015/2/9", "3063.51", "3095.12", "19.22", "0.62%", "3049.11", "3119.03", "206108384", "24071968", "-"], ["2015/2/10", "3090.49", "3141.59", "46.47", "1.50%", "3084.25", "3142.1", "193817136", "22508492", "-"], ["2015/2/11", "3145.76", "3157.7", "16.11", "0.51%", "3139.05", "3166.42", "172840096", "21086256", "-"], ["2015/2/12", "3157.96", "3173.42", "15.71", "0.50%", "3134.24", "3181.77", "194592320", "22969158", "-"], ["2015/2/13", "3186.81", "3203.83", "30.41", "0.96%", "3182.79", "3237.16", "261290432", "29301768", "-"], ["2015/2/16", "3206.14", "3222.36", "18.54", "0.58%", "3195.88", "3228.85", "223797440", "26595070", "-"], ["2015/2/17", "3230.88", "3246.91", "24.54", "0.76%", "3230.77", "3255.73", "228332624", "26334004", "-"], ["2015/2/25", "3256.48", "3228.84", "-18.06", "-0.56%", "3215.55", "3257.22", "233348096", "26514336", "-"], ["2015/2/26", "3222.15", "3298.36", "69.52", "2.15%", "3202.19", "3300.62", "301263872", "33434746", "-"], ["2015/2/27", "3296.83", "3310.3", "11.94", "0.36%", "3291.01", "3324.55", "299163712", "33501958", "-"], ["2015/3/2", "3332.72", "3336.28", "25.98", "0.78%", "3298.67", "3336.76", "346445664", "41025956", "-"], ["2015/3/3", "3317.7", "3263.05", "-73.23", "-2.20%", "3260.43", "3317.7", "382044608", "44159348", "-"], ["2015/3/4", "3264.18", "3279.53", "16.48", "0.51%", "3250.48", "3286.59", "293639520", "34678976", "-"], ["2015/3/5", "3264.08", "3248.48", "-31.06", "-0.95%", "3221.67", "3266.64", "320663584", "37358000", "-"], ["2015/3/6", "3248.04", "3241.19", "-7.29", "-0.22%", "3234.53", "3266.93", "282915808", "32834414", "-"], ["2015/3/9", "3224.31", "3302.41", "61.22", "1.89%", "3198.37", "3307.7", "321495456", "35992752", "-"], ["2015/3/10", "3289.08", "3286.07", "-16.34", "-0.49%", "3277.09", "3309.92", "285817568", "32995596", "-"], ["2015/3/11", "3289.59", "3290.9", "4.83", "0.15%", "3278.47", "3325.05", "282985536", "32757308", "-"], ["2015/3/12", "3314.81", "3349.32", "58.42", "1.78%", "3300.49", "3360.05", "357295104", "40719240", "-"], ["2015/3/13", "3359.49", "3372.91", "23.59", "0.70%", "3352.15", "3391.25", "328410144", "37404140", "-"], ["2015/3/16", "3391.16", "3449.3", "76.39", "2.26%", "3377.09", "3449.3", "399132416", "47935532", "-"], ["2015/3/17", "3469.6", "3502.85", "53.54", "1.55%", "3459.69", "3504.12", "520939520", "60150068", "-"], ["2015/3/18", "3510.5", "3577.3", "74.45", "2.13%", "3503.85", "3577.66", "545217152", "61736700", "-"], ["2015/3/19", "3576.02", "3582.27", "4.97", "0.14%", "3546.84", "3600.68", "537346624", "61224968", "-"], ["2015/3/20", "3587.08", "3617.32", "35.05", "0.98%", "3569.38", "3632.34", "516661664", "65177196", "-"], ["2015/3/23", "3640.1", "3687.73", "70.41", "1.95%", "3635.49", "3688.25", "536062816", "66157464", "-"], ["2015/3/24", "3692.57", "3691.41", "3.68", "0.10%", "3600.7", "3715.87", "639554688", "75488472", "-"], ["2015/3/25", "3680.95", "3660.73", "-30.68", "-0.83%", "3634.56", "3693.15", "521886336", "64549892", "-"], ["2015/3/26", "3641.94", "3682.09", "21.37", "0.58%", "3615.01", "3707.32", "488647200", "61951560", "-"], ["2015/3/27", "3686.13", "3691.1", "9", "0.24%", "3656.83", "3710.48", "408945184", "50929848", "-"], ["2015/3/30", "3710.61", "3786.57", "95.47", "2.59%", "3710.61", "3795.94", "564702400", "69212536", "-"], ["2015/3/31", "3822.99", "3747.9", "-38.67", "-1.02%", "3737.04", "3835.57", "561676032", "72129488", "-"], ["2015/4/1", "3748.34", "3810.29", "62.4", "1.66%", "3742.21", "3817.08", "447458304", "59241832", "-"], ["2015/4/2", "3827.69", "3825.78", "15.49", "0.41%", "3775.89", "3835.45", "479299680", "63202892", "-"], ["2015/4/3", "3803.38", "3863.93", "38.14", "1.00%", "3792.21", "3864.41", "473033312", "63565136", "-"]]; +// prettier-ignore +const colorList = ['#c23531', '#2f4554', '#61a0a8', '#d48265', '#91c7ae', '#749f83', '#ca8622', '#bda29a', '#6e7074', '#546570', '#c4ccd3']; +const labelFont = 'bold 12px Sans-serif'; +function calculateMA(dayCount, data) { + let result = []; + for (let i = 0, len = data.length; i < len; i++) { + if (i < dayCount) { + result.push('-'); + continue; + } + let sum = 0; + for (let j = 0; j < dayCount; j++) { + sum += +data[i - j][1]; + } + result.push((sum / dayCount).toFixed(2)); + } + return result; +} +// prettier-ignore +const dates = ["2016-03-29", "2016-03-30", "2016-03-31", "2016-04-01", "2016-04-04", "2016-04-05", "2016-04-06", "2016-04-07", "2016-04-08", "2016-04-11", "2016-04-12", "2016-04-13", "2016-04-14", "2016-04-15", "2016-04-18", "2016-04-19", "2016-04-20", "2016-04-21", "2016-04-22", "2016-04-25", "2016-04-26", "2016-04-27", "2016-04-28", "2016-04-29", "2016-05-02", "2016-05-03", "2016-05-04", "2016-05-05", "2016-05-06", "2016-05-09", "2016-05-10", "2016-05-11", "2016-05-12", "2016-05-13", "2016-05-16", "2016-05-17", "2016-05-18", "2016-05-19", "2016-05-20", "2016-05-23", "2016-05-24", "2016-05-25", "2016-05-26", "2016-05-27", "2016-05-31", "2016-06-01", "2016-06-02", "2016-06-03", "2016-06-06", "2016-06-07", "2016-06-08", "2016-06-09", "2016-06-10", "2016-06-13", "2016-06-14", "2016-06-15", "2016-06-16", "2016-06-17", "2016-06-20", "2016-06-21", "2016-06-22"]; +// prettier-ignore +const data = [[17512.58, 17633.11, 17434.27, 17642.81, 86160000], [17652.36, 17716.66, 17652.36, 17790.11, 79330000], [17716.05, 17685.09, 17669.72, 17755.7, 102600000], [17661.74, 17792.75, 17568.02, 17811.48, 104890000], [17799.39, 17737, 17710.67, 17806.38, 85230000], [17718.03, 17603.32, 17579.56, 17718.03, 115230000], [17605.45, 17716.05, 17542.54, 17723.55, 99410000], [17687.28, 17541.96, 17484.23, 17687.28, 90120000], [17555.39, 17576.96, 17528.16, 17694.51, 79990000], [17586.48, 17556.41, 17555.9, 17731.63, 107100000], [17571.34, 17721.25, 17553.57, 17744.43, 81020000], [17741.66, 17908.28, 17741.66, 17918.35, 91710000], [17912.25, 17926.43, 17885.44, 17962.14, 84510000], [17925.95, 17897.46, 17867.41, 17937.65, 118160000], [17890.2, 18004.16, 17848.22, 18009.53, 89390000], [18012.1, 18053.6, 17984.43, 18103.46, 89820000], [18059.49, 18096.27, 18031.21, 18167.63, 100210000], [18092.84, 17982.52, 17963.89, 18107.29, 102720000], [17985.05, 18003.75, 17909.89, 18026.85, 134120000], [17990.94, 17977.24, 17855.55, 17990.94, 83770000], [17987.38, 17990.32, 17934.17, 18043.77, 92570000], [17996.14, 18041.55, 17920.26, 18084.66, 109090000], [18023.88, 17830.76, 17796.55, 18035.73, 100920000], [17813.09, 17773.64, 17651.98, 17814.83, 136670000], [17783.78, 17891.16, 17773.71, 17912.35, 80100000], [17870.75, 17750.91, 17670.88, 17870.75, 97060000], [17735.02, 17651.26, 17609.01, 17738.06, 95020000], [17664.48, 17660.71, 17615.82, 17736.11, 81530000], [17650.3, 17740.63, 17580.38, 17744.54, 80020000], [17743.85, 17705.91, 17668.38, 17783.16, 85590000], [17726.66, 17928.35, 17726.66, 17934.61, 75790000], [17919.03, 17711.12, 17711.05, 17919.03, 87390000], [17711.12, 17720.5, 17625.38, 17798.19, 88560000], [17711.12, 17535.32, 17512.48, 17734.74, 86640000], [17531.76, 17710.71, 17531.76, 17755.8, 88440000], [17701.46, 17529.98, 17469.92, 17701.46, 103260000], [17501.28, 17526.62, 17418.21, 17636.22, 79120000], [17514.16, 17435.4, 17331.07, 17514.16, 95530000], [17437.32, 17500.94, 17437.32, 17571.75, 111990000], [17507.04, 17492.93, 17480.05, 17550.7, 87790000], [17525.19, 17706.05, 17525.19, 17742.59, 86480000], [17735.09, 17851.51, 17735.09, 17891.71, 79180000], [17859.52, 17828.29, 17803.82, 17888.66, 68940000], [17826.85, 17873.22, 17824.73, 17873.22, 73190000], [17891.5, 17787.2, 17724.03, 17899.24, 147390000], [17754.55, 17789.67, 17664.79, 17809.18, 78530000], [17789.05, 17838.56, 17703.55, 17838.56, 75560000], [17799.8, 17807.06, 17689.68, 17833.17, 82270000], [17825.69, 17920.33, 17822.81, 17949.68, 71870000], [17936.22, 17938.28, 17936.22, 18003.23, 78750000], [17931.91, 18005.05, 17931.91, 18016, 71260000], [17969.98, 17985.19, 17915.88, 18005.22, 69690000], [17938.82, 17865.34, 17812.34, 17938.82, 90540000], [17830.5, 17732.48, 17731.35, 17893.28, 101690000], [17710.77, 17674.82, 17595.79, 17733.92, 93740000], [17703.65, 17640.17, 17629.01, 17762.96, 94130000], [17602.23, 17733.1, 17471.29, 17754.91, 91950000], [17733.44, 17675.16, 17602.78, 17733.44, 248680000], [17736.87, 17804.87, 17736.87, 17946.36, 99380000], [17827.33, 17829.73, 17799.8, 17877.84, 85130000], [17832.67, 17780.83, 17770.36, 17920.16, 89440000]]; +// prettier-ignore +const volumes = [86160000, 79330000, 102600000, 104890000, 85230000, 115230000, 99410000, 90120000, 79990000, 107100000, 81020000, 91710000, 84510000, 118160000, 89390000, 89820000, 100210000, 102720000, 134120000, 83770000, 92570000, 109090000, 100920000, 136670000, 80100000, 97060000, 95020000, 81530000, 80020000, 85590000, 75790000, 87390000, 88560000, 86640000, 88440000, 103260000, 79120000, 95530000, 111990000, 87790000, 86480000, 79180000, 68940000, 73190000, 147390000, 78530000, 75560000, 82270000, 71870000, 78750000, 71260000, 69690000, 90540000, 101690000, 93740000, 94130000, 91950000, 248680000, 99380000, 85130000, 89440000]; +const dataMA5 = calculateMA(5, data); +const dataMA10 = calculateMA(10, data); +const dataMA20 = calculateMA(20, data); +option = { + animation: false, + color: colorList, + title: { + left: 'center', + text: 'Candlestick on Mobile' + }, + legend: { + top: 30, + data: ['日K', 'MA5', 'MA10', 'MA20', 'MA30'] + }, + tooltip: { + triggerOn: 'none', + transitionDuration: 0, + confine: true, + borderRadius: 4, + borderWidth: 1, + borderColor: '#333', + backgroundColor: 'rgba(255,255,255,0.9)', + textStyle: { + fontSize: 12, + color: '#333' + }, + position: function (pos, params, el, elRect, size) { + const obj = { + top: 60 + }; + obj[['left', 'right'][+(pos[0] < size.viewSize[0] / 2)]] = 5; + return obj; + } + }, + axisPointer: { + link: [ + { + xAxisIndex: [0, 1] + } + ] + }, + dataZoom: [ + { + type: 'slider', + xAxisIndex: [0, 1], + realtime: false, + start: 20, + end: 70, + top: 65, + height: 20, + handleIcon: 'path://M10.7,11.9H9.3c-4.9,0.3-8.8,4.4-8.8,9.4c0,5,3.9,9.1,8.8,9.4h1.3c4.9-0.3,8.8-4.4,8.8-9.4C19.5,16.3,15.6,12.2,10.7,11.9z M13.3,24.4H6.7V23h6.6V24.4z M13.3,19.6H6.7v-1.4h6.6V19.6z', + handleSize: '120%' + }, + { + type: 'inside', + xAxisIndex: [0, 1], + start: 40, + end: 70, + top: 30, + height: 20 + } + ], + xAxis: [ + { + type: 'category', + data: dates, + boundaryGap: false, + axisLine: { lineStyle: { color: '#777' } }, + axisLabel: { + formatter: function (value) { + return echarts.format.formatTime('MM-dd', value); + } + }, + min: 'dataMin', + max: 'dataMax', + axisPointer: { + show: true + } + }, + { + type: 'category', + gridIndex: 1, + data: dates, + boundaryGap: false, + splitLine: { show: false }, + axisLabel: { show: false }, + axisTick: { show: false }, + axisLine: { lineStyle: { color: '#777' } }, + min: 'dataMin', + max: 'dataMax', + axisPointer: { + type: 'shadow', + label: { show: false }, + triggerTooltip: true, + handle: { + show: true, + margin: 30, + color: '#B80C00' + } + } + } + ], + yAxis: [ + { + scale: true, + splitNumber: 2, + axisLine: { lineStyle: { color: '#777' } }, + splitLine: { show: true }, + axisTick: { show: false }, + axisLabel: { + inside: true, + formatter: '{value}\n' + } + }, + { + scale: true, + gridIndex: 1, + splitNumber: 2, + axisLabel: { show: false }, + axisLine: { show: false }, + axisTick: { show: false }, + splitLine: { show: false } + } + ], + grid: [ + { + left: 20, + right: 20, + top: 110, + height: 120 + }, + { + left: 20, + right: 20, + height: 40, + top: 260 + } + ], + graphic: [ + { + type: 'group', + left: 'center', + top: 70, + width: 300, + bounding: 'raw', + children: [ + { + id: 'MA5', + type: 'text', + style: { fill: colorList[1], font: labelFont }, + left: 0 + }, + { + id: 'MA10', + type: 'text', + style: { fill: colorList[2], font: labelFont }, + left: 'center' + }, + { + id: 'MA20', + type: 'text', + style: { fill: colorList[3], font: labelFont }, + right: 0 + } + ] + } + ], + series: [ + { + name: 'Volume', + type: 'bar', + xAxisIndex: 1, + yAxisIndex: 1, + itemStyle: { + color: '#7fbe9e' + }, + emphasis: { + itemStyle: { + color: '#140' + } + }, + data: volumes + }, + { + type: 'candlestick', + name: '日K', + data: data, + itemStyle: { + color: '#ef232a', + color0: '#14b143', + borderColor: '#ef232a', + borderColor0: '#14b143' + }, + emphasis: { + itemStyle: { + color: 'black', + color0: '#444', + borderColor: 'black', + borderColor0: '#444' + } + } + }, + { + name: 'MA5', + type: 'line', + data: dataMA5, + smooth: true, + showSymbol: false, + lineStyle: { + width: 1 + } + }, + { + name: 'MA10', + type: 'line', + data: dataMA10, + smooth: true, + showSymbol: false, + lineStyle: { + width: 1 + } + }, + { + name: 'MA20', + type: 'line', + data: dataMA20, + smooth: true, + showSymbol: false, + lineStyle: { + width: 1 + } + } + ] +}; +export {}; diff --git a/testdata/candlestick-touch.js.svg b/testdata/candlestick-touch.js.svg new file mode 100644 index 0000000..abe561f --- /dev/null +++ b/testdata/candlestick-touch.js.svg @@ -0,0 +1,171 @@ + + + + + + + + + + + + + + + + + + + +17,000 +17,500 +18,000 +18,500 +2016-04-14 +2016-04-19 +2016-04-22 +2016-04-27 +2016-05-02 +2016-05-05 +2016-05-10 +2016-05-13 +2016-05-18 +2016-05-23 +2016-05-26 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +日K + + +MA5 + + +MA10 + + +MA20 + + + + + + + + +Candlestick on Mobile + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/circle-packing-with-d3.js b/testdata/circle-packing-with-d3.js new file mode 100644 index 0000000..d963a5d --- /dev/null +++ b/testdata/circle-packing-with-d3.js @@ -0,0 +1,193 @@ +"use strict"; +/* +title: Circle Packing with d3 +category: custom +titleCN: Circle Packing with d3 +difficulty: 11 +*/ +$.when($.get(ROOT_PATH + '/data/asset/data/option-view.json'), $.getScript('https://fastly.jsdelivr.net/npm/d3-hierarchy@2.0.0/dist/d3-hierarchy.min.js')).done(function (res) { + run(res[0]); +}); +function run(rawData) { + const dataWrap = prepareData(rawData); + initChart(dataWrap.seriesData, dataWrap.maxDepth); +} +function prepareData(rawData) { + const seriesData = []; + let maxDepth = 0; + function convert(source, basePath, depth) { + if (source == null) { + return; + } + if (maxDepth > 5) { + return; + } + maxDepth = Math.max(depth, maxDepth); + seriesData.push({ + id: basePath, + value: source.$count, + depth: depth, + index: seriesData.length + }); + for (var key in source) { + if (source.hasOwnProperty(key) && !key.match(/^\$/)) { + var path = basePath + '.' + key; + convert(source[key], path, depth + 1); + } + } + } + convert(rawData, 'option', 0); + return { + seriesData: seriesData, + maxDepth: maxDepth + }; +} +function initChart(seriesData, maxDepth) { + var displayRoot = stratify(); + function stratify() { + return d3 + .stratify() + .parentId(function (d) { + return d.id.substring(0, d.id.lastIndexOf('.')); + })(seriesData) + .sum(function (d) { + return d.value || 0; + }) + .sort(function (a, b) { + return b.value - a.value; + }); + } + function overallLayout(params, api) { + var context = params.context; + d3 + .pack() + .size([api.getWidth() - 2, api.getHeight() - 2]) + .padding(3)(displayRoot); + context.nodes = {}; + displayRoot.descendants().forEach(function (node, index) { + context.nodes[node.id] = node; + }); + } + function renderItem(params, api) { + var context = params.context; + // Only do that layout once in each time `setOption` called. + if (!context.layout) { + context.layout = true; + overallLayout(params, api); + } + var nodePath = api.value('id'); + var node = context.nodes[nodePath]; + if (!node) { + // Reder nothing. + return; + } + var isLeaf = !node.children || !node.children.length; + var focus = new Uint32Array(node.descendants().map(function (node) { + return node.data.index; + })); + var nodeName = isLeaf + ? nodePath + .slice(nodePath.lastIndexOf('.') + 1) + .split(/(?=[A-Z][^A-Z])/g) + .join('\n') + : ''; + var z2 = api.value('depth') * 2; + return { + type: 'circle', + focus: focus, + shape: { + cx: node.x, + cy: node.y, + r: node.r + }, + transition: ['shape'], + z2: z2, + textContent: { + type: 'text', + style: { + // transition: isLeaf ? 'fontSize' : null, + text: nodeName, + fontFamily: 'Arial', + width: node.r * 1.3, + overflow: 'truncate', + fontSize: node.r / 3 + }, + emphasis: { + style: { + overflow: null, + fontSize: Math.max(node.r / 3, 12) + } + } + }, + textConfig: { + position: 'inside' + }, + style: { + fill: api.visual('color') + }, + emphasis: { + style: { + fontFamily: 'Arial', + fontSize: 12, + shadowBlur: 20, + shadowOffsetX: 3, + shadowOffsetY: 5, + shadowColor: 'rgba(0,0,0,0.3)' + } + } + }; + } + option = { + dataset: { + source: seriesData + }, + tooltip: {}, + visualMap: [ + { + show: false, + min: 0, + max: maxDepth, + dimension: 'depth', + inRange: { + color: ['#006edd', '#e0ffff'] + } + } + ], + hoverLayerThreshold: Infinity, + series: { + type: 'custom', + renderItem: renderItem, + progressive: 0, + coordinateSystem: 'none', + encode: { + tooltip: 'value', + itemName: 'id' + } + } + }; + myChart.setOption(option); + myChart.on('click', { seriesIndex: 0 }, function (params) { + drillDown(params.data.id); + }); + function drillDown(targetNodeId) { + displayRoot = stratify(); + if (targetNodeId != null) { + displayRoot = displayRoot.descendants().find(function (node) { + return node.data.id === targetNodeId; + }); + } + // A trick to prevent d3-hierarchy from visiting parents in this algorithm. + displayRoot.parent = null; + myChart.setOption({ + dataset: { + source: seriesData + } + }); + } + // Reset: click on the blank area. + myChart.getZr().on('click', function (event) { + if (!event.target) { + drillDown(); + } + }); +} diff --git a/testdata/confidence-band.js b/testdata/confidence-band.js new file mode 100644 index 0000000..d87f1a7 --- /dev/null +++ b/testdata/confidence-band.js @@ -0,0 +1,118 @@ +/* +title: Confidence Band +category: line +titleCN: Confidence Band +difficulty: 4 +*/ +myChart.showLoading(); +$.get(ROOT_PATH + '/data/asset/data/confidence-band.json', function (data) { + myChart.hideLoading(); + var base = -data.reduce(function (min, val) { + return Math.floor(Math.min(min, val.l)); + }, Infinity); + myChart.setOption((option = { + title: { + text: 'Confidence Band', + subtext: 'Example in MetricsGraphics.js', + left: 'center' + }, + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'cross', + animation: false, + label: { + backgroundColor: '#ccc', + borderColor: '#aaa', + borderWidth: 1, + shadowBlur: 0, + shadowOffsetX: 0, + shadowOffsetY: 0, + color: '#222' + } + }, + formatter: function (params) { + return (params[2].name + + '
' + + ((params[2].value - base) * 100).toFixed(1) + + '%'); + } + }, + grid: { + left: '3%', + right: '4%', + bottom: '3%', + containLabel: true + }, + xAxis: { + type: 'category', + data: data.map(function (item) { + return item.date; + }), + axisLabel: { + formatter: function (value, idx) { + var date = new Date(value); + return idx === 0 + ? value + : [date.getMonth() + 1, date.getDate()].join('-'); + } + }, + boundaryGap: false + }, + yAxis: { + axisLabel: { + formatter: function (val) { + return (val - base) * 100 + '%'; + } + }, + axisPointer: { + label: { + formatter: function (params) { + return ((params.value - base) * 100).toFixed(1) + '%'; + } + } + }, + splitNumber: 3 + }, + series: [ + { + name: 'L', + type: 'line', + data: data.map(function (item) { + return item.l + base; + }), + lineStyle: { + opacity: 0 + }, + stack: 'confidence-band', + symbol: 'none' + }, + { + name: 'U', + type: 'line', + data: data.map(function (item) { + return item.u - item.l; + }), + lineStyle: { + opacity: 0 + }, + areaStyle: { + color: '#ccc' + }, + stack: 'confidence-band', + symbol: 'none' + }, + { + type: 'line', + data: data.map(function (item) { + return item.value + base; + }), + itemStyle: { + color: '#333' + }, + showSymbol: false + } + ] + })); +}); +export {}; diff --git a/testdata/custom-bar-trend.js b/testdata/custom-bar-trend.js new file mode 100644 index 0000000..2475c22 --- /dev/null +++ b/testdata/custom-bar-trend.js @@ -0,0 +1,113 @@ +/* +title: Custom Bar Trend +category: custom +titleCN: 使用自定义系列添加柱状图趋势 +difficulty: 3 +*/ +const yearCount = 7; +const categoryCount = 30; +const xAxisData = []; +const customData = []; +const legendData = []; +const dataList = []; +legendData.push('trend'); +const encodeY = []; +for (var i = 0; i < yearCount; i++) { + legendData.push(2010 + i + ''); + dataList.push([]); + encodeY.push(1 + i); +} +for (var i = 0; i < categoryCount; i++) { + var val = Math.random() * 1000; + xAxisData.push('category' + i); + var customVal = [i]; + customData.push(customVal); + for (var j = 0; j < dataList.length; j++) { + var value = j === 0 + ? echarts.number.round(val, 2) + : echarts.number.round(Math.max(0, dataList[j - 1][i] + (Math.random() - 0.5) * 200), 2); + dataList[j].push(value); + customVal.push(value); + } +} +option = { + tooltip: { + trigger: 'axis' + }, + legend: { + data: legendData + }, + dataZoom: [ + { + type: 'slider', + start: 50, + end: 70 + }, + { + type: 'inside', + start: 50, + end: 70 + } + ], + xAxis: { + data: xAxisData + }, + yAxis: {}, + series: [ + { + type: 'custom', + name: 'trend', + renderItem: function (params, api) { + var xValue = api.value(0); + var currentSeriesIndices = api.currentSeriesIndices(); + var barLayout = api.barLayout({ + barGap: '30%', + barCategoryGap: '20%', + count: currentSeriesIndices.length - 1 + }); + var points = []; + for (var i = 0; i < currentSeriesIndices.length; i++) { + var seriesIndex = currentSeriesIndices[i]; + if (seriesIndex !== params.seriesIndex) { + var point = api.coord([xValue, api.value(seriesIndex)]); + point[0] += barLayout[i - 1].offsetCenter; + point[1] -= 20; + points.push(point); + } + } + var style = api.style({ + stroke: api.visual('color'), + fill: 'none' + }); + return { + type: 'polyline', + shape: { + points: points + }, + style: style + }; + }, + itemStyle: { + borderWidth: 2 + }, + encode: { + x: 0, + y: encodeY + }, + data: customData, + z: 100 + }, + ...dataList.map(function (data, index) { + return { + type: 'bar', + animation: false, + name: legendData[index + 1], + itemStyle: { + opacity: 0.5 + }, + data: data + }; + }) + ] +}; +export {}; diff --git a/testdata/custom-bar-trend.js.svg b/testdata/custom-bar-trend.js.svg new file mode 100644 index 0000000..0c497e3 --- /dev/null +++ b/testdata/custom-bar-trend.js.svg @@ -0,0 +1,125 @@ + + + + + + + + + + + + + + + + +0 +200 +400 +600 +800 +1,000 +category15 +category16 +category17 +category18 +category19 +category20 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +trend + +2010 + +2011 + +2012 + +2013 + +2014 + +2015 + +2016 + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/custom-calendar-icon.js b/testdata/custom-calendar-icon.js new file mode 100644 index 0000000..e48f4da --- /dev/null +++ b/testdata/custom-calendar-icon.js @@ -0,0 +1,121 @@ +/* +title: Custom Calendar Icon +category: 'custom, calendar' +titleCN: 日历图自定义图标 +difficulty: 7 +*/ +const layouts = [ + [[0, 0]], + [ + [-0.25, 0], + [0.25, 0] + ], + [ + [0, -0.2], + [-0.2, 0.2], + [0.2, 0.2] + ], + [ + [-0.25, -0.25], + [-0.25, 0.25], + [0.25, -0.25], + [0.25, 0.25] + ] +]; +const pathes = [ + 'M936.857805 523.431322c0 0-42.065715-68.89513-88.786739-68.89513-46.68416 0-95.732122 71.223091-95.732122 71.223091s-44.28544-72.503296-93.440922-71.152538c-35.565466 0.977306-62.89705 30.882406-79.124275 64.06615L579.773747 790.800797c-3.253248 37.391565-5.677568 50.904371-12.002816 69.63497-6.651802 19.698688-19.544883 35.227341-31.650099 45.909606-14.30231 12.621414-29.59831 22.066586-45.854208 27.424563-16.28969 5.362074-30.098739 6.496973-51.536794 6.496973-19.498906 0-36.95104-2.963456-52.395418-8.850534-15.410586-5.887078-28.420403-14.313984-39.034573-25.246003-10.613146-10.930995-18.757939-24.08151-24.435507-39.525171-5.676544-15.443763-8.532685-40.195482-8.532685-59.270963l0-26.232454 74.435273 0c0 24.644301-0.17705 64.452915 8.81408 77.006848 9.02697 12.515021 22.756147 18.092032 41.148826 18.791014 16.728678 0.636518 30.032179-8.061645 30.032179-8.061645s11.922022-10.5472 14.992077-19.756954c2.674995-8.025805 3.565363-22.180147 3.565363-22.180147s2.080461-21.789286 2.080461-34.234675L489.399906 514.299369c-16.678502-18.827776-43.801395-61.938688-82.756096-60.927693-54.699008 1.419366-100.422144 70.059622-100.422144 70.059622s-56.065126-70.059622-93.440922-70.059622c-37.376717 0-91.077939 70.059622-91.077939 70.059622S105.343488 156.737741 476.742042 119.363584l53.70327-74.714624 51.373056 74.714624C964.889395 142.740992 936.857805 523.431322 936.857805 523.431322z', + 'M533.504 268.288q33.792-41.984 71.68-75.776 32.768-27.648 74.24-50.176t86.528-19.456q63.488 5.12 105.984 30.208t67.584 63.488 34.304 87.04 6.144 99.84-17.92 97.792-36.864 87.04-48.64 74.752-53.248 61.952q-40.96 41.984-85.504 78.336t-84.992 62.464-73.728 41.472-51.712 15.36q-20.48 1.024-52.224-14.336t-69.632-41.472-79.872-61.952-82.944-75.776q-26.624-25.6-57.344-59.392t-57.856-74.24-46.592-87.552-21.504-100.352 11.264-99.84 39.936-83.456 65.536-61.952 88.064-35.328q24.576-5.12 49.152-1.536t48.128 12.288 45.056 22.016 40.96 27.648q45.056 33.792 86.016 80.896z', + 'M741.06368 733.310464c8.075264-29.262438 20.615373-40.632422 14.64105-162.810061C966.089728 361.789952 967.93897 72.37847 967.855002 54.693683c0.279347-0.279347 0.418509-0.419533 0.418509-0.419533s-0.17705-0.00512-0.428749-0.00512c0-0.251699 0-0.428749 0-0.428749s-0.139162 0.14633-0.418509 0.425677c-17.695744-0.083866-307.10784 1.760051-515.833958 212.142592-122.181632-5.984256-133.55305 6.563533-162.815693 14.644531C235.35063 295.798886 103.552614 436.975309 90.630758 486.076621c-12.921856 49.105408 39.634227 56.859034 58.579558 58.581197 18.953421 1.724314 121.471386-9.475789 130.09111 4.309094 0 0 16.367411 11.200102 17.226035 41.346662 0.850432 29.796659 15.173222 71.354163 37.123994 97.267302-0.028672 0.027648-0.05632 0.054272-0.083866 0.074752 0.158618 0.13097 0.316211 0.261939 0.474829 0.390861 0.129946 0.149402 0.261939 0.319283 0.393011 0.468685 0.019456-0.019456 0.04608-0.049152 0.075776-0.075674 25.918362 21.961216 67.477504 36.272128 97.269248 37.122458 30.149837 0.859546 41.354547 17.234534 41.354547 17.234534 13.779354 8.608051 2.583962 111.122842 4.302131 130.075546 1.727386 18.95168 9.477222 71.498445 58.579558 58.576077C585.12896 918.526771 726.311117 786.734182 741.06368 733.310464zM595.893555 426.206003c-39.961702-39.965184-39.961702-104.75991 0-144.720077 39.970918-39.96928 104.768307-39.96928 144.730112 0 39.970918 39.960064 39.970918 104.75479 0 144.720077C700.661862 466.171187 635.864474 466.171187 595.893555 426.206003zM358.53312 769.516032c-31.923302-4.573184-54.890394-18.410291-71.41847-35.402342-16.984474-16.526438-30.830387-39.495475-35.405824-71.420621-4.649062-28.082586-20.856832-41.167565-38.76649-38.763827-17.906586 2.40681-77.046886 66.714419-80.857805 89.475891-3.80887 22.752154 29.271859 12.081152 46.424166 27.654861 17.151283 15.590093-2.139853 61.93664-14.733107 86.845952-6.441984 12.735078-10.289766 26.42176-4.22953 33.76087 7.346586 6.070272 21.03593 2.222592 33.769472-4.220109 24.912384-12.585677 71.258829-31.872922 86.842368-14.731469 15.583539 17.160806 4.911002 50.229965 27.674419 46.419251 22.754099-3.807744 87.065395-62.946611 89.466163-80.85248C399.70857 790.374093 386.627072 774.166938 358.53312 769.516032z', + 'M848.794624 939.156685 571.780416 939.156685 571.780416 653.17123l341.897539 0 0 221.100654C913.677926 909.960704 884.482867 939.156685 848.794624 939.156685zM571.780403 318.743552c-11.861606-3.210138-31.443354-8.36864-39.829709-16.176435-0.596582-0.561766-1.016218-1.246413-1.613824-1.841971-0.560845 0.596582-1.016218 1.280205-1.613824 1.841971-8.386355 7.807795-15.96631 12.965274-27.827917 16.176435l0 263.544325L141.030675 582.287877 141.030675 355.202884c0-35.687834 29.195059-64.882688 64.883302-64.882688l150.649125 0c-16.984474-9.525965-32.846438-20.56233-46.111027-32.932045-60.250624-56.144691-71.129907-137.062605-24.283034-180.767027 19.615539-18.264986 46.252237-27.124736 75.026739-27.124736 39.933133 0 83.972915 17.070797 118.995968 49.706086 20.353331 18.983322 37.722624 43.405619 50.145075 69.056819 12.457267-25.6512 29.791744-50.074419 50.180915-69.056819 35.022029-32.63529 79.062835-49.706086 118.994944-49.706086 28.74071 0 55.410176 8.860774 75.025715 27.124736 46.882611 43.704422 35.96759 124.622336-24.283034 180.767027-13.264589 12.368691-29.127578 23.40608-46.111027 32.932045l144.649234 0c35.688243 0 64.882278 29.195981 64.882278 64.882688l0 227.084948L571.780416 582.287833 571.780416 318.743508zM435.064218 147.625267c-21.476966-19.965747-49.094144-31.913882-73.868288-31.913882-7.404954 0-21.125018 1.211597-29.863322 9.386803-2.000691 1.824563-8.070144 7.439462-8.070144 21.369754 0 15.650406 8.492749 40.24873 32.319386 62.477926 29.124506 27.12576 77.202432 47.601152 111.76704 47.601152 12.176794 0 16.492237-2.666701 16.527053-2.702541C489.524736 242.54505 475.664486 185.453773 435.064218 147.625267zM577.78135 254.790963c0 0 0.034816-0.034816 0.069632-0.034816 0.807424 0 5.50871 1.790771 15.509914 1.790771 34.564608 0 82.64151-20.47529 111.76704-47.601152 23.826637-22.229299 32.283546-46.810112 32.283546-62.442189 0-13.930291-6.033613-19.562496-8.035328-21.404467-8.77312-8.17623-22.457344-9.386803-29.864346-9.386803-24.808038 0-52.390298 11.948134-73.867264 31.913882C585.325466 185.208218 571.358822 241.73865 577.78135 254.790963zM500.89513 939.156685 205.914017 939.156685c-35.688243 0-64.883302-29.195981-64.883302-64.883712L141.030714 653.17123l359.864462 0L500.895177 939.15666z' +]; +const colors = ['#c4332b', '#16B644', '#6862FD', '#FDC763']; +function getVirtulData(year) { + year = year || '2017'; + let date = +echarts.number.parseDate(year + '-01-01'); + let end = +echarts.number.parseDate(+year + 1 + '-01-01'); + let dayTime = 3600 * 24 * 1000; + let data = []; + for (let time = date; time < end; time += dayTime) { + let items = []; + let eventCount = Math.round(Math.random() * pathes.length); + for (let i = 0; i < eventCount; i++) { + items.push(Math.round(Math.random() * (pathes.length - 1))); + } + data.push([echarts.format.formatTime('yyyy-MM-dd', time), items.join('|')]); + } + return data; +} +option = { + tooltip: {}, + calendar: [ + { + left: 'center', + top: 'middle', + cellSize: [70, 70], + yearLabel: { show: false }, + orient: 'vertical', + dayLabel: { + firstDay: 1, + nameMap: 'cn' + }, + monthLabel: { + show: false + }, + range: '2017-03' + } + ], + series: [ + { + type: 'custom', + coordinateSystem: 'calendar', + renderItem: function (params, api) { + const cellPoint = api.coord(api.value(0)); + const cellWidth = params.coordSys.cellWidth; + const cellHeight = params.coordSys.cellHeight; + const value = api.value(1); + const events = value && value.split('|'); + if (isNaN(cellPoint[0]) || isNaN(cellPoint[1])) { + return; + } + const group = { + type: 'group', + children: (layouts[events.length - 1] || []).map(function (itemLayout, index) { + return { + type: 'path', + shape: { + pathData: pathes[+events[index]], + x: -8, + y: -8, + width: 16, + height: 16 + }, + position: [ + cellPoint[0] + + echarts.number.linearMap(itemLayout[0], [-0.5, 0.5], [-cellWidth / 2, cellWidth / 2]), + cellPoint[1] + + echarts.number.linearMap(itemLayout[1], [-0.5, 0.5], [-cellHeight / 2 + 20, cellHeight / 2]) + ], + style: api.style({ + fill: colors[+events[index]] + }) + }; + }) || [] + }; + group.children.push({ + type: 'text', + style: { + x: cellPoint[0], + y: cellPoint[1] - cellHeight / 2 + 15, + text: echarts.format.formatTime('dd', api.value(0)), + fill: '#777', + textFont: api.font({ fontSize: 14 }) + } + }); + return group; + }, + dimensions: [undefined, { type: 'ordinal' }], + data: getVirtulData('2017') + } + ] +}; +export {}; diff --git a/testdata/custom-calendar-icon.js.svg b/testdata/custom-calendar-icon.js.svg new file mode 100644 index 0000000..ccc44b3 --- /dev/null +++ b/testdata/custom-calendar-icon.js.svg @@ -0,0 +1,45 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +M +T +W +T +F +S +S + \ No newline at end of file diff --git a/testdata/custom-cartesian-polygon.js b/testdata/custom-cartesian-polygon.js new file mode 100644 index 0000000..3876de4 --- /dev/null +++ b/testdata/custom-cartesian-polygon.js @@ -0,0 +1,64 @@ +/* +title: Custom Cartesian Polygon +titleCN: 自定义多边形图 +category: custom +difficulty: 3 +*/ +const data = []; +const dataCount = 7; +for (let i = 0; i < dataCount; i++) { + data.push([ + echarts.number.round(Math.random() * 100), + echarts.number.round(Math.random() * 400) + ]); +} +option = { + tooltip: { + trigger: 'axis' + }, + legend: { + data: ['bar', 'error'] + }, + dataZoom: [ + { + type: 'slider', + filterMode: 'none' + }, + { + type: 'inside', + filterMode: 'none' + } + ], + xAxis: {}, + yAxis: {}, + series: [ + { + type: 'custom', + renderItem: function (params, api) { + if (params.context.rendered) { + return; + } + params.context.rendered = true; + let points = []; + for (let i = 0; i < data.length; i++) { + points.push(api.coord(data[i])); + } + let color = api.visual('color'); + return { + type: 'polygon', + transition: ['shape'], + shape: { + points: points + }, + style: api.style({ + fill: color, + stroke: echarts.color.lift(color, 0.1) + }) + }; + }, + clip: true, + data: data + } + ] +}; +export {}; diff --git a/testdata/custom-cartesian-polygon.js.svg b/testdata/custom-cartesian-polygon.js.svg new file mode 100644 index 0000000..9866f35 --- /dev/null +++ b/testdata/custom-cartesian-polygon.js.svg @@ -0,0 +1,47 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + +0 +100 +200 +300 +400 +0 +20 +40 +60 +80 +100 + + + + + + + + + + \ No newline at end of file diff --git a/testdata/custom-error-bar.js b/testdata/custom-error-bar.js new file mode 100644 index 0000000..d76b52f --- /dev/null +++ b/testdata/custom-error-bar.js @@ -0,0 +1,122 @@ +/* +title: Error Bar on Catesian +category: custom +titleCN: 使用自定系列给柱状图添加误差范围 +difficulty: 3 +*/ +var categoryData = []; +var errorData = []; +var barData = []; +var dataCount = 100; +for (var i = 0; i < dataCount; i++) { + var val = Math.random() * 1000; + categoryData.push('category' + i); + errorData.push([ + i, + echarts.number.round(Math.max(0, val - Math.random() * 100)), + echarts.number.round(val + Math.random() * 80) + ]); + barData.push(echarts.number.round(val, 2)); +} +option = { + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'shadow' + } + }, + title: { + text: 'Error bar chart' + }, + legend: { + data: ['bar', 'error'] + }, + dataZoom: [ + { + type: 'slider', + start: 50, + end: 70 + }, + { + type: 'inside', + start: 50, + end: 70 + } + ], + xAxis: { + data: categoryData + }, + yAxis: {}, + series: [ + { + type: 'bar', + name: 'bar', + data: barData, + itemStyle: { + color: '#77bef7' + } + }, + { + type: 'custom', + name: 'error', + itemStyle: { + borderWidth: 1.5 + }, + renderItem: function (params, api) { + var xValue = api.value(0); + var highPoint = api.coord([xValue, api.value(1)]); + var lowPoint = api.coord([xValue, api.value(2)]); + var halfWidth = api.size([1, 0])[0] * 0.1; + var style = api.style({ + stroke: api.visual('color'), + fill: undefined + }); + return { + type: 'group', + children: [ + { + type: 'line', + transition: ['shape'], + shape: { + x1: highPoint[0] - halfWidth, + y1: highPoint[1], + x2: highPoint[0] + halfWidth, + y2: highPoint[1] + }, + style: style + }, + { + type: 'line', + transition: ['shape'], + shape: { + x1: highPoint[0], + y1: highPoint[1], + x2: lowPoint[0], + y2: lowPoint[1] + }, + style: style + }, + { + type: 'line', + transition: ['shape'], + shape: { + x1: lowPoint[0] - halfWidth, + y1: lowPoint[1], + x2: lowPoint[0] + halfWidth, + y2: lowPoint[1] + }, + style: style + } + ] + }; + }, + encode: { + x: 0, + y: [1, 2] + }, + data: errorData, + z: 100 + } + ] +}; +export {}; diff --git a/testdata/custom-error-bar.js.svg b/testdata/custom-error-bar.js.svg new file mode 100644 index 0000000..b7feda5 --- /dev/null +++ b/testdata/custom-error-bar.js.svg @@ -0,0 +1,321 @@ + + + + + + + + + + + + + + + + + + +0 +200 +400 +600 +800 +1,000 +1,200 +category51 +category54 +category57 +category60 +category63 +category66 +category69 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +bar + +error + + + + + + + + +Error bar chart + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/custom-error-scatter.js b/testdata/custom-error-scatter.js new file mode 100644 index 0000000..d44fe73 --- /dev/null +++ b/testdata/custom-error-scatter.js @@ -0,0 +1,131 @@ +/* +title: Error Scatter on Catesian +category: 'custom, dataZoom' +titleCN: 使用自定系列给散点图添加误差范围 +difficulty: 2 +*/ +// Prime Costs and Prices for ACME Fashion\nCollection "Spring-Summer, 2016" +// Data from https://playground.anychart.com/gallery/7.12.0/Error_Charts/Marker_Chart +// prettier-ignore +const dimensions = [ + 'name', 'Price', 'Prime cost', 'Prime cost min', 'Prime cost max', 'Price min', 'Price max' +]; +// prettier-ignore +const data = [ + ['Blouse "Blue Viola"', 101.88, 99.75, 76.75, 116.75, 69.88, 119.88], + ['Dress "Daisy"', 155.8, 144.03, 126.03, 156.03, 129.8, 188.8], + ['Trousers "Cutesy Classic"', 203.25, 173.56, 151.56, 187.56, 183.25, 249.25], + ['Dress "Morning Dew"', 256, 120.5, 98.5, 136.5, 236, 279], + ['Turtleneck "Dark Chocolate"', 408.89, 294.75, 276.75, 316.75, 385.89, 427.89], + ['Jumper "Early Spring"', 427.36, 430.24, 407.24, 452.24, 399.36, 461.36], + ['Breeches "Summer Mood"', 356, 135.5, 123.5, 151.5, 333, 387], + ['Dress "Mauve Chamomile"', 406, 95.5, 73.5, 111.5, 366, 429], + ['Dress "Flying Tits"', 527.36, 503.24, 488.24, 525.24, 485.36, 551.36], + ['Dress "Singing Nightingales"', 587.36, 543.24, 518.24, 555.24, 559.36, 624.36], + ['Sundress "Cloudy weather"', 603.36, 407.24, 392.24, 419.24, 581.36, 627.36], + ['Sundress "East motives"', 633.36, 477.24, 445.24, 487.24, 594.36, 652.36], + ['Sweater "Cold morning"', 517.36, 437.24, 416.24, 454.24, 488.36, 565.36], + ['Trousers "Lavender Fields"', 443.36, 387.24, 370.24, 413.24, 412.36, 484.36], + ['Jumper "Coffee with Milk"', 543.36, 307.24, 288.24, 317.24, 509.36, 574.36], + ['Blouse "Blooming Cactus"', 790.36, 277.24, 254.24, 295.24, 764.36, 818.36], + ['Sweater "Fluffy Comfort"', 790.34, 678.34, 660.34, 690.34, 762.34, 824.34] +]; +function renderItem(params, api) { + const group = { + type: 'group', + children: [] + }; + let coordDims = ['x', 'y']; + for (let baseDimIdx = 0; baseDimIdx < 2; baseDimIdx++) { + let otherDimIdx = 1 - baseDimIdx; + let encode = params.encode; + let baseValue = api.value(encode[coordDims[baseDimIdx]][0]); + let param = []; + param[baseDimIdx] = baseValue; + param[otherDimIdx] = api.value(encode[coordDims[otherDimIdx]][1]); + let highPoint = api.coord(param); + param[otherDimIdx] = api.value(encode[coordDims[otherDimIdx]][2]); + let lowPoint = api.coord(param); + let halfWidth = 5; + var style = api.style({ + stroke: api.visual('color'), + fill: undefined + }); + group.children.push({ + type: 'line', + transition: ['shape'], + shape: makeShape(baseDimIdx, highPoint[baseDimIdx] - halfWidth, highPoint[otherDimIdx], highPoint[baseDimIdx] + halfWidth, highPoint[otherDimIdx]), + style: style + }, { + type: 'line', + transition: ['shape'], + shape: makeShape(baseDimIdx, highPoint[baseDimIdx], highPoint[otherDimIdx], lowPoint[baseDimIdx], lowPoint[otherDimIdx]), + style: style + }, { + type: 'line', + transition: ['shape'], + shape: makeShape(baseDimIdx, lowPoint[baseDimIdx] - halfWidth, lowPoint[otherDimIdx], lowPoint[baseDimIdx] + halfWidth, lowPoint[otherDimIdx]), + style: style + }); + } + function makeShape(baseDimIdx, base1, value1, base2, value2) { + var shape = {}; + shape[coordDims[baseDimIdx] + '1'] = base1; + shape[coordDims[1 - baseDimIdx] + '1'] = value1; + shape[coordDims[baseDimIdx] + '2'] = base2; + shape[coordDims[1 - baseDimIdx] + '2'] = value2; + return shape; + } + return group; +} +option = { + tooltip: {}, + legend: { + data: ['bar', 'error'] + }, + dataZoom: [ + { + type: 'slider' + }, + { + type: 'inside' + } + ], + grid: { + bottom: 80 + }, + xAxis: {}, + yAxis: {}, + series: [ + { + type: 'scatter', + name: 'error', + data: data, + dimensions: dimensions, + encode: { + x: 2, + y: 1, + tooltip: [2, 1, 3, 4, 5, 6], + itemName: 0 + }, + itemStyle: { + color: '#77bef7' + } + }, + { + type: 'custom', + name: 'error', + renderItem: renderItem, + dimensions: dimensions, + encode: { + x: [2, 3, 4], + y: [1, 5, 6], + tooltip: [2, 1, 3, 4, 5, 6], + itemName: 0 + }, + data: data, + z: 100 + } + ] +}; +export {}; diff --git a/testdata/custom-error-scatter.js.svg b/testdata/custom-error-scatter.js.svg new file mode 100644 index 0000000..2ae5605 --- /dev/null +++ b/testdata/custom-error-scatter.js.svg @@ -0,0 +1,329 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +0 +200 +400 +600 +800 +1,000 +0 +100 +200 +300 +400 +500 +600 +700 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +error + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/custom-gantt-flight.js b/testdata/custom-gantt-flight.js new file mode 100644 index 0000000..2183efc --- /dev/null +++ b/testdata/custom-gantt-flight.js @@ -0,0 +1,523 @@ +"use strict"; +/* +title: Gantt Chart of Airport Flights +category: custom, dataZoom +titleCN: 机场航班甘特图 +difficulty: 4 +*/ +var HEIGHT_RATIO = 0.6; +var DIM_CATEGORY_INDEX = 0; +var DIM_TIME_ARRIVAL = 1; +var DIM_TIME_DEPARTURE = 2; +var DATA_ZOOM_AUTO_MOVE_THROTTLE = 30; +var DATA_ZOOM_X_INSIDE_INDEX = 1; +var DATA_ZOOM_Y_INSIDE_INDEX = 3; +var DATA_ZOOM_AUTO_MOVE_SPEED = 0.2; +var DATA_ZOOM_AUTO_MOVE_DETECT_AREA_WIDTH = 30; +var _draggable; +var _draggingEl; +var _dropShadow; +var _draggingCursorOffset = [0, 0]; +var _draggingTimeLength; +var _draggingRecord; +var _dropRecord; +var _cartesianXBounds = []; +var _cartesianYBounds = []; +var _rawData; +var _autoDataZoomAnimator; +$.get(ROOT_PATH + '/data/asset/data/airport-schedule.json', function (rawData) { + _rawData = rawData; + myChart.setOption((option = makeOption())); + initDrag(); +}); +function makeOption() { + return { + tooltip: {}, + animation: false, + toolbox: { + left: 20, + top: 0, + itemSize: 20, + feature: { + myDrag: { + show: true, + title: 'Make bars\ndraggable', + icon: 'path://M990.55 380.08 q11.69 0 19.88 8.19 q7.02 7.01 7.02 18.71 l0 480.65 q-1.17 43.27 -29.83 71.93 q-28.65 28.65 -71.92 29.82 l-813.96 0 q-43.27 -1.17 -72.5 -30.41 q-28.07 -28.07 -29.24 -71.34 l0 -785.89 q1.17 -43.27 29.24 -72.5 q29.23 -29.24 72.5 -29.24 l522.76 0 q11.7 0 18.71 7.02 q8.19 8.18 8.19 18.71 q0 11.69 -7.6 19.29 q-7.6 7.61 -19.3 7.61 l-518.08 0 q-22.22 1.17 -37.42 16.37 q-15.2 15.2 -15.2 37.42 l0 775.37 q0 23.39 15.2 38.59 q15.2 15.2 37.42 15.2 l804.6 0 q22.22 0 37.43 -15.2 q15.2 -15.2 16.37 -38.59 l0 -474.81 q0 -11.7 7.02 -18.71 q8.18 -8.19 18.71 -8.19 l0 0 ZM493.52 723.91 l-170.74 -170.75 l509.89 -509.89 q23.39 -23.39 56.13 -21.05 q32.75 1.17 59.65 26.9 l47.94 47.95 q25.73 26.89 27.49 59.64 q1.75 32.75 -21.64 57.3 l-508.72 509.9 l0 0 ZM870.09 80.69 l-56.13 56.14 l94.72 95.9 l56.14 -57.31 q8.19 -9.35 8.19 -21.05 q-1.17 -12.86 -10.53 -22.22 l-47.95 -49.12 q-10.52 -9.35 -23.39 -9.35 q-11.69 -1.17 -21.05 7.01 l0 0 ZM867.75 272.49 l-93.56 -95.9 l-380.08 380.08 l94.73 94.73 l378.91 -378.91 l0 0 ZM322.78 553.16 l38.59 39.77 l-33.92 125.13 l125.14 -33.92 l38.59 38.6 l-191.79 52.62 q-5.85 1.17 -12.28 0 q-6.44 -1.17 -11.11 -5.84 q-4.68 -4.68 -5.85 -11.7 q-2.34 -5.85 0 -11.69 l52.63 -192.97 l0 0 Z', + onclick: onDragSwitchClick + } + } + }, + title: { + text: 'Gantt of Airport Flight', + left: 'center' + }, + dataZoom: [ + { + type: 'slider', + xAxisIndex: 0, + filterMode: 'weakFilter', + height: 20, + bottom: 0, + start: 0, + end: 26, + handleIcon: 'path://M10.7,11.9H9.3c-4.9,0.3-8.8,4.4-8.8,9.4c0,5,3.9,9.1,8.8,9.4h1.3c4.9-0.3,8.8-4.4,8.8-9.4C19.5,16.3,15.6,12.2,10.7,11.9z M13.3,24.4H6.7V23h6.6V24.4z M13.3,19.6H6.7v-1.4h6.6V19.6z', + handleSize: '80%', + showDetail: false + }, + { + type: 'inside', + id: 'insideX', + xAxisIndex: 0, + filterMode: 'weakFilter', + start: 0, + end: 26, + zoomOnMouseWheel: false, + moveOnMouseMove: true + }, + { + type: 'slider', + yAxisIndex: 0, + zoomLock: true, + width: 10, + right: 10, + top: 70, + bottom: 20, + start: 95, + end: 100, + handleSize: 0, + showDetail: false + }, + { + type: 'inside', + id: 'insideY', + yAxisIndex: 0, + start: 95, + end: 100, + zoomOnMouseWheel: false, + moveOnMouseMove: true, + moveOnMouseWheel: true + } + ], + grid: { + show: true, + top: 70, + bottom: 20, + left: 100, + right: 20, + backgroundColor: '#fff', + borderWidth: 0 + }, + xAxis: { + type: 'time', + position: 'top', + splitLine: { + lineStyle: { + color: ['#E9EDFF'] + } + }, + axisLine: { + show: false + }, + axisTick: { + lineStyle: { + color: '#929ABA' + } + }, + axisLabel: { + color: '#929ABA', + inside: false, + align: 'center' + } + }, + yAxis: { + axisTick: { show: false }, + splitLine: { show: false }, + axisLine: { show: false }, + axisLabel: { show: false }, + min: 0, + max: _rawData.parkingApron.data.length + }, + series: [ + { + id: 'flightData', + type: 'custom', + renderItem: renderGanttItem, + dimensions: _rawData.flight.dimensions, + encode: { + x: [DIM_TIME_ARRIVAL, DIM_TIME_DEPARTURE], + y: DIM_CATEGORY_INDEX, + tooltip: [DIM_CATEGORY_INDEX, DIM_TIME_ARRIVAL, DIM_TIME_DEPARTURE] + }, + data: _rawData.flight.data + }, + { + type: 'custom', + renderItem: renderAxisLabelItem, + dimensions: _rawData.parkingApron.dimensions, + encode: { + x: -1, + y: 0 + }, + data: _rawData.parkingApron.data.map(function (item, index) { + return [index].concat(item); + }) + } + ] + }; +} +function renderGanttItem(params, api) { + var categoryIndex = api.value(DIM_CATEGORY_INDEX); + var timeArrival = api.coord([api.value(DIM_TIME_ARRIVAL), categoryIndex]); + var timeDeparture = api.coord([api.value(DIM_TIME_DEPARTURE), categoryIndex]); + var coordSys = params.coordSys; + _cartesianXBounds[0] = coordSys.x; + _cartesianXBounds[1] = coordSys.x + coordSys.width; + _cartesianYBounds[0] = coordSys.y; + _cartesianYBounds[1] = coordSys.y + coordSys.height; + var barLength = timeDeparture[0] - timeArrival[0]; + // Get the heigth corresponds to length 1 on y axis. + var barHeight = api.size([0, 1])[1] * HEIGHT_RATIO; + var x = timeArrival[0]; + var y = timeArrival[1] - barHeight; + var flightNumber = api.value(3) + ''; + var flightNumberWidth = echarts.format.getTextRect(flightNumber).width; + var text = barLength > flightNumberWidth + 40 && x + barLength >= 180 + ? flightNumber + : ''; + var rectNormal = clipRectByRect(params, { + x: x, + y: y, + width: barLength, + height: barHeight + }); + var rectVIP = clipRectByRect(params, { + x: x, + y: y, + width: barLength / 2, + height: barHeight + }); + var rectText = clipRectByRect(params, { + x: x, + y: y, + width: barLength, + height: barHeight + }); + return { + type: 'group', + children: [ + { + type: 'rect', + ignore: !rectNormal, + shape: rectNormal, + style: api.style() + }, + { + type: 'rect', + ignore: !rectVIP && !api.value(4), + shape: rectVIP, + style: api.style({ fill: '#ddb30b' }) + }, + { + type: 'rect', + ignore: !rectText, + shape: rectText, + style: api.style({ + fill: 'transparent', + stroke: 'transparent', + text: text, + textFill: '#fff' + }) + } + ] + }; +} +function renderAxisLabelItem(params, api) { + var y = api.coord([0, api.value(0)])[1]; + if (y < params.coordSys.y + 5) { + return; + } + return { + type: 'group', + position: [10, y], + children: [ + { + type: 'path', + shape: { + d: 'M0,0 L0,-20 L30,-20 C42,-20 38,-1 50,-1 L70,-1 L70,0 Z', + x: 0, + y: -20, + width: 90, + height: 20, + layout: 'cover' + }, + style: { + fill: '#368c6c' + } + }, + { + type: 'text', + style: { + x: 24, + y: -3, + text: api.value(1), + textVerticalAlign: 'bottom', + textAlign: 'center', + textFill: '#fff' + } + }, + { + type: 'text', + style: { + x: 75, + y: -2, + textVerticalAlign: 'bottom', + textAlign: 'center', + text: api.value(2), + textFill: '#000' + } + } + ] + }; +} +function clipRectByRect(params, rect) { + return echarts.graphic.clipRectByRect(rect, { + x: params.coordSys.x, + y: params.coordSys.y, + width: params.coordSys.width, + height: params.coordSys.height + }); +} +// ------------- +// Enable Drag +// ------------- +function onDragSwitchClick(model, api, type) { + _draggable = !_draggable; + myChart.setOption({ + dataZoom: [ + { + id: 'insideX', + disabled: _draggable + }, + { + id: 'insideY', + disabled: _draggable + } + ] + }); + this.model.setIconStatus(type, _draggable ? 'emphasis' : 'normal'); +} +function initDrag() { + _autoDataZoomAnimator = makeAnimator(dispatchDataZoom); + myChart.on('mousedown', function (param) { + if (!_draggable || !param || param.seriesIndex == null) { + return; + } + // Drag start + _draggingRecord = { + dataIndex: param.dataIndex, + categoryIndex: param.value[DIM_CATEGORY_INDEX], + timeArrival: param.value[DIM_TIME_ARRIVAL], + timeDeparture: param.value[DIM_TIME_DEPARTURE] + }; + var style = { + lineWidth: 2, + fill: 'rgba(255,0,0,0.1)', + stroke: 'rgba(255,0,0,0.8)', + lineDash: [6, 3] + }; + _draggingEl = addOrUpdateBar(_draggingEl, _draggingRecord, style, 100); + _draggingCursorOffset = [ + _draggingEl.position[0] - param.event.offsetX, + _draggingEl.position[1] - param.event.offsetY + ]; + _draggingTimeLength = + _draggingRecord.timeDeparture - _draggingRecord.timeArrival; + }); + myChart.getZr().on('mousemove', function (event) { + if (!_draggingEl) { + return; + } + var cursorX = event.offsetX; + var cursorY = event.offsetY; + // Move _draggingEl. + _draggingEl.attr('position', [ + _draggingCursorOffset[0] + cursorX, + _draggingCursorOffset[1] + cursorY + ]); + prepareDrop(); + autoDataZoomWhenDraggingOutside(cursorX, cursorY); + }); + myChart.getZr().on('mouseup', function () { + // Drop + if (_draggingEl && _dropRecord) { + updateRawData() && + myChart.setOption({ + series: { + id: 'flightData', + data: _rawData.flight.data + } + }); + } + dragRelease(); + }); + myChart.getZr().on('globalout', dragRelease); + function dragRelease() { + _autoDataZoomAnimator.stop(); + if (_draggingEl) { + myChart.getZr().remove(_draggingEl); + _draggingEl = null; + } + if (_dropShadow) { + myChart.getZr().remove(_dropShadow); + _dropShadow = null; + } + _dropRecord = _draggingRecord = null; + } + function addOrUpdateBar(el, itemData, style, z) { + var pointArrival = myChart.convertToPixel('grid', [ + itemData.timeArrival, + itemData.categoryIndex + ]); + var pointDeparture = myChart.convertToPixel('grid', [ + itemData.timeDeparture, + itemData.categoryIndex + ]); + var barLength = pointDeparture[0] - pointArrival[0]; + var barHeight = Math.abs(myChart.convertToPixel('grid', [0, 0])[1] - + myChart.convertToPixel('grid', [0, 1])[1]) * HEIGHT_RATIO; + if (!el) { + el = new echarts.graphic.Rect({ + shape: { x: 0, y: 0, width: 0, height: 0 }, + style: style, + z: z + }); + myChart.getZr().add(el); + } + el.attr({ + shape: { x: 0, y: 0, width: barLength, height: barHeight }, + position: [pointArrival[0], pointArrival[1] - barHeight] + }); + return el; + } + function prepareDrop() { + // Check droppable place. + var xPixel = _draggingEl.shape.x + _draggingEl.position[0]; + var yPixel = _draggingEl.shape.y + _draggingEl.position[1]; + var cursorData = myChart.convertFromPixel('grid', [xPixel, yPixel]); + if (cursorData) { + // Make drop shadow and _dropRecord + _dropRecord = { + categoryIndex: Math.floor(cursorData[1]), + timeArrival: cursorData[0], + timeDeparture: cursorData[0] + _draggingTimeLength + }; + var style = { fill: 'rgba(0,0,0,0.4)' }; + _dropShadow = addOrUpdateBar(_dropShadow, _dropRecord, style, 99); + } + } + // This is some business logic, don't care about it. + function updateRawData() { + var flightData = _rawData.flight.data; + var movingItem = flightData[_draggingRecord.dataIndex]; + // Check conflict + for (var i = 0; i < flightData.length; i++) { + var dataItem = flightData[i]; + if (dataItem !== movingItem && + _dropRecord.categoryIndex === dataItem[DIM_CATEGORY_INDEX] && + _dropRecord.timeArrival < dataItem[DIM_TIME_DEPARTURE] && + _dropRecord.timeDeparture > dataItem[DIM_TIME_ARRIVAL]) { + alert('Conflict! Find a free space to settle the bar!'); + return; + } + } + // No conflict. + movingItem[DIM_CATEGORY_INDEX] = _dropRecord.categoryIndex; + movingItem[DIM_TIME_ARRIVAL] = _dropRecord.timeArrival; + movingItem[DIM_TIME_DEPARTURE] = _dropRecord.timeDeparture; + return true; + } + function autoDataZoomWhenDraggingOutside(cursorX, cursorY) { + // When cursor is outside the cartesian and being dragging, + // auto move the dataZooms. + var cursorDistX = getCursorCartesianDist(cursorX, _cartesianXBounds); + var cursorDistY = getCursorCartesianDist(cursorY, _cartesianYBounds); + if (cursorDistX !== 0 || cursorDistY !== 0) { + _autoDataZoomAnimator.start({ + cursorDistX: cursorDistX, + cursorDistY: cursorDistY + }); + } + else { + _autoDataZoomAnimator.stop(); + } + } + function dispatchDataZoom(params) { + var option = myChart.getOption(); + var optionInsideX = option.dataZoom[DATA_ZOOM_X_INSIDE_INDEX]; + var optionInsideY = option.dataZoom[DATA_ZOOM_Y_INSIDE_INDEX]; + var batch = []; + prepareBatch(batch, 'insideX', optionInsideX.start, optionInsideX.end, params.cursorDistX); + prepareBatch(batch, 'insideY', optionInsideY.start, optionInsideY.end, -params.cursorDistY); + batch.length && + myChart.dispatchAction({ + type: 'dataZoom', + batch: batch + }); + function prepareBatch(batch, id, start, end, cursorDist) { + if (cursorDist === 0) { + return; + } + var sign = cursorDist / Math.abs(cursorDist); + var size = end - start; + var delta = DATA_ZOOM_AUTO_MOVE_SPEED * sign; + start += delta; + end += delta; + if (end > 100) { + end = 100; + start = end - size; + } + if (start < 0) { + start = 0; + end = start + size; + } + batch.push({ + dataZoomId: id, + start: start, + end: end + }); + } + } + function getCursorCartesianDist(cursorXY, bounds) { + var dist0 = cursorXY - (bounds[0] + DATA_ZOOM_AUTO_MOVE_DETECT_AREA_WIDTH); + var dist1 = cursorXY - (bounds[1] - DATA_ZOOM_AUTO_MOVE_DETECT_AREA_WIDTH); + return dist0 * dist1 <= 0 + ? 0 // cursor is in cartesian + : dist0 < 0 + ? dist0 // cursor is at left/top of cartesian + : dist1; // cursor is at right/bottom of cartesian + } + function makeAnimator(callback) { + var requestId; + var callbackParams; + // Use throttle to prevent from calling dispatchAction frequently. + callback = echarts.throttle(callback, DATA_ZOOM_AUTO_MOVE_THROTTLE); + function onFrame() { + callback(callbackParams); + requestId = requestAnimationFrame(onFrame); + } + return { + start: function (params) { + callbackParams = params; + if (requestId == null) { + onFrame(); + } + }, + stop: function () { + if (requestId != null) { + cancelAnimationFrame(requestId); + } + requestId = callbackParams = null; + } + }; + } +} diff --git a/testdata/custom-gauge.js b/testdata/custom-gauge.js new file mode 100644 index 0000000..3e646a3 --- /dev/null +++ b/testdata/custom-gauge.js @@ -0,0 +1,163 @@ +"use strict"; +/* +title: Custom Gauge +category: custom +titleCN: 自定义仪表 +difficulty: 9 +*/ +var _panelImageURL = ROOT_PATH + '/data/asset/img/custom-gauge-panel.png'; +var _animationDuration = 1000; +var _animationDurationUpdate = 1000; +var _animationEasingUpdate = 'quarticInOut'; +var _valOnRadianMax = 200; +var _outerRadius = 200; +var _innerRadius = 170; +var _pointerInnerRadius = 40; +var _insidePanelRadius = 140; +var _currentDataIndex = 0; +function renderItem(params, api) { + var valOnRadian = api.value(1); + var coords = api.coord([api.value(0), valOnRadian]); + var polarEndRadian = coords[3]; + var imageStyle = { + image: _panelImageURL, + x: params.coordSys.cx - _outerRadius, + y: params.coordSys.cy - _outerRadius, + width: _outerRadius * 2, + height: _outerRadius * 2 + }; + return { + type: 'group', + children: [ + { + type: 'image', + style: imageStyle, + clipPath: { + type: 'sector', + shape: { + cx: params.coordSys.cx, + cy: params.coordSys.cy, + r: _outerRadius, + r0: _innerRadius, + startAngle: 0, + endAngle: -polarEndRadian, + transition: 'endAngle', + enterFrom: { endAngle: 0 } + } + } + }, + { + type: 'image', + style: imageStyle, + clipPath: { + type: 'polygon', + shape: { + points: makePionterPoints(params, polarEndRadian) + }, + extra: { + polarEndRadian: polarEndRadian, + transition: 'polarEndRadian', + enterFrom: { polarEndRadian: 0 } + }, + during: function (apiDuring) { + apiDuring.setShape('points', makePionterPoints(params, apiDuring.getExtra('polarEndRadian'))); + } + } + }, + { + type: 'circle', + shape: { + cx: params.coordSys.cx, + cy: params.coordSys.cy, + r: _insidePanelRadius + }, + style: { + fill: '#fff', + shadowBlur: 25, + shadowOffsetX: 0, + shadowOffsetY: 0, + shadowColor: 'rgba(76,107,167,0.4)' + } + }, + { + type: 'text', + extra: { + valOnRadian: valOnRadian, + transition: 'valOnRadian', + enterFrom: { valOnRadian: 0 } + }, + style: { + text: makeText(valOnRadian), + fontSize: 50, + fontWeight: 700, + x: params.coordSys.cx, + y: params.coordSys.cy, + fill: 'rgb(0,50,190)', + align: 'center', + verticalAlign: 'middle', + enterFrom: { opacity: 0 } + }, + during: function (apiDuring) { + apiDuring.setStyle('text', makeText(apiDuring.getExtra('valOnRadian'))); + } + } + ] + }; +} +function convertToPolarPoint(renderItemParams, radius, radian) { + return [ + Math.cos(radian) * radius + renderItemParams.coordSys.cx, + -Math.sin(radian) * radius + renderItemParams.coordSys.cy + ]; +} +function makePionterPoints(renderItemParams, polarEndRadian) { + return [ + convertToPolarPoint(renderItemParams, _outerRadius, polarEndRadian), + convertToPolarPoint(renderItemParams, _outerRadius, polarEndRadian + Math.PI * 0.03), + convertToPolarPoint(renderItemParams, _pointerInnerRadius, polarEndRadian) + ]; +} +function makeText(valOnRadian) { + // Validate additive animation calc. + if (valOnRadian < -10) { + alert('illegal during val: ' + valOnRadian); + } + return ((valOnRadian / _valOnRadianMax) * 100).toFixed(0) + '%'; +} +option = { + animationEasing: _animationEasingUpdate, + animationDuration: _animationDuration, + animationDurationUpdate: _animationDurationUpdate, + animationEasingUpdate: _animationEasingUpdate, + dataset: { + source: [[1, 156]] + }, + tooltip: {}, + angleAxis: { + type: 'value', + startAngle: 0, + show: false, + min: 0, + max: _valOnRadianMax + }, + radiusAxis: { + type: 'value', + show: false + }, + polar: {}, + series: [ + { + type: 'custom', + coordinateSystem: 'polar', + renderItem: renderItem + } + ] +}; +setInterval(function () { + var nextSource = [[1, Math.round(Math.random() * _valOnRadianMax)]]; + myChart.setOption({ + dataset: { + source: nextSource + } + }); +}, 3000); diff --git a/testdata/custom-hexbin.js b/testdata/custom-hexbin.js new file mode 100644 index 0000000..98b6e28 --- /dev/null +++ b/testdata/custom-hexbin.js @@ -0,0 +1,231 @@ +"use strict"; +/* +title: Hexagonal Binning +category: custom, map +titleCN: 六边形分箱图(自定义系列) +difficulty: 6 +*/ +// Hexbin statistics code based on [d3-hexbin](https://github.com/d3/d3-hexbin) +function hexBinStatistics(points, r) { + var dx = r * 2 * Math.sin(Math.PI / 3); + var dy = r * 1.5; + var binsById = {}; + var bins = []; + for (var i = 0, n = points.length; i < n; ++i) { + var point = points[i]; + var px = point[0]; + var py = point[1]; + if (isNaN(px) || isNaN(py)) { + continue; + } + var pj = Math.round((py = py / dy)); + var pi = Math.round((px = px / dx - (pj & 1) / 2)); + var py1 = py - pj; + if (Math.abs(py1) * 3 > 1) { + var px1 = px - pi; + var pi2 = pi + (px < pi ? -1 : 1) / 2; + var pj2 = pj + (py < pj ? -1 : 1); + var px2 = px - pi2; + var py2 = py - pj2; + if (px1 * px1 + py1 * py1 > px2 * px2 + py2 * py2) { + pi = pi2 + (pj & 1 ? 1 : -1) / 2; + pj = pj2; + } + } + var id = pi + '-' + pj; + var bin = binsById[id]; + if (bin) { + bin.points.push(point); + } + else { + bins.push((bin = binsById[id] = { points: [point] })); + bin.x = (pi + (pj & 1) / 2) * dx; + bin.y = pj * dy; + } + } + var maxBinLen = -Infinity; + for (var i = 0; i < bins.length; i++) { + maxBinLen = Math.max(maxBinLen, bins.length); + } + return { + maxBinLen: maxBinLen, + bins: bins + }; +} +$.when($.getJSON(ROOT_PATH + '/data/asset/data/kawhi-leonard-16-17-regular.json'), $.getJSON(ROOT_PATH + '/data/asset/data/nba-court.json')).done(function (shotData, nbaCourt) { + shotData = shotData[0]; + nbaCourt = nbaCourt[0]; + echarts.registerMap('nbaCourt', nbaCourt.borderGeoJSON); + var backgroundColor = '#333'; + var hexagonRadiusInGeo = 1; + var hexBinResult = hexBinStatistics(shotData.data.map(function (item) { + // "shot_made_flag" made missed + var made = item[shotData.schema.indexOf('shot_made_flag')]; + return [ + item[shotData.schema.indexOf('loc_x')], + item[shotData.schema.indexOf('loc_y')], + made === 'made' ? 1 : 0 + ]; + }), hexagonRadiusInGeo); + var data = hexBinResult.bins.map(function (bin) { + var made = 0; + bin.points.forEach(function (point) { + made += point[2]; + }); + return [ + bin.x, + bin.y, + bin.points.length, + ((made / bin.points.length) * 100).toFixed(2) + ]; + }); + function renderItemHexBin(params, api) { + var center = api.coord([api.value(0), api.value(1)]); + var points = []; + var pointsBG = []; + var maxViewRadius = api.size([hexagonRadiusInGeo, 0])[0]; + var minViewRadius = Math.min(maxViewRadius, 4); + var extentMax = Math.log(Math.sqrt(hexBinResult.maxBinLen)); + var viewRadius = echarts.number.linearMap(Math.log(Math.sqrt(api.value(2))), [0, extentMax], [minViewRadius, maxViewRadius]); + var angle = Math.PI / 6; + for (var i = 0; i < 6; i++, angle += Math.PI / 3) { + points.push([ + center[0] + viewRadius * Math.cos(angle), + center[1] + viewRadius * Math.sin(angle) + ]); + pointsBG.push([ + center[0] + maxViewRadius * Math.cos(angle), + center[1] + maxViewRadius * Math.sin(angle) + ]); + } + return { + type: 'group', + children: [ + { + type: 'polygon', + shape: { + points: points + }, + style: { + stroke: '#ccc', + fill: api.visual('color'), + lineWidth: 1 + } + }, + { + type: 'polygon', + shape: { + points: pointsBG + }, + style: { + stroke: null, + fill: 'rgba(0,0,0,0.5)', + lineWidth: 0 + }, + z2: -19 + } + ] + }; + } + function renderItemNBACourt(param, api) { + return { + type: 'group', + children: nbaCourt.geometry.map(function (item) { + return { + type: item.type, + style: { + stroke: '#aaa', + fill: null, + lineWidth: 1.5 + }, + shape: { + points: item.points.map(api.coord) + } + }; + }) + }; + } + option = { + backgroundColor: backgroundColor, + tooltip: { + backgroundColor: 'rgba(255,255,255,0.9)', + textStyle: { + color: '#333' + } + }, + animation: false, + title: { + text: 'Some Player', + subtext: 'Regular Season', + backgroundColor: backgroundColor, + top: 10, + left: 10, + textStyle: { + color: '#eee' + } + }, + legend: { + data: ['bar', 'error'] + }, + geo: { + left: 0, + right: 0, + top: 0, + bottom: 0, + roam: true, + silent: true, + itemStyle: { + color: backgroundColor, + borderWidth: 0 + }, + map: 'nbaCourt' + }, + visualMap: { + type: 'continuous', + orient: 'horizontal', + right: 30, + top: 40, + min: 0, + max: 100, + align: 'bottom', + text: [null, 'FG: '], + dimension: 3, + calculable: true, + textStyle: { + color: '#eee' + }, + formatter: '{value} %', + inRange: { + // color: ['rgba(241,222,158, 0.3)', 'rgba(241,222,158, 1)'] + color: ['green', 'yellow'] + } + }, + series: [ + { + type: 'custom', + coordinateSystem: 'geo', + geoIndex: 0, + renderItem: renderItemHexBin, + dimensions: [ + null, + null, + 'Field Goals Attempted (hexagon size)', + 'Field Goal Percentage (color)' + ], + encode: { + tooltip: [2, 3] + }, + data: data + }, + { + coordinateSystem: 'geo', + type: 'custom', + geoIndex: 0, + renderItem: renderItemNBACourt, + silent: true, + data: [0] + } + ] + }; + myChart.setOption(option); +}); diff --git a/testdata/custom-ohlc.js b/testdata/custom-ohlc.js new file mode 100644 index 0000000..7b68ec7 --- /dev/null +++ b/testdata/custom-ohlc.js @@ -0,0 +1,160 @@ +/* +title: OHLC Chart +category: candlestick +titleCN: OHLC 图(使用自定义系列) +difficulty: 1 +*/ +function splitData(rawData) { + const categoryData = []; + const values = []; + for (var i = 0; i < rawData.length; i++) { + categoryData.push(rawData[i][0]); + rawData[i][0] = i; + values.push(rawData[i]); + } + return { + categoryData: categoryData, + values: values + }; +} +function renderItem(params, api) { + var xValue = api.value(0); + var openPoint = api.coord([xValue, api.value(1)]); + var closePoint = api.coord([xValue, api.value(2)]); + var lowPoint = api.coord([xValue, api.value(3)]); + var highPoint = api.coord([xValue, api.value(4)]); + var halfWidth = api.size([1, 0])[0] * 0.35; + var style = api.style({ + stroke: api.visual('color') + }); + return { + type: 'group', + children: [ + { + type: 'line', + shape: { + x1: lowPoint[0], + y1: lowPoint[1], + x2: highPoint[0], + y2: highPoint[1] + }, + style: style + }, + { + type: 'line', + shape: { + x1: openPoint[0], + y1: openPoint[1], + x2: openPoint[0] - halfWidth, + y2: openPoint[1] + }, + style: style + }, + { + type: 'line', + shape: { + x1: closePoint[0], + y1: closePoint[1], + x2: closePoint[0] + halfWidth, + y2: closePoint[1] + }, + style: style + } + ] + }; +} +$.get(ROOT_PATH + '/data/asset/data/stock-DJI.json', function (rawData) { + var data = splitData(rawData); + myChart.setOption((option = { + animation: false, + legend: { + bottom: 10, + left: 'center', + data: ['Dow-Jones index'] + }, + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'cross' + }, + position: function (pos, params, el, elRect, size) { + var obj = { top: 10 }; + obj[['left', 'right'][+(pos[0] < size.viewSize[0] / 2)]] = 30; + return obj; + } + }, + axisPointer: { + link: [{ xAxisIndex: 'all' }] + }, + toolbox: { + feature: { + dataZoom: { + yAxisIndex: false + }, + brush: { + type: ['lineX', 'clear'] + } + } + }, + grid: [ + { + left: '10%', + right: '8%', + bottom: 150 + } + ], + xAxis: [ + { + type: 'category', + data: data.categoryData, + boundaryGap: false, + axisLine: { onZero: false }, + splitLine: { show: false }, + min: 'dataMin', + max: 'dataMax', + axisPointer: { + z: 100 + } + } + ], + yAxis: [ + { + scale: true, + splitArea: { + show: true + } + } + ], + dataZoom: [ + { + type: 'inside', + start: 98, + end: 100, + minValueSpan: 10 + }, + { + show: true, + type: 'slider', + bottom: 60, + start: 98, + end: 100, + minValueSpan: 10 + } + ], + series: [ + { + name: 'Dow-Jones index', + type: 'custom', + renderItem: renderItem, + dimensions: ['-', 'open', 'close', 'lowest', 'highest'], + encode: { + x: 0, + y: [1, 2, 3, 4], + tooltip: [1, 2, 3, 4] + }, + data: data.values + } + ] + }), true); +}); +export {}; diff --git a/testdata/custom-polar-heatmap.js b/testdata/custom-polar-heatmap.js new file mode 100644 index 0000000..4fd901d --- /dev/null +++ b/testdata/custom-polar-heatmap.js @@ -0,0 +1,81 @@ +/* +title: Polar Heatmap +category: custom +titleCN: 极坐标热力图(自定义系列) +difficulty: 4 +*/ +// prettier-ignore +const hours = ['12a', '1a', '2a', '3a', '4a', '5a', '6a', '7a', '8a', '9a', '10a', '11a', '12p', '1p', '2p', '3p', '4p', '5p', '6p', '7p', '8p', '9p', '10p', '11p']; +// prettier-ignore +const days = ['Saturday', 'Friday', 'Thursday', 'Wednesday', 'Tuesday', 'Monday', 'Sunday']; +// prettier-ignore +const data = [[0, 0, 5], [0, 1, 1], [0, 2, 0], [0, 3, 0], [0, 4, 0], [0, 5, 0], [0, 6, 0], [0, 7, 0], [0, 8, 0], [0, 9, 0], [0, 10, 0], [0, 11, 2], [0, 12, 4], [0, 13, 1], [0, 14, 1], [0, 15, 3], [0, 16, 4], [0, 17, 6], [0, 18, 4], [0, 19, 4], [0, 20, 3], [0, 21, 3], [0, 22, 2], [0, 23, 5], [1, 0, 7], [1, 1, 0], [1, 2, 0], [1, 3, 0], [1, 4, 0], [1, 5, 0], [1, 6, 0], [1, 7, 0], [1, 8, 0], [1, 9, 0], [1, 10, 5], [1, 11, 2], [1, 12, 2], [1, 13, 6], [1, 14, 9], [1, 15, 11], [1, 16, 6], [1, 17, 7], [1, 18, 8], [1, 19, 12], [1, 20, 5], [1, 21, 5], [1, 22, 7], [1, 23, 2], [2, 0, 1], [2, 1, 1], [2, 2, 0], [2, 3, 0], [2, 4, 0], [2, 5, 0], [2, 6, 0], [2, 7, 0], [2, 8, 0], [2, 9, 0], [2, 10, 3], [2, 11, 2], [2, 12, 1], [2, 13, 9], [2, 14, 8], [2, 15, 10], [2, 16, 6], [2, 17, 5], [2, 18, 5], [2, 19, 5], [2, 20, 7], [2, 21, 4], [2, 22, 2], [2, 23, 4], [3, 0, 7], [3, 1, 3], [3, 2, 0], [3, 3, 0], [3, 4, 0], [3, 5, 0], [3, 6, 0], [3, 7, 0], [3, 8, 1], [3, 9, 0], [3, 10, 5], [3, 11, 4], [3, 12, 7], [3, 13, 14], [3, 14, 13], [3, 15, 12], [3, 16, 9], [3, 17, 5], [3, 18, 5], [3, 19, 10], [3, 20, 6], [3, 21, 4], [3, 22, 4], [3, 23, 1], [4, 0, 1], [4, 1, 3], [4, 2, 0], [4, 3, 0], [4, 4, 0], [4, 5, 1], [4, 6, 0], [4, 7, 0], [4, 8, 0], [4, 9, 2], [4, 10, 4], [4, 11, 4], [4, 12, 2], [4, 13, 4], [4, 14, 4], [4, 15, 14], [4, 16, 12], [4, 17, 1], [4, 18, 8], [4, 19, 5], [4, 20, 3], [4, 21, 7], [4, 22, 3], [4, 23, 0], [5, 0, 2], [5, 1, 1], [5, 2, 0], [5, 3, 3], [5, 4, 0], [5, 5, 0], [5, 6, 0], [5, 7, 0], [5, 8, 2], [5, 9, 0], [5, 10, 4], [5, 11, 1], [5, 12, 5], [5, 13, 10], [5, 14, 5], [5, 15, 7], [5, 16, 11], [5, 17, 6], [5, 18, 0], [5, 19, 5], [5, 20, 3], [5, 21, 4], [5, 22, 2], [5, 23, 0], [6, 0, 1], [6, 1, 0], [6, 2, 0], [6, 3, 0], [6, 4, 0], [6, 5, 0], [6, 6, 0], [6, 7, 0], [6, 8, 0], [6, 9, 0], [6, 10, 1], [6, 11, 0], [6, 12, 2], [6, 13, 1], [6, 14, 3], [6, 15, 4], [6, 16, 0], [6, 17, 0], [6, 18, 0], [6, 19, 0], [6, 20, 1], [6, 21, 2], [6, 22, 2], [6, 23, 6]]; +const maxValue = data.reduce(function (max, item) { + return Math.max(max, item[2]); +}, -Infinity); +option = { + legend: { + data: ['Punch Card'] + }, + polar: {}, + tooltip: {}, + visualMap: { + type: 'continuous', + min: 0, + max: maxValue, + top: 'middle', + dimension: 2, + calculable: true + }, + angleAxis: { + type: 'category', + data: hours, + boundaryGap: false, + splitLine: { + show: true, + lineStyle: { + color: '#ddd', + type: 'dashed' + } + }, + axisLine: { + show: false + } + }, + radiusAxis: { + type: 'category', + data: days, + z: 100 + }, + series: [ + { + name: 'Punch Card', + type: 'custom', + coordinateSystem: 'polar', + itemStyle: { + color: '#d14a61' + }, + renderItem: function (params, api) { + var values = [api.value(0), api.value(1)]; + var coord = api.coord(values); + var size = api.size([1, 1], values); + return { + type: 'sector', + shape: { + cx: params.coordSys.cx, + cy: params.coordSys.cy, + r0: coord[2] - size[0] / 2, + r: coord[2] + size[0] / 2, + startAngle: -(coord[3] + size[1] / 2), + endAngle: -(coord[3] - size[1] / 2) + }, + style: api.style({ + fill: api.visual('color') + }) + }; + }, + data: data + } + ] +}; +export {}; diff --git a/testdata/custom-polar-heatmap.js.svg b/testdata/custom-polar-heatmap.js.svg new file mode 100644 index 0000000..5491996 --- /dev/null +++ b/testdata/custom-polar-heatmap.js.svg @@ -0,0 +1,260 @@ + + +12a +1a +2a +3a +4a +5a +6a +7a +8a +9a +10a +11a +12p +1p +2p +3p +4p +5p +6p +7p +8p +9p +10p +11p + + + + +0 +14 + + + + + + + +Punch Card + + + + + +Saturday +Wednesday +Sunday + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/custom-profile.js b/testdata/custom-profile.js new file mode 100644 index 0000000..16ead87 --- /dev/null +++ b/testdata/custom-profile.js @@ -0,0 +1,113 @@ +"use strict"; +/* +title: Profile +category: custom +titleCN: 性能分析图 +difficulty: 3 +*/ +var data = []; +var dataCount = 10; +var startTime = +new Date(); +var categories = ['categoryA', 'categoryB', 'categoryC']; +var types = [ + { name: 'JS Heap', color: '#7b9ce1' }, + { name: 'Documents', color: '#bd6d6c' }, + { name: 'Nodes', color: '#75d874' }, + { name: 'Listeners', color: '#e0bc78' }, + { name: 'GPU Memory', color: '#dc77dc' }, + { name: 'GPU', color: '#72b362' } +]; +// Generate mock data +categories.forEach(function (category, index) { + var baseTime = startTime; + for (var i = 0; i < dataCount; i++) { + var typeItem = types[Math.round(Math.random() * (types.length - 1))]; + var duration = Math.round(Math.random() * 10000); + data.push({ + name: typeItem.name, + value: [index, baseTime, (baseTime += duration), duration], + itemStyle: { + normal: { + color: typeItem.color + } + } + }); + baseTime += Math.round(Math.random() * 2000); + } +}); +function renderItem(params, api) { + var categoryIndex = api.value(0); + var start = api.coord([api.value(1), categoryIndex]); + var end = api.coord([api.value(2), categoryIndex]); + var height = api.size([0, 1])[1] * 0.6; + var rectShape = echarts.graphic.clipRectByRect({ + x: start[0], + y: start[1] - height / 2, + width: end[0] - start[0], + height: height + }, { + x: params.coordSys.x, + y: params.coordSys.y, + width: params.coordSys.width, + height: params.coordSys.height + }); + return (rectShape && { + type: 'rect', + transition: ['shape'], + shape: rectShape, + style: api.style() + }); +} +option = { + tooltip: { + formatter: function (params) { + return params.marker + params.name + ': ' + params.value[3] + ' ms'; + } + }, + title: { + text: 'Profile', + left: 'center' + }, + dataZoom: [ + { + type: 'slider', + filterMode: 'weakFilter', + showDataShadow: false, + top: 400, + labelFormatter: '' + }, + { + type: 'inside', + filterMode: 'weakFilter' + } + ], + grid: { + height: 300 + }, + xAxis: { + min: startTime, + scale: true, + axisLabel: { + formatter: function (val) { + return Math.max(0, val - startTime) + ' ms'; + } + } + }, + yAxis: { + data: categories + }, + series: [ + { + type: 'custom', + renderItem: renderItem, + itemStyle: { + opacity: 0.8 + }, + encode: { + x: [1, 2], + y: 0 + }, + data: data + } + ] +}; diff --git a/testdata/custom-profile.js.svg b/testdata/custom-profile.js.svg new file mode 100644 index 0000000..a08bc9e --- /dev/null +++ b/testdata/custom-profile.js.svg @@ -0,0 +1,35 @@ + + + + + + + + + + + + + + + +categoryA +categoryB +categoryC +1,705,721,550,000 +1,705,721,560,000 +1,705,721,570,000 +1,705,721,580,000 +1,705,721,590,000 +1,705,721,600,000 + + + + + + + + + +Profile + \ No newline at end of file diff --git a/testdata/custom-profit.js b/testdata/custom-profit.js new file mode 100644 index 0000000..d818b23 --- /dev/null +++ b/testdata/custom-profit.js @@ -0,0 +1,77 @@ +/* +title: Profit +category: custom +titleCN: 利润分布直方图 +difficulty: 1 +*/ +const colorList = [ + '#4f81bd', + '#c0504d', + '#9bbb59', + '#604a7b', + '#948a54', + '#e46c0b' +]; +const data = [ + [10, 16, 3, 'A'], + [16, 18, 15, 'B'], + [18, 26, 12, 'C'], + [26, 32, 22, 'D'], + [32, 56, 7, 'E'], + [56, 62, 17, 'F'] +].map(function (item, index) { + return { + value: item, + itemStyle: { + color: colorList[index] + } + }; +}); +option = { + title: { + text: 'Profit', + left: 'center' + }, + tooltip: {}, + xAxis: { + scale: true + }, + yAxis: {}, + series: [ + { + type: 'custom', + renderItem: function (params, api) { + var yValue = api.value(2); + var start = api.coord([api.value(0), yValue]); + var size = api.size([ + api.value(1) - api.value(0), + yValue + ]); + var style = api.style(); + return { + type: 'rect', + shape: { + x: start[0], + y: start[1], + width: size[0], + height: size[1] + }, + style: style + }; + }, + label: { + show: true, + position: 'top' + }, + dimensions: ['from', 'to', 'profit'], + encode: { + x: [0, 1], + y: 2, + tooltip: [0, 1, 2], + itemName: 3 + }, + data: data + } + ] +}; +export {}; diff --git a/testdata/custom-profit.js.svg b/testdata/custom-profit.js.svg new file mode 100644 index 0000000..a2f5802 --- /dev/null +++ b/testdata/custom-profit.js.svg @@ -0,0 +1,46 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +0 +5 +10 +15 +20 +25 +10 +20 +30 +40 +50 +60 +70 + +Profit + \ No newline at end of file diff --git a/testdata/custom-spiral-race.js b/testdata/custom-spiral-race.js new file mode 100644 index 0000000..c4f64d7 --- /dev/null +++ b/testdata/custom-spiral-race.js @@ -0,0 +1,222 @@ +"use strict"; +/* +title: Custom Spiral Race +category: custom +titleCN: 自定义螺旋线竞速 +difficulty: 11 +*/ +var _animationDuration = 5000; +var _animationDurationUpdate = 7000; +var _animationEasingUpdate = 'linear'; +// prettier-ignore +var _radianLabels = ['Aries', 'Taurus', 'Gemini', 'Cancer', 'Leo', 'Virgo', 'Libra', 'Scorpius', 'Sagittarius', 'Capricornus', 'Aquarius', 'Pisces']; +var _valOnRoundRadian = _radianLabels.length; +var _radianStep = Math.PI / 45; +var _barWidthValue = 0.4; +var _valOnRadiusStep = 4; +// angleAxis.startAngle is 90 by default. +var _startRadian = Math.PI / 2; +// prettier-ignore +var _colors = [ + { fill: '#5470c6', text: '#2747a5' }, + { fill: '#91cc75', text: '#447f27' }, + { fill: '#fac858', text: '#a0761c' } +]; +var _currentDataIndex = 0; +// prettier-ignore +var _datasourceList = [ + [[1, 3], [2, 6], [3, 9]], + [[1, 12], [2, 16], [3, 14]], + [[1, 17], [2, 22], [3, 19]], + [[1, 19], [2, 33], [3, 24]], + [[1, 24], [2, 42], [3, 29]], + [[1, 27], [2, 47], [3, 41]], + [[1, 36], [2, 52], [3, 52]], + [[1, 46], [2, 59], [3, 63]], + [[1, 60], [2, 63], [3, 69]], +]; +var _barNamesByOrdinal = { 1: 'A', 2: 'B', 3: 'C' }; +function getMaxRadius() { + var radius = 0; + var datasource = _datasourceList[_currentDataIndex]; + for (var j = 0; j < datasource.length; j++) { + var dataItem = datasource[j]; + radius = Math.max(radius, getSpiralValueOnRadius(dataItem[0], dataItem[1])); + } + return Math.ceil(radius * 1.2); +} +function getSpiralValueOnRadius(valOnStartRadius, valOnEndAngle) { + return (valOnStartRadius + _valOnRadiusStep * (valOnEndAngle / _valOnRoundRadian)); +} +function getSpiralRadius(startRadius, endRadian, radiusStep) { + return (startRadius + radiusStep * ((_startRadian - endRadian) / (Math.PI * 2))); +} +function renderItem(params, api) { + var children = []; + var dataIdx = params.dataIndex; + addShapes(params, api, children, api.value(0), api.value(1), _colors[dataIdx]); + return { + type: 'group', + children: children + }; +} +function addShapes(params, api, children, valOnStartRadius, valOnEndRadian, color) { + var coords = api.coord([valOnStartRadius, valOnEndRadian]); + var startRadius = coords[2]; + var endRadian = coords[3]; + var widthRadius = api.coord([_barWidthValue, 0])[2]; + addPolygon(params, children, widthRadius, startRadius, endRadian, color); + addLabel(params, children, widthRadius, startRadius, endRadian, color); +} +function addPolygon(params, children, widthRadius, startRadius, endRadian, color) { + children.push({ + type: 'polygon', + shape: { + points: makeShapePoints(params, widthRadius, startRadius, endRadian) + }, + extra: { + widthRadius: widthRadius, + startRadius: startRadius, + endRadian: endRadian, + transition: ['widthRadius', 'startRadius', 'endRadian'] + }, + style: { + fill: color.fill + }, + during: function (apiDuring) { + apiDuring.setShape('points', makeShapePoints(params, apiDuring.getExtra('widthRadius'), apiDuring.getExtra('startRadius'), apiDuring.getExtra('endRadian'))); + } + }); +} +function makeShapePoints(params, widthRadius, startRadius, endRadian) { + var points = []; + var radiusStep = getRadiusStepByWidth(widthRadius); + // angleAxis.clockwise is true by default. So when rotate clickwisely, radian decreases. + for (var iRadian = _startRadian, end = endRadian - _radianStep; iRadian > end; iRadian -= _radianStep) { + iRadian < endRadian && (iRadian = endRadian); + var iRadius = getSpiralRadius(startRadius - widthRadius, iRadian, radiusStep); + points.push(convertToPolarPoint(params, iRadius, iRadian)); + } + for (var iRadian = endRadian; iRadian < _startRadian + _radianStep; iRadian += _radianStep) { + iRadian > _startRadian && (iRadian = _startRadian); + var iRadius = getSpiralRadius(startRadius + widthRadius, iRadian, radiusStep); + points.push(convertToPolarPoint(params, iRadius, iRadian)); + } + return points; +} +function getRadiusStepByWidth(widthRadius) { + return (widthRadius / _barWidthValue) * _valOnRadiusStep; +} +function addLabel(params, children, widthRadius, startRadius, endRadian, color) { + var point = makeLabelPosition(params, widthRadius, startRadius, endRadian); + children.push({ + type: 'text', + x: point[0], + y: point[1], + transition: [], + extra: { + startRadius: startRadius, + endRadian: endRadian, + widthRadius: widthRadius, + transition: ['startRadius', 'endRadian', 'widthRadius'] + }, + style: { + text: makeText(endRadian), + fill: color.text, + stroke: '#fff', + lineWidth: 3, + fontSize: 16, + align: 'center', + verticalAlign: 'middle', + rich: { + round: { fontSize: 24 }, + percent: { fontSize: 18 } + } + }, + z2: 50, + during: function (apiDuring) { + var endRadian = apiDuring.getExtra('endRadian'); + var point = makeLabelPosition(params, apiDuring.getExtra('widthRadius'), apiDuring.getExtra('startRadius'), endRadian); + apiDuring.setTransform('x', point[0]).setTransform('y', point[1]); + apiDuring.setStyle('text', makeText(endRadian)); + } + }); + function makeText(endRadian) { + var radian = _startRadian - endRadian; + var PI2 = Math.PI * 2; + var round = Math.floor(radian / PI2); + var percent = (((radian / PI2) % 1) * 100).toFixed(1) + '%'; + return 'Round {round|' + round + '}\n{percent|' + percent + '}'; + } +} +function makeLabelPosition(params, widthRadius, startRadius, endRadian) { + var radiusStep = getRadiusStepByWidth(widthRadius); + var iRadius = getSpiralRadius(startRadius, endRadian, radiusStep); + return convertToPolarPoint(params, iRadius, endRadian - 10 / iRadius); +} +function convertToPolarPoint(renderItemParams, radius, radian) { + return [ + Math.cos(radian) * radius + renderItemParams.coordSys.cx, + -Math.sin(radian) * radius + renderItemParams.coordSys.cy + ]; +} +option = { + animationDuration: _animationDuration, + animationDurationUpdate: _animationDurationUpdate, + animationEasingUpdate: _animationEasingUpdate, + dataset: { + source: _datasourceList[_currentDataIndex] + }, + tooltip: {}, + angleAxis: { + type: 'value', + splitArea: { show: true }, + axisLabel: { + formatter: function (val) { + return _radianLabels[val]; + }, + color: 'rgba(0,0,0,0.2)' + }, + axisLine: { lineStyle: { color: 'rgba(0,0,0,0.2)' } }, + min: 0, + max: _valOnRoundRadian + }, + radiusAxis: { + type: 'value', + interval: 1, + splitLine: { show: false }, + axisLabel: { + color: 'rgba(0,0,0,0.6)', + formatter: function (value) { + return _barNamesByOrdinal[value] || ''; + } + }, + axisTick: { show: false }, + axisLine: { lineStyle: { color: 'rgba(0,0,0,0.2)' } }, + min: 0, + max: getMaxRadius() + }, + polar: {}, + series: [ + { + type: 'custom', + coordinateSystem: 'polar', + renderItem: renderItem + } + ] +}; +function next() { + ++_currentDataIndex; + myChart.setOption({ + dataset: { + source: _datasourceList[_currentDataIndex] + }, + radiusAxis: { + max: getMaxRadius() + } + }); + if (_currentDataIndex < _datasourceList.length - 1) { + setTimeout(next, _animationDurationUpdate); + } +} +setTimeout(next, 1000); diff --git a/testdata/custom-spiral-race.js.svg b/testdata/custom-spiral-race.js.svg new file mode 100644 index 0000000..11cf9a5 --- /dev/null +++ b/testdata/custom-spiral-race.js.svg @@ -0,0 +1,30 @@ + + +0 +1 +2 +3 +4 +5 +6 +7 +8 +9 +10 +11 + + + + + + +0 +1 +2 +3 +4 +5 +6 +7 +8 + \ No newline at end of file diff --git a/testdata/custom-wind.js b/testdata/custom-wind.js new file mode 100644 index 0000000..1264605 --- /dev/null +++ b/testdata/custom-wind.js @@ -0,0 +1,117 @@ +/* +title: Use custom series to draw wind vectors +titleCN: 使用自定义系列绘制风场 +category: custom +difficulty: 7 +*/ +function shuffle(array) { + // https://stackoverflow.com/questions/2450954/how-to-randomize-shuffle-a-javascript-array + var currentIndex = array.length; + var temporaryValue; + var randomIndex; + // While there remain elements to shuffle... + while (0 !== currentIndex) { + // Pick a remaining element... + randomIndex = Math.floor(Math.random() * currentIndex); + currentIndex -= 1; + // And swap it with the current element. + temporaryValue = array[currentIndex]; + array[currentIndex] = array[randomIndex]; + array[randomIndex] = temporaryValue; + } + return array; +} +$.getJSON(ROOT_PATH + '/data-gl/asset/data/winds.json', function (windData) { + var p = 0; + var maxMag = 0; + var minMag = Infinity; + var data = []; + for (var j = 0; j < windData.ny; j++) { + for (var i = 0; i < windData.nx; i++, p++) { + var vx = windData.data[p][0]; + var vy = windData.data[p][1]; + var mag = Math.sqrt(vx * vx + vy * vy); + // 数据是一个一维数组 + // [ [经度, 维度,向量经度方向的值,向量维度方向的值] ] + data.push([ + (i / windData.nx) * 360 - 180, + (j / windData.ny) * 180 - 90, + vx, + vy, + mag + ]); + maxMag = Math.max(mag, maxMag); + minMag = Math.min(mag, minMag); + } + } + shuffle(data); + myChart.setOption((option = { + backgroundColor: '#333', + visualMap: { + left: 'center', + min: minMag, + max: maxMag, + dimension: 4, + inRange: { + // prettier-ignore + color: ['#313695', '#4575b4', '#74add1', '#abd9e9', '#e0f3f8', '#ffffbf', '#fee090', '#fdae61', '#f46d43', '#d73027', '#a50026'] + }, + calculable: true, + textStyle: { + color: '#fff' + }, + orient: 'horizontal' + }, + geo: { + map: 'world', + left: 0, + right: 0, + top: 0, + zoom: 1, + silent: true, + roam: true, + itemStyle: { + areaColor: '#323c48', + borderColor: '#111' + } + }, + series: { + type: 'custom', + coordinateSystem: 'geo', + data: data, + encode: { + x: 0, + y: 0 + }, + renderItem: function (params, api) { + const x = api.value(0); + const y = api.value(1); + const dx = api.value(2); + const dy = api.value(3); + const start = api.coord([ + Math.max(x - dx / 5, -180), + Math.max(y - dy / 5, -90) + ]); + const end = api.coord([ + Math.min(x + dx / 5, 180), + Math.min(y + dy / 5, 90) + ]); + return { + type: 'line', + shape: { + x1: start[0], + y1: start[1], + x2: end[0], + y2: end[1] + }, + style: { + lineWidth: 0.5, + stroke: api.visual('color') + } + }; + }, + progressive: 2000 + } + })); +}); +export {}; diff --git a/testdata/cycle-plot.js b/testdata/cycle-plot.js new file mode 100644 index 0000000..98acfbe --- /dev/null +++ b/testdata/cycle-plot.js @@ -0,0 +1,138 @@ +"use strict"; +/* +title: Cycle Plot +category: custom +titleCN: Cycle Plot +difficulty: 3 +*/ +// prettier-ignore +var rawData = [ + [2002, 14, 21, 25, 21, 26, 32, 27, 20, 10, 11, 5, 5], + [2003, 18, 24, 28, 24, 33, 37, 30, 25, 13, 14, 6, 6], + [2004, 22, 31, 36, 28, 37, 43, 35, 30, 13, 13, 7, 7], + [2005, 25, 32, 38, 34, 39, 48, 38, 29, 14, 14, 8, 8], + [2006, 29, 38, 47, 33, 44, 57, 41, 39, 16, 16, 9, 8], + [2007, 29, 35, 49, 34, 43, 57, 41, 37, 20, 17, 9, 10], + [2008, 22, 32, 37, 30, 35, 44, 38, 31, 16, 17, 8, 7], + [2009, 25, 34, 41, 33, 39, 47, 44, 32, 17, 17, 9, 8], + [2010, 26, 35, 46, 40, 47, 61, 47, 41, 20, 18, 9, 10], + [2011, 29, 39, 55, 38, 55, 67, 53, 41, 19, 20, 11, 11], + [2012, 38, 48, 60, 49, 57, 79, 62, 54, 26, 26, 13, 11] +]; +var dataByMonth = []; +// prettier-ignore +var months = ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec']; +rawData.forEach(function (entry, yearIndex) { + entry.forEach(function (value, index) { + if (index) { + var monthIndex = index - 1; + var monthItem = (dataByMonth[monthIndex] = dataByMonth[monthIndex] || []); + monthItem[0] = monthIndex; + monthItem[yearIndex + 1] = value; + } + }); +}); +var averageByMonth = []; +dataByMonth.forEach(function (entry, index) { + var sum = 0; + entry.forEach(function (value, index) { + index && (sum += value); + }); + averageByMonth.push([index, sum / (entry.length - 1)]); +}); +function renderTrendItem(params, api) { + var categoryIndex = api.value(0); + var unitBandWidth = (api.size([0, 0])[0] * 0.85) / (rawData.length - 1); + var points = rawData.map(function (entry, index) { + var value = api.value(index + 1); + var point = api.coord([categoryIndex, value]); + point[0] += unitBandWidth * (index - rawData.length / 2); + return point; + }); + return { + type: 'polyline', + transition: ['shape'], + shape: { + points: points + }, + style: api.style({ + fill: null, + stroke: api.visual('color'), + lineWidth: 2 + }) + }; +} +function renderAverageItem(param, api) { + var bandWidth = api.size([0, 0])[0] * 0.85; + var point = api.coord([api.value(0), api.value(1)]); + return { + type: 'line', + transition: ['shape'], + shape: { + x1: point[0] - bandWidth / 2, + x2: point[0] + bandWidth / 2, + y1: point[1], + y2: point[1] + }, + style: api.style({ + fill: null, + stroke: api.visual('color'), + lineWidth: 2 + }) + }; +} +option = { + tooltip: {}, + title: { + text: 'Sales Trends by Year within Each Month', + subtext: 'Sample of Cycle Plot', + left: 'center' + }, + legend: { + top: 70, + data: ['Trend by year (2002 - 2012)', 'Average'] + }, + dataZoom: [ + { + type: 'slider', + labelFormatter: '' + }, + { + type: 'inside' + } + ], + grid: { + bottom: 70, + top: 120 + }, + xAxis: { + data: months + }, + yAxis: { + boundaryGap: [0, '20%'] + }, + series: [ + { + type: 'custom', + name: 'Average', + renderItem: renderAverageItem, + encode: { + x: 0, + y: 1 + }, + data: averageByMonth + }, + { + type: 'custom', + name: 'Trend by year (2002 - 2012)', + renderItem: renderTrendItem, + encode: { + x: 0, + y: rawData.map(function (entry, index) { + return index + 1; + }) + }, + data: dataByMonth + } + ] +}; diff --git a/testdata/cycle-plot.js.svg b/testdata/cycle-plot.js.svg new file mode 100644 index 0000000..8b849f3 --- /dev/null +++ b/testdata/cycle-plot.js.svg @@ -0,0 +1,57 @@ + + + + + + + + + + + + + + + + + + + + + + +0 +20 +40 +60 +80 +100 +Jan +Feb +Mar +Apr +May +Jun +Jul +Aug +Sep +Oct +Nov +Dec + + + +Trend by year (2002 - 2012) + +Average + + + + + + + + +Sales Trends by Year within Each Month +Sample of Cycle Plot + \ No newline at end of file diff --git a/testdata/data-transform-aggregate.js b/testdata/data-transform-aggregate.js new file mode 100644 index 0000000..7dca34f --- /dev/null +++ b/testdata/data-transform-aggregate.js @@ -0,0 +1,136 @@ +"use strict"; +/* +title: Data Transform Simple Aggregate +category: boxplot +titleCN: 简单的数据聚合 +difficulty: 4 +*/ +$.when($.get(ROOT_PATH + '/data/asset/data/life-expectancy-table.json'), $.getScript('https://fastly.jsdelivr.net/npm/echarts-simple-transform/dist/ecSimpleTransform.min.js')).done(function (res) { + run(res[0]); +}); +function run(_rawData) { + echarts.registerTransform(ecSimpleTransform.aggregate); + option = { + dataset: [ + { + id: 'raw', + source: _rawData + }, + { + id: 'since_year', + fromDatasetId: 'raw', + transform: [ + { + type: 'filter', + config: { + dimension: 'Year', + gte: 1950 + } + } + ] + }, + { + id: 'income_aggregate', + fromDatasetId: 'since_year', + transform: [ + { + type: 'ecSimpleTransform:aggregate', + config: { + resultDimensions: [ + { name: 'min', from: 'Income', method: 'min' }, + { name: 'Q1', from: 'Income', method: 'Q1' }, + { name: 'median', from: 'Income', method: 'median' }, + { name: 'Q3', from: 'Income', method: 'Q3' }, + { name: 'max', from: 'Income', method: 'max' }, + { name: 'Country', from: 'Country' } + ], + groupBy: 'Country' + } + }, + { + type: 'sort', + config: { + dimension: 'Q3', + order: 'asc' + } + } + ] + } + ], + title: { + text: 'Income since 1950' + }, + tooltip: { + trigger: 'axis', + confine: true + }, + xAxis: { + name: 'Income', + nameLocation: 'middle', + nameGap: 30, + scale: true + }, + yAxis: { + type: 'category' + }, + grid: { + bottom: 100 + }, + legend: { + selected: { detail: false } + }, + dataZoom: [ + { + type: 'inside' + }, + { + type: 'slider', + height: 20 + } + ], + series: [ + { + name: 'boxplot', + type: 'boxplot', + datasetId: 'income_aggregate', + itemStyle: { + color: '#b8c5f2' + }, + encode: { + x: ['min', 'Q1', 'median', 'Q3', 'max'], + y: 'Country', + itemName: ['Country'], + tooltip: ['min', 'Q1', 'median', 'Q3', 'max'] + } + }, + { + name: 'detail', + type: 'scatter', + datasetId: 'since_year', + symbolSize: 6, + tooltip: { + trigger: 'item' + }, + label: { + show: true, + position: 'top', + align: 'left', + verticalAlign: 'middle', + rotate: 90, + fontSize: 12 + }, + itemStyle: { + color: '#d00000' + }, + encode: { + x: 'Income', + y: 'Country', + label: 'Year', + itemName: 'Year', + tooltip: ['Country', 'Year', 'Income'] + } + } + ] + }; + myChart.setOption(option); +} diff --git a/testdata/data-transform-filter.js b/testdata/data-transform-filter.js new file mode 100644 index 0000000..30c8cef --- /dev/null +++ b/testdata/data-transform-filter.js @@ -0,0 +1,84 @@ +/* +title: Data Transform Filter +category: line +titleCN: 数据过滤 +difficulty: 3 +*/ +$.get(ROOT_PATH + '/data/asset/data/life-expectancy-table.json', function (_rawData) { + run(_rawData); +}); +function run(_rawData) { + option = { + dataset: [ + { + id: 'dataset_raw', + source: _rawData + }, + { + id: 'dataset_since_1950_of_germany', + fromDatasetId: 'dataset_raw', + transform: { + type: 'filter', + config: { + and: [ + { dimension: 'Year', gte: 1950 }, + { dimension: 'Country', '=': 'Germany' } + ] + } + } + }, + { + id: 'dataset_since_1950_of_france', + fromDatasetId: 'dataset_raw', + transform: { + type: 'filter', + config: { + and: [ + { dimension: 'Year', gte: 1950 }, + { dimension: 'Country', '=': 'France' } + ] + } + } + } + ], + title: { + text: 'Income of Germany and France since 1950' + }, + tooltip: { + trigger: 'axis' + }, + xAxis: { + type: 'category', + nameLocation: 'middle' + }, + yAxis: { + name: 'Income' + }, + series: [ + { + type: 'line', + datasetId: 'dataset_since_1950_of_germany', + showSymbol: false, + encode: { + x: 'Year', + y: 'Income', + itemName: 'Year', + tooltip: ['Income'] + } + }, + { + type: 'line', + datasetId: 'dataset_since_1950_of_france', + showSymbol: false, + encode: { + x: 'Year', + y: 'Income', + itemName: 'Year', + tooltip: ['Income'] + } + } + ] + }; + myChart.setOption(option); +} +export {}; diff --git a/testdata/data-transform-multiple-pie.js b/testdata/data-transform-multiple-pie.js new file mode 100644 index 0000000..e458e44 --- /dev/null +++ b/testdata/data-transform-multiple-pie.js @@ -0,0 +1,96 @@ +/* +title: Partition Data to Pies +category: dataset, pie, transform +titleCN: 分割数据到数个饼图 +difficulty: 3 +*/ +option = { + dataset: [ + { + source: [ + ['Product', 'Sales', 'Price', 'Year'], + ['Cake', 123, 32, 2011], + ['Cereal', 231, 14, 2011], + ['Tofu', 235, 5, 2011], + ['Dumpling', 341, 25, 2011], + ['Biscuit', 122, 29, 2011], + ['Cake', 143, 30, 2012], + ['Cereal', 201, 19, 2012], + ['Tofu', 255, 7, 2012], + ['Dumpling', 241, 27, 2012], + ['Biscuit', 102, 34, 2012], + ['Cake', 153, 28, 2013], + ['Cereal', 181, 21, 2013], + ['Tofu', 395, 4, 2013], + ['Dumpling', 281, 31, 2013], + ['Biscuit', 92, 39, 2013], + ['Cake', 223, 29, 2014], + ['Cereal', 211, 17, 2014], + ['Tofu', 345, 3, 2014], + ['Dumpling', 211, 35, 2014], + ['Biscuit', 72, 24, 2014] + ] + }, + { + transform: { + type: 'filter', + config: { dimension: 'Year', value: 2011 } + } + }, + { + transform: { + type: 'filter', + config: { dimension: 'Year', value: 2012 } + } + }, + { + transform: { + type: 'filter', + config: { dimension: 'Year', value: 2013 } + } + } + ], + series: [ + { + type: 'pie', + radius: 50, + center: ['50%', '25%'], + datasetIndex: 1 + }, + { + type: 'pie', + radius: 50, + center: ['50%', '50%'], + datasetIndex: 2 + }, + { + type: 'pie', + radius: 50, + center: ['50%', '75%'], + datasetIndex: 3 + } + ], + // Optional. Only for responsive layout: + media: [ + { + query: { minAspectRatio: 1 }, + option: { + series: [ + { center: ['25%', '50%'] }, + { center: ['50%', '50%'] }, + { center: ['75%', '50%'] } + ] + } + }, + { + option: { + series: [ + { center: ['50%', '25%'] }, + { center: ['50%', '50%'] }, + { center: ['50%', '75%'] } + ] + } + } + ] +}; +export {}; diff --git a/testdata/data-transform-multiple-pie.js.svg b/testdata/data-transform-multiple-pie.js.svg new file mode 100644 index 0000000..280364f --- /dev/null +++ b/testdata/data-transform-multiple-pie.js.svg @@ -0,0 +1,215 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Cake +Tofu +Dumpling +Biscuit +Cake +Cereal +Tofu +Dumpling +Biscuit +Cake +Cereal +Tofu +Dumpling +Biscuit + + \ No newline at end of file diff --git a/testdata/data-transform-sort-bar.js b/testdata/data-transform-sort-bar.js new file mode 100644 index 0000000..6521d92 --- /dev/null +++ b/testdata/data-transform-sort-bar.js @@ -0,0 +1,41 @@ +/* +title: Sort Data in Bar Chart +category: dataset, bar, transform +titleCN: 柱状图排序 +difficulty: 0 +*/ +option = { + dataset: [ + { + dimensions: ['name', 'age', 'profession', 'score', 'date'], + source: [ + ['Hannah Krause', 41, 'Engineer', 314, '2011-02-12'], + ['Zhao Qian', 20, 'Teacher', 351, '2011-03-01'], + ['Jasmin Krause ', 52, 'Musician', 287, '2011-02-14'], + ['Li Lei', 37, 'Teacher', 219, '2011-02-18'], + ['Karle Neumann', 25, 'Engineer', 253, '2011-04-02'], + ['Adrian Groß', 19, 'Teacher', '-', '2011-01-16'], + ['Mia Neumann', 71, 'Engineer', 165, '2011-03-19'], + ['Böhm Fuchs', 36, 'Musician', 318, '2011-02-24'], + ['Han Meimei', 67, 'Engineer', 366, '2011-03-12'] + ] + }, + { + transform: { + type: 'sort', + config: { dimension: 'score', order: 'desc' } + } + } + ], + xAxis: { + type: 'category', + axisLabel: { interval: 0, rotate: 30 } + }, + yAxis: {}, + series: { + type: 'bar', + encode: { x: 'name', y: 'score' }, + datasetIndex: 1 + } +}; +export {}; diff --git a/testdata/data-transform-sort-bar.js.svg b/testdata/data-transform-sort-bar.js.svg new file mode 100644 index 0000000..b3d7975 --- /dev/null +++ b/testdata/data-transform-sort-bar.js.svg @@ -0,0 +1,133 @@ + + + + + + + + + + + + + + + + + + +0 +100 +200 +300 +400 +Han Meimei +Zhao Qian +Böhm Fuchs +Hannah Krause +Jasmin Krause +Karle Neumann +Li Lei +Mia Neumann +Adrian Groß + + + + + + + + + + \ No newline at end of file diff --git a/testdata/dataset-default.js b/testdata/dataset-default.js new file mode 100644 index 0000000..d5d6df7 --- /dev/null +++ b/testdata/dataset-default.js @@ -0,0 +1,55 @@ +/* +title: Default arrangement +category: 'dataset, pie' +titleCN: 默认 encode 设置 +difficulty: 3 +*/ +option = { + legend: {}, + tooltip: {}, + dataset: { + source: [ + ['product', '2012', '2013', '2014', '2015', '2016', '2017'], + ['Milk Tea', 86.5, 92.1, 85.7, 83.1, 73.4, 55.1], + ['Matcha Latte', 41.1, 30.4, 65.1, 53.3, 83.8, 98.7], + ['Cheese Cocoa', 24.1, 67.2, 79.5, 86.4, 65.2, 82.5], + ['Walnut Brownie', 55.2, 67.1, 69.2, 72.4, 53.9, 39.1] + ] + }, + series: [ + { + type: 'pie', + radius: '20%', + center: ['25%', '30%'] + // No encode specified, by default, it is '2012'. + }, + { + type: 'pie', + radius: '20%', + center: ['75%', '30%'], + encode: { + itemName: 'product', + value: '2013' + } + }, + { + type: 'pie', + radius: '20%', + center: ['25%', '75%'], + encode: { + itemName: 'product', + value: '2014' + } + }, + { + type: 'pie', + radius: '20%', + center: ['75%', '75%'], + encode: { + itemName: 'product', + value: '2015' + } + } + ] +}; +export {}; diff --git a/testdata/dataset-default.js.svg b/testdata/dataset-default.js.svg new file mode 100644 index 0000000..7b5c296 --- /dev/null +++ b/testdata/dataset-default.js.svg @@ -0,0 +1,240 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Milk Tea +Matcha Latte +Cheese Cocoa +Walnut Brownie +Milk Tea +Matcha Latte +Cheese Cocoa +Walnut Brownie +Milk Tea +Matcha Latte +Cheese Cocoa +Walnut Brownie +Milk Tea +Matcha Latte +Cheese Cocoa +Walnut Brownie + + +Milk Tea + +Matcha Latte + +Cheese Cocoa + +Walnut Brownie + + \ No newline at end of file diff --git a/testdata/dataset-encode0.js b/testdata/dataset-encode0.js new file mode 100644 index 0000000..9f08003 --- /dev/null +++ b/testdata/dataset-encode0.js @@ -0,0 +1,49 @@ +/* +title: Simple Encode +category: 'dataset, bar' +titleCN: 指定数据到坐标轴的映射 +difficulty: 1 +*/ +option = { + dataset: { + source: [ + ['score', 'amount', 'product'], + [89.3, 58212, 'Matcha Latte'], + [57.1, 78254, 'Milk Tea'], + [74.4, 41032, 'Cheese Cocoa'], + [50.1, 12755, 'Cheese Brownie'], + [89.7, 20145, 'Matcha Cocoa'], + [68.1, 79146, 'Tea'], + [19.6, 91852, 'Orange Juice'], + [10.6, 101852, 'Lemon Juice'], + [32.7, 20112, 'Walnut Brownie'] + ] + }, + grid: { containLabel: true }, + xAxis: { name: 'amount' }, + yAxis: { type: 'category' }, + visualMap: { + orient: 'horizontal', + left: 'center', + min: 10, + max: 100, + text: ['High Score', 'Low Score'], + // Map the score column to color + dimension: 0, + inRange: { + color: ['#65B581', '#FFCE34', '#FD665F'] + } + }, + series: [ + { + type: 'bar', + encode: { + // Map the "amount" column to X axis. + x: 'amount', + // Map the "product" column to Y axis + y: 'product' + } + } + ] +}; +export {}; diff --git a/testdata/dataset-encode0.js.svg b/testdata/dataset-encode0.js.svg new file mode 100644 index 0000000..853488b --- /dev/null +++ b/testdata/dataset-encode0.js.svg @@ -0,0 +1,368 @@ + + + + + + + + + + +amount + + + + + + + + + + +Matcha Latte +Milk Tea +Cheese Cocoa +Cheese Brownie +Matcha Cocoa +Tea +Orange Juice +Lemon Juice +Walnut Brownie +0 +20,000 +40,000 +60,000 +80,000 +100,000 +120,000 + + + + + + + + + + + + + + +Low Score +High Score + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/dataset-encode1.js b/testdata/dataset-encode1.js new file mode 100644 index 0000000..f7fe089 --- /dev/null +++ b/testdata/dataset-encode1.js @@ -0,0 +1,117 @@ +/* +title: Encode and Matrix +category: dataset +titleCN: 指定数据到坐标轴的映射 +difficulty: 3 +*/ +$.get(ROOT_PATH + '/data/asset/data/life-expectancy-table.json', function (data) { + var sizeValue = '57%'; + var symbolSize = 2.5; + option = { + legend: {}, + tooltip: {}, + toolbox: { + left: 'center', + feature: { + dataZoom: {} + } + }, + grid: [ + { right: sizeValue, bottom: sizeValue }, + { left: sizeValue, bottom: sizeValue }, + { right: sizeValue, top: sizeValue }, + { left: sizeValue, top: sizeValue } + ], + xAxis: [ + { + type: 'value', + gridIndex: 0, + name: 'Income', + axisLabel: { rotate: 50, interval: 0 } + }, + { + type: 'category', + gridIndex: 1, + name: 'Country', + boundaryGap: false, + axisLabel: { rotate: 50, interval: 0 } + }, + { + type: 'value', + gridIndex: 2, + name: 'Income', + axisLabel: { rotate: 50, interval: 0 } + }, + { + type: 'value', + gridIndex: 3, + name: 'Life Expectancy', + axisLabel: { rotate: 50, interval: 0 } + } + ], + yAxis: [ + { type: 'value', gridIndex: 0, name: 'Life Expectancy' }, + { type: 'value', gridIndex: 1, name: 'Income' }, + { type: 'value', gridIndex: 2, name: 'Population' }, + { type: 'value', gridIndex: 3, name: 'Population' } + ], + dataset: { + dimensions: [ + 'Income', + 'Life Expectancy', + 'Population', + 'Country', + { name: 'Year', type: 'ordinal' } + ], + source: data + }, + series: [ + { + type: 'scatter', + symbolSize: symbolSize, + xAxisIndex: 0, + yAxisIndex: 0, + encode: { + x: 'Income', + y: 'Life Expectancy', + tooltip: [0, 1, 2, 3, 4] + } + }, + { + type: 'scatter', + symbolSize: symbolSize, + xAxisIndex: 1, + yAxisIndex: 1, + encode: { + x: 'Country', + y: 'Income', + tooltip: [0, 1, 2, 3, 4] + } + }, + { + type: 'scatter', + symbolSize: symbolSize, + xAxisIndex: 2, + yAxisIndex: 2, + encode: { + x: 'Income', + y: 'Population', + tooltip: [0, 1, 2, 3, 4] + } + }, + { + type: 'scatter', + symbolSize: symbolSize, + xAxisIndex: 3, + yAxisIndex: 3, + encode: { + x: 'Life Expectancy', + y: 'Population', + tooltip: [0, 1, 2, 3, 4] + } + } + ] + }; + myChart.setOption(option); +}); +export {}; diff --git a/testdata/dataset-link.js b/testdata/dataset-link.js new file mode 100644 index 0000000..183bad6 --- /dev/null +++ b/testdata/dataset-link.js @@ -0,0 +1,90 @@ +/* +title: Share Dataset +category: 'dataset, line, pie' +titleCN: 联动和共享数据集 +difficulty: 5 +*/ +setTimeout(function () { + option = { + legend: {}, + tooltip: { + trigger: 'axis', + showContent: false + }, + dataset: { + source: [ + ['product', '2012', '2013', '2014', '2015', '2016', '2017'], + ['Milk Tea', 56.5, 82.1, 88.7, 70.1, 53.4, 85.1], + ['Matcha Latte', 51.1, 51.4, 55.1, 53.3, 73.8, 68.7], + ['Cheese Cocoa', 40.1, 62.2, 69.5, 36.4, 45.2, 32.5], + ['Walnut Brownie', 25.2, 37.1, 41.2, 18, 33.9, 49.1] + ] + }, + xAxis: { type: 'category' }, + yAxis: { gridIndex: 0 }, + grid: { top: '55%' }, + series: [ + { + type: 'line', + smooth: true, + seriesLayoutBy: 'row', + emphasis: { focus: 'series' } + }, + { + type: 'line', + smooth: true, + seriesLayoutBy: 'row', + emphasis: { focus: 'series' } + }, + { + type: 'line', + smooth: true, + seriesLayoutBy: 'row', + emphasis: { focus: 'series' } + }, + { + type: 'line', + smooth: true, + seriesLayoutBy: 'row', + emphasis: { focus: 'series' } + }, + { + type: 'pie', + id: 'pie', + radius: '30%', + center: ['50%', '25%'], + emphasis: { + focus: 'self' + }, + label: { + formatter: '{b}: {@2012} ({d}%)' + }, + encode: { + itemName: 'product', + value: '2012', + tooltip: '2012' + } + } + ] + }; + myChart.on('updateAxisPointer', function (event) { + const xAxisInfo = event.axesInfo[0]; + if (xAxisInfo) { + const dimension = xAxisInfo.value + 1; + myChart.setOption({ + series: { + id: 'pie', + label: { + formatter: '{b}: {@[' + dimension + ']} ({d}%)' + }, + encode: { + value: dimension, + tooltip: dimension + } + } + }); + } + }); + myChart.setOption(option); +}); +export {}; diff --git a/testdata/dataset-series-layout-by.js b/testdata/dataset-series-layout-by.js new file mode 100644 index 0000000..0b0e7fd --- /dev/null +++ b/testdata/dataset-series-layout-by.js @@ -0,0 +1,36 @@ +/* +title: Series Layout By Column or Row +category: 'dataset, bar' +titleCN: 系列按行和按列排布 +difficulty: 5 +*/ +option = { + legend: {}, + tooltip: {}, + dataset: { + source: [ + ['product', '2012', '2013', '2014', '2015'], + ['Matcha Latte', 41.1, 30.4, 65.1, 53.3], + ['Milk Tea', 86.5, 92.1, 85.7, 83.1], + ['Cheese Cocoa', 24.1, 67.2, 79.5, 86.4] + ] + }, + xAxis: [ + { type: 'category', gridIndex: 0 }, + { type: 'category', gridIndex: 1 } + ], + yAxis: [{ gridIndex: 0 }, { gridIndex: 1 }], + grid: [{ bottom: '55%' }, { top: '55%' }], + series: [ + // These series are in the first grid. + { type: 'bar', seriesLayoutBy: 'row' }, + { type: 'bar', seriesLayoutBy: 'row' }, + { type: 'bar', seriesLayoutBy: 'row' }, + // These series are in the second grid. + { type: 'bar', xAxisIndex: 1, yAxisIndex: 1 }, + { type: 'bar', xAxisIndex: 1, yAxisIndex: 1 }, + { type: 'bar', xAxisIndex: 1, yAxisIndex: 1 }, + { type: 'bar', xAxisIndex: 1, yAxisIndex: 1 } + ] +}; +export {}; diff --git a/testdata/dataset-series-layout-by.js.svg b/testdata/dataset-series-layout-by.js.svg new file mode 100644 index 0000000..98f794e --- /dev/null +++ b/testdata/dataset-series-layout-by.js.svg @@ -0,0 +1,352 @@ + + + + + + + + + + + + + + + + + + + + + + + + + +0 +20 +40 +60 +80 +100 +0 +20 +40 +60 +80 +100 +2012 +2013 +2014 +2015 +Matcha Latte +Milk Tea +Cheese Cocoa + + + + + + + + + + + + + + + + + + + + + + + + + + +Matcha Latte + +Milk Tea + +Cheese Cocoa + +2012 + +2013 + +2014 + +2015 + + \ No newline at end of file diff --git a/testdata/dataset-simple0.js b/testdata/dataset-simple0.js new file mode 100644 index 0000000..f731ead --- /dev/null +++ b/testdata/dataset-simple0.js @@ -0,0 +1,25 @@ +/* +title: Simple Example of Dataset +category: 'dataset, bar' +titleCN: 最简单的数据集(dataset) +difficulty: 5 +*/ +option = { + legend: {}, + tooltip: {}, + dataset: { + source: [ + ['product', '2015', '2016', '2017'], + ['Matcha Latte', 43.3, 85.8, 93.7], + ['Milk Tea', 83.1, 73.4, 55.1], + ['Cheese Cocoa', 86.4, 65.2, 82.5], + ['Walnut Brownie', 72.4, 53.9, 39.1] + ] + }, + xAxis: { type: 'category' }, + yAxis: {}, + // Declare several bar series, each will be mapped + // to a column of dataset.source by default. + series: [{ type: 'bar' }, { type: 'bar' }, { type: 'bar' }] +}; +export {}; diff --git a/testdata/dataset-simple0.js.svg b/testdata/dataset-simple0.js.svg new file mode 100644 index 0000000..0fbadb3 --- /dev/null +++ b/testdata/dataset-simple0.js.svg @@ -0,0 +1,180 @@ + + + + + + + + + + + + + + +0 +20 +40 +60 +80 +100 +Matcha Latte +Milk Tea +Cheese Cocoa +Walnut Brownie + + + + + + + + + + + + + + +2015 + +2016 + +2017 + + \ No newline at end of file diff --git a/testdata/dataset-simple1.js b/testdata/dataset-simple1.js new file mode 100644 index 0000000..55013a3 --- /dev/null +++ b/testdata/dataset-simple1.js @@ -0,0 +1,25 @@ +/* +title: Dataset in Object Array +category: 'dataset, bar' +titleCN: 对象数组的输入格式 +difficulty: 5 +*/ +option = { + legend: {}, + tooltip: {}, + dataset: { + dimensions: ['product', '2015', '2016', '2017'], + source: [ + { product: 'Matcha Latte', '2015': 43.3, '2016': 85.8, '2017': 93.7 }, + { product: 'Milk Tea', '2015': 83.1, '2016': 73.4, '2017': 55.1 }, + { product: 'Cheese Cocoa', '2015': 86.4, '2016': 65.2, '2017': 82.5 }, + { product: 'Walnut Brownie', '2015': 72.4, '2016': 53.9, '2017': 39.1 } + ] + }, + xAxis: { type: 'category' }, + yAxis: {}, + // Declare several bar series, each will be mapped + // to a column of dataset.source by default. + series: [{ type: 'bar' }, { type: 'bar' }, { type: 'bar' }] +}; +export {}; diff --git a/testdata/dataset-simple1.js.svg b/testdata/dataset-simple1.js.svg new file mode 100644 index 0000000..0fbadb3 --- /dev/null +++ b/testdata/dataset-simple1.js.svg @@ -0,0 +1,180 @@ + + + + + + + + + + + + + + +0 +20 +40 +60 +80 +100 +Matcha Latte +Milk Tea +Cheese Cocoa +Walnut Brownie + + + + + + + + + + + + + + +2015 + +2016 + +2017 + + \ No newline at end of file diff --git a/testdata/doc-example/aria-decal-newspaper.js b/testdata/doc-example/aria-decal-newspaper.js new file mode 100644 index 0000000..a1097f7 --- /dev/null +++ b/testdata/doc-example/aria-decal-newspaper.js @@ -0,0 +1,92 @@ +"use strict"; +option = { + series: [{ + type: 'bar', + name: 'Apples', + data: [108, 26, 39, 24], + itemStyle: { + borderColor: 'black', + borderWidth: 2 + } + }, { + type: 'bar', + name: 'Oranges', + data: [23, 40, 60, 70], + itemStyle: { + borderColor: 'black', + borderWidth: 2 + } + }, { + type: 'bar', + name: 'Bananas', + data: [129, 40, 40, 50], + itemStyle: { + borderColor: 'black', + borderWidth: 2 + } + }, { + type: 'bar', + name: 'Pears', + data: [40, 60, 50, 89], + itemStyle: { + borderColor: 'black', + borderWidth: 2 + } + }], + xAxis: { + data: ['Q1', 'Q2', 'Q3', 'Q4'], + axisLine: { + color: 'black' + }, + axisTick: { + color: 'black' + }, + axisLabel: { + color: 'black' + } + }, + yAxis: { + axisLine: { + color: 'black' + }, + axisTick: { + color: 'black' + }, + axisLabel: { + color: 'black' + }, + splitLine: { + lineStyle: { + color: 'black', + type: 'dashed' + } + } + }, + aria: { + decal: { + show: true, + decals: [{ + dashArrayX: 0, + dashArrayY: 0, + color: 'black' + }, { + dashArrayX: 0, + dashArrayY: 0, + color: 'black' + }, { + dashArrayX: [1, 0], + dashArrayY: [2, 5], + symbolSize: 1, + rotation: Math.PI / 6, + color: 'black' + }, { + symbol: 'circle', + dashArrayX: [[8, 8], [0, 8, 8, 0]], + dashArrayY: [6, 0], + symbolSize: 0.8, + color: 'black' + }] + } + }, + color: ['white', 'black', 'white', 'white'] +}; diff --git a/testdata/doc-example/aria-decal-simple.js b/testdata/doc-example/aria-decal-simple.js new file mode 100644 index 0000000..8f20080 --- /dev/null +++ b/testdata/doc-example/aria-decal-simple.js @@ -0,0 +1,26 @@ +"use strict"; +option = { + xAxis: { + type: 'category', + data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'] + }, + yAxis: { + type: 'value' + }, + series: [{ + data: [120, 200, 150, 80, 70, 110, 130], + type: 'bar' + }, { + data: [20, 40, 90, 40, 30, 70, 120], + type: 'bar' + }, { + data: [140, 230, 120, 50, 30, 150, 120], + type: 'bar' + }], + aria: { + enabled: true, + decal: { + show: true + } + } +}; diff --git a/testdata/doc-example/aria-decal.js b/testdata/doc-example/aria-decal.js new file mode 100644 index 0000000..6923e1d --- /dev/null +++ b/testdata/doc-example/aria-decal.js @@ -0,0 +1,121 @@ +"use strict"; +var decalColor = 'rgba(0, 0, 0, 0.8)'; +var svg = 'M136.71078,90.7149424 C135.038663,90.084817 133.319214,89.8204828 131.637995,89.8987366 C131.93792,88.5693311 132.022117,87.2371959 131.901965,85.9319035 C131.475516,81.1970909 128.414369,76.8944942 123.681104,75.0882862 C118.812669,73.2488659 113.532803,74.556888 110.072058,78.0014222 C111.44425,78.0132512 112.836467,78.2716709 114.184082,78.7876003 C120.385569,81.1311211 123.498145,88.0593162 121.156545,94.2582038 C120.289538,96.5421242 118.80038,98.4052027 116.960324,99.7405227 C113.796773,102.011704 109.591905,102.714169 105.683776,101.228711 C99.4827445,98.8915594 96.3669821,91.9606345 98.7113134,85.7581072 C99.0176102,84.9537305 99.4044636,84.2007647 99.8609505,83.4869258 L99.8545788,83.4869258 C99.8545788,83.4869258 99.8545788,83.4869258 99.8545788,83.4932953 C101.850742,80.3754255 103.561544,76.9968612 104.927364,73.3990041 C115.528966,45.4164295 101.427934,14.127175 73.4261234,3.52605368 C45.4215819,-7.07142797 14.1333382,7.02472855 3.52900521,35.0104878 C0.629425582,42.6470623 -0.42099504,50.523403 0.149272308,58.1686218 C0.16110547,58.4206719 0.185226914,58.6786366 0.209348358,58.9366014 C2.47266801,84.9182432 19.2184117,108.595036 45.2413538,118.442737 C71.7121355,128.45559 100.448968,121.413198 119.352898,102.762395 C122.585626,99.6263266 127.465895,98.4657129 131.950208,100.160455 C137.34704,102.203699 140.39954,107.712861 139.559386,113.191995 C141.579216,111.769777 143.215378,109.750646 144.163851,107.256987 C146.676122,100.628613 143.33553,93.2204304 136.71078,90.7149424 ZZ'; +var base64 = 'image://data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAJ8AAAClCAYAAABC+i8rAAAAAXNSR0IArs4c6QAAAERlWElmTU0AKgAAAAgAAYdpAAQAAAABAAAAGgAAAAAAA6ABAAMAAAABAAEAAKACAAQAAAABAAAAn6ADAAQAAAABAAAApQAAAACQfA6rAAAc5klEQVR4Ae1dC3xcRb2eObtJNiUJ0EKBgtAUUFDE9u6m5WkLWqAlm/em5aLcSkGrCApeHipqfHERQbCUIvSCD1Dp5p3UalFsoUBvmgQBxYtUkhZKqy2l2FceuzvjN9vs9uwme/ac3bOPszvn90t2zpz//Oc/33xnXmcelOTQtXbO1WUH/PvOJZTORLLKKeFTOSEncM6nUkLh5mWUUkY4CRCKv+AvH4XsDkLodsrJdk75dkqUt7mNvupZMOt12tTEcgiirEoKzSprDBrT5qo9x098C0Cc8wjhM0GmcpDNvDRRsg+k7QV5NyuU9tgU+/N1m9v3GDRTisdAwLyMihGBmd7rLvv0Ufvee/+TINhC/C0gnH/ATP3xdFFK/OD2s/htU1hBe31/2854YeTz2AhYgnwts6tcjPHrkYyrUAqVxk5O+p4AOI4ydhPndHWpvexnC3t+uS99sedGTFlLPu88Twk9OHwNyHY950S04bL2QjtyP0rhxwuI/cHa/o43s9bQLDMs68jX7XRPGqL8BpQot6FwOS7L8IpjDmWU8jVUsd3r2dy5MY5w3j/OGvKtn7fEsevAns8jR25HKXKC1XMG7cIuu1JwKzoob1g9LamyPyvI11xRVccZW45OxMmpSmhm9FIfhntWksLi7zRuan4vMzZkb6wZJZ/3fM/JfH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6ixGp2uTuRsnDHAu9iQuQT1TiwewSKvxKKE9gtRkl6Z/2LbdtCfun4PX73UQW72JCwJbELxY86t8ERvJ+2B5T6zd1rcNOemNbxodDbjRjnKyywiV4o2kNmXPTdKZNmPWOGJi0dbefVng24zlXLgES/Vt/HcqOpEVX1kpleV9WHYslr+dNCx/1o+4VnnYg2Iwaow2TUCpvNz9ARXSHOlcMLjaGR0uJr8IsSKtmL+hyMBL95hjTV/l/HVqw7uALV+z9Cfgn/omFv9DTrROLy+/zhjsJY+L1sevE6PbpmkBOfhlzEy4aDZaL16VFFUJK+gy8ZES8zcmtpt9N9nC4FWSiETsaqxt6uLwnTgsMIjRuaD+Co9Fq08+pQP2MiF90qikajtiPMOnd/97vR4Rr7OjZPcpR9GG/xd6D/BTSU9kXL6LkPNezF6T7Q1RP6Q9jwOJkePUIGtr4eCi9+8Z30yHgciezl4sVs0zuo6+p/1Cfk1XagNEyIfEIHxifuga0jsHFU/MHLjuOOTF0opLbVbLfgEfAYBOIdsP9iT/+az+I+yK1/Awz+VK7/QH61AAAAAElFTkSuQmCC'; +var decals = [{ + color: decalColor, + dashArrayX: [1, 0], + dashArrayY: [2, 5], + symbolSize: 1, + rotation: Math.PI / 6 + }, { + color: decalColor, + symbol: 'circle', + dashArrayX: [[8, 8], [0, 8, 8, 0]], + dashArrayY: [6, 0], + symbolSize: 0.8 + }, { + color: decalColor, + dashArrayX: [1, 0], + dashArrayY: [4, 3], + rotation: -Math.PI / 4 + }, { + color: decalColor, + dashArrayX: [[6, 6], [0, 6, 6, 0]], + dashArrayY: [6, 0] + }, { + color: decalColor, + dashArrayX: [[1, 0], [1, 6]], + dashArrayY: [1, 0, 6, 0], + rotation: Math.PI / 4 + }, { + color: decalColor, + symbol: 'triangle', + dashArrayX: [[9, 9], [0, 9, 9, 0]], + dashArrayY: [7, 2], + symbolSize: 0.75 + }, { + color: decalColor, + dashArrayX: [1, 0], + dashArrayY: 10, + rotation: 0 + }, { + color: decalColor, + dashArrayX: [10, 10], + dashArrayY: [1, 0], + rotation: 0 + }, { + color: decalColor, + dashArrayX: [10, 5, 20, 5], + dashArrayY: 10, + rotation: 0 + }, { + color: decalColor, + dashArrayX: [[10, 5, 20, 5], [20, 5]], + dashArrayY: [10, 5], + rotation: 0 + }, { + symbol: 'rect', + dashArrayX: [[8, 8], [0, 8, 8, 0]], + dashArrayY: [8, 0], + symbolSize: 0.8, + rotation: Math.PI / 4, + color: 'black' + }, { + color: decalColor, + dashArrayX: [[30, 30], [0, 30, 30, 0]], + dashArrayY: [15, 0], + symbol: 'path://' + svg + // }, { + // color: decalColor, + // dashArrayX: [[30, 30], [0, 30, 30, 0]], + // dashArrayY: [30, 0], + // symbol: base64, + // symbolSize: 0.8 + }]; +var columns = 6; +var rows = Math.floor(decals.length / columns) + 1; +function renderItem(params, api) { + var paletteColor = api.visual('color'); + var paletteDecal = api.visual('decal'); + return { + type: 'group', + x: (api.value(0) % columns) * 120 + 50, + y: Math.floor(api.value(0) / columns) * 120 + 50, + children: [{ + type: 'rect', + shape: { x: 0, y: 0, width: 100, height: 100 }, + style: { fill: paletteColor, decal: paletteDecal }, + }] + }; +} +option = { + xAxis: { + type: 'value', + max: 1, + show: false + }, + yAxis: { + type: 'value', + show: false + }, + series: (function () { + var series = []; + for (var i = 0; i < decals.length; ++i) { + series.push({ + type: 'custom', + data: [[i]], + renderItem: renderItem + }); + } + return series; + })(), + aria: { + enabled: true, + decal: { + show: true, + decals: decals + } + }, + color: ['#ddd'] +}; diff --git a/testdata/doc-example/aria-pie.js b/testdata/doc-example/aria-pie.js new file mode 100644 index 0000000..a569b8a --- /dev/null +++ b/testdata/doc-example/aria-pie.js @@ -0,0 +1,23 @@ +"use strict"; +option = { + aria: { + enabled: true + }, + title: { + text: '某站点用户访问来源', + left: 'center' + }, + series: [ + { + name: '访问来源', + type: 'pie', + data: [ + { value: 335, name: '直接访问' }, + { value: 310, name: '邮件营销' }, + { value: 234, name: '联盟广告' }, + { value: 135, name: '视频广告' }, + { value: 1548, name: '搜索引擎' } + ] + } + ] +}; diff --git a/testdata/doc-example/axisPointer-handle-image.js b/testdata/doc-example/axisPointer-handle-image.js new file mode 100644 index 0000000..7c78864 --- /dev/null +++ b/testdata/doc-example/axisPointer-handle-image.js @@ -0,0 +1,505 @@ +"use strict"; +option = { + "tooltip": { + "alwaysShowContent": true + }, + "legend": { + "tooltip": { + "show": true + }, + "data": [ + "line10.63891", + "line20.63891", + "line30.63891", + "line10.54970", + "line20.54970", + "line30.54970" + ] + }, + "grid": [ + { + "left": 120, + "top": 90, + "height": 150, + "right": 120, + "id": "grid0.63891" + }, + { + "left": 120, + "top": 400, + "height": 150, + "right": 120, + "id": "grid0.54970" + } + ], + "xAxis": [ + { + "id": "xAxis0.63891", + "gridId": "grid0.63891", + "type": "value", + "splitArea": { + "show": true + }, + "axisPointer": { + "handle": { + "show": true + }, + "snap": true, + "value": 600 + } + }, + { + "id": "xAxis0.54970", + "gridId": "grid0.54970", + "type": "value", + "splitArea": { + "show": true + }, + "position": "top", + "axisPointer": { + "handle": { + "show": true, + "icon": "image://http://echarts.baidu.com/images/favicon.png" + }, + "snap": true, + "value": 600 + } + } + ], + "yAxis": [ + { + "id": "yAxis0.63891", + "gridId": "grid0.63891", + "nameLocation": "middle", + "nameGap": 40, + "axisPointer": { + "handle": { + "show": true, + "margin": 70 + } + } + }, + { + "id": "yAxis0.54970", + "gridId": "grid0.54970", + "nameLocation": "middle", + "nameGap": 40, + "inverse": true, + "position": "right", + "axisLine": { + "onZero": false + }, + "axisPointer": { + "handle": { + "show": true, + "icon": "image://http://echarts.baidu.com/images/favicon.png", + "margin": 70 + } + } + } + ], + "series": [ + { + "id": "scatter1-id0.63891", + "name": "scatter10.63891", + "xAxisId": "xAxis0.63891", + "yAxisId": "yAxis0.63891", + "type": "scatter", + "symbolSize": 10, + "data": [ + [ + "-", + "-" + ], + [ + "915.64", + "-0.885" + ], + [ + "318.86", + "-0.718" + ], + [ + "731.00", + "-1.278" + ], + [ + "117.95", + "-0.503" + ], + [ + "165.59", + "-0.495" + ], + [ + "-", + "-" + ], + [ + "923.67", + "-1.186" + ], + [ + "620.87", + "-0.582" + ], + [ + "613.80", + "-1.000" + ], + [ + "631.36", + "-0.810" + ], + [ + "411.87", + "-0.562" + ], + [ + "-", + "-" + ] + ], + "smooth": true, + "connectNulls": true + }, + { + "id": "scatter2-id0.63891", + "name": "scatter20.63891", + "xAxisId": "xAxis0.63891", + "yAxisId": "yAxis0.63891", + "type": "scatter", + "symbolSize": 10, + "data": [ + [ + "-", + "-" + ], + [ + "761.85", + "2.070" + ], + [ + "885.98", + "2.468" + ], + [ + "340.89", + "2.334" + ], + [ + "397.43", + "1.867" + ], + [ + "926.59", + "1.920" + ], + [ + "-", + "-" + ], + [ + "645.14", + "0.913" + ], + [ + "178.72", + "1.133" + ], + [ + "912.58", + "0.597" + ], + [ + "190.59", + "1.050" + ], + [ + "946.08", + "0.491" + ], + [ + "-", + "-" + ] + ], + "connectNulls": true, + "smooth": true + }, + { + "id": "scatter3-id0.63891", + "name": "scatter30.63891", + "xAxisId": "xAxis0.63891", + "yAxisId": "yAxis0.63891", + "type": "scatter", + "symbolSize": 10, + "symbol": "circle", + "data": [ + [ + "-", + "-" + ], + [ + "42.21", + "0.205" + ], + [ + "232.49", + "0.995" + ], + [ + "610.14", + "0.516" + ], + [ + "44.03", + "0.228" + ], + [ + "870.30", + "0.468" + ], + [ + "-", + "-" + ], + [ + "831.77", + "0.860" + ], + [ + "581.28", + "0.453" + ], + [ + "819.39", + "0.317" + ], + [ + "282.70", + "0.877" + ], + [ + "515.71", + "0.429" + ], + [ + "-", + "-" + ] + ], + "label": { + "normal": { + "show": true, + "textStyle": { + "color": "#333" + } + } + }, + "connectNulls": true, + "smooth": true + }, + { + "id": "scatter1-id0.54970", + "name": "scatter10.54970", + "xAxisId": "xAxis0.54970", + "yAxisId": "yAxis0.54970", + "type": "scatter", + "symbolSize": 10, + "data": [ + [ + "-", + "-" + ], + [ + "763.44", + "-0.916" + ], + [ + "505.52", + "-0.737" + ], + [ + "280.73", + "-1.397" + ], + [ + "490.35", + "-0.661" + ], + [ + "645.96", + "-0.580" + ], + [ + "-", + "-" + ], + [ + "488.98", + "-0.650" + ], + [ + "433.71", + "-0.359" + ], + [ + "467.77", + "-0.409" + ], + [ + "929.08", + "-0.643" + ], + [ + "474.34", + "-0.421" + ], + [ + "-", + "-" + ] + ], + "smooth": true, + "connectNulls": true + }, + { + "id": "scatter2-id0.54970", + "name": "scatter20.54970", + "xAxisId": "xAxis0.54970", + "yAxisId": "yAxis0.54970", + "type": "scatter", + "symbolSize": 10, + "data": [ + [ + "-", + "-" + ], + [ + "691.37", + "2.368" + ], + [ + "778.30", + "2.102" + ], + [ + "976.10", + "2.725" + ], + [ + "889.06", + "2.037" + ], + [ + "622.41", + "2.111" + ], + [ + "-", + "-" + ], + [ + "365.56", + "0.952" + ], + [ + "492.75", + "0.708" + ], + [ + "141.85", + "0.826" + ], + [ + "832.20", + "1.223" + ], + [ + "373.60", + "0.651" + ], + [ + "-", + "-" + ] + ], + "connectNulls": true, + "smooth": true + }, + { + "id": "scatter3-id0.54970", + "name": "scatter30.54970", + "xAxisId": "xAxis0.54970", + "yAxisId": "yAxis0.54970", + "type": "scatter", + "symbolSize": 10, + "symbol": "circle", + "data": [ + [ + "-", + "-" + ], + [ + "886.38", + "0.812" + ], + [ + "852.70", + "0.507" + ], + [ + "572.48", + "1.008" + ], + [ + "331.00", + "0.527" + ], + [ + "317.95", + "0.841" + ], + [ + "-", + "-" + ], + [ + "267.26", + "1.199" + ], + [ + "315.98", + "0.531" + ], + [ + "269.14", + "0.847" + ], + [ + "532.92", + "0.699" + ], + [ + "522.15", + "0.254" + ], + [ + "-", + "-" + ] + ], + "label": { + "normal": { + "show": true, + "textStyle": { + "color": "#333" + } + } + }, + "connectNulls": true, + "smooth": true + } + ] +}; diff --git a/testdata/doc-example/axisPointer-handle-image.js.svg b/testdata/doc-example/axisPointer-handle-image.js.svg new file mode 100644 index 0000000..4994b51 --- /dev/null +++ b/testdata/doc-example/axisPointer-handle-image.js.svg @@ -0,0 +1,978 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +-2 +-1 +0 +1 +2 +3 +-2 +-1 +0 +1 +2 +3 +0 +200 +400 +600 +800 +1,000 +0 +200 +400 +600 +800 +1,000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +0.205 +0.995 +0.516 +0.228 +0.468 +0.860 +0.453 +0.317 +0.877 +0.429 +0.812 +0.507 +1.008 +0.527 +0.841 +1.199 +0.531 +0.847 +0.699 +0.254 + + + + + + + + + + +3.00 + +3.00 + +600.00 + +600.00 + + + + + + + + + + \ No newline at end of file diff --git a/testdata/doc-example/bar-dataZoom-filterMode.js b/testdata/doc-example/bar-dataZoom-filterMode.js new file mode 100644 index 0000000..d7ead03 --- /dev/null +++ b/testdata/doc-example/bar-dataZoom-filterMode.js @@ -0,0 +1,78 @@ +"use strict"; +myChart.showLoading(); +$.get(ROOT_PATH + '/data/asset/data/obama_budget_proposal_2012.list.json', function (obama_budget_2012) { + myChart.hideLoading(); + option = { + tooltip: { + trigger: 'item' + }, + legend: { + data: ['Growth', 'Budget 2011', 'Budget 2012'], + itemGap: 5 + }, + grid: { + top: '12%', + left: '1%', + right: '10%', + containLabel: true + }, + xAxis: [ + { + type: 'category', + data: obama_budget_2012.names + } + ], + yAxis: [ + { + type: 'value', + name: 'Budget (million USD)', + axisLabel: { + formatter: function (a) { + a = +a; + return isFinite(a) + ? echarts.format.addCommas(+a / 1000) + : ''; + } + } + } + ], + dataZoom: [ + { + type: 'slider', + show: true, + start: 94, + end: 100, + handleSize: 8 + }, + { + type: 'inside', + start: 94, + end: 100 + }, + { + type: 'slider', + show: true, + yAxisIndex: 0, + filterMode: 'empty', + width: 12, + height: '70%', + handleSize: 8, + showDataShadow: false, + left: '93%' + } + ], + series: [ + { + name: 'Budget 2011', + type: 'bar', + data: obama_budget_2012.budget2011List + }, + { + name: 'Budget 2012', + type: 'bar', + data: obama_budget_2012.budget2012List + } + ] + }; + myChart.setOption(option); +}); diff --git a/testdata/doc-example/bar-large.js b/testdata/doc-example/bar-large.js new file mode 100644 index 0000000..d9f8f79 --- /dev/null +++ b/testdata/doc-example/bar-large.js @@ -0,0 +1,57 @@ +"use strict"; +var xAxisData = []; +var data1 = []; +var data2 = []; +for (var i = 0; i < 2000; i++) { + xAxisData.push('类目' + i); + data1.push((Math.sin(i / 50) * (i / 50 - 100) + i / 20) * 50); + data2.push((Math.cos(i / 50) * (i / 50 - 100) + i / 20) * 50); +} +option = { + title: { + text: '柱状图动画延迟' + }, + legend: { + data: ['bar', 'bar2'], + align: 'left' + }, + toolbox: { + feature: { + magicType: { + type: ['stack', 'tiled'] + }, + dataView: {}, + saveAsImage: { + pixelRatio: 2 + } + } + }, + tooltip: {}, + xAxis: { + data: xAxisData, + silent: false, + splitLine: { + show: false + } + }, + yAxis: {}, + series: [{ + name: 'bar', + type: 'bar', + data: data1, + animationDelay: function (idx) { + return idx * 5; + } + }, { + name: 'bar2', + type: 'bar', + data: data2, + animationDelay: function (idx) { + return idx * 5 + 100; + } + }], + animationEasing: 'elasticOut', + animationDelayUpdate: function (idx) { + return idx * 5; + } +}; diff --git a/testdata/doc-example/bar-large.js.svg b/testdata/doc-example/bar-large.js.svg new file mode 100644 index 0000000..9aa4e4d --- /dev/null +++ b/testdata/doc-example/bar-large.js.svg @@ -0,0 +1,48043 @@ + + + + + + + + + + + + + + + + + + + + + +-6,000 +-3,000 +0 +3,000 +6,000 +9,000 +类目0 +类目195 +类目390 +类目585 +类目780 +类目975 +类目1170 +类目1365 +类目1560 +类目1755 +类目1950 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +bar + +bar2 + + + + + +柱状图动画延迟 + + \ No newline at end of file diff --git a/testdata/doc-example/bar-media-timeline.js b/testdata/doc-example/bar-media-timeline.js new file mode 100644 index 0000000..25b1084 --- /dev/null +++ b/testdata/doc-example/bar-media-timeline.js @@ -0,0 +1,339 @@ +"use strict"; +$.when($.getScript(ROOT_PATH + '/data/asset/data/timelineGDP.js'), $.getScript(ROOT_PATH + '/data/asset/data/draggable.js')).done(function () { + draggable.init($('div[_echarts_instance_]')[0], myChart, { + width: 700, + height: 630, + lockY: true, + throttle: 70 + }); + myChart.hideLoading(); + var categoryData = [ + '北京', '天津', '河北', '山西', '内蒙古', '辽宁', '吉林', '黑龙江', + '上海', '江苏', '浙江', '安徽', '福建', '江西', '山东', '河南', + '湖北', '湖南', '广东', '广西', '海南', '重庆', '四川', '贵州', + '云南', '西藏', '陕西', '甘肃', '青海', '宁夏', '新疆' + ]; + option = { + baseOption: { + timeline: { + axisType: 'category', + autoPlay: true, + playInterval: 1000, + data: [ + '2002-01-01', '2003-01-01', '2004-01-01', + '2005-01-01', '2006-01-01', '2007-01-01', + '2008-01-01', '2009-01-01', '2010-01-01', + '2011-01-01' + ], + label: { + formatter: function (s) { + return (new Date(s)).getFullYear(); + } + } + }, + title: { + subtext: 'Media Query 示例' + }, + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'shadow' + } + }, + xAxis: { + type: 'value', + name: 'GDP(亿元)', + max: 30000, + data: null + }, + yAxis: { + type: 'category', + data: categoryData, + axisLabel: { interval: 0 }, + splitLine: { show: false } + }, + legend: { + data: ['第一产业', '第二产业', '第三产业', 'GDP', '金融', '房地产'], + selected: { + 'GDP': false, '金融': false, '房地产': false + } + }, + calculable: true, + series: [ + { name: 'GDP', type: 'bar' }, + { name: '金融', type: 'bar' }, + { name: '房地产', type: 'bar' }, + { name: '第一产业', type: 'bar' }, + { name: '第二产业', type: 'bar' }, + { name: '第三产业', type: 'bar' }, + { name: 'GDP占比', type: 'pie' } + ] + }, + media: [ + { + option: { + legend: { + orient: 'horizontal', + left: 'right', + itemGap: 10 + }, + grid: { + left: '10%', + top: 80, + right: 90, + bottom: 100 + }, + xAxis: { + nameLocation: 'end', + nameGap: 10, + splitNumber: 5, + splitLine: { + show: true + } + }, + timeline: { + orient: 'horizontal', + inverse: false, + left: '20%', + right: '20%', + bottom: 10, + height: 40 + }, + series: [ + { name: 'GDP占比', center: ['75%', '30%'], radius: '28%' } + ] + } + }, + { + query: { maxWidth: 670, minWidth: 550 }, + option: { + legend: { + orient: 'horizontal', + left: 200, + itemGap: 5 + }, + grid: { + left: '10%', + top: 80, + right: 90, + bottom: 100 + }, + xAxis: { + nameLocation: 'end', + nameGap: 10, + splitNumber: 5, + splitLine: { + show: true + } + }, + timeline: { + orient: 'horizontal', + inverse: false, + left: '20%', + right: '20%', + bottom: 10, + height: 40 + }, + series: [ + { name: 'GDP占比', center: ['75%', '30%'], radius: '28%' } + ] + } + }, + { + query: { maxWidth: 550 }, + option: { + legend: { + orient: 'vertical', + left: 'right', + itemGap: 5 + }, + grid: { + left: 55, + top: '32%', + right: 100, + bottom: 50 + }, + xAxis: { + nameLocation: 'middle', + nameGap: 25, + splitNumber: 3 + }, + timeline: { + orient: 'vertical', + inverse: true, + right: 10, + top: 150, + bottom: 10, + width: 55 + }, + series: [ + { name: 'GDP占比', center: ['45%', '20%'], radius: '28%' } + ] + } + } + ], + options: [ + { + title: { text: '2002全国宏观经济指标' }, + series: [ + { data: dataMap.dataGDP['2002'] }, + { data: dataMap.dataFinancial['2002'] }, + { data: dataMap.dataEstate['2002'] }, + { data: dataMap.dataPI['2002'] }, + { data: dataMap.dataSI['2002'] }, + { data: dataMap.dataTI['2002'] }, + { data: [ + { name: '第一产业', value: dataMap.dataPI['2002sum'] }, + { name: '第二产业', value: dataMap.dataSI['2002sum'] }, + { name: '第三产业', value: dataMap.dataTI['2002sum'] } + ] } + ] + }, + { + title: { text: '2003全国宏观经济指标' }, + series: [ + { data: dataMap.dataGDP['2003'] }, + { data: dataMap.dataFinancial['2003'] }, + { data: dataMap.dataEstate['2003'] }, + { data: dataMap.dataPI['2003'] }, + { data: dataMap.dataSI['2003'] }, + { data: dataMap.dataTI['2003'] }, + { data: [ + { name: '第一产业', value: dataMap.dataPI['2003sum'] }, + { name: '第二产业', value: dataMap.dataSI['2003sum'] }, + { name: '第三产业', value: dataMap.dataTI['2003sum'] } + ] } + ] + }, + { + title: { text: '2004全国宏观经济指标' }, + series: [ + { data: dataMap.dataGDP['2004'] }, + { data: dataMap.dataFinancial['2004'] }, + { data: dataMap.dataEstate['2004'] }, + { data: dataMap.dataPI['2004'] }, + { data: dataMap.dataSI['2004'] }, + { data: dataMap.dataTI['2004'] }, + { data: [ + { name: '第一产业', value: dataMap.dataPI['2004sum'] }, + { name: '第二产业', value: dataMap.dataSI['2004sum'] }, + { name: '第三产业', value: dataMap.dataTI['2004sum'] } + ] } + ] + }, + { + title: { text: '2005全国宏观经济指标' }, + series: [ + { data: dataMap.dataGDP['2005'] }, + { data: dataMap.dataFinancial['2005'] }, + { data: dataMap.dataEstate['2005'] }, + { data: dataMap.dataPI['2005'] }, + { data: dataMap.dataSI['2005'] }, + { data: dataMap.dataTI['2005'] }, + { data: [ + { name: '第一产业', value: dataMap.dataPI['2005sum'] }, + { name: '第二产业', value: dataMap.dataSI['2005sum'] }, + { name: '第三产业', value: dataMap.dataTI['2005sum'] } + ] } + ] + }, + { + title: { text: '2006全国宏观经济指标' }, + series: [ + { data: dataMap.dataGDP['2006'] }, + { data: dataMap.dataFinancial['2006'] }, + { data: dataMap.dataEstate['2006'] }, + { data: dataMap.dataPI['2006'] }, + { data: dataMap.dataSI['2006'] }, + { data: dataMap.dataTI['2006'] }, + { data: [ + { name: '第一产业', value: dataMap.dataPI['2006sum'] }, + { name: '第二产业', value: dataMap.dataSI['2006sum'] }, + { name: '第三产业', value: dataMap.dataTI['2006sum'] } + ] } + ] + }, + { + title: { text: '2007全国宏观经济指标' }, + series: [ + { data: dataMap.dataGDP['2007'] }, + { data: dataMap.dataFinancial['2007'] }, + { data: dataMap.dataEstate['2007'] }, + { data: dataMap.dataPI['2007'] }, + { data: dataMap.dataSI['2007'] }, + { data: dataMap.dataTI['2007'] }, + { data: [ + { name: '第一产业', value: dataMap.dataPI['2007sum'] }, + { name: '第二产业', value: dataMap.dataSI['2007sum'] }, + { name: '第三产业', value: dataMap.dataTI['2007sum'] } + ] } + ] + }, + { + title: { text: '2008全国宏观经济指标' }, + series: [ + { data: dataMap.dataGDP['2008'] }, + { data: dataMap.dataFinancial['2008'] }, + { data: dataMap.dataEstate['2008'] }, + { data: dataMap.dataPI['2008'] }, + { data: dataMap.dataSI['2008'] }, + { data: dataMap.dataTI['2008'] }, + { data: [ + { name: '第一产业', value: dataMap.dataPI['2008sum'] }, + { name: '第二产业', value: dataMap.dataSI['2008sum'] }, + { name: '第三产业', value: dataMap.dataTI['2008sum'] } + ] } + ] + }, + { + title: { text: '2009全国宏观经济指标' }, + series: [ + { data: dataMap.dataGDP['2009'] }, + { data: dataMap.dataFinancial['2009'] }, + { data: dataMap.dataEstate['2009'] }, + { data: dataMap.dataPI['2009'] }, + { data: dataMap.dataSI['2009'] }, + { data: dataMap.dataTI['2009'] }, + { data: [ + { name: '第一产业', value: dataMap.dataPI['2009sum'] }, + { name: '第二产业', value: dataMap.dataSI['2009sum'] }, + { name: '第三产业', value: dataMap.dataTI['2009sum'] } + ] } + ] + }, + { + title: { text: '2010全国宏观经济指标' }, + series: [ + { data: dataMap.dataGDP['2010'] }, + { data: dataMap.dataFinancial['2010'] }, + { data: dataMap.dataEstate['2010'] }, + { data: dataMap.dataPI['2010'] }, + { data: dataMap.dataSI['2010'] }, + { data: dataMap.dataTI['2010'] }, + { data: [ + { name: '第一产业', value: dataMap.dataPI['2010sum'] }, + { name: '第二产业', value: dataMap.dataSI['2010sum'] }, + { name: '第三产业', value: dataMap.dataTI['2010sum'] } + ] } + ] + }, + { + title: { text: '2011全国宏观经济指标' }, + series: [ + { data: dataMap.dataGDP['2011'] }, + { data: dataMap.dataFinancial['2011'] }, + { data: dataMap.dataEstate['2011'] }, + { data: dataMap.dataPI['2011'] }, + { data: dataMap.dataSI['2011'] }, + { data: dataMap.dataTI['2011'] }, + { data: [ + { name: '第一产业', value: dataMap.dataPI['2011sum'] }, + { name: '第二产业', value: dataMap.dataSI['2011sum'] }, + { name: '第三产业', value: dataMap.dataTI['2011sum'] } + ] } + ] + } + ] + }; + myChart.setOption(option); +}); diff --git a/testdata/doc-example/barGrid-barGap.js b/testdata/doc-example/barGrid-barGap.js new file mode 100644 index 0000000..a997ea3 --- /dev/null +++ b/testdata/doc-example/barGrid-barGap.js @@ -0,0 +1,47 @@ +"use strict"; +option = { + xAxis: { + data: ['a', 'b', 'c', 'd'], + axisTick: { show: false }, + axisLabel: { + formatter: 'barGap: \'-100%\'' + } + }, + yAxis: { + splitLine: { show: false } + }, + animationDurationUpdate: 1200, + series: [{ + type: 'bar', + itemStyle: { + normal: { + color: '#ddd' + } + }, + silent: true, + barWidth: 40, + barGap: '-100%', + data: [60, 60, 60, 60] + }, { + type: 'bar', + barWidth: 40, + z: 10, + data: [45, 60, 13, 25] + }] +}; +var barGaps = ['30%', '-100%']; +var loopIndex = 0; +setInterval(function () { + var barGap = barGaps[loopIndex]; + myChart.setOption({ + xAxis: { + axisLabel: { + formatter: 'barGap: \'' + barGap + '\'' + } + }, + series: [{ + barGap: barGap + }] + }); + loopIndex = (loopIndex + 1) % barGaps.length; +}, 2000); diff --git a/testdata/doc-example/barGrid-barGap.js.svg b/testdata/doc-example/barGrid-barGap.js.svg new file mode 100644 index 0000000..f11fb3a --- /dev/null +++ b/testdata/doc-example/barGrid-barGap.js.svg @@ -0,0 +1,115 @@ + + + +0 +10 +20 +30 +40 +50 +60 +barGap: '-100%' +barGap: '-100%' +barGap: '-100%' +barGap: '-100%' + + + + + + + + + + \ No newline at end of file diff --git a/testdata/doc-example/candlestick-axisPointer.js b/testdata/doc-example/candlestick-axisPointer.js new file mode 100644 index 0000000..c4a73c1 --- /dev/null +++ b/testdata/doc-example/candlestick-axisPointer.js @@ -0,0 +1,235 @@ +"use strict"; +function splitData(rawData) { + var categoryData = []; + var values = []; + var volumns = []; + for (var i = 0; i < rawData.length; i++) { + categoryData.push(rawData[i].splice(0, 1)[0]); + values.push(rawData[i]); + volumns.push(rawData[i][4]); + } + return { + categoryData: categoryData, + values: values, + volumns: volumns + }; +} +function calculateMA(dayCount, data) { + var result = []; + for (var i = 0, len = data.values.length; i < len; i++) { + if (i < dayCount) { + result.push('-'); + continue; + } + var sum = 0; + for (var j = 0; j < dayCount; j++) { + sum += data.values[i - j][1]; + } + result.push(+(sum / dayCount).toFixed(3)); + } + return result; +} +$.get(ROOT_PATH + '/data/asset/data/stock-DJI.json', function (rawData) { + var data = splitData(rawData); + myChart.setOption(option = { + animation: false, + legend: { + bottom: 10, + left: 'center', + data: ['Dow-Jones index', 'MA5', 'MA10', 'MA20', 'MA30'] + }, + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'cross' + }, + backgroundColor: 'rgba(255, 255, 255, 0.8)', + position: function (pos, params, el, elRect, size) { + var obj = { top: 10 }; + obj[['left', 'right'][+(pos[0] < size.viewSize[0] / 2)]] = 30; + return obj; + }, + extraCssText: 'width: 170px' + }, + axisPointer: { + link: { xAxisIndex: 'all' }, + label: { + backgroundColor: '#777' + } + }, + toolbox: { + feature: { + dataZoom: { + yAxisIndex: false + }, + brush: { + type: ['lineX', 'clear'] + } + } + }, + brush: { + xAxisIndex: 'all', + brushLink: 'all', + outOfBrush: { + colorAlpha: 0.1 + } + }, + grid: [ + { + left: '10%', + right: '8%', + height: '50%' + }, + { + left: '10%', + right: '8%', + bottom: '20%', + height: '15%' + } + ], + xAxis: [ + { + type: 'category', + data: data.categoryData, + scale: true, + boundaryGap: false, + axisLine: { onZero: false }, + splitLine: { show: false }, + splitNumber: 20, + min: 'dataMin', + max: 'dataMax', + axisPointer: { + z: 100 + } + }, + { + type: 'category', + gridIndex: 1, + data: data.categoryData, + scale: true, + boundaryGap: false, + axisLine: { onZero: false }, + axisTick: { show: false }, + splitLine: { show: false }, + axisLabel: { show: false }, + splitNumber: 20, + min: 'dataMin', + max: 'dataMax', + axisPointer: { + label: { + formatter: function (params) { + var seriesValue = (params.seriesData[0] || {}).value; + return params.value + + (seriesValue != null + ? '\n' + echarts.format.addCommas(seriesValue) + : ''); + } + } + } + } + ], + yAxis: [ + { + scale: true, + splitArea: { + show: true + } + }, + { + scale: true, + gridIndex: 1, + splitNumber: 2, + axisLabel: { show: false }, + axisLine: { show: false }, + axisTick: { show: false }, + splitLine: { show: false } + } + ], + dataZoom: [ + { + type: 'inside', + xAxisIndex: [0, 1], + start: 98, + end: 100 + }, + { + show: true, + xAxisIndex: [0, 1], + type: 'slider', + top: '85%', + start: 98, + end: 100 + } + ], + series: [ + { + name: 'Dow-Jones index', + type: 'candlestick', + data: data.values, + itemStyle: { + normal: { + color: '#06B800', + color0: '#FA0000', + borderColor: null, + borderColor0: null + } + }, + tooltip: { + formatter: function (param) { + param = param[0]; + return [ + 'Date: ' + param.name + '
', + 'Open: ' + param.data[0] + '
', + 'Close: ' + param.data[1] + '
', + 'Lowest: ' + param.data[2] + '
', + 'Highest: ' + param.data[3] + '
' + ].join(''); + } + } + }, + { + name: 'MA5', + type: 'line', + data: calculateMA(5, data), + smooth: true, + lineStyle: { + normal: { opacity: 0.5 } + } + }, + { + name: 'MA10', + type: 'line', + data: calculateMA(10, data), + smooth: true, + lineStyle: { + normal: { opacity: 0.5 } + } + }, + { + name: 'MA20', + type: 'line', + data: calculateMA(20, data), + smooth: true, + lineStyle: { + normal: { opacity: 0.5 } + } + }, + { + name: 'MA30', + type: 'line', + data: calculateMA(30, data), + smooth: true, + lineStyle: { + normal: { opacity: 0.5 } + } + }, + { + name: 'Volumn', + type: 'bar', + xAxisIndex: 1, + yAxisIndex: 1, + data: data.volumns + } + ] + }, true); +}); diff --git a/testdata/doc-example/canvas-vs-svg-en.js b/testdata/doc-example/canvas-vs-svg-en.js new file mode 100644 index 0000000..d6fd51e --- /dev/null +++ b/testdata/doc-example/canvas-vs-svg-en.js @@ -0,0 +1,118 @@ +"use strict"; +var axisLine = { + lineStyle: { + color: '#888' + } +}; +var themeColor = '#B03A5B'; +option = { + color: ['transparent', themeColor], + legend: { + data: [{ + name: 'Canvas renderer', + icon: 'path://M0,0 L58,0 L58,38 L0,38 L0,0 Z M6,6 L6,32 L53,32 L53,6 L6,6 Z' + }, { + name: 'SVG renderer', + icon: 'rect' + }], + top: 25 + }, + title: [{ + subtext: 'PC', + subtextStyle: { + color: '#666', + fontSize: 15 + }, + left: '21%', + top: 50 + }, { + subtext: 'Mobile', + subtextStyle: { + color: '#666', + fontSize: 15 + }, + left: '73%', + top: 50 + }], + xAxis: [{ + data: ['Line Series\n1000 Datums', 'Bar Series\n1000 Datums', 'Pie Series\n100 Series'], + axisLabel: { + interval: 0 + }, + axisLine: axisLine + }, { + data: ['Line Series\n100 Datums', 'Bar Series\n100 Datums', 'Pie Series\n10 Series'], + axisLabel: { + interval: 0 + }, + gridIndex: 1, + axisLine: axisLine + }], + yAxis: [{ + name: 'FPS', + axisLine: axisLine + }, { + gridIndex: 1, + name: 'FPS', + axisLine: axisLine + }], + grid: [{ + xAxisIndex: 0, + yAxisIndex: 0, + right: '55%', + left: 30, + bottom: 40, + top: 100 + }, { + left: '55%', + right: 10, + bottom: 40, + top: 100 + }], + series: [{ + name: 'Canvas renderer', + type: 'scatter', + data: [], + itemStyle: { + normal: { + color: themeColor + } + } + }, { + name: 'Canvas renderer', + type: 'bar', + data: [30, 58, 19], + itemStyle: { + normal: { + borderWidth: 2, + borderColor: themeColor + } + }, + barGap: '30%', + barCategoryGap: '40%' + }, { + name: 'SVG renderer', + type: 'bar', + data: [60, 32, 38] + }, { + name: 'Canvas renderer', + type: 'bar', + data: [5, 5, 5], + xAxisIndex: 1, + yAxisIndex: 1, + itemStyle: { + normal: { + borderWidth: 2, + borderColor: themeColor + } + }, + barGap: '30%', + barCategoryGap: '40%' + }, { + name: 'SVG renderer', + type: 'bar', + data: [17, 11, 9], + xAxisIndex: 1, + yAxisIndex: 1, + }] +}; diff --git a/testdata/doc-example/canvas-vs-svg-en.js.svg b/testdata/doc-example/canvas-vs-svg-en.js.svg new file mode 100644 index 0000000..0ab9408 --- /dev/null +++ b/testdata/doc-example/canvas-vs-svg-en.js.svg @@ -0,0 +1,212 @@ + + + + + + + + + + + + + + + + +FPS +FPS + + + + + + + + + + +0 +10 +20 +30 +40 +50 +60 +0 +3 +6 +9 +12 +15 +18 +Line Series +1000 Datums +Bar Series +1000 Datums +Pie Series +100 Series +Line Series +100 Datums +Bar Series +100 Datums +Pie Series +10 Series + + + + + + + + + + + + + + +Canvas renderer + +SVG renderer + + +PC +Mobile + + \ No newline at end of file diff --git a/testdata/doc-example/canvas-vs-svg.js b/testdata/doc-example/canvas-vs-svg.js new file mode 100644 index 0000000..df452ca --- /dev/null +++ b/testdata/doc-example/canvas-vs-svg.js @@ -0,0 +1,118 @@ +"use strict"; +var axisLine = { + lineStyle: { + color: '#888' + } +}; +var themeColor = '#B03A5B'; +option = { + color: ['transparent', themeColor], + legend: { + data: [{ + name: 'Canvas 渲染器', + icon: 'path://M0,0 L58,0 L58,38 L0,38 L0,0 Z M6,6 L6,32 L53,32 L53,6 L6,6 Z' + }, { + name: 'SVG 渲染器', + icon: 'rect' + }], + top: 25 + }, + title: [{ + subtext: 'PC端', + subtextStyle: { + color: '#666', + fontSize: 15 + }, + left: '21%', + top: 50 + }, { + subtext: '移动端', + subtextStyle: { + color: '#666', + fontSize: 15 + }, + left: '73%', + top: 50 + }], + xAxis: [{ + data: ['折线图\n1000数据', '柱状图\n1000数据', '饼图\n100系列'], + axisLabel: { + interval: 0 + }, + axisLine: axisLine + }, { + data: ['折线图\n100数据', '柱状图\n100数据', '饼图\n10系列'], + axisLabel: { + interval: 0 + }, + gridIndex: 1, + axisLine: axisLine + }], + yAxis: [{ + name: 'FPS', + axisLine: axisLine + }, { + gridIndex: 1, + name: 'FPS', + axisLine: axisLine + }], + grid: [{ + xAxisIndex: 0, + yAxisIndex: 0, + right: '55%', + left: 30, + bottom: 40, + top: 100 + }, { + left: '55%', + right: 10, + bottom: 40, + top: 100 + }], + series: [{ + name: 'Canvas 渲染器', + type: 'scatter', + data: [], + itemStyle: { + normal: { + color: themeColor + } + } + }, { + name: 'Canvas 渲染器', + type: 'bar', + data: [30, 58, 19], + itemStyle: { + normal: { + borderWidth: 2, + borderColor: themeColor + } + }, + barGap: '30%', + barCategoryGap: '40%' + }, { + name: 'SVG 渲染器', + type: 'bar', + data: [60, 32, 38] + }, { + name: 'Canvas 渲染器', + type: 'bar', + data: [5, 5, 5], + xAxisIndex: 1, + yAxisIndex: 1, + itemStyle: { + normal: { + borderWidth: 2, + borderColor: themeColor + } + }, + barGap: '30%', + barCategoryGap: '40%' + }, { + name: 'SVG 渲染器', + type: 'bar', + data: [17, 11, 9], + xAxisIndex: 1, + yAxisIndex: 1, + }] +}; diff --git a/testdata/doc-example/canvas-vs-svg.js.svg b/testdata/doc-example/canvas-vs-svg.js.svg new file mode 100644 index 0000000..08be8f8 --- /dev/null +++ b/testdata/doc-example/canvas-vs-svg.js.svg @@ -0,0 +1,212 @@ + + + + + + + + + + + + + + + + +FPS +FPS + + + + + + + + + + +0 +10 +20 +30 +40 +50 +60 +0 +3 +6 +9 +12 +15 +18 +折线图 +1000数据 +柱状图 +1000数据 +饼图 +100系列 +折线图 +100数据 +柱状图 +100数据 +饼图 +10系列 + + + + + + + + + + + + + + +Canvas 渲染器 + +SVG 渲染器 + + +PC端 +移动端 + + \ No newline at end of file diff --git a/testdata/doc-example/custom-transition-simple.js b/testdata/doc-example/custom-transition-simple.js new file mode 100644 index 0000000..8063add --- /dev/null +++ b/testdata/doc-example/custom-transition-simple.js @@ -0,0 +1,92 @@ +"use strict"; +option = { + animationDurationUpdate: 1500, + xAxis: { + min: 0, + max: 1 + }, + yAxis: { + min: 0, + max: 1 + }, + series: { + type: 'custom', + renderItem: function renderItem1(params, api) { + var pos = api.coord([api.value(0), api.value(1)]); + var width = 50 + Math.random() * 150; + var height = 50 + Math.random() * 150; + var r = Math.random() * 40; + var fill = echarts.color.random(); + var stroke = '#000'; + var lineWidth = 2 + Math.round(Math.random() * 20); + return { + type: 'group', + children: [{ + type: 'rect', + x: pos[0] / 2, + y: pos[1], + shape: { + x: -width / 2, + y: -height / 2, + width: width, + height: height, + r: r + }, + style: { + fill: fill, + stroke: stroke, + lineWidth: lineWidth + }, + textContent: { + style: { + text: 'Has transition', + fontSize: 20 + } + }, + textConfig: { + position: 'bottom' + }, + silent: true, + // Has transition + transition: ['shape', 'style', 'x', 'y'] + }, { + type: 'rect', + x: pos[0] / 2 + params.coordSys.width / 2, + y: pos[1], + shape: { + x: -width / 2, + y: -height / 2, + width: width, + height: height, + r: r + }, + style: { + fill: fill, + stroke: stroke, + lineWidth: lineWidth + }, + textContent: { + style: { + text: 'No transition', + fontSize: 20 + } + }, + textConfig: { + position: 'bottom' + }, + silent: true, + // No transition + transition: [] + }] + }; + }, + data: [[Math.random(), Math.random()]] + } +}; +setInterval(function () { + myChart.setOption({ + series: { + data: [[Math.random(), Math.random()]] + } + }); +}, 2000); diff --git a/testdata/doc-example/custom-transition-simple.js.svg b/testdata/doc-example/custom-transition-simple.js.svg new file mode 100644 index 0000000..3c15612 --- /dev/null +++ b/testdata/doc-example/custom-transition-simple.js.svg @@ -0,0 +1,41 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +0 +0.2 +0.4 +0.6 +0.8 +1 +0 +0.2 +0.4 +0.6 +0.8 +1 + \ No newline at end of file diff --git a/testdata/doc-example/data-transform-multiple-sort-bar.js b/testdata/doc-example/data-transform-multiple-sort-bar.js new file mode 100644 index 0000000..6057bee --- /dev/null +++ b/testdata/doc-example/data-transform-multiple-sort-bar.js @@ -0,0 +1,51 @@ +"use strict"; +option = { + dataset: [{ + dimensions: ['name', 'age', 'profession', 'score', 'date'], + source: [ + [' Hannah Krause ', 41, 'Engineer', 314, '2011-02-12'], + ['Zhao Qian ', 20, 'Teacher', 351, '2011-03-01'], + [' Jasmin Krause ', 52, 'Musician', 287, '2011-02-14'], + ['Li Lei', 37, 'Teacher', 219, '2011-02-18'], + [' Karle Neumann ', 25, 'Engineer', 253, '2011-04-02'], + [' Adrian Groß', 19, 'Teacher', null, '2011-01-16'], + ['Mia Neumann', 71, 'Engineer', 165, '2011-03-19'], + [' Böhm Fuchs', 36, 'Musician', 318, '2011-02-24'], + ['Han Meimei ', 67, 'Engineer', 366, '2011-03-12'], + ] + }, { + transform: { + type: 'sort', + config: [ + { dimension: 'profession', order: 'desc' }, + { dimension: 'score', order: 'desc' } + ] + } + }], + xAxis: { + type: 'category', + axisLabel: { interval: 0, rotate: 30 }, + }, + yAxis: {}, + series: { + type: 'bar', + label: { + show: true, + rotate: 90, + position: 'insideBottom', + align: 'left', + verticalAlign: 'middle' + }, + itemStyle: { + color: function (params) { + return ({ + Engineer: '#5470c6', + Teacher: '#91cc75', + Musician: '#fac858' + })[params.data[2]]; + } + }, + encode: { x: 'name', y: 'score', label: ['profession'] }, + datasetIndex: 1 + } +}; diff --git a/testdata/doc-example/data-transform-multiple-sort-bar.js.svg b/testdata/doc-example/data-transform-multiple-sort-bar.js.svg new file mode 100644 index 0000000..bfec4a4 --- /dev/null +++ b/testdata/doc-example/data-transform-multiple-sort-bar.js.svg @@ -0,0 +1,141 @@ + + + + + + + + + + + + + + + + + + +0 +100 +200 +300 +400 +Zhao Qian +Li Lei + Adrian Groß + Böhm Fuchs + Jasmin Krause +Han Meimei + Hannah Krause + Karle Neumann +Mia Neumann + + + + + + + + +Teacher +Teacher +Musician +Musician +Engineer +Engineer +Engineer +Engineer + + \ No newline at end of file diff --git a/testdata/doc-example/dataset-encode-simple0.js b/testdata/doc-example/dataset-encode-simple0.js new file mode 100644 index 0000000..d2f86d3 --- /dev/null +++ b/testdata/doc-example/dataset-encode-simple0.js @@ -0,0 +1,31 @@ +"use strict"; +option = { + dataset: { + source: [ + ['score', 'amount', 'product'], + [89.3, 58212, 'Matcha Latte'], + [57.1, 78254, 'Milk Tea'], + [74.4, 41032, 'Cheese Cocoa'], + [50.1, 12755, 'Cheese Brownie'], + [89.7, 20145, 'Matcha Cocoa'], + [68.1, 79146, 'Tea'], + [19.6, 91852, 'Orange Juice'], + [10.6, 101852, 'Lemon Juice'], + [32.7, 20112, 'Walnut Brownie'] + ] + }, + grid: { containLabel: true }, + xAxis: {}, + yAxis: { type: 'category' }, + series: [ + { + type: 'bar', + encode: { + // Map the "amount" column to X axis. + x: 'amount', + // Map the "product" column to Y axis + y: 'product' + } + } + ] +}; diff --git a/testdata/doc-example/dataset-encode-simple0.js.svg b/testdata/doc-example/dataset-encode-simple0.js.svg new file mode 100644 index 0000000..454b2ca --- /dev/null +++ b/testdata/doc-example/dataset-encode-simple0.js.svg @@ -0,0 +1,149 @@ + + + + + + + + + + + + + + + + + + + + +Matcha Latte +Milk Tea +Cheese Cocoa +Cheese Brownie +Matcha Cocoa +Tea +Orange Juice +Lemon Juice +Walnut Brownie +0 +20,000 +40,000 +60,000 +80,000 +100,000 +120,000 + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/doc-example/geo-svg-label-basic.js b/testdata/doc-example/geo-svg-label-basic.js new file mode 100644 index 0000000..4418e93 --- /dev/null +++ b/testdata/doc-example/geo-svg-label-basic.js @@ -0,0 +1,41 @@ +"use strict"; +var svg = ` + + + + + + + + +`; +echarts.registerMap('simple_svg', { svg: svg }); +option = { + geo: { + map: 'simple_svg', + regions: [{ + name: 'name_a', + label: { + formatter: [ + 'This two rects are wrapped in a ', + 'So a single label is displayed in the center', + 'of the bounding rect of the ' + ].join('\n'), + backgroundColor: 'rgba(0,0,0,0.2)', + padding: 5 + } + }, { + name: 'name_b', + label: { + formatter: [ + 'This two rects are named', + 'with the same name.', + 'So each of them has a label.' + ].join('\n'), + backgroundColor: 'rgba(0,0,0,0.2)', + padding: 5 + } + }] + } +}; diff --git a/testdata/doc-example/geo-svg-layout-basic.js b/testdata/doc-example/geo-svg-layout-basic.js new file mode 100644 index 0000000..c309d09 --- /dev/null +++ b/testdata/doc-example/geo-svg-layout-basic.js @@ -0,0 +1,131 @@ +"use strict"; +var svg_noWidthHeight_noViewBox = ` + + + +`; +var svg_noWidthHeight_hasViewBox = ` + + + +`; +var svg_hasWidthHeight_hasViewBox = ` + + + +`; +echarts.registerMap('svg_noWidthHeight_noViewBox', { svg: svg_noWidthHeight_noViewBox }); +echarts.registerMap('svg_noWidthHeight_hasViewBox', { svg: svg_noWidthHeight_hasViewBox }); +echarts.registerMap('svg_hasWidthHeight_hasViewBox', { svg: svg_hasWidthHeight_hasViewBox }); +var WIDTH = 100; +var HEIGHT = 100; +var X_GAP = 120; +var Y_GAP = 120; +var X_START = 40; +var currentLeft = X_START; +var currentTop = 40; +var currentGeoIndex = 0; +option = { + geo: [], + graphic: [] +}; +function addGeoOption(option, optionPartial, labelLines) { + optionPartial.geo.left = currentLeft; + optionPartial.geo.top = currentTop; + optionPartial.geo.width = WIDTH; + optionPartial.geo.height = HEIGHT; + option.geo.push(optionPartial.geo); + labelLines.unshift('{head|geo ' + currentGeoIndex + ':}'); + option.graphic.push({ + type: 'rect', + shape: { x: currentLeft, y: currentTop, width: WIDTH, height: HEIGHT }, + style: { fill: null, stroke: '#000', lineWidth: 2 }, + textContent: { + style: { + text: labelLines.join('\n'), + fontFamily: 'Arial', + fontSize: 12, + align: 'left', + rich: { head: { fill: 'red', lineHeight: 20 } } + } + }, + textConfig: { position: [0, HEIGHT + 10] } + }); + currentLeft += WIDTH + X_GAP; + if (!((currentGeoIndex + 1) % 3)) { + currentLeft = X_START; + currentTop += HEIGHT + Y_GAP; + } + currentGeoIndex++; +} +addGeoOption(option, { + geo: { + map: 'svg_noWidthHeight_noViewBox' + }, +}, [ + '', + '', + '' +]); +addGeoOption(option, { + geo: { + map: 'svg_noWidthHeight_hasViewBox', + } +}, [ + '', + '', + '' +]); +addGeoOption(option, { + geo: { + map: 'svg_hasWidthHeight_hasViewBox', + } +}, [ + '', + '', + '' +]); +addGeoOption(option, { + geo: { + map: 'svg_noWidthHeight_noViewBox', + boundingCoords: [[-50, -50], [150, 150]], + } +}, [ + '', + '', + '', + 'geo.boundingCoords: ', + ' [[-50, -50], [150, 150]]' +]); +addGeoOption(option, { + geo: { + map: 'svg_noWidthHeight_hasViewBox', + boundingCoords: [[-50, -50], [150, 150]], + } +}, [ + '', + '', + '', + 'geo.boundingCoords: ', + ' [[-50, -50], [150, 150]]' +]); +addGeoOption(option, { + geo: { + map: 'svg_hasWidthHeight_hasViewBox', + boundingCoords: [[-50, -50], [150, 150]], + } +}, [ + '', + '', + '', + 'geo.boundingCoords: ', + ' [[-50, -50], [150, 150]]' +]); diff --git a/testdata/doc-example/geo-svg-named-basic.js b/testdata/doc-example/geo-svg-named-basic.js new file mode 100644 index 0000000..5d8bf7a --- /dev/null +++ b/testdata/doc-example/geo-svg-named-basic.js @@ -0,0 +1,13 @@ +"use strict"; +var svg = ` + + + + +`; +echarts.registerMap('simple_svg', { svg: svg }); +option = { + geo: { + map: 'simple_svg' + } +}; diff --git a/testdata/doc-example/getting-started.js b/testdata/doc-example/getting-started.js new file mode 100644 index 0000000..f1bb0e6 --- /dev/null +++ b/testdata/doc-example/getting-started.js @@ -0,0 +1,21 @@ +"use strict"; +option = { + title: { + text: 'ECharts Getting Started Example' + }, + tooltip: {}, + legend: { + data: ['sales'] + }, + xAxis: { + data: ['Shirts', 'Cardigans', 'Chiffons', 'Pants', 'Heels', 'Socks'] + }, + yAxis: {}, + series: [ + { + name: 'sales', + type: 'bar', + data: [5, 20, 36, 10, 10, 20] + } + ] +}; diff --git a/testdata/doc-example/getting-started.js.svg b/testdata/doc-example/getting-started.js.svg new file mode 100644 index 0000000..4ad12f8 --- /dev/null +++ b/testdata/doc-example/getting-started.js.svg @@ -0,0 +1,108 @@ + + + + + + + + + + + + + + + +0 +10 +20 +30 +40 +Shirts +Cardigans +Chiffons +Pants +Heels +Socks + + + + + + + + +sales + +ECharts Getting Started Example + + \ No newline at end of file diff --git a/testdata/doc-example/graphic-bounding.js b/testdata/doc-example/graphic-bounding.js new file mode 100644 index 0000000..ae3a2fd --- /dev/null +++ b/testdata/doc-example/graphic-bounding.js @@ -0,0 +1,98 @@ +"use strict"; +option = { + graphic: [{ + type: 'group', + id: 'textGroup1', + left: 30, + top: 30, + bounding: 'raw', + children: [ + { + type: 'rect', + z: 100, + left: 'center', + top: 'center', + shape: { + width: 330, + height: 100 + }, + style: { + fill: '#fff', + stroke: '#999', + lineWidth: 2, + shadowBlur: 8, + shadowOffsetX: 3, + shadowOffsetY: 3, + shadowColor: 'rgba(0,0,0,0.3)' + } + }, + { + type: 'text', + z: 100, + top: 'middle', + left: 'center', + style: { + text: [ + '这个文本框的 bounding 为 "raw"', + '表示定位时仅仅取 group 自己的', + '未经过 transform 的包围盒。' + ].join('\n'), + font: '20px "STHeiti", sans-serif' + } + } + ] + }, { + type: 'group', + id: 'textGroup2', + left: 0, + bottom: 0, + children: [ + { + type: 'rect', + z: 100, + left: 'center', + top: 'center', + shape: { + width: 330, + height: 100 + }, + style: { + fill: '#fff', + stroke: '#999', + lineWidth: 2, + shadowBlur: 8, + shadowOffsetX: 3, + shadowOffsetY: 3, + shadowColor: 'rgba(0,0,0,0.3)' + } + }, + { + type: 'text', + z: 100, + top: 'middle', + left: 'center', + style: { + text: [ + '这个文本框的 bounding 为 "all"', + '表示定位时取整个 group 的', + '经过 transform 后的包围盒。' + ].join('\n'), + font: '20px "STHeiti", sans-serif' + } + } + ] + }] +}; +var rotation = 0; +setInterval(function () { + rotation = (rotation + Math.PI / 300) % (Math.PI * 2); + myChart.setOption({ + graphic: [{ + id: 'textGroup1', + rotation: rotation + }, { + id: 'textGroup2', + rotation: rotation + }] + }); +}, 20); diff --git a/testdata/doc-example/graphic-bounding.js.svg b/testdata/doc-example/graphic-bounding.js.svg new file mode 100644 index 0000000..174de3e --- /dev/null +++ b/testdata/doc-example/graphic-bounding.js.svg @@ -0,0 +1,16 @@ + + + +这个文本框的 bounding 为 "raw" +表示定位时仅仅取 group 自己的 +未经过 transform 的包围盒。 + +这个文本框的 bounding 为 "all" +表示定位时取整个 group 的 +经过 transform 后的包围盒。 + + + + + + \ No newline at end of file diff --git a/testdata/doc-example/label-position.js b/testdata/doc-example/label-position.js new file mode 100644 index 0000000..ac57b94 --- /dev/null +++ b/testdata/doc-example/label-position.js @@ -0,0 +1,81 @@ +"use strict"; +app.configParameters = { + position: { + options: [ + 'left', 'right', 'top', 'bottom', + 'inside', + 'insideTop', 'insideLeft', 'insideRight', 'insideBottom', + 'insideTopLeft', 'insideTopRight', 'insideBottomLeft', 'insideBottomRight' + ] + }, + align: { + options: ['left', 'center', 'right'] + }, + verticalAlign: { + options: ['top', 'middle', 'bottom'] + }, + distance: { + min: 0, + max: 100 + } +}; +app.config = { + position: 'top', + align: 'center', + verticalAlign: 'middle', + distance: 5, + onChange: function () { + myChart.setOption({ + series: { + type: 'scatter', + label: { + position: app.config.position, + align: app.config.align, + verticalAlign: app.config.verticalAlign, + distance: app.config.distance + } + } + }); + } +}; +option = { + series: [ + { + type: 'scatter', + symbolSize: 360, + symbol: 'roundRect', + data: [[1, 1]], + label: { + position: app.config.position, + align: app.config.align, + verticalAlign: app.config.verticalAlign, + distance: app.config.distance, + show: true, + formatter: [ + 'Label Text', + ].join('\n'), + width: 200, + height: 60, + backgroundColor: 'rgba(0, 255, 255, 0.3)', + borderColor: '#555', + borderWidth: 2, + borderRadius: 5, + padding: 10, + fontSize: 18, + shadowBlur: 3, + shadowColor: '#888', + shadowOffsetX: 0, + shadowOffsetY: 3, + textBorderColor: '#000', + textBorderWidth: 3, + color: '#fff' + } + } + ], + xAxis: { + max: 2 + }, + yAxis: { + max: 2 + } +}; diff --git a/testdata/doc-example/label-position.js.svg b/testdata/doc-example/label-position.js.svg new file mode 100644 index 0000000..e6e23be --- /dev/null +++ b/testdata/doc-example/label-position.js.svg @@ -0,0 +1,60 @@ + + + + + + + + + + + + + + + + + + + + + + + + +0 +0.5 +1 +1.5 +2 +0 +0.5 +1 +1.5 +2 + + +Label Text + + + + + + + \ No newline at end of file diff --git a/testdata/doc-example/line-stack-tiled.js b/testdata/doc-example/line-stack-tiled.js new file mode 100644 index 0000000..a0a6458 --- /dev/null +++ b/testdata/doc-example/line-stack-tiled.js @@ -0,0 +1,46 @@ +"use strict"; +option = { + title: { + text: '某楼盘销售情况', + subtext: '纯属虚构' + }, + tooltip: { + trigger: 'axis' + }, + legend: { + data: ['意向', '预购', '成交'] + }, + toolbox: { + show: true, + feature: { + magicType: { show: true, type: ['stack', 'tiled'] }, + saveAsImage: { show: true } + } + }, + xAxis: { + type: 'category', + boundaryGap: false, + data: ['周一', '周二', '周三', '周四', '周五', '周六', '周日'] + }, + yAxis: { + type: 'value' + }, + series: [{ + name: '成交', + type: 'line', + smooth: true, + data: [10, 12, 21, 54, 260, 830, 710] + }, + { + name: '预购', + type: 'line', + smooth: true, + data: [30, 182, 434, 791, 390, 30, 10] + }, + { + name: '意向', + type: 'line', + smooth: true, + data: [1320, 1132, 601, 234, 120, 90, 20] + }] +}; diff --git a/testdata/doc-example/line-stack-tiled.js.svg b/testdata/doc-example/line-stack-tiled.js.svg new file mode 100644 index 0000000..790c795 --- /dev/null +++ b/testdata/doc-example/line-stack-tiled.js.svg @@ -0,0 +1,124 @@ + + + + + + + + + + + + + + + + +0 +300 +600 +900 +1,200 +1,500 +周一 +周二 +周三 +周四 +周五 +周六 +周日 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +意向 + + +预购 + + +成交 + + + + +某楼盘销售情况 +纯属虚构 + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/doc-example/map-example.js b/testdata/doc-example/map-example.js new file mode 100644 index 0000000..729ad94 --- /dev/null +++ b/testdata/doc-example/map-example.js @@ -0,0 +1,144 @@ +"use strict"; +option = { + title: { + text: 'iphone销量', + subtext: '纯属虚构', + left: 'center' + }, + tooltip: { + trigger: 'item' + }, + legend: { + orient: 'vertical', + left: 'left', + data: ['iphone3', 'iphone4', 'iphone5'] + }, + visualMap: { + min: 0, + max: 2500, + left: 'left', + top: 'bottom', + text: ['高', '低'], + calculable: true + }, + toolbox: { + show: true, + orient: 'vertical', + left: 'right', + top: 'center', + feature: { + mark: { show: true }, + dataView: { show: true, readOnly: false }, + restore: { show: true }, + saveAsImage: { show: true } + } + }, + series: [ + { + name: 'iphone3', + type: 'map', + mapType: 'china', + roam: false, + label: { + normal: { + show: false + }, + emphasis: { + show: true + } + }, + data: [ + { name: '北京', value: Math.round(Math.random() * 1000) }, + { name: '天津', value: Math.round(Math.random() * 1000) }, + { name: '上海', value: Math.round(Math.random() * 1000) }, + { name: '重庆', value: Math.round(Math.random() * 1000) }, + { name: '河北', value: Math.round(Math.random() * 1000) }, + { name: '河南', value: Math.round(Math.random() * 1000) }, + { name: '云南', value: Math.round(Math.random() * 1000) }, + { name: '辽宁', value: Math.round(Math.random() * 1000) }, + { name: '黑龙江', value: Math.round(Math.random() * 1000) }, + { name: '湖南', value: Math.round(Math.random() * 1000) }, + { name: '安徽', value: Math.round(Math.random() * 1000) }, + { name: '山东', value: Math.round(Math.random() * 1000) }, + { name: '新疆', value: Math.round(Math.random() * 1000) }, + { name: '江苏', value: Math.round(Math.random() * 1000) }, + { name: '浙江', value: Math.round(Math.random() * 1000) }, + { name: '江西', value: Math.round(Math.random() * 1000) }, + { name: '湖北', value: Math.round(Math.random() * 1000) }, + { name: '广西', value: Math.round(Math.random() * 1000) }, + { name: '甘肃', value: Math.round(Math.random() * 1000) }, + { name: '山西', value: Math.round(Math.random() * 1000) }, + { name: '内蒙古', value: Math.round(Math.random() * 1000) }, + { name: '陕西', value: Math.round(Math.random() * 1000) }, + { name: '吉林', value: Math.round(Math.random() * 1000) }, + { name: '福建', value: Math.round(Math.random() * 1000) }, + { name: '贵州', value: Math.round(Math.random() * 1000) }, + { name: '广东', value: Math.round(Math.random() * 1000) }, + { name: '青海', value: Math.round(Math.random() * 1000) }, + { name: '西藏', value: Math.round(Math.random() * 1000) }, + { name: '四川', value: Math.round(Math.random() * 1000) }, + { name: '宁夏', value: Math.round(Math.random() * 1000) }, + { name: '海南', value: Math.round(Math.random() * 1000) }, + { name: '台湾', value: Math.round(Math.random() * 1000) }, + { name: '香港', value: Math.round(Math.random() * 1000) }, + { name: '澳门', value: Math.round(Math.random() * 1000) } + ] + }, + { + name: 'iphone4', + type: 'map', + mapType: 'china', + label: { + normal: { + show: false + }, + emphasis: { + show: true + } + }, + data: [ + { name: '北京', value: Math.round(Math.random() * 1000) }, + { name: '天津', value: Math.round(Math.random() * 1000) }, + { name: '上海', value: Math.round(Math.random() * 1000) }, + { name: '重庆', value: Math.round(Math.random() * 1000) }, + { name: '河北', value: Math.round(Math.random() * 1000) }, + { name: '安徽', value: Math.round(Math.random() * 1000) }, + { name: '新疆', value: Math.round(Math.random() * 1000) }, + { name: '浙江', value: Math.round(Math.random() * 1000) }, + { name: '江西', value: Math.round(Math.random() * 1000) }, + { name: '山西', value: Math.round(Math.random() * 1000) }, + { name: '内蒙古', value: Math.round(Math.random() * 1000) }, + { name: '吉林', value: Math.round(Math.random() * 1000) }, + { name: '福建', value: Math.round(Math.random() * 1000) }, + { name: '广东', value: Math.round(Math.random() * 1000) }, + { name: '西藏', value: Math.round(Math.random() * 1000) }, + { name: '四川', value: Math.round(Math.random() * 1000) }, + { name: '宁夏', value: Math.round(Math.random() * 1000) }, + { name: '香港', value: Math.round(Math.random() * 1000) }, + { name: '澳门', value: Math.round(Math.random() * 1000) } + ] + }, + { + name: 'iphone5', + type: 'map', + mapType: 'china', + label: { + normal: { + show: false + }, + emphasis: { + show: true + } + }, + data: [ + { name: '北京', value: Math.round(Math.random() * 1000) }, + { name: '天津', value: Math.round(Math.random() * 1000) }, + { name: '上海', value: Math.round(Math.random() * 1000) }, + { name: '广东', value: Math.round(Math.random() * 1000) }, + { name: '台湾', value: Math.round(Math.random() * 1000) }, + { name: '香港', value: Math.round(Math.random() * 1000) }, + { name: '澳门', value: Math.round(Math.random() * 1000) } + ] + } + ] +}; diff --git a/testdata/doc-example/map-visualMap-continuous-text.js b/testdata/doc-example/map-visualMap-continuous-text.js new file mode 100644 index 0000000..b45575e --- /dev/null +++ b/testdata/doc-example/map-visualMap-continuous-text.js @@ -0,0 +1,90 @@ +"use strict"; +myChart.showLoading(); +$.get(ROOT_PATH + '/data/asset/geo/HK.json', function (geoJson) { + myChart.hideLoading(); + echarts.registerMap('HK', geoJson); + myChart.setOption(option = { + title: { + text: '香港18区人口密度 (2011)', + subtext: '人口密度数据来自Wikipedia', + sublink: 'http://zh.wikipedia.org/wiki/%E9%A6%99%E6%B8%AF%E8%A1%8C%E6%94%BF%E5%8D%80%E5%8A%83#cite_note-12' + }, + tooltip: { + trigger: 'item', + formatter: '{b}
{c} (p / km2)' + }, + toolbox: { + show: true, + orient: 'vertical', + left: 'right', + top: 'center', + feature: { + mark: { show: true }, + dataView: { show: true, readOnly: false }, + restore: { show: true }, + saveAsImage: { show: true } + } + }, + visualMap: { + type: 'continuous', + min: 800, + max: 50000, + text: ['High', 'Low'], + realtime: false, + calculable: true, + color: ['orangered', 'yellow', 'lightskyblue'] + }, + series: [ + { + name: '香港18区人口密度', + type: 'map', + mapType: 'HK', + itemStyle: { + normal: { label: { show: true } }, + emphasis: { label: { show: true } } + }, + data: [ + { name: '中西区', value: 20057.34 }, + { name: '湾仔', value: 15477.48 }, + { name: '东区', value: 31686.1 }, + { name: '南区', value: 6992.6 }, + { name: '油尖旺', value: 44045.49 }, + { name: '深水埗', value: 40689.64 }, + { name: '九龙城', value: 37659.78 }, + { name: '黄大仙', value: 45180.97 }, + { name: '观塘', value: 55204.26 }, + { name: '葵青', value: 21900.9 }, + { name: '荃湾', value: 4918.26 }, + { name: '屯门', value: 5881.84 }, + { name: '元朗', value: 4178.01 }, + { name: '北区', value: 2227.92 }, + { name: '大埔', value: 2180.98 }, + { name: '沙田', value: 9172.94 }, + { name: '西贡', value: 3368 }, + { name: '离岛', value: 806.98 } + ], + // 自定义名称映射 + nameMap: { + 'Central and Western': '中西区', + 'Eastern': '东区', + 'Islands': '离岛', + 'Kowloon City': '九龙城', + 'Kwai Tsing': '葵青', + 'Kwun Tong': '观塘', + 'North': '北区', + 'Sai Kung': '西贡', + 'Sha Tin': '沙田', + 'Sham Shui Po': '深水埗', + 'Southern': '南区', + 'Tai Po': '大埔', + 'Tsuen Wan': '荃湾', + 'Tuen Mun': '屯门', + 'Wan Chai': '湾仔', + 'Wong Tai Sin': '黄大仙', + 'Yau Tsim Mong': '油尖旺', + 'Yuen Long': '元朗' + } + } + ] + }); +}); diff --git a/testdata/doc-example/map-visualMap-continuous.js b/testdata/doc-example/map-visualMap-continuous.js new file mode 100644 index 0000000..613f969 --- /dev/null +++ b/testdata/doc-example/map-visualMap-continuous.js @@ -0,0 +1,230 @@ +"use strict"; +option = { + title: { + text: 'World Population (2010)', + subtext: 'from United Nations, Total population, both sexes combined, as of 1 July (thousands)', + sublink: 'http://esa.un.org/wpp/Excel-Data/population.htm', + left: 'center', + top: 'top' + }, + tooltip: { + trigger: 'item', + formatter: function (params) { + var value = (params.value + '').split('.'); + value = value[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g, '$1,') + + '.' + value[1]; + return params.seriesName + '
' + params.name + ' : ' + value; + } + }, + toolbox: { + show: true, + orient: 'vertical', + left: 'right', + top: 'center', + feature: { + mark: { show: true }, + dataView: { show: true, readOnly: false }, + restore: { show: true }, + saveAsImage: { show: true } + } + }, + visualMap: { + type: 'continuous', + min: 0, + max: 1000000, + text: ['High', 'Low'], + realtime: false, + calculable: true, + color: ['orangered', 'yellow', 'lightskyblue'] + }, + series: [ + { + name: 'World Population (2010)', + type: 'map', + mapType: 'world', + roam: true, + itemStyle: { + emphasis: { label: { show: true } } + }, + data: [ + { name: 'Afghanistan', value: 28397.812 }, + { name: 'Angola', value: 19549.124 }, + { name: 'Albania', value: 3150.143 }, + { name: 'United Arab Emirates', value: 8441.537 }, + { name: 'Argentina', value: 40374.224 }, + { name: 'Armenia', value: 2963.496 }, + { name: 'French Southern and Antarctic Lands', value: 268.065 }, + { name: 'Australia', value: 22404.488 }, + { name: 'Austria', value: 8401.924 }, + { name: 'Azerbaijan', value: 9094.718 }, + { name: 'Burundi', value: 9232.753 }, + { name: 'Belgium', value: 10941.288 }, + { name: 'Benin', value: 9509.798 }, + { name: 'Burkina Faso', value: 15540.284 }, + { name: 'Bangladesh', value: 151125.475 }, + { name: 'Bulgaria', value: 7389.175 }, + { name: 'The Bahamas', value: 66402.316 }, + { name: 'Bosnia and Herzegovina', value: 3845.929 }, + { name: 'Belarus', value: 9491.07 }, + { name: 'Belize', value: 308.595 }, + { name: 'Bermuda', value: 64.951 }, + { name: 'Bolivia', value: 716.939 }, + { name: 'Brazil', value: 195210.154 }, + { name: 'Brunei', value: 27.223 }, + { name: 'Bhutan', value: 716.939 }, + { name: 'Botswana', value: 1969.341 }, + { name: 'Central African Republic', value: 4349.921 }, + { name: 'Canada', value: 34126.24 }, + { name: 'Switzerland', value: 7830.534 }, + { name: 'Chile', value: 17150.76 }, + { name: 'China', value: 1359821.465 }, + { name: 'Ivory Coast', value: 60508.978 }, + { name: 'Cameroon', value: 20624.343 }, + { name: 'Democratic Republic of the Congo', value: 62191.161 }, + { name: 'Republic of the Congo', value: 3573.024 }, + { name: 'Colombia', value: 46444.798 }, + { name: 'Costa Rica', value: 4669.685 }, + { name: 'Cuba', value: 11281.768 }, + { name: 'Northern Cyprus', value: 1.468 }, + { name: 'Cyprus', value: 1103.685 }, + { name: 'Czech Republic', value: 10553.701 }, + { name: 'Germany', value: 83017.404 }, + { name: 'Djibouti', value: 834.036 }, + { name: 'Denmark', value: 5550.959 }, + { name: 'Dominican Republic', value: 10016.797 }, + { name: 'Algeria', value: 37062.82 }, + { name: 'Ecuador', value: 15001.072 }, + { name: 'Egypt', value: 78075.705 }, + { name: 'Eritrea', value: 5741.159 }, + { name: 'Spain', value: 46182.038 }, + { name: 'Estonia', value: 1298.533 }, + { name: 'Ethiopia', value: 87095.281 }, + { name: 'Finland', value: 5367.693 }, + { name: 'Fiji', value: 860.559 }, + { name: 'Falkland Islands', value: 49.581 }, + { name: 'France', value: 63230.866 }, + { name: 'Gabon', value: 1556.222 }, + { name: 'United Kingdom', value: 62066.35 }, + { name: 'Georgia', value: 4388.674 }, + { name: 'Ghana', value: 24262.901 }, + { name: 'Guinea', value: 10876.033 }, + { name: 'Gambia', value: 1680.64 }, + { name: 'Guinea Bissau', value: 10876.033 }, + { name: 'Equatorial Guinea', value: 696.167 }, + { name: 'Greece', value: 11109.999 }, + { name: 'Greenland', value: 56.546 }, + { name: 'Guatemala', value: 14341.576 }, + { name: 'French Guiana', value: 231.169 }, + { name: 'Guyana', value: 786.126 }, + { name: 'Honduras', value: 7621.204 }, + { name: 'Croatia', value: 4338.027 }, + { name: 'Haiti', value: 9896.4 }, + { name: 'Hungary', value: 10014.633 }, + { name: 'Indonesia', value: 240676.485 }, + { name: 'India', value: 1205624.648 }, + { name: 'Ireland', value: 4467.561 }, + { name: 'Iran', value: 240676.485 }, + { name: 'Iraq', value: 30962.38 }, + { name: 'Iceland', value: 318.042 }, + { name: 'Israel', value: 7420.368 }, + { name: 'Italy', value: 60508.978 }, + { name: 'Jamaica', value: 2741.485 }, + { name: 'Jordan', value: 6454.554 }, + { name: 'Japan', value: 127352.833 }, + { name: 'Kazakhstan', value: 15921.127 }, + { name: 'Kenya', value: 40909.194 }, + { name: 'Kyrgyzstan', value: 5334.223 }, + { name: 'Cambodia', value: 14364.931 }, + { name: 'South Korea', value: 51452.352 }, + { name: 'Kosovo', value: 97.743 }, + { name: 'Kuwait', value: 2991.58 }, + { name: 'Laos', value: 6395.713 }, + { name: 'Lebanon', value: 4341.092 }, + { name: 'Liberia', value: 3957.99 }, + { name: 'Libya', value: 6040.612 }, + { name: 'Sri Lanka', value: 20758.779 }, + { name: 'Lesotho', value: 2008.921 }, + { name: 'Lithuania', value: 3068.457 }, + { name: 'Luxembourg', value: 507.885 }, + { name: 'Latvia', value: 2090.519 }, + { name: 'Morocco', value: 31642.36 }, + { name: 'Moldova', value: 103.619 }, + { name: 'Madagascar', value: 21079.532 }, + { name: 'Mexico', value: 117886.404 }, + { name: 'Macedonia', value: 507.885 }, + { name: 'Mali', value: 13985.961 }, + { name: 'Myanmar', value: 51931.231 }, + { name: 'Montenegro', value: 620.078 }, + { name: 'Mongolia', value: 2712.738 }, + { name: 'Mozambique', value: 23967.265 }, + { name: 'Mauritania', value: 3609.42 }, + { name: 'Malawi', value: 15013.694 }, + { name: 'Malaysia', value: 28275.835 }, + { name: 'Namibia', value: 2178.967 }, + { name: 'New Caledonia', value: 246.379 }, + { name: 'Niger', value: 15893.746 }, + { name: 'Nigeria', value: 159707.78 }, + { name: 'Nicaragua', value: 5822.209 }, + { name: 'Netherlands', value: 16615.243 }, + { name: 'Norway', value: 4891.251 }, + { name: 'Nepal', value: 26846.016 }, + { name: 'New Zealand', value: 4368.136 }, + { name: 'Oman', value: 2802.768 }, + { name: 'Pakistan', value: 173149.306 }, + { name: 'Panama', value: 3678.128 }, + { name: 'Peru', value: 29262.83 }, + { name: 'Philippines', value: 93444.322 }, + { name: 'Papua New Guinea', value: 6858.945 }, + { name: 'Poland', value: 38198.754 }, + { name: 'Puerto Rico', value: 3709.671 }, + { name: 'North Korea', value: 1.468 }, + { name: 'Portugal', value: 10589.792 }, + { name: 'Paraguay', value: 6459.721 }, + { name: 'Qatar', value: 1749.713 }, + { name: 'Romania', value: 21861.476 }, + { name: 'Russia', value: 21861.476 }, + { name: 'Rwanda', value: 10836.732 }, + { name: 'Western Sahara', value: 514.648 }, + { name: 'Saudi Arabia', value: 27258.387 }, + { name: 'Sudan', value: 35652.002 }, + { name: 'South Sudan', value: 9940.929 }, + { name: 'Senegal', value: 12950.564 }, + { name: 'Solomon Islands', value: 526.447 }, + { name: 'Sierra Leone', value: 5751.976 }, + { name: 'El Salvador', value: 6218.195 }, + { name: 'Somaliland', value: 9636.173 }, + { name: 'Somalia', value: 9636.173 }, + { name: 'Republic of Serbia', value: 3573.024 }, + { name: 'Suriname', value: 524.96 }, + { name: 'Slovakia', value: 5433.437 }, + { name: 'Slovenia', value: 2054.232 }, + { name: 'Sweden', value: 9382.297 }, + { name: 'Swaziland', value: 1193.148 }, + { name: 'Syria', value: 7830.534 }, + { name: 'Chad', value: 11720.781 }, + { name: 'Togo', value: 6306.014 }, + { name: 'Thailand', value: 66402.316 }, + { name: 'Tajikistan', value: 7627.326 }, + { name: 'Turkmenistan', value: 5041.995 }, + { name: 'East Timor', value: 10016.797 }, + { name: 'Trinidad and Tobago', value: 1328.095 }, + { name: 'Tunisia', value: 10631.83 }, + { name: 'Turkey', value: 72137.546 }, + { name: 'United Republic of Tanzania', value: 44973.33 }, + { name: 'Uganda', value: 33987.213 }, + { name: 'Ukraine', value: 46050.22 }, + { name: 'Uruguay', value: 3371.982 }, + { name: 'United States of America', value: 312247.116 }, + { name: 'Uzbekistan', value: 27769.27 }, + { name: 'Venezuela', value: 236.299 }, + { name: 'Vietnam', value: 89047.397 }, + { name: 'Vanuatu', value: 236.299 }, + { name: 'West Bank', value: 13.565 }, + { name: 'Yemen', value: 22763.008 }, + { name: 'South Africa', value: 51452.352 }, + { name: 'Zambia', value: 13216.985 }, + { name: 'Zimbabwe', value: 13076.978 } + ] + } + ] +}; diff --git a/testdata/doc-example/map-visualMap-pieces.js b/testdata/doc-example/map-visualMap-pieces.js new file mode 100644 index 0000000..6a5893c --- /dev/null +++ b/testdata/doc-example/map-visualMap-pieces.js @@ -0,0 +1,76 @@ +"use strict"; +myChart.showLoading(); +$.get(ROOT_PATH + '/data/asset/geo/USA.json', function (usaJson) { + echarts.registerMap('USA', usaJson, { + Alaska: { + left: -131, + top: 25, + width: 15 + }, + Hawaii: { + left: -110, + top: 28, + width: 5 + }, + 'Puerto Rico': { + left: -76, + top: 26, + width: 2 + } + }); + myChart.hideLoading(); + const data = echarts.util.map(usaJson.features, function (feature) { + return { + name: feature.properties.name, + value: Math.round(Math.random() * Math.random() * 1500) + }; + }); + option = { + title: { + text: 'Order', + subtext: 'Fake Data', + left: 'center' + }, + tooltip: { + trigger: 'item' + }, + visualMap: { + type: 'piecewise', + pieces: [ + { min: 1500 }, + { min: 900, max: 1500 }, + { min: 310, max: 1000 }, + { + min: 200, + max: 300, + label: '200 - 300 (Custom Color)', + color: 'lightgreen' + }, + { min: 10, max: 200, label: '10 to 200 (Custom Label)' } + ], + outOfRange: { + color: '#eee' + } + }, + series: [ + { + name: 'Order', + type: 'map', + map: 'USA', + roam: true, + label: { + show: true, + color: 'inherit' + }, + labelLayout(params) { + return { + hideOverlap: true, + fontSize: Math.max(params.rect.width / 10, 8) + }; + }, + data: data + } + ] + }; + myChart.setOption(option); +}); diff --git a/testdata/doc-example/map-visualMap-piecewise-text.js b/testdata/doc-example/map-visualMap-piecewise-text.js new file mode 100644 index 0000000..73068de --- /dev/null +++ b/testdata/doc-example/map-visualMap-piecewise-text.js @@ -0,0 +1,90 @@ +"use strict"; +myChart.showLoading(); +$.get(ROOT_PATH + '/data/asset/geo/HK.json', function (geoJson) { + myChart.hideLoading(); + echarts.registerMap('HK', geoJson); + myChart.setOption(option = { + title: { + text: '香港18区人口密度 (2011)', + subtext: '人口密度数据来自Wikipedia', + sublink: 'http://zh.wikipedia.org/wiki/%E9%A6%99%E6%B8%AF%E8%A1%8C%E6%94%BF%E5%8D%80%E5%8A%83#cite_note-12' + }, + tooltip: { + trigger: 'item', + formatter: '{b}
{c} (p / km2)' + }, + toolbox: { + show: true, + orient: 'vertical', + left: 'right', + top: 'center', + feature: { + mark: { show: true }, + dataView: { show: true, readOnly: false }, + restore: { show: true }, + saveAsImage: { show: true } + } + }, + visualMap: { + type: 'piecewise', + min: 800, + max: 50000, + text: ['High', 'Low'], + realtime: false, + calculable: true, + color: ['orangered', 'yellow', 'lightskyblue'] + }, + series: [ + { + name: '香港18区人口密度', + type: 'map', + mapType: 'HK', + itemStyle: { + normal: { label: { show: true } }, + emphasis: { label: { show: true } } + }, + data: [ + { name: '中西区', value: 20057.34 }, + { name: '湾仔', value: 15477.48 }, + { name: '东区', value: 31686.1 }, + { name: '南区', value: 6992.6 }, + { name: '油尖旺', value: 44045.49 }, + { name: '深水埗', value: 40689.64 }, + { name: '九龙城', value: 37659.78 }, + { name: '黄大仙', value: 45180.97 }, + { name: '观塘', value: 55204.26 }, + { name: '葵青', value: 21900.9 }, + { name: '荃湾', value: 4918.26 }, + { name: '屯门', value: 5881.84 }, + { name: '元朗', value: 4178.01 }, + { name: '北区', value: 2227.92 }, + { name: '大埔', value: 2180.98 }, + { name: '沙田', value: 9172.94 }, + { name: '西贡', value: 3368 }, + { name: '离岛', value: 806.98 } + ], + // 自定义名称映射 + nameMap: { + 'Central and Western': '中西区', + 'Eastern': '东区', + 'Islands': '离岛', + 'Kowloon City': '九龙城', + 'Kwai Tsing': '葵青', + 'Kwun Tong': '观塘', + 'North': '北区', + 'Sai Kung': '西贡', + 'Sha Tin': '沙田', + 'Sham Shui Po': '深水埗', + 'Southern': '南区', + 'Tai Po': '大埔', + 'Tsuen Wan': '荃湾', + 'Tuen Mun': '屯门', + 'Wan Chai': '湾仔', + 'Wong Tai Sin': '黄大仙', + 'Yau Tsim Mong': '油尖旺', + 'Yuen Long': '元朗' + } + } + ] + }); +}); diff --git a/testdata/doc-example/mix-timeline-all.js b/testdata/doc-example/mix-timeline-all.js new file mode 100644 index 0000000..ff7afa5 --- /dev/null +++ b/testdata/doc-example/mix-timeline-all.js @@ -0,0 +1,355 @@ +"use strict"; +var dataMap = {}; +function dataFormatter(obj) { + var pList = ['北京', '天津', '河北', '山西', '内蒙古', '辽宁', '吉林', '黑龙江', '上海', '江苏', '浙江', '安徽', '福建', '江西', '山东', '河南', '湖北', '湖南', '广东', '广西', '海南', '重庆', '四川', '贵州', '云南', '西藏', '陕西', '甘肃', '青海', '宁夏', '新疆']; + var temp; + for (var year = 2002; year <= 2011; year++) { + var max = 0; + var sum = 0; + temp = obj[year]; + for (var i = 0, l = temp.length; i < l; i++) { + max = Math.max(max, temp[i]); + sum += temp[i]; + obj[year][i] = { + name: pList[i], + value: temp[i] + }; + } + obj[year + 'max'] = Math.floor(max / 100) * 100; + obj[year + 'sum'] = sum; + } + return obj; +} +dataMap.dataGDP = dataFormatter({ + //max : 60000, + 2011: [16251.93, 11307.28, 24515.76, 11237.55, 14359.88, 22226.7, 10568.83, 12582, 19195.69, 49110.27, 32318.85, 15300.65, 17560.18, 11702.82, 45361.85, 26931.03, 19632.26, 19669.56, 53210.28, 11720.87, 2522.66, 10011.37, 21026.68, 5701.84, 8893.12, 605.83, 12512.3, 5020.37, 1670.44, 2102.21, 6610.05], + 2010: [14113.58, 9224.46, 20394.26, 9200.86, 11672, 18457.27, 8667.58, 10368.6, 17165.98, 41425.48, 27722.31, 12359.33, 14737.12, 9451.26, 39169.92, 23092.36, 15967.61, 16037.96, 46013.06, 9569.85, 2064.5, 7925.58, 17185.48, 4602.16, 7224.18, 507.46, 10123.48, 4120.75, 1350.43, 1689.65, 5437.47], + 2009: [12153.03, 7521.85, 17235.48, 7358.31, 9740.25, 15212.49, 7278.75, 8587, 15046.45, 34457.3, 22990.35, 10062.82, 12236.53, 7655.18, 33896.65, 19480.46, 12961.1, 13059.69, 39482.56, 7759.16, 1654.21, 6530.01, 14151.28, 3912.68, 6169.75, 441.36, 8169.8, 3387.56, 1081.27, 1353.31, 4277.05], + 2008: [11115, 6719.01, 16011.97, 7315.4, 8496.2, 13668.58, 6426.1, 8314.37, 14069.87, 30981.98, 21462.69, 8851.66, 10823.01, 6971.05, 30933.28, 18018.53, 11328.92, 11555, 36796.71, 7021, 1503.06, 5793.66, 12601.23, 3561.56, 5692.12, 394.85, 7314.58, 3166.82, 1018.62, 1203.92, 4183.21], + 2007: [9846.81, 5252.76, 13607.32, 6024.45, 6423.18, 11164.3, 5284.69, 7104, 12494.01, 26018.48, 18753.73, 7360.92, 9248.53, 5800.25, 25776.91, 15012.46, 9333.4, 9439.6, 31777.01, 5823.41, 1254.17, 4676.13, 10562.39, 2884.11, 4772.52, 341.43, 5757.29, 2703.98, 797.35, 919.11, 3523.16], + 2006: [8117.78, 4462.74, 11467.6, 4878.61, 4944.25, 9304.52, 4275.12, 6211.8, 10572.24, 21742.05, 15718.47, 6112.5, 7583.85, 4820.53, 21900.19, 12362.79, 7617.47, 7688.67, 26587.76, 4746.16, 1065.67, 3907.23, 8690.24, 2338.98, 3988.14, 290.76, 4743.61, 2277.35, 648.5, 725.9, 3045.26], + 2005: [6969.52, 3905.64, 10012.11, 4230.53, 3905.03, 8047.26, 3620.27, 5513.7, 9247.66, 18598.69, 13417.68, 5350.17, 6554.69, 4056.76, 18366.87, 10587.42, 6590.19, 6596.1, 22557.37, 3984.1, 918.75, 3467.72, 7385.1, 2005.42, 3462.73, 248.8, 3933.72, 1933.98, 543.32, 612.61, 2604.19], + 2004: [6033.21, 3110.97, 8477.63, 3571.37, 3041.07, 6672, 3122.01, 4750.6, 8072.83, 15003.6, 11648.7, 4759.3, 5763.35, 3456.7, 15021.84, 8553.79, 5633.24, 5641.94, 18864.62, 3433.5, 819.66, 3034.58, 6379.63, 1677.8, 3081.91, 220.34, 3175.58, 1688.49, 466.1, 537.11, 2209.09], + 2003: [5007.21, 2578.03, 6921.29, 2855.23, 2388.38, 6002.54, 2662.08, 4057.4, 6694.23, 12442.87, 9705.02, 3923.11, 4983.67, 2807.41, 12078.15, 6867.7, 4757.45, 4659.99, 15844.64, 2821.11, 713.96, 2555.72, 5333.09, 1426.34, 2556.02, 185.09, 2587.72, 1399.83, 390.2, 445.36, 1886.35], + 2002: [4315, 2150.76, 6018.28, 2324.8, 1940.94, 5458.22, 2348.54, 3637.2, 5741.03, 10606.85, 8003.67, 3519.72, 4467.55, 2450.48, 10275.5, 6035.48, 4212.82, 4151.54, 13502.42, 2523.73, 642.73, 2232.86, 4725.01, 1243.43, 2312.82, 162.04, 2253.39, 1232.03, 340.65, 377.16, 1612.6] +}); +dataMap.dataPI = dataFormatter({ + //max : 4000, + 2011: [136.27, 159.72, 2905.73, 641.42, 1306.3, 1915.57, 1277.44, 1701.5, 124.94, 3064.78, 1583.04, 2015.31, 1612.24, 1391.07, 3973.85, 3512.24, 2569.3, 2768.03, 2665.2, 2047.23, 659.23, 844.52, 2983.51, 726.22, 1411.01, 74.47, 1220.9, 678.75, 155.08, 184.14, 1139.03], + 2010: [124.36, 145.58, 2562.81, 554.48, 1095.28, 1631.08, 1050.15, 1302.9, 114.15, 2540.1, 1360.56, 1729.02, 1363.67, 1206.98, 3588.28, 3258.09, 2147, 2325.5, 2286.98, 1675.06, 539.83, 685.38, 2482.89, 625.03, 1108.38, 68.72, 988.45, 599.28, 134.92, 159.29, 1078.63], + 2009: [118.29, 128.85, 2207.34, 477.59, 929.6, 1414.9, 980.57, 1154.33, 113.82, 2261.86, 1163.08, 1495.45, 1182.74, 1098.66, 3226.64, 2769.05, 1795.9, 1969.69, 2010.27, 1458.49, 462.19, 606.8, 2240.61, 550.27, 1067.6, 63.88, 789.64, 497.05, 107.4, 127.25, 759.74], + 2008: [112.83, 122.58, 2034.59, 313.58, 907.95, 1302.02, 916.72, 1088.94, 111.8, 2100.11, 1095.96, 1418.09, 1158.17, 1060.38, 3002.65, 2658.78, 1780, 1892.4, 1973.05, 1453.75, 436.04, 575.4, 2216.15, 539.19, 1020.56, 60.62, 753.72, 462.27, 105.57, 118.94, 691.07], + 2007: [101.26, 110.19, 1804.72, 311.97, 762.1, 1133.42, 783.8, 915.38, 101.84, 1816.31, 986.02, 1200.18, 1002.11, 905.77, 2509.14, 2217.66, 1378, 1626.48, 1695.57, 1241.35, 361.07, 482.39, 2032, 446.38, 837.35, 54.89, 592.63, 387.55, 83.41, 97.89, 628.72], + 2006: [88.8, 103.35, 1461.81, 276.77, 634.94, 939.43, 672.76, 750.14, 93.81, 1545.05, 925.1, 1011.03, 865.98, 786.14, 2138.9, 1916.74, 1140.41, 1272.2, 1532.17, 1032.47, 323.48, 386.38, 1595.48, 382.06, 724.4, 50.9, 484.81, 334, 67.55, 79.54, 527.8], + 2005: [88.68, 112.38, 1400, 262.42, 589.56, 882.41, 625.61, 684.6, 90.26, 1461.51, 892.83, 966.5, 827.36, 727.37, 1963.51, 1892.01, 1082.13, 1100.65, 1428.27, 912.5, 300.75, 463.4, 1481.14, 368.94, 661.69, 48.04, 435.77, 308.06, 65.34, 72.07, 509.99], + 2004: [87.36, 105.28, 1370.43, 276.3, 522.8, 798.43, 568.69, 605.79, 83.45, 1367.58, 814.1, 950.5, 786.84, 664.5, 1778.45, 1649.29, 1020.09, 1022.45, 1248.59, 817.88, 278.76, 428.05, 1379.93, 334.5, 607.75, 44.3, 387.88, 286.78, 60.7, 65.33, 461.26], + 2003: [84.11, 89.91, 1064.05, 215.19, 420.1, 615.8, 488.23, 504.8, 81.02, 1162.45, 717.85, 749.4, 692.94, 560, 1480.67, 1198.7, 798.35, 886.47, 1072.91, 658.78, 244.29, 339.06, 1128.61, 298.69, 494.6, 40.7, 302.66, 237.91, 48.47, 55.63, 412.9], + 2002: [82.44, 84.21, 956.84, 197.8, 374.69, 590.2, 446.17, 474.2, 79.68, 1110.44, 685.2, 783.66, 664.78, 535.98, 1390, 1288.36, 707, 847.25, 1015.08, 601.99, 222.89, 317.87, 1047.95, 281.1, 463.44, 39.75, 282.21, 215.51, 47.31, 52.95, 305] +}); +dataMap.dataSI = dataFormatter({ + //max : 26600, + 2011: [3752.48, 5928.32, 13126.86, 6635.26, 8037.69, 12152.15, 5611.48, 5962.41, 7927.89, 25203.28, 16555.58, 8309.38, 9069.2, 6390.55, 24017.11, 15427.08, 9815.94, 9361.99, 26447.38, 5675.32, 714.5, 5543.04, 11029.13, 2194.33, 3780.32, 208.79, 6935.59, 2377.83, 975.18, 1056.15, 3225.9], + 2010: [3388.38, 4840.23, 10707.68, 5234, 6367.69, 9976.82, 4506.31, 5025.15, 7218.32, 21753.93, 14297.93, 6436.62, 7522.83, 5122.88, 21238.49, 13226.38, 7767.24, 7343.19, 23014.53, 4511.68, 571, 4359.12, 8672.18, 1800.06, 3223.49, 163.92, 5446.1, 1984.97, 744.63, 827.91, 2592.15], + 2009: [2855.55, 3987.84, 8959.83, 3993.8, 5114, 7906.34, 3541.92, 4060.72, 6001.78, 18566.37, 11908.49, 4905.22, 6005.3, 3919.45, 18901.83, 11010.5, 6038.08, 5687.19, 19419.7, 3381.54, 443.43, 3448.77, 6711.87, 1476.62, 2582.53, 136.63, 4236.42, 1527.24, 575.33, 662.32, 1929.59], + 2008: [2626.41, 3709.78, 8701.34, 4242.36, 4376.19, 7158.84, 3097.12, 4319.75, 6085.84, 16993.34, 11567.42, 4198.93, 5318.44, 3554.81, 17571.98, 10259.99, 5082.07, 5028.93, 18502.2, 3037.74, 423.55, 3057.78, 5823.39, 1370.03, 2452.75, 115.56, 3861.12, 1470.34, 557.12, 609.98, 2070.76], + 2007: [2509.4, 2892.53, 7201.88, 3454.49, 3193.67, 5544.14, 2475.45, 3695.58, 5571.06, 14471.26, 10154.25, 3370.96, 4476.42, 2975.53, 14647.53, 8282.83, 4143.06, 3977.72, 16004.61, 2425.29, 364.26, 2368.53, 4648.79, 1124.79, 2038.39, 98.48, 2986.46, 1279.32, 419.03, 455.04, 1647.55], + 2006: [2191.43, 2457.08, 6110.43, 2755.66, 2374.96, 4566.83, 1915.29, 3365.31, 4969.95, 12282.89, 8511.51, 2711.18, 3695.04, 2419.74, 12574.03, 6724.61, 3365.08, 3187.05, 13469.77, 1878.56, 308.62, 1871.65, 3775.14, 967.54, 1705.83, 80.1, 2452.44, 1043.19, 331.91, 351.58, 1459.3], + 2005: [2026.51, 2135.07, 5271.57, 2357.04, 1773.21, 3869.4, 1580.83, 2971.68, 4381.2, 10524.96, 7164.75, 2245.9, 3175.92, 1917.47, 10478.62, 5514.14, 2852.12, 2612.57, 11356.6, 1510.68, 240.83, 1564, 3067.23, 821.16, 1426.42, 63.52, 1951.36, 838.56, 264.61, 281.05, 1164.79], + 2004: [1853.58, 1685.93, 4301.73, 1919.4, 1248.27, 3061.62, 1329.68, 2487.04, 3892.12, 8437.99, 6250.38, 1844.9, 2770.49, 1566.4, 8478.69, 4182.1, 2320.6, 2190.54, 9280.73, 1253.7, 205.6, 1376.91, 2489.4, 681.5, 1281.63, 52.74, 1553.1, 713.3, 211.7, 244.05, 914.47], + 2003: [1487.15, 1337.31, 3417.56, 1463.38, 967.49, 2898.89, 1098.37, 2084.7, 3209.02, 6787.11, 5096.38, 1535.29, 2340.82, 1204.33, 6485.05, 3310.14, 1956.02, 1777.74, 7592.78, 984.08, 175.82, 1135.31, 2014.8, 569.37, 1047.66, 47.64, 1221.17, 572.02, 171.92, 194.27, 719.54], + 2002: [1249.99, 1069.08, 2911.69, 1134.31, 754.78, 2609.85, 943.49, 1843.6, 2622.45, 5604.49, 4090.48, 1337.04, 2036.97, 941.77, 5184.98, 2768.75, 1709.89, 1523.5, 6143.4, 846.89, 148.88, 958.87, 1733.38, 481.96, 934.88, 32.72, 1007.56, 501.69, 144.51, 153.06, 603.15] +}); +dataMap.dataTI = dataFormatter({ + //max : 25000, + 2011: [12363.18, 5219.24, 8483.17, 3960.87, 5015.89, 8158.98, 3679.91, 4918.09, 11142.86, 20842.21, 14180.23, 4975.96, 6878.74, 3921.2, 17370.89, 7991.72, 7247.02, 7539.54, 24097.7, 3998.33, 1148.93, 3623.81, 7014.04, 2781.29, 3701.79, 322.57, 4355.81, 1963.79, 540.18, 861.92, 2245.12], + 2010: [10600.84, 4238.65, 7123.77, 3412.38, 4209.03, 6849.37, 3111.12, 4040.55, 9833.51, 17131.45, 12063.82, 4193.69, 5850.62, 3121.4, 14343.14, 6607.89, 6053.37, 6369.27, 20711.55, 3383.11, 953.67, 2881.08, 6030.41, 2177.07, 2892.31, 274.82, 3688.93, 1536.5, 470.88, 702.45, 1766.69], + 2009: [9179.19, 3405.16, 6068.31, 2886.92, 3696.65, 5891.25, 2756.26, 3371.95, 8930.85, 13629.07, 9918.78, 3662.15, 5048.49, 2637.07, 11768.18, 5700.91, 5127.12, 5402.81, 18052.59, 2919.13, 748.59, 2474.44, 5198.8, 1885.79, 2519.62, 240.85, 3143.74, 1363.27, 398.54, 563.74, 1587.72], + 2008: [8375.76, 2886.65, 5276.04, 2759.46, 3212.06, 5207.72, 2412.26, 2905.68, 7872.23, 11888.53, 8799.31, 3234.64, 4346.4, 2355.86, 10358.64, 5099.76, 4466.85, 4633.67, 16321.46, 2529.51, 643.47, 2160.48, 4561.69, 1652.34, 2218.81, 218.67, 2699.74, 1234.21, 355.93, 475, 1421.38], + 2007: [7236.15, 2250.04, 4600.72, 2257.99, 2467.41, 4486.74, 2025.44, 2493.04, 6821.11, 9730.91, 7613.46, 2789.78, 3770, 1918.95, 8620.24, 4511.97, 3812.34, 3835.4, 14076.83, 2156.76, 528.84, 1825.21, 3881.6, 1312.94, 1896.78, 188.06, 2178.2, 1037.11, 294.91, 366.18, 1246.89], + 2006: [5837.55, 1902.31, 3895.36, 1846.18, 1934.35, 3798.26, 1687.07, 2096.35, 5508.48, 7914.11, 6281.86, 2390.29, 3022.83, 1614.65, 7187.26, 3721.44, 3111.98, 3229.42, 11585.82, 1835.12, 433.57, 1649.2, 3319.62, 989.38, 1557.91, 159.76, 1806.36, 900.16, 249.04, 294.78, 1058.16], + 2005: [4854.33, 1658.19, 3340.54, 1611.07, 1542.26, 3295.45, 1413.83, 1857.42, 4776.2, 6612.22, 5360.1, 2137.77, 2551.41, 1411.92, 5924.74, 3181.27, 2655.94, 2882.88, 9772.5, 1560.92, 377.17, 1440.32, 2836.73, 815.32, 1374.62, 137.24, 1546.59, 787.36, 213.37, 259.49, 929.41], + 2004: [4092.27, 1319.76, 2805.47, 1375.67, 1270, 2811.95, 1223.64, 1657.77, 4097.26, 5198.03, 4584.22, 1963.9, 2206.02, 1225.8, 4764.7, 2722.4, 2292.55, 2428.95, 8335.3, 1361.92, 335.3, 1229.62, 2510.3, 661.8, 1192.53, 123.3, 1234.6, 688.41, 193.7, 227.73, 833.36], + 2003: [3435.95, 1150.81, 2439.68, 1176.65, 1000.79, 2487.85, 1075.48, 1467.9, 3404.19, 4493.31, 3890.79, 1638.42, 1949.91, 1043.08, 4112.43, 2358.86, 2003.08, 1995.78, 7178.94, 1178.25, 293.85, 1081.35, 2189.68, 558.28, 1013.76, 96.76, 1063.89, 589.91, 169.81, 195.46, 753.91], + 2002: [2982.57, 997.47, 2149.75, 992.69, 811.47, 2258.17, 958.88, 1319.4, 3038.9, 3891.92, 3227.99, 1399.02, 1765.8, 972.73, 3700.52, 1978.37, 1795.93, 1780.79, 6343.94, 1074.85, 270.96, 956.12, 1943.68, 480.37, 914.5, 89.56, 963.62, 514.83, 148.83, 171.14, 704.5] +}); +dataMap.dataEstate = dataFormatter({ + //max : 3600, + 2011: [1074.93, 411.46, 918.02, 224.91, 384.76, 876.12, 238.61, 492.1, 1019.68, 2747.89, 1677.13, 634.92, 911.16, 402.51, 1838.14, 987, 634.67, 518.04, 3321.31, 465.68, 208.71, 396.28, 620.62, 160.3, 222.31, 17.44, 398.03, 134.25, 29.05, 79.01, 176.22], + 2010: [1006.52, 377.59, 697.79, 192, 309.25, 733.37, 212.32, 391.89, 1002.5, 2600.95, 1618.17, 532.17, 679.03, 340.56, 1622.15, 773.23, 564.41, 464.21, 2813.95, 405.79, 188.33, 266.38, 558.56, 139.64, 223.45, 14.54, 315.95, 110.02, 25.41, 60.53, 143.44], + 2009: [1062.47, 308.73, 612.4, 173.31, 286.65, 605.27, 200.14, 301.18, 1237.56, 2025.39, 1316.84, 497.94, 656.61, 305.9, 1329.59, 622.98, 546.11, 400.11, 2470.63, 348.98, 121.76, 229.09, 548.14, 136.15, 205.14, 13.28, 239.92, 101.37, 23.05, 47.56, 115.23], + 2008: [844.59, 227.88, 513.81, 166.04, 273.3, 500.81, 182.7, 244.47, 939.34, 1626.13, 1052.03, 431.27, 506.98, 281.96, 1104.95, 512.42, 526.88, 340.07, 2057.45, 282.96, 95.6, 191.21, 453.63, 104.81, 195.48, 15.08, 193.27, 93.8, 19.96, 38.85, 89.79], + 2007: [821.5, 183.44, 467.97, 134.12, 191.01, 410.43, 153.03, 225.81, 958.06, 1365.71, 981.42, 366.57, 511.5, 225.96, 953.69, 447.44, 409.65, 301.8, 2029.77, 239.45, 67.19, 196.06, 376.84, 93.19, 193.59, 13.24, 153.98, 83.52, 16.98, 29.49, 91.28], + 2006: [658.3, 156.64, 397.14, 117.01, 136.5, 318.54, 131.01, 194.7, 773.61, 1017.91, 794.41, 281.98, 435.22, 184.67, 786.51, 348.7, 294.73, 254.81, 1722.07, 192.2, 44.45, 158.2, 336.2, 80.24, 165.92, 11.92, 125.2, 73.21, 15.17, 25.53, 68.9], + 2005: [493.73, 122.67, 330.87, 106, 98.75, 256.77, 112.29, 163.34, 715.97, 799.73, 688.86, 231.66, 331.8, 171.88, 664.9, 298.19, 217.17, 215.63, 1430.37, 165.05, 38.2, 143.88, 286.23, 76.38, 148.69, 10.02, 108.62, 63.78, 14.1, 22.97, 55.79], + 2004: [436.11, 106.14, 231.08, 95.1, 73.81, 203.1, 97.93, 137.74, 666.3, 534.17, 587.83, 188.28, 248.44, 167.2, 473.27, 236.44, 204.8, 191.5, 1103.75, 122.52, 30.64, 129.12, 264.3, 68.3, 116.54, 5.8, 95.9, 56.84, 13, 20.78, 53.55], + 2003: [341.88, 92.31, 185.19, 78.73, 61.05, 188.49, 91.99, 127.2, 487.82, 447.47, 473.16, 162.63, 215.84, 138.02, 418.21, 217.58, 176.8, 186.49, 955.66, 100.93, 25.14, 113.69, 231.72, 59.86, 103.79, 4.35, 83.9, 48.09, 11.41, 16.85, 47.84], + 2002: [298.02, 73.04, 140.89, 65.83, 51.48, 130.94, 76.11, 118.7, 384.86, 371.09, 360.63, 139.18, 188.09, 125.27, 371.13, 199.31, 145.17, 165.29, 808.16, 82.83, 21.45, 90.48, 210.82, 53.49, 95.68, 3.42, 77.68, 41.52, 9.74, 13.46, 43.04] +}); +dataMap.dataFinancial = dataFormatter({ + //max : 3200, + 2011: [2215.41, 756.5, 746.01, 519.32, 447.46, 755.57, 207.65, 370.78, 2277.4, 2600.11, 2730.29, 503.85, 862.41, 357.44, 1640.41, 868.2, 674.57, 501.09, 2916.13, 445.37, 105.24, 704.66, 868.15, 297.27, 456.23, 31.7, 432.11, 145.05, 62.56, 134.18, 288.77], + 2010: [1863.61, 572.99, 615.42, 448.3, 346.44, 639.27, 190.12, 304.59, 1950.96, 2105.92, 2326.58, 396.17, 767.58, 241.49, 1361.45, 697.68, 561.27, 463.16, 2658.76, 384.53, 78.12, 496.56, 654.7, 231.51, 375.08, 27.08, 384.75, 100.54, 54.53, 97.87, 225.2], + 2009: [1603.63, 461.2, 525.67, 361.64, 291.1, 560.2, 180.83, 227.54, 1804.28, 1596.98, 1899.33, 359.6, 612.2, 165.1, 1044.9, 499.92, 479.11, 402.57, 2283.29, 336.82, 65.73, 389.97, 524.63, 194.44, 351.74, 23.17, 336.21, 88.27, 45.63, 75.54, 198.87], + 2008: [1519.19, 368.1, 420.74, 290.91, 219.09, 455.07, 147.24, 177.43, 1414.21, 1298.48, 1653.45, 313.81, 497.65, 130.57, 880.28, 413.83, 393.05, 334.32, 1972.4, 249.01, 47.33, 303.01, 411.14, 151.55, 277.66, 22.42, 287.16, 72.49, 36.54, 64.8, 171.97], + 2007: [1302.77, 288.17, 347.65, 218.73, 148.3, 386.34, 126.03, 155.48, 1209.08, 1054.25, 1251.43, 223.85, 385.84, 101.34, 734.9, 302.31, 337.27, 260.14, 1705.08, 190.73, 34.43, 247.46, 359.11, 122.25, 168.55, 11.51, 231.03, 61.6, 27.67, 51.05, 149.22], + 2006: [982.37, 186.87, 284.04, 169.63, 108.21, 303.41, 100.75, 74.17, 825.2, 653.25, 906.37, 166.01, 243.9, 79.75, 524.94, 219.72, 174.99, 204.72, 899.91, 129.14, 16.37, 213.7, 299.5, 89.43, 143.62, 6.44, 152.25, 50.51, 23.69, 36.99, 99.25], + 2005: [840.2, 147.4, 213.47, 135.07, 72.52, 232.85, 83.63, 35.03, 675.12, 492.4, 686.32, 127.05, 186.12, 69.55, 448.36, 181.74, 127.32, 162.37, 661.81, 91.93, 13.16, 185.18, 262.26, 73.67, 130.5, 7.57, 127.58, 44.73, 20.36, 32.25, 80.34], + 2004: [713.79, 136.97, 209.1, 110.29, 55.89, 188.04, 77.17, 32.2, 612.45, 440.5, 523.49, 94.1, 171, 65.1, 343.37, 170.82, 118.85, 118.64, 602.68, 74, 11.56, 162.38, 236.5, 60.3, 118.4, 5.4, 90.1, 42.99, 19, 27.92, 70.3], + 2003: [635.56, 112.79, 199.87, 118.48, 55.89, 145.38, 73.15, 32.2, 517.97, 392.11, 451.54, 87.45, 150.09, 64.31, 329.71, 165.11, 107.31, 99.35, 534.28, 61.59, 10.68, 147.04, 206.24, 48.01, 105.48, 4.74, 77.87, 42.31, 17.98, 24.8, 64.92], + 2002: [561.91, 76.86, 179.6, 124.1, 48.39, 137.18, 75.45, 31.6, 485.25, 368.86, 347.53, 81.85, 138.28, 76.51, 310.07, 158.77, 96.95, 92.43, 454.65, 35.86, 10.08, 134.52, 183.13, 41.45, 102.39, 2.81, 67.3, 42.08, 16.75, 21.45, 52.18] +}); +option = { + baseOption: { + timeline: { + axisType: 'category', + // realtime: false, + // loop: false, + autoPlay: true, + // currentIndex: 2, + playInterval: 1000, + // controlStyle: { + // position: 'left' + // }, + data: [ + '2002-01-01', '2003-01-01', '2004-01-01', + { + value: '2005-01-01', + tooltip: { + formatter: '{b} GDP达到一个高度' + }, + symbol: 'diamond', + symbolSize: 16 + }, + '2006-01-01', '2007-01-01', '2008-01-01', '2009-01-01', '2010-01-01', + { + value: '2011-01-01', + tooltip: { + formatter: function (params) { + return params.name + 'GDP达到又一个高度'; + } + }, + symbol: 'diamond', + symbolSize: 18 + }, + ], + label: { + formatter: function (s) { + return (new Date(s)).getFullYear(); + } + } + }, + title: { + subtext: '数据来自国家统计局' + }, + tooltip: {}, + legend: { + left: 'right', + data: ['第一产业', '第二产业', '第三产业'], + selected: { + 'GDP': false, '金融': false, '房地产': false + } + }, + calculable: true, + grid: { + top: 80, + bottom: 100 + }, + xAxis: [ + { + 'type': 'category', + 'axisLabel': { 'interval': 0 }, + 'data': [ + '北京', '\n天津', '河北', '\n山西', '内蒙古', '\n辽宁', '吉林', '\n黑龙江', + '上海', '\n江苏', '浙江', '\n安徽', '福建', '\n江西', '山东', '\n河南', + '湖北', '\n湖南', '广东', '\n广西', '海南', '\n重庆', '四川', '\n贵州', + '云南', '\n西藏', '陕西', '\n甘肃', '青海', '\n宁夏', '新疆' + ], + splitLine: { show: false } + } + ], + yAxis: [ + { + type: 'value', + name: 'GDP(亿元)', + // max: 53500 + max: 30000 + } + ], + series: [ + { name: 'GDP', type: 'bar' }, + { name: '金融', type: 'bar' }, + { name: '房地产', type: 'bar' }, + { name: '第一产业', type: 'bar' }, + { name: '第二产业', type: 'bar' }, + { name: '第三产业', type: 'bar' }, + { + name: 'GDP占比', + type: 'pie', + center: ['75%', '35%'], + radius: '28%' + } + ] + }, + options: [ + { + title: { text: '2002全国宏观经济指标' }, + series: [ + { data: dataMap.dataGDP['2002'] }, + { data: dataMap.dataFinancial['2002'] }, + { data: dataMap.dataEstate['2002'] }, + { data: dataMap.dataPI['2002'] }, + { data: dataMap.dataSI['2002'] }, + { data: dataMap.dataTI['2002'] }, + { data: [ + { name: '第一产业', value: dataMap.dataPI['2002sum'] }, + { name: '第二产业', value: dataMap.dataSI['2002sum'] }, + { name: '第三产业', value: dataMap.dataTI['2002sum'] } + ] } + ] + }, + { + title: { text: '2003全国宏观经济指标' }, + series: [ + { data: dataMap.dataGDP['2003'] }, + { data: dataMap.dataFinancial['2003'] }, + { data: dataMap.dataEstate['2003'] }, + { data: dataMap.dataPI['2003'] }, + { data: dataMap.dataSI['2003'] }, + { data: dataMap.dataTI['2003'] }, + { data: [ + { name: '第一产业', value: dataMap.dataPI['2003sum'] }, + { name: '第二产业', value: dataMap.dataSI['2003sum'] }, + { name: '第三产业', value: dataMap.dataTI['2003sum'] } + ] } + ] + }, + { + title: { text: '2004全国宏观经济指标' }, + series: [ + { data: dataMap.dataGDP['2004'] }, + { data: dataMap.dataFinancial['2004'] }, + { data: dataMap.dataEstate['2004'] }, + { data: dataMap.dataPI['2004'] }, + { data: dataMap.dataSI['2004'] }, + { data: dataMap.dataTI['2004'] }, + { data: [ + { name: '第一产业', value: dataMap.dataPI['2004sum'] }, + { name: '第二产业', value: dataMap.dataSI['2004sum'] }, + { name: '第三产业', value: dataMap.dataTI['2004sum'] } + ] } + ] + }, + { + title: { text: '2005全国宏观经济指标' }, + series: [ + { data: dataMap.dataGDP['2005'] }, + { data: dataMap.dataFinancial['2005'] }, + { data: dataMap.dataEstate['2005'] }, + { data: dataMap.dataPI['2005'] }, + { data: dataMap.dataSI['2005'] }, + { data: dataMap.dataTI['2005'] }, + { data: [ + { name: '第一产业', value: dataMap.dataPI['2005sum'] }, + { name: '第二产业', value: dataMap.dataSI['2005sum'] }, + { name: '第三产业', value: dataMap.dataTI['2005sum'] } + ] } + ] + }, + { + title: { text: '2006全国宏观经济指标' }, + series: [ + { data: dataMap.dataGDP['2006'] }, + { data: dataMap.dataFinancial['2006'] }, + { data: dataMap.dataEstate['2006'] }, + { data: dataMap.dataPI['2006'] }, + { data: dataMap.dataSI['2006'] }, + { data: dataMap.dataTI['2006'] }, + { data: [ + { name: '第一产业', value: dataMap.dataPI['2006sum'] }, + { name: '第二产业', value: dataMap.dataSI['2006sum'] }, + { name: '第三产业', value: dataMap.dataTI['2006sum'] } + ] } + ] + }, + { + title: { text: '2007全国宏观经济指标' }, + series: [ + { data: dataMap.dataGDP['2007'] }, + { data: dataMap.dataFinancial['2007'] }, + { data: dataMap.dataEstate['2007'] }, + { data: dataMap.dataPI['2007'] }, + { data: dataMap.dataSI['2007'] }, + { data: dataMap.dataTI['2007'] }, + { data: [ + { name: '第一产业', value: dataMap.dataPI['2007sum'] }, + { name: '第二产业', value: dataMap.dataSI['2007sum'] }, + { name: '第三产业', value: dataMap.dataTI['2007sum'] } + ] } + ] + }, + { + title: { text: '2008全国宏观经济指标' }, + series: [ + { data: dataMap.dataGDP['2008'] }, + { data: dataMap.dataFinancial['2008'] }, + { data: dataMap.dataEstate['2008'] }, + { data: dataMap.dataPI['2008'] }, + { data: dataMap.dataSI['2008'] }, + { data: dataMap.dataTI['2008'] }, + { data: [ + { name: '第一产业', value: dataMap.dataPI['2008sum'] }, + { name: '第二产业', value: dataMap.dataSI['2008sum'] }, + { name: '第三产业', value: dataMap.dataTI['2008sum'] } + ] } + ] + }, + { + title: { text: '2009全国宏观经济指标' }, + series: [ + { data: dataMap.dataGDP['2009'] }, + { data: dataMap.dataFinancial['2009'] }, + { data: dataMap.dataEstate['2009'] }, + { data: dataMap.dataPI['2009'] }, + { data: dataMap.dataSI['2009'] }, + { data: dataMap.dataTI['2009'] }, + { data: [ + { name: '第一产业', value: dataMap.dataPI['2009sum'] }, + { name: '第二产业', value: dataMap.dataSI['2009sum'] }, + { name: '第三产业', value: dataMap.dataTI['2009sum'] } + ] } + ] + }, + { + title: { text: '2010全国宏观经济指标' }, + series: [ + { data: dataMap.dataGDP['2010'] }, + { data: dataMap.dataFinancial['2010'] }, + { data: dataMap.dataEstate['2010'] }, + { data: dataMap.dataPI['2010'] }, + { data: dataMap.dataSI['2010'] }, + { data: dataMap.dataTI['2010'] }, + { data: [ + { name: '第一产业', value: dataMap.dataPI['2010sum'] }, + { name: '第二产业', value: dataMap.dataSI['2010sum'] }, + { name: '第三产业', value: dataMap.dataTI['2010sum'] } + ] } + ] + }, + { + title: { text: '2011全国宏观经济指标' }, + series: [ + { data: dataMap.dataGDP['2011'] }, + { data: dataMap.dataFinancial['2011'] }, + { data: dataMap.dataEstate['2011'] }, + { data: dataMap.dataPI['2011'] }, + { data: dataMap.dataSI['2011'] }, + { data: dataMap.dataTI['2011'] }, + { data: [ + { name: '第一产业', value: dataMap.dataPI['2011sum'] }, + { name: '第二产业', value: dataMap.dataSI['2011sum'] }, + { name: '第三产业', value: dataMap.dataTI['2011sum'] } + ] } + ] + } + ] +}; diff --git a/testdata/doc-example/mix-timeline-all.js.svg b/testdata/doc-example/mix-timeline-all.js.svg new file mode 100644 index 0000000..4de9197 --- /dev/null +++ b/testdata/doc-example/mix-timeline-all.js.svg @@ -0,0 +1,1280 @@ + + + + + + + + + +GDP(亿元) + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +0 +5,000 +10,000 +15,000 +20,000 +25,000 +30,000 +北京 +天津 +河北 +山西 +内蒙古 +辽宁 +吉林 +黑龙江 +上海 +江苏 +浙江 +安徽 +福建 +江西 +山东 +河南 +湖北 +湖南 +广东 +广西 +海南 +重庆 +四川 +贵州 +云南 +西藏 +陕西 +甘肃 +青海 +宁夏 +新疆 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +第一产业 +第二产业 +第三产业 + + + + +2002-01-01 +2004-01-01 +2006-01-01 +2008-01-01 +2010-01-01 + +第一产业 + +第二产业 + +第三产业 + + + + + + + + + + + + + + +2002全国宏观经济指标 +数据来自国家统计局 + + + + + + + \ No newline at end of file diff --git a/testdata/doc-example/parallel-all.js b/testdata/doc-example/parallel-all.js new file mode 100644 index 0000000..a5e97ab --- /dev/null +++ b/testdata/doc-example/parallel-all.js @@ -0,0 +1,174 @@ +"use strict"; +// Schema: +// date,AQIindex,PM2.5,PM10,CO,NO2,SO2 +var dataBJ = [ + [1, 55, 9, 56, 0.46, 18, 6, "良"], + [2, 25, 11, 21, 0.65, 34, 9, "优"], + [3, 56, 7, 63, 0.3, 14, 5, "良"], + [4, 33, 7, 29, 0.33, 16, 6, "优"], + [5, 42, 24, 44, 0.76, 40, 16, "优"], + [6, 82, 58, 90, 1.77, 68, 33, "良"], + [7, 74, 49, 77, 1.46, 48, 27, "良"], + [8, 78, 55, 80, 1.29, 59, 29, "良"], + [9, 267, 216, 280, 4.8, 108, 64, "重度污染"], + [10, 185, 127, 216, 2.52, 61, 27, "中度污染"], + [11, 39, 19, 38, 0.57, 31, 15, "优"], + [12, 41, 11, 40, 0.43, 21, 7, "优"], + [13, 64, 38, 74, 1.04, 46, 22, "良"], + [14, 108, 79, 120, 1.7, 75, 41, "轻度污染"], + [15, 108, 63, 116, 1.48, 44, 26, "轻度污染"], + [16, 33, 6, 29, 0.34, 13, 5, "优"], + [17, 94, 66, 110, 1.54, 62, 31, "良"], + [18, 186, 142, 192, 3.88, 93, 79, "中度污染"], + [19, 57, 31, 54, 0.96, 32, 14, "良"], + [20, 22, 8, 17, 0.48, 23, 10, "优"], + [21, 39, 15, 36, 0.61, 29, 13, "优"], + [22, 94, 69, 114, 2.08, 73, 39, "良"], + [23, 99, 73, 110, 2.43, 76, 48, "良"], + [24, 31, 12, 30, 0.5, 32, 16, "优"], + [25, 42, 27, 43, 1, 53, 22, "优"], + [26, 154, 117, 157, 3.05, 92, 58, "中度污染"], + [27, 234, 185, 230, 4.09, 123, 69, "重度污染"], + [28, 160, 120, 186, 2.77, 91, 50, "中度污染"], + [29, 134, 96, 165, 2.76, 83, 41, "轻度污染"], + [30, 52, 24, 60, 1.03, 50, 21, "良"], + [31, 46, 5, 49, 0.28, 10, 6, "优"] +]; +var dataGZ = [ + [1, 26, 37, 27, 1.163, 27, 13, "优"], + [2, 85, 62, 71, 1.195, 60, 8, "良"], + [3, 78, 38, 74, 1.363, 37, 7, "良"], + [4, 21, 21, 36, 0.634, 40, 9, "优"], + [5, 41, 42, 46, 0.915, 81, 13, "优"], + [6, 56, 52, 69, 1.067, 92, 16, "良"], + [7, 64, 30, 28, 0.924, 51, 2, "良"], + [8, 55, 48, 74, 1.236, 75, 26, "良"], + [9, 76, 85, 113, 1.237, 114, 27, "良"], + [10, 91, 81, 104, 1.041, 56, 40, "良"], + [11, 84, 39, 60, 0.964, 25, 11, "良"], + [12, 64, 51, 101, 0.862, 58, 23, "良"], + [13, 70, 69, 120, 1.198, 65, 36, "良"], + [14, 77, 105, 178, 2.549, 64, 16, "良"], + [15, 109, 68, 87, 0.996, 74, 29, "轻度污染"], + [16, 73, 68, 97, 0.905, 51, 34, "良"], + [17, 54, 27, 47, 0.592, 53, 12, "良"], + [18, 51, 61, 97, 0.811, 65, 19, "良"], + [19, 91, 71, 121, 1.374, 43, 18, "良"], + [20, 73, 102, 182, 2.787, 44, 19, "良"], + [21, 73, 50, 76, 0.717, 31, 20, "良"], + [22, 84, 94, 140, 2.238, 68, 18, "良"], + [23, 93, 77, 104, 1.165, 53, 7, "良"], + [24, 99, 130, 227, 3.97, 55, 15, "良"], + [25, 146, 84, 139, 1.094, 40, 17, "轻度污染"], + [26, 113, 108, 137, 1.481, 48, 15, "轻度污染"], + [27, 81, 48, 62, 1.619, 26, 3, "良"], + [28, 56, 48, 68, 1.336, 37, 9, "良"], + [29, 82, 92, 174, 3.29, 0, 13, "良"], + [30, 106, 116, 188, 3.628, 101, 16, "轻度污染"], + [31, 118, 50, 0, 1.383, 76, 11, "轻度污染"] +]; +var dataSH = [ + [1, 91, 45, 125, 0.82, 34, 23, "良"], + [2, 65, 27, 78, 0.86, 45, 29, "良"], + [3, 83, 60, 84, 1.09, 73, 27, "良"], + [4, 109, 81, 121, 1.28, 68, 51, "轻度污染"], + [5, 106, 77, 114, 1.07, 55, 51, "轻度污染"], + [6, 109, 81, 121, 1.28, 68, 51, "轻度污染"], + [7, 106, 77, 114, 1.07, 55, 51, "轻度污染"], + [8, 89, 65, 78, 0.86, 51, 26, "良"], + [9, 53, 33, 47, 0.64, 50, 17, "良"], + [10, 80, 55, 80, 1.01, 75, 24, "良"], + [11, 117, 81, 124, 1.03, 45, 24, "轻度污染"], + [12, 99, 71, 142, 1.1, 62, 42, "良"], + [13, 95, 69, 130, 1.28, 74, 50, "良"], + [14, 116, 87, 131, 1.47, 84, 40, "轻度污染"], + [15, 108, 80, 121, 1.3, 85, 37, "轻度污染"], + [16, 134, 83, 167, 1.16, 57, 43, "轻度污染"], + [17, 79, 43, 107, 1.05, 59, 37, "良"], + [18, 71, 46, 89, 0.86, 64, 25, "良"], + [19, 97, 71, 113, 1.17, 88, 31, "良"], + [20, 84, 57, 91, 0.85, 55, 31, "良"], + [21, 87, 63, 101, 0.9, 56, 41, "良"], + [22, 104, 77, 119, 1.09, 73, 48, "轻度污染"], + [23, 87, 62, 100, 1, 72, 28, "良"], + [24, 168, 128, 172, 1.49, 97, 56, "中度污染"], + [25, 65, 45, 51, 0.74, 39, 17, "良"], + [26, 39, 24, 38, 0.61, 47, 17, "优"], + [27, 39, 24, 39, 0.59, 50, 19, "优"], + [28, 93, 68, 96, 1.05, 79, 29, "良"], + [29, 188, 143, 197, 1.66, 99, 51, "中度污染"], + [30, 174, 131, 174, 1.55, 108, 50, "中度污染"], + [31, 187, 143, 201, 1.39, 89, 53, "中度污染"] +]; +var schema = [ + { name: 'date', index: 0, text: '日期' }, + { name: 'AQIindex', index: 1, text: 'AQI' }, + { name: 'PM25', index: 2, text: 'PM2.5' }, + { name: 'PM10', index: 3, text: 'PM10' }, + { name: 'CO', index: 4, text: ' CO' }, + { name: 'NO2', index: 5, text: 'NO2' }, + { name: 'SO2', index: 6, text: 'SO2' }, + { name: '等级', index: 7, text: '等级' } +]; +var lineStyle = { + normal: { + width: 1, + opacity: 0.5 + } +}; +option = { + color: [ + '#c23531', '#91c7ae', '#dd8668' + ], + legend: { + top: 10, + data: ['北京', '上海', '广州'], + itemGap: 20 + }, + parallelAxis: [ + { dim: 0, name: schema[0].text, inverse: true, max: 31, nameLocation: 'start' }, + { dim: 1, name: schema[1].text }, + { dim: 2, name: schema[2].text }, + { dim: 3, name: schema[3].text }, + { dim: 4, name: schema[4].text }, + { dim: 5, name: schema[5].text }, + { dim: 6, name: schema[6].text }, + { dim: 7, name: schema[7].text, + type: 'category', data: ['优', '良', '轻度污染', '中度污染', '重度污染', '严重污染'] } + ], + parallel: { + left: '5%', + right: '13%', + bottom: '10%', + top: '20%', + parallelAxisDefault: { + type: 'value', + name: 'AQI指数', + nameLocation: 'end', + nameGap: 20, + nameTextStyle: { + fontSize: 12 + } + } + }, + series: [ + { + name: '北京', + type: 'parallel', + lineStyle: lineStyle, + data: dataBJ + }, + { + name: '上海', + type: 'parallel', + lineStyle: lineStyle, + data: dataSH + }, + { + name: '广州', + type: 'parallel', + lineStyle: lineStyle, + data: dataGZ + } + ] +}; diff --git a/testdata/doc-example/parallel-all.js.svg b/testdata/doc-example/parallel-all.js.svg new file mode 100644 index 0000000..a77df8c --- /dev/null +++ b/testdata/doc-example/parallel-all.js.svg @@ -0,0 +1,280 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +北京 + +上海 + +广州 + +日期 + +AQI + +PM2.5 + +PM10 + + CO + +NO2 + +SO2 + +等级 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +0 +5 +10 +15 +20 +25 +30 +31 +0 +50 +100 +150 +200 +250 +300 +0 +50 +100 +150 +200 +250 +0 +50 +100 +150 +200 +250 +300 +0 +1 +2 +3 +4 +5 +0 +20 +40 +60 +80 +100 +120 +140 +0 +20 +40 +60 +80 + + +轻度污染 +中度污染 +重度污染 +严重污染 + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/doc-example/pictorialBar-clip.js b/testdata/doc-example/pictorialBar-clip.js new file mode 100644 index 0000000..3775498 --- /dev/null +++ b/testdata/doc-example/pictorialBar-clip.js @@ -0,0 +1,94 @@ +"use strict"; +var path = 'path://M36.7,102.84c-1.17,2.54-2.99,4.98-3.39,7.63c-1.51,9.89-3.31,19.58-1.93,29.95 c0.95,7.15-2.91,14.82-3.57,22.35c-0.64,7.36-0.2,14.86,0.35,22.25c0.12,1.68,2.66,3.17,4.67,5.4c-0.6,0.82-1.5,2.22-2.58,3.48 c-0.96,1.12-1.96,2.35-3.21,3.04c-1.71,0.95-3.71,2.03-5.51,1.9c-1.18-0.08-3.04-2.13-3.16-3.43c-0.44-4.72,0-9.52-0.41-14.25 c-0.94-10.88-2.32-21.72-3.24-32.61c-0.49-5.84-1.63-12.01-0.35-17.54c3.39-14.56,2.8-28.84,0.36-43.4 c-2.71-16.16-1.06-32.4,0.54-48.59c0.91-9.22,4.62-17.36,8.53-25.57c1.32-2.77,1.88-6.84,0.87-9.62C21.89-3.77,18.09-11,14.7-18.38 c-0.56,0.1-1.13,0.21-1.69,0.31C10.17-11.52,6.29-5.2,4.71,1.65C2.05,13.21-4.42,22.3-11.43,31.28c-1.32,1.69-2.51,3.5-3.98,5.04 c-4.85,5.08-3.25,10.98-2.32,16.82c0.25,1.53,0.52,3.06,0.77,4.59c-0.53,0.22-1.07,0.43-1.6,0.65c-1.07-2.09-2.14-4.19-3.28-6.44 c-6.39,2.91-2.67,9.6-5.23,15.16c-1.61-3.31-2.77-5.68-3.93-8.06c0-0.33,0-0.67,0-1c6.96-16.08,14.63-31.9,20.68-48.31 C-5.24-4.07-2.03-18.55,2-32.73c0.36-1.27,0.75-2.53,0.98-3.82c1.36-7.75,4.19-10.23,11.88-10.38c1.76-0.04,3.52-0.21,5.76-0.35 c-0.55-3.95-1.21-7.3-1.45-10.68c-0.61-8.67,0.77-16.69,7.39-23.19c2.18-2.14,4.27-4.82,5.25-7.65c2.39-6.88,11.66-9,16.94-8.12 c5.92,0.99,12.15,7.93,12.16,14.12c0.01,9.89-5.19,17.26-12.24,23.68c-2.17,1.97-5.35,4.77-5.17,6.94c0.31,3.78,4.15,5.66,8.08,6.04 c1.82,0.18,3.7,0.37,5.49,0.1c5.62-0.85,8.8,2.17,10.85,6.73C73.38-27.19,78.46-14.9,84.2-2.91c1.52,3.17,4.52,5.91,7.41,8.09 c7.64,5.77,15.57,11.16,23.45,16.61c2.28,1.58,4.64,3.23,7.21,4.14c5.18,1.84,8.09,5.63,9.82,10.46c0.45,1.24,0.19,3.71-0.6,4.18 c-1.06,0.63-3.15,0.27-4.44-0.38c-7.05-3.54-12.84-8.88-19.14-13.5c-3.5-2.57-7.9-4-12.03-5.6c-9.44-3.66-17.73-8.42-22.5-18.09 c-2.43-4.94-6.09-9.27-9.69-14.61c-1.2,10.98-4.46,20.65,1.14,31.19c6.62,12.47,5.89,26.25,1.21,39.49 c-2.52,7.11-6.5,13.74-8.67,20.94c-1.91,6.33-2.2,13.15-3.23,19.75c-0.72,4.63-0.84,9.48-2.36,13.84 c-2.49,7.16-6.67,13.83-5.84,21.82c0.42,4.02,1.29,7.99,2.1,12.8c-3.74-0.49-7.47-0.4-10.67-1.66c-1.33-0.53-2.43-4.11-2.07-6.01 c1.86-9.94,3.89-19.69,0.07-29.74C34.55,108.63,36.19,105.52,36.7,102.84c1.25-8.45,2.51-16.89,3.71-24.9 c-0.83-0.58-0.85-0.59-0.87-0.61c-0.03,0.16-0.07,0.32-0.09,0.48C38.53,86.15,37.62,94.5,36.7,102.84z'; +option = { + color: ['#bb0004', '#ccc'], + xAxis: { + data: [ + 'symbolClip: true\nsymbolRepeat: false', + 'symbolClip: true\nsymbolRepeat: true', + 'symbolClip: false\nsymbolRepeat: true' + ], + axisTick: { + show: false + }, + axisLabel: { + interval: 0 + } + }, + yAxis: { + max: 80, + splitLine: { show: false } + }, + series: [{ + // This series represents real value. + type: 'pictorialBar', + name: 'realValue', + symbol: path, + // 'real value' series should has higher z than 'background' + // series. + z: 10, + // When there is another series used as the background of + // this series, it is recommended that assign + // symbolBoundingData the same value in 'realValue' series + // and 'background' series. + symbolBoundingData: 80, + data: [{ + value: 40, + symbolClip: true + }, { + value: 40, + symbolSize: ['50%', '80%'], + symbolClip: true, + symbolRepeat: true + }, { + value: 40, + symbolSize: ['50%', '80%'], + symbolClip: false, + symbolRepeat: true + }] + }, { + // This series is used as background. + type: 'pictorialBar', + name: 'background', + symbol: path, + // When a series is used as background, it is recommended + // that assign symbolBoundingData the same value in + // 'realValue' series and 'background' series. + symbolBoundingData: 80, + label: { + normal: { + show: true, + position: 'outside', + formatter: 'value: {c}', + textStyle: { + color: '#bb0004' + } + } + }, + data: [{ + value: 40, + // When a series is used as background and symbolClip + // is used in 'realValue' series, it is recommended that + // set animationDuration to be zero, which disables + // initial aniation, and keeps update animation enabled. + animationDuration: 0 + }, { + value: 40, + symbolSize: ['50%', '80%'], + // When a series is used as background, it is + // recommended that set symbolRepeat as 'fixed'. + symbolRepeat: 'fixed', + // When a series is used as background and symbolClip + // is used in 'realValue' series, it is recommended that + // set animationDuration to be zero, which disables + // initial aniation, and keeps update animation enabled. + animationDuration: 0 + }, { + value: 40, + symbolSize: ['50%', '80%'], + // When a series is used as background, it is + // recommended that set symbolRepeat as 'fixed'. + symbolRepeat: 'fixed' + }] + }] +}; diff --git a/testdata/doc-example/pictorialBar-clip.js.svg b/testdata/doc-example/pictorialBar-clip.js.svg new file mode 100644 index 0000000..d705df4 --- /dev/null +++ b/testdata/doc-example/pictorialBar-clip.js.svg @@ -0,0 +1,142 @@ + + + +0 +20 +40 +60 +80 +symbolClip: true +symbolRepeat: false +symbolClip: true +symbolRepeat: true +symbolClip: false +symbolRepeat: true + + + + + + + + + + + + +value: 40 +value: 40 +value: 40 + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/doc-example/pictorialBar-graphicType.js b/testdata/doc-example/pictorialBar-graphicType.js new file mode 100644 index 0000000..242c241 --- /dev/null +++ b/testdata/doc-example/pictorialBar-graphicType.js @@ -0,0 +1,60 @@ +"use strict"; +var textureImg = new Image(); +textureImg.src = 'data:image/jpeg;base64,/9j/4AAQSkZJRgABAQEBLAEsAAD/4gxYSUNDX1BST0ZJTEUAAQEAAAxITGlubwIQAABtbnRyUkdCIFhZWiAHzgACAAkABgAxAABhY3NwTVNGVAAAAABJRUMgc1JHQgAAAAAAAAAAAAAAAAAA9tYAAQAAAADTLUhQICAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABFjcHJ0AAABUAAAADNkZXNjAAABhAAAAGx3dHB0AAAB8AAAABRia3B0AAACBAAAABRyWFlaAAACGAAAABRnWFlaAAACLAAAABRiWFlaAAACQAAAABRkbW5kAAACVAAAAHBkbWRkAAACxAAAAIh2dWVkAAADTAAAAIZ2aWV3AAAD1AAAACRsdW1pAAAD+AAAABRtZWFzAAAEDAAAACR0ZWNoAAAEMAAAAAxyVFJDAAAEPAAACAxnVFJDAAAEPAAACAxiVFJDAAAEPAAACAx0ZXh0AAAAAENvcHlyaWdodCAoYykgMTk5OC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in symbol', + 'a image link', + 'dataURI of a image', + 'SVG DataPath', + 'pattern from image' + ], + axisTick: { + show: false + }, + axisLabel: { + interval: 0 + } + }, + yAxis: { + splitLine: { show: false } + }, + series: [{ + type: 'pictorialBar', + name: 'pictorial element', + symbolSize: ['100%', '70%'], + symbolPosition: 'center', + z: 10, + data: [{ + value: 60, + // Built-in type, can be 'circle', 'rect', 'roundRect', 'square', 'diamond', 'triangle', 'pin', 'arrow'. + symbol: 'diamond', + }, { + value: 60, + // Image link. + symbol: 'image://' + ROOT_PATH + '/data/asset/img/hill-Qomolangma.png', + }, { + value: 60, + // Image dataURI. + symbol: 'image://data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAHUAAACUCAYAAACtHGabAAAACXBIWXMAABcSAAAXEgFnn9JSAAAKTWlDQ1BQaG90b3Nob3AgSUNDIHByb2ZpbGUAAHjanVN3WJP3Fj7f92UPVkLY8LGXbIEAIiOsCMgQWaIQkgBhhBASQMWFiApWFBURnEhVxILVCkidiOKgKLhnQYqIWotVXDjuH9yntX167+3t+9f7vOec5/zOec8PgBESJpHmomoAOVKFPDrYH49PSMTJvYACFUjgBCAQ5svCZwXFAADwA3l4fnSwP/wBr28AAgBw1S4kEsfh/4O6UCZXACCRAOAiEucLAZBSAMguVMgUAMgYALBTs2QKAJQAAGx5fEIiAKoNAOz0ST4FANipk9wXANiiHKkIAI0BAJkoRyQCQLsAYFWBUiwCwMIAoKxAIi4EwK4BgFm2MkcCgL0FAHaOWJAPQGAAgJlCLMwAIDgCAEMeE80DIEwDoDDSv+CpX3CFuEgBAMDLlc2XS9IzFLiV0Bp38vDg4iHiwmyxQmEXKRBmCeQinJebIxNI5wNMzgwAABr50cH+OD+Q5+bk4eZm52zv9MWi/mvwbyI+IfHf/ryMAgQAEE7P79pf5eXWA3DHAbB1v2upWwDaVgBo3/ldM9sJoFoK0Hr5i3k4/EAenqFQyDwdHAoLC+0lYqG9MOOLPv8z4W/gi372/EAe/tt68ABxmkCZrcCjg/1xY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d9LQrWH0g8V84lRn/CUkvIAYHHySrY4cx+yX5vFoX+Wao+ybkhJQNkIv0JydC6bTpUnYKud2YOsYtiNDKO6Bki+KbUn20qxs9EhW9wvZxJyZ1NQVaBQuMIwp1CFvvQb+dDHZQPy1oVBDBWrHv2s+VZR2oI8bbEgm92AxcGknGFvXRhEXxWntpmOVCPdjIYaH3IwnGGbXfwrlpodGqC7MWNALXlVUcpFgpTpZnYRlAd5JQPAsIGi/yZO7T4U4G+gsoV2DQylumOmlWrBDdZC/aU4bGdAnb1TnXbLBtQGFFpKMAWg9nQOlGmo5gKrpIYrvQD60oWZLai9Qgg2FdhFqbJfUOWQ2gfPeEVJGKd2Cy/TDFdkP4B+Ndb25hSqDHAngNDLNAPUaBVAWtW8ViavoMoAW4TQbEGC+dVp0o6Cn/y3Zhti3kCNA9ksZM2teQzwEPjn4w0BGMp0OJ22UOOALhdAm0U/m7IEDoLy7ALA4Vwq8IaAmkQCFhoylacxfAoBAwB7JrLRbLf/HwBxI17fueoAtgAAAABJRU5ErkJggg==' + }, { + value: 60, + // SVG DataPath + symbol: 'path://M40.02-99c2.07,1.21,4.26,2.25,6.19,3.66c5.94,4.34,8.23,12.57,4.95,19.79 c-3.21,7.08-6.82,14.03-10.86,20.67c-2.17,3.56-1.25,5.38,1.99,6.36c2.94,0.89,6.36,1.91,9.15,1.21c5.51-1.4,8.33,1.23,10.66,5.29 c4.71,8.22,9.72,16.29,13.84,24.8C81.06-6.65,89,0.4,99.56,5.17C109.82,9.8,120,14.7,129.85,20.15c4.72,2.61,9.09,6.37,10.24,12.97 c-2.89-1.93-5.2-3.75-7.78-5.04c-0.99-0.5-2.6,0.22-4.83,0.5c-5.36-9.35-16.8-9.4-26.74-12.62C91.68,13.04,81.82,11.37,75.66,3 c-5.98-8.13-11.61-16.52-17.4-24.79c-0.46-0.66-0.98-1.27-1.66-2.16c-3.21,7.75-6.78,15-9.12,22.63c-1.15,3.76-0.64,8.37,0.26,12.33 c0.81,3.59,3.01,6.92,4.87,10.22c6.73,11.95,2.41,22.89-2.91,33.75c-0.35,0.72-0.86,1.43-1.46,1.97 c-7.11,6.38-14.48,12.5-21.24,19.22c-2.08,2.07-3.1,5.7-3.62,8.77c-1.92,11.44-3.81,22.92-4.93,34.46 c-0.5,5.16,1.06,10.49,1.28,15.75c0.23,5.7,0.39,11.47-0.15,17.13c-1.15,12.11-2.83,24.17-4.11,36.27c-0.18,1.72,0.8,3.53,1.13,5.33 c0.88,4.76-0.22,6.23-4.71,5.17c-4.53-1.06-8.86-2.94-14.27-4.8c1.98-1.62,2.84-2.83,3.94-3.12c5.42-1.44,7-5.2,6.39-10.23 c-1.39-11.39-3.15-22.73-4.24-34.14c-0.53-5.56,0.16-11.23,0.24-16.85c0.06-4.49,0.01-8.97,0.01-14.72 c-2.79,1.53-5.2,2.27-6.79,3.83c-4.26,4.19-8.39,8.56-12.11,13.22c-1.55,1.95-2.19,4.76-2.79,7.29c-0.47,1.99,0.6,5.02-0.48,6.05 c-2.17,2.08-5.2,3.79-8.13,4.38c-3.61,0.73-7.49,0.18-12.26,0.18c6.34-8.69,11.91-16.11,17.22-23.71c3.29-4.71,6.23-9.67,9.24-14.58 c2.15-3.5,3.76-7.4,6.3-10.57c5.38-6.73,6.74-14.28,6.72-22.64C0.88,68.3,1.36,57.91,2.26,47.58c0.69-7.85,2.15-15.67,3.7-23.41 c0.77-3.83,2.89-7.39,3.72-11.22c1.83-8.4-1.9-16-4.38-23.95C2.96-5.34-0.31,0.12-1.5,6c-1.96,9.72-7.34,17.44-12.26,25.57 c-4.39,7.25-8.79,14.52-12.75,22.01c-2.64,5-4.5,10.41-6.83,15.92c-4.82-5.28-4.65-10.59-0.94-16.97 C-21.4,30.4-12.08,6.78-6.17-18.12c1.4-5.88,1.24-12.11,2.23-18.12c1.2-7.27,4.15-9.56,11.39-9.69c8.65-0.14,13.86-4.77,14.48-13.51 c0.35-5.01,0.16-10.11-0.28-15.12c-0.82-9.3,2.49-16.57,10.17-21.69c2.08-1.39,4.78-1.87,7.2-2.76C39.35-99,39.69-99,40.02-99z' + }, { + value: 60, + symbol: 'circle', + // Pattern + itemStyle: { + normal: { + color: { + image: textureImg, + repeat: 'repeat' + } + } + } + }] + }] +}; diff --git a/testdata/doc-example/pictorialBar-patternSize.js b/testdata/doc-example/pictorialBar-patternSize.js new file mode 100644 index 0000000..67e440a --- /dev/null +++ b/testdata/doc-example/pictorialBar-patternSize.js @@ -0,0 +1,44 @@ +"use strict"; +var textureImg = new Image(); +textureImg.src = 'data:image/jpeg;base64,/9j/4AAQSkZJRgABAQEBLAEsAAD/4gxYSUNDX1BST0ZJTEUAAQEAAAxITGlubwIQAABtbnRyUkdCIFhZWiAHzgACAAkABgAxAABhY3NwTVNGVAAAAABJRUMgc1JHQgAAAAAAAAAAAAAAAAAA9tYAAQAAAADTLUhQICAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABFjcHJ0AAABUAAAADNkZXNjAAABhAAAAGx3dHB0AAAB8AAAABRia3B0AAACBAAAABRyWFlaAAACGAAAABRnWFlaAAACLAAAABRiWFlaAAACQAAAABRkbW5kAAACVAAAAHBkbWRkAAACxAAAAIh2dWVkAAADTAAAAIZ2aWV3AAAD1AAAACRsdW1pAAAD+AAAABRtZWFzAAAEDAAAACR0ZWNoAAAEMAAAAAxyVFJDAAAEPAAACAxnVFJDAAAEPAAACAxiVFJDAAAEPAAACAx0ZXh0AAAAAENvcHlyaWdodCAoYykgMTk5OCBIZXdsZXR0LVBhY2thcmQgQ29tcGFueQAAZGVzYwAAAAAAAAASc1JHQiBJRUM2MTk2Ni0yLjEAAAAAAAAAAAAAABJzUkdCIElFQzYxOTY2LTIuMQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAWFlaIAAAAAAAAPNRAAEAAAABFsxYWVogAAAAAAAAAAAAAAAAAAAAAFhZWiAAAAAAAABvogAAOPUA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q1tNpNI7XpUaSY4Mj8WJ9e+O+uQ+5Sz9ewNGxnUyyPIZJfLcm5GQL44yLWtxq2M6PqSrvb9xyCnpzTVXj2Kq4/ImbYFjnOb/AK6DZ0yMqY7JdDTAdSnkenMUsBvKBJcsl+Rb2sbel9a2t+Jj7Mq1/J08huqMhrpIIwdk6iHxEyFOCpPvwPsNGg5r9RXTcPuBppvpUNP4d56i6eETjccEfr+1tVN7/UhbOv3J/UgXaMz3KEiNmJw7i4zbsMWB1pX+JnZgqSfw2eplpRMdojKDYoi7Xt/nzqtfoZC/rkqdMrJ/NHHErttBDKxA3KLg24PH31nep6zSlnyJNFJTNVxGWMIsVype4c4PPoQ1/wBeNLRxkxNJzp7ySU1Qs5jvDUJU2Pcgixte+L2118EydTcYHpksiwyKVepmjkBV0Q2tuvYYIGR/TVuH9pKfxG4quQVs1GsBFG7GZi0mbKTcAC5/l76CdFvuaD3xhasua2eJ0kBIY3JXCgWx/wB+uoeTn2CjMH+oy1EpAjE8YI3X3EXHOl3mEmm7OSQz1XVpKeScSvADIZZHIFsYx39hrhCu5Ci2zYh0uzV22SmjaOBigAcm9zu5IzgjTt57DVd8jfUhS/6jMz00cFjcgoG2La5vb1z/AINCu8fdjsm+RmDqUMtEaaljg2kBTuRWkJJwwXn3zbUaI6ylxMIjDJHFDJ4YEIMgYzToC4FrHA9u3GfXSRYRCG8aZ/OrPtbI/wDrX9u3xo8SXWf/2Q=='; +option = { + color: ['#bb0004', '#FFD48A'], + xAxis: { + data: [ + 'symbolPatternSize: 400', + 'symbolPatternSize: 800', + 'symbolPatternSize: 100' + ], + axisTick: { + show: false + }, + axisLabel: { + interval: 0 + } + }, + yAxis: { + splitLine: { show: false } + }, + series: [{ + type: 'pictorialBar', + name: 'pictorial element', + symbol: 'triangle', + itemStyle: { + normal: { + color: { + image: textureImg, + repeat: 'repeat' + } + } + }, + data: [{ + value: 60, + }, { + value: 60, + symbolPatternSize: 800 + }, { + value: 60, + symbolPatternSize: 100 + }] + }] +}; diff --git a/testdata/doc-example/pictorialBar-position.js b/testdata/doc-example/pictorialBar-position.js new file mode 100644 index 0000000..4af3f38 --- /dev/null +++ b/testdata/doc-example/pictorialBar-position.js @@ -0,0 +1,52 @@ +"use strict"; +var walk = 'path://M29.902,23.275c1.86,0,3.368-1.506,3.368-3.365c0-1.859-1.508-3.365-3.368-3.365 c-1.857,0-3.365,1.506-3.365,3.365C26.537,21.769,28.045,23.275,29.902,23.275z M36.867,30.74c-1.666-0.467-3.799-1.6-4.732-4.199 c-0.932-2.6-3.131-2.998-4.797-2.998s-7.098,3.894-7.098,3.894c-1.133,1.001-2.1,6.502-0.967,6.769 c1.133,0.269,1.266-1.533,1.934-3.599c0.666-2.065,3.797-3.466,3.797-3.466s0.201,2.467-0.398,3.866 c-0.599,1.399-1.133,2.866-1.467,6.198s-1.6,3.665-3.799,6.266c-2.199,2.598-0.6,3.797,0.398,3.664 c1.002-0.133,5.865-5.598,6.398-6.998c0.533-1.397,0.668-3.732,0.668-3.732s0,0,2.199,1.867c2.199,1.865,2.332,4.6,2.998,7.73 s2.332,0.934,2.332-0.467c0-1.401,0.269-5.465-1-7.064c-1.265-1.6-3.73-3.465-3.73-5.265s1.199-3.732,1.199-3.732 c0.332,1.667,3.335,3.065,5.599,3.399C38.668,33.206,38.533,31.207,36.867,30.74z'; +option = { + color: ['#bb0004', '#FFD48A'], + legend: { + data: ['pictorial element', 'reference bar'] + }, + xAxis: { + data: [ + 'symbolPosition: "start"\nsymbolOffset: [0, 0]', + 'symbolPosition: "end"\nsymbolOffset: [0, 0]', + 'symbolPosition: "center"\nsymbolOffset: [0, 0]', + 'symbolPosition: "end"\nsymbolOffset: [\'-100%\', -120]' + ], + axisTick: { + show: false + }, + axisLabel: { + interval: 0 + } + }, + yAxis: { + max: 80, + splitLine: { show: false } + }, + series: [{ + type: 'pictorialBar', + name: 'pictorial element', + symbol: walk, + symbolSize: [50, 120], + z: 10, + data: [{ + value: 60, + symbolPosition: 'start' + }, { + value: 60, + symbolPosition: 'end' + }, { + value: 60, + symbolPosition: 'center' + }, { + value: 60, + symbolPosition: 'end', + symbolOffset: [-80, '-100%'] + }] + }, { + type: 'bar', + name: 'reference bar', + barGap: '-100%', + data: [60, 60, 60, 60] + }] +}; diff --git a/testdata/doc-example/pictorialBar-position.js.svg b/testdata/doc-example/pictorialBar-position.js.svg new file mode 100644 index 0000000..1d978f9 --- /dev/null +++ b/testdata/doc-example/pictorialBar-position.js.svg @@ -0,0 +1,126 @@ + + + +0 +20 +40 +60 +80 +symbolPosition: "start" +symbolOffset: [0, 0] +symbolPosition: "end" +symbolOffset: [0, 0] +symbolPosition: "center" +symbolOffset: [0, 0] +symbolPosition: "end" +symbolOffset: ['-100%', -120] + + + + + + +pictorial element + +reference bar + + + + + + + + + + \ No newline at end of file diff --git a/testdata/doc-example/pictorialBar-repeat.js b/testdata/doc-example/pictorialBar-repeat.js new file mode 100644 index 0000000..bab96a2 --- /dev/null +++ b/testdata/doc-example/pictorialBar-repeat.js @@ -0,0 +1,25 @@ +"use strict"; +option = { + legend: { + data: ['pictorialBar', 'bar'] + }, + xAxis: { + data: ['symbolRepeat: true', 'symbolRepeat: false'] + }, + yAxis: { + splitLine: { show: false } + }, + animationEasing: 'elasticOut', + series: [{ + type: 'pictorialBar', + symbol: 'circle', + data: [{ + value: 29000, + symbolRepeat: true, + symbolSize: [50, 50] + }, { + value: 29000, + symbolSize: [50, '100%'] + }] + }] +}; diff --git a/testdata/doc-example/pictorialBar-repeat.js.svg b/testdata/doc-example/pictorialBar-repeat.js.svg new file mode 100644 index 0000000..8679cb6 --- /dev/null +++ b/testdata/doc-example/pictorialBar-repeat.js.svg @@ -0,0 +1,131 @@ + + + + + + +0 +5,000 +10,000 +15,000 +20,000 +25,000 +30,000 +symbolRepeat: true +symbolRepeat: false + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/doc-example/pictorialBar-repeatDirection.js b/testdata/doc-example/pictorialBar-repeatDirection.js new file mode 100644 index 0000000..a166124 --- /dev/null +++ b/testdata/doc-example/pictorialBar-repeatDirection.js @@ -0,0 +1,52 @@ +"use strict"; +var paperDataURI = 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAJgAAAAyCAYAAACgRRKpAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAB6FJREFUeNrsnE9y2zYYxUmRkig7spVdpx3Hdqb7ZNeFO2PdoD1Cj9DeoEdKbmDPeNFNW7lu0y7tRZvsYqfjWhL/qPgggoIggABIQKQkwsOhE5sQCfzw3uNHJu5sNnOaZq29RttolwfAbxgwChO9nad//4C2C7S9Sfe3uzQobqNghdoJBdIw3R8qHnvNANcA1sBUGCaV9pYC7rYBbLvbgAFpaBgmWbujlO1NA9h2wQTbcdHOoih2ZujLa7WcFtoMtUsKuFEDWL3bkAHq2GTnT+OJkyTzsXRd1/G8FoYN9vBnQ+pGZ7f7BrDqYSLbq6IdxXGM96BKIlBgDP97mgj7aLXcDLa8fgqoGwFu1ABmvzwwLAuTTJmw/SFIfG/ZBmEMIwRiHCVOnCTSPkk/BDoD7YHJbvcNYOVgYmtNWo1cs0xJ8pQJDgXIfM9bscE4TrDyAWwETuEEpP0QSzWU365T0CpXtzoDdsJY3bmpjqfT0AlRKMfWhQBhFYkGLAwjpE6JIxsnAAz6YW0QjksQaBGGTq0fw/mt0kJvXQA7cezWmpYaqBJ73XmKREABQMAKARjZsOXZqU4/FvLbWgu9VQA24NzRGYEJJm6C1GmuJJ4w39C5Sj6x/H6IKiWxPHflwQv9wPEV5TeibgS4200DzGitSdX6VCZWR0nonAR98dQNgxInpey0BvnNeKHXJGDGYYLiJQwiqIjuHZ+uKsWpEsUYOHVAeOdm0k4rzm9vKYUbrRswY7UmcVYa48mR5SN2YgkoMlXCoHEmQ6cfAojni1VkAUmsrEplVddCfitU6FUFzDpMvDw1nkzFA5dz91dkYvP61MlJREV8waQWUSWRnVac35QeY/EAe83c0RmD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QgogIlYXRGYqCLrBdkAsB/RN987Gu9kgY3CyUGA1Mlq68ptNupjOnd9vaCj/OhF/fVtJ81Mi2ymX+yOMqCgHwCIQAX7ElX7DKj9vWDpIXj2LPLm93ffoh3Z1vmPTa3nNtU7NNW3NvLKKnAMhPDSCyRVpUVRdVYYKAImXBsTwo0DtTKmvBOvEjbb9TZdK8X5TOEOkpQr3DSwF7E6+u6ubAOHgQVQEiZtoJQA48A2TGE7XidstnObqpUG3bZW3tSxOs7jlapbKaC0AWNgg1d4vqsCtnXkNtFbG2XqTjqPVypqdwxQtyY7L/xGa9Ww2c5txPZgeDptX/mY7E2CWbEgvulAGQOsTrDZzm1Cq8t/k2AngbICWJ1gs5Xbij5e2TWgrAPGwHaSggbAvariAovktjKPV3YdqLUCVjfYeLmt6JsEDVA1A6xusEFue/HiuM5Wt5FA1QKwusD28uXLBqhtB0wAG2znOwLYVgFVa8AY2AYUbN9sEWBbDdTGALYO2NYE2E4BtZGA2YLNEmA7DdTGA2YSttPT04nrut0GqAYwVdiGjsZrRkdHR3ftdlv3aQP9/zA0QO0KYBzgpO+0KQL2wCjUqMGmAUwJNgFgDVANYGZgQ4DdI8AGDVANYFba3/98+PqLzz+7ajCw1/4XYABXWBExzrUA+gAAAABJRU5ErkJggg=='; +option = { + backgroundColor: '#0f375f', + legend: { + data: ['all'], + textStyle: { color: '#ddd' } + }, + xAxis: [{ + data: ['symbolRepeatDirection: "start"', 'symbolRepeatDirection: "end"'], + axisTick: { show: false }, + axisLine: { + lineStyle: { + color: '#ccc' + } + }, + axisLabel: { + margin: 20, + textStyle: { + color: '#ddd', + fontSize: 14 + } + } + }], + yAxis: { + splitLine: { show: false }, + axisTick: { show: false }, + axisLine: { show: false }, + axisLabel: { show: false } + }, + animationEasing: 'elasticOut', + series: [{ + type: 'pictorialBar', + name: 'all', + hoverAnimation: true, + symbol: 'image://' + paperDataURI, + symbolRepeat: true, + symbolSize: [130, 30], + symbolOffset: [0, 10], + symbolMargin: '-30%', + animationDelay: function (dataIndex, params) { + return params.index * 30; + }, + data: [{ + value: 13000, + symbolRepeatDirection: 'start' + }, { + value: 13000, + symbolRepeatDirection: 'end' + }] + }] +}; diff --git a/testdata/doc-example/pictorialBar-repeatDirection.js.svg b/testdata/doc-example/pictorialBar-repeatDirection.js.svg new file mode 100644 index 0000000..1bc9554 --- /dev/null +++ b/testdata/doc-example/pictorialBar-repeatDirection.js.svg @@ -0,0 +1,855 @@ + + + +symbolRepeatDirection: "start" +symbolRepeatDirection: "end" + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +all + + \ No newline at end of file diff --git a/testdata/doc-example/pictorialBar-repeatLayout.js b/testdata/doc-example/pictorialBar-repeatLayout.js new file mode 100644 index 0000000..af6e134 --- /dev/null +++ b/testdata/doc-example/pictorialBar-repeatLayout.js @@ -0,0 +1,200 @@ +"use strict"; +var paper = 'image://data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAJgAAAAyCAYAAACgRRKpAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAB6FJREFUeNrsnE9y2zYYxUmRkig7spVdpx3Hdqb7ZNeFO2PdoD1Cj9DeoEdKbmDPeNFNW7lu0y7tRZvsYqfjWhL/qPgggoIggABIQKQkwsOhE5sQCfzw3uNHJu5sNnOaZq29RttolwfAbxgwChO9nad//4C2C7S9Sfe3uzQobqNghdoJBdIw3R8qHnvNANcA1sBUGCaV9pYC7rYBbLvbgAFpaBgmWbujlO1NA9h2wQTbcdHOoih2ZujLa7WcFtoMtUsKuFEDWL3bkAHq2GTnT+OJkyTzsXRd1/G8FoYN9vBnQ+pGZ7f7BrDqYSLbq6IdxXGM96BKIlBgDP97mgj7aLXcDLa8fgqoGwFu1ABmvzwwLAuTTJmw/SFIfG/ZBmEMIwRiHCVOnCTSPkk/BDoD7YHJbvcNYOVg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AGDVANYFba3/98+PqLzz+7ajCw1/4XYABXWBExzrUA+gAAAABJRU5ErkJggg=='; +var startData = 13000; +var maxData = 18000; +var minData = 5000; +option = { + backgroundColor: '#0f375f', + tooltip: {}, + legend: { + data: ['all'], + textStyle: { color: '#ddd' } + }, + grid: { + right: 20, + left: 140, + bottom: 160 + }, + xAxis: { + data: ['a', 'b', 'c', 'd'], + axisTick: { show: false }, + axisLine: { + lineStyle: { + color: '#ddd' + } + }, + axisLabel: { show: false } + }, + yAxis: { + splitLine: { show: false }, + axisTick: { + lineStyle: { + color: '#ddd' + } + }, + axisLine: { + lineStyle: { + color: '#ddd' + } + }, + axisLabel: { + textStyle: { + color: '#ddd' + } + } + }, + animationEasing: 'cubicOut', + animationDuration: 100, + animationDurationUpdate: 2000, + series: [{ + type: 'pictorialBar', + name: 'all', + id: 'paper', + hoverAnimation: true, + label: { + normal: { + show: true, + position: 'top', + formatter: '{c} km', + textStyle: { + fontSize: 16, + color: '#e54035' + } + } + }, + symbol: paper, + symbolSize: ['70%', 50], + symbolMargin: '-25%', + data: [{ + value: maxData, + symbolRepeat: true + }, { + value: startData, + symbolRepeat: true + }, { + value: startData, + symbolBoundingData: startData, + symbolRepeat: true + }, { + value: startData, + symbolBoundingData: startData, + symbolRepeat: 20 + }], + markLine: { + symbol: ['none', 'none'], + label: { + normal: { show: false } + }, + lineStyle: { + normal: { + color: '#e54035' + } + }, + data: [{ + yAxis: startData + }] + } + }, { + name: 'all', + type: 'pictorialBar', + symbol: 'circle', + itemStyle: { + normal: { + color: '#185491' + } + }, + silent: true, + symbolSize: ['150%', 50], + symbolOffset: [0, 20], + z: -10, + data: [1, 1, 1, 1] + }] +}; +setInterval(function () { + var dynamicData = Math.round(Math.random() * (maxData - minData) + minData); + myChart.setOption({ + series: [{ + id: 'paper', + data: [{ + value: maxData, + symbolRepeat: true + }, { + value: dynamicData, + symbolRepeat: true + }, { + value: dynamicData, + symbolBoundingData: dynamicData, + symbolRepeat: true + }, { + value: dynamicData, + symbolBoundingData: dynamicData, + symbolRepeat: 20 + }], + markLine: { + data: [{ + yAxis: dynamicData + }] + } + }] + }); +}, 3000); +// Add descriptions. +function addDescriptions() { + var descriptions = [ + [ + 'symbolBoundingData:', + 'value:', + 'symbolRepeat:', + 'characteristic:', + ], + [ + 'default', + 'max value', + 'true (auto)', + 'This is a standard' + ], + [ + 'default', + 'current value', + 'true (auto)', + 'Not accurate\nSymbol gap stable\nAppropriate to compare\nwith other bar' + ], + [ + 'current value', + 'current value', + 'true (auto)', + 'Accurate\nSymbol gap unstable\nInappropriate to compare\nwith other bar' + ], + [ + 'current value', + 'current value', + '20 (a fixed number)', + 'Accurate\nSymbol gap unstable\nNot responsive' + ] + ]; + myChart.setOption({ + graphic: descriptions.map(function (item, index) { + var pos = myChart.convertToPixel('grid', [Math.max(index - 1, 0), -1000]); + return { + type: 'group', + position: pos, + left: index ? null : 10, + children: [{ + type: 'text', + left: 'center', + top: 0, + style: { + text: descriptions[index].join('\n\n'), + fill: index ? '#fff' : 'yellow', + textAlign: index ? 'left' : 'right' + }, + z: 101 + }] + }; + }) + }, { silent: true }); +} +setTimeout(function () { + addDescriptions(); + myChart.on('updated', addDescriptions); +}, 100); diff --git a/testdata/doc-example/pictorialBar-repeatLayout.js.svg b/testdata/doc-example/pictorialBar-repeatLayout.js.svg new file mode 100644 index 0000000..5758db2 --- /dev/null +++ b/testdata/doc-example/pictorialBar-repeatLayout.js.svg @@ -0,0 +1,787 @@ + + + + + + + + + + + +0 +3,000 +6,000 +9,000 +12,000 +15,000 +18,000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +18000 km +13000 km +13000 km +13000 km + + +all + + + \ No newline at end of file diff --git a/testdata/doc-example/pictorialBar-symbolBoundingDataArray.js b/testdata/doc-example/pictorialBar-symbolBoundingDataArray.js new file mode 100644 index 0000000..f57b2d4 --- /dev/null +++ b/testdata/doc-example/pictorialBar-symbolBoundingDataArray.js @@ -0,0 +1,82 @@ +"use strict"; +// Thanks [anoosurf](https://github.com/anoosurf) ~. +var starPath = 'path://m15.5,19c-0.082,0 -0.164,-0.02 -0.239,-0.061l-5.261,-2.869l-5.261,2.869c-0.168,0.092 -0.373,0.079 -0.529,-0.032s-0.235,-0.301 -0.203,-0.49l0.958,-5.746l-3.818,-3.818c-0.132,-0.132 -0.18,-0.328 -0.123,-0.506s0.209,-0.31 0.394,-0.341l5.749,-0.958l2.386,-4.772c0.085,-0.169 0.258,-0.276 0.447,-0.276s0.363,0.107 0.447,0.276l2.386,4.772l5.749,0.958c0.185,0.031 0.337,0.162 0.394,0.341s0.01,0.374 -0.123,0.506l-3.818,3.818l0.958,5.746c0.031,0.189 -0.048,0.379 -0.203,0.49c-0.086,0.061 -0.188,0.093 -0.29,0.093z'; +var categoryData = ['DTA', 'Fin', 'Tool', 'VTG', 'CAAT', 'UYL', 'TC']; +var data = [-12, -60, 34, 23, -21, 0, -25]; +option = { + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'shadow' + } + }, + grid: { + left: 120 + }, + xAxis: { + splitLine: { show: false }, + axisLine: { show: false }, + axisTick: { show: false }, + axisLabel: { show: false } + }, + yAxis: { + data: categoryData, + axisTick: { show: false }, + axisLine: { + lineStyle: { color: '#ccc' } + }, + axisLabel: { + margin: 40, + textStyle: { + color: '#999', + fontSize: 16 + } + }, + splitLine: { show: true }, + position: 'top' + }, + series: [{ + name: 'bg', + type: 'pictorialBar', + symbol: starPath, + tooltip: { trigger: 'none' }, + itemStyle: { + normal: { + color: '#ddd' + } + }, + silent: true, + symbolRepeat: 'fixed', + symbolClip: false, + symbolBoundingData: 40, + symbolSize: ['80%', '80%'], + z: -1, + data: data + }, { + name: 'bg', + type: 'pictorialBar', + symbol: starPath, + tooltip: { trigger: 'none' }, + itemStyle: { + normal: { + color: '#ddd' + } + }, + silent: true, + symbolRepeat: 'fixed', + symbolClip: false, + symbolBoundingData: -60, + symbolSize: ['80%', '80%'], + z: -1, + data: data + }, { + name: 'data', + type: 'pictorialBar', + symbol: starPath, + symbolRepeat: true, + symbolClip: true, + symbolSize: ['80%', '80%'], + symbolBoundingData: [-60, 40], + data: data + }] +}; diff --git a/testdata/doc-example/pictorialBar-symbolBoundingDataArray.js.svg b/testdata/doc-example/pictorialBar-symbolBoundingDataArray.js.svg new file mode 100644 index 0000000..19c134f --- /dev/null +++ b/testdata/doc-example/pictorialBar-symbolBoundingDataArray.js.svg @@ -0,0 +1,1259 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +DTA +Fin +Tool +VTG +CAAT +UYL +TC + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/doc-example/pictorialBar-symbolSize.js b/testdata/doc-example/pictorialBar-symbolSize.js new file mode 100644 index 0000000..84c61be --- /dev/null +++ b/testdata/doc-example/pictorialBar-symbolSize.js @@ -0,0 +1,110 @@ +"use strict"; +var rocket = 'path://M-244.396,44.399c0,0,0.47-2.931-2.427-6.512c2.819-8.221,3.21-15.709,3.21-15.709s5.795,1.383,5.795,7.325C-237.818,39.679-244.396,44.399-244.396,44.399z M-260.371,40.827c0,0-3.881-12.946-3.881-18.319c0-2.416,0.262-4.566,0.669-6.517h17.684c0.411,1.952,0.675,4.104,0.675,6.519c0,5.291-3.87,18.317-3.87,18.317H-260.371z M-254.745,18.951c-1.99,0-3.603,1.676-3.603,3.744c0,2.068,1.612,3.744,3.603,3.744c1.988,0,3.602-1.676,3.602-3.744S-252.757,18.951-254.745,18.951z M-255.521,2.228v-5.098h1.402v4.969c1.603,1.213,5.941,5.069,7.901,12.5h-17.05C-261.373,7.373-257.245,3.558-255.521,2.228zM-265.07,44.399c0,0-6.577-4.721-6.577-14.896c0-5.942,5.794-7.325,5.794-7.325s0.393,7.488,3.211,15.708C-265.539,41.469-265.07,44.399-265.07,44.399z M-252.36,45.15l-1.176-1.22L-254.789,48l-1.487-4.069l-1.019,2.116l-1.488-3.826h8.067L-252.36,45.15z'; +option = { + color: ['#bb0004', '#FFD48A'], + legend: { + data: ['pictorial element', 'reference bar'] + }, + xAxis: { + data: ['a', 'b', 'c', 'd'], + axisTick: { + show: false + }, + axisLabel: { + interval: 0 + } + }, + yAxis: { + max: 80, + splitLine: { show: false } + }, + grid: { + left: 40, + right: 10 + }, + series: [{ + type: 'pictorialBar', + name: 'pictorial element', + symbol: rocket, + z: 10, + data: [{ + value: 60, + symbolSize: [ + '50%', + '100%' // 100% of the height of reference bar. + ] + }, { + value: 60, + symbolSize: [ + '50%', + 120 // Fixed height value. + ] + }, { + value: 60, + symbolSize: 50 // Equivalent to [50, 50] + }, { + value: 60, + symbolRepeat: true, + symbolSize: '70%' // Equivalent to ['70%', '70%'] + // And both width and height percentage are calculated based + // on the width of reference bar when symbolRepeat used. + }] + }, { + type: 'bar', + name: 'reference bar', + barGap: '-100%', + data: [60, 60, 60, 60] + }] +}; +// Add descriptions. +function addDescriptions() { + var descriptions = [ + [ + 'symbolSize: ["50%", "100%"]', + 'That is:', + '50% of reference bar width', + '100% of reference bar height.' + ], + [ + 'symbolSize: ["50%", 120]', + 'That is:', + '50% of reference bar width,', + 'fixed height 120.' + ], + [ + 'symbolSize: 50', + 'equivalent to [50, 50]' + ], + [ + 'symbolSize: "70%"', + 'equivalent to ["70%", "70%"]', + '', + 'When symbolRepeat used, both', + 'width and height percentage are', + 'calculated based on the width of', + 'reference bar.' + ] + ]; + myChart.setOption({ + graphic: option.xAxis.data.map(function (itemName, index) { + return { + type: 'group', + position: myChart.convertToPixel('grid', [index, 70]), + children: [{ + type: 'text', + left: 'center', + top: 'middle', + style: { + text: descriptions[index].join('\n'), + fill: '#bb0004' + }, + z: 101 + }] + }; + }) + }, { silent: true }); +} +setTimeout(function () { + addDescriptions(); + myChart.on('updated', addDescriptions); +}, 100); diff --git a/testdata/doc-example/pictorialBar-symbolSize.js.svg b/testdata/doc-example/pictorialBar-symbolSize.js.svg new file mode 100644 index 0000000..c2402e0 --- /dev/null +++ b/testdata/doc-example/pictorialBar-symbolSize.js.svg @@ -0,0 +1,158 @@ + + + +0 +20 +40 +60 +80 +a +b +c +d + + + + + + +pictorial element + +reference bar + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/doc-example/pie-highlight.js b/testdata/doc-example/pie-highlight.js new file mode 100644 index 0000000..2e36cb7 --- /dev/null +++ b/testdata/doc-example/pie-highlight.js @@ -0,0 +1,61 @@ +"use strict"; +option = { + title: { + text: '饼图程序调用高亮示例', + left: 'center' + }, + tooltip: { + trigger: 'item', + formatter: '{a}
{b} : {c} ({d}%)' + }, + legend: { + orient: 'vertical', + left: 'left', + data: ['直接访问', '邮件营销', '联盟广告', '视频广告', '搜索引擎'] + }, + series: [ + { + name: '访问来源', + type: 'pie', + radius: '55%', + center: ['50%', '60%'], + data: [ + { value: 335, name: '直接访问' }, + { value: 310, name: '邮件营销' }, + { value: 234, name: '联盟广告' }, + { value: 135, name: '视频广告' }, + { value: 1548, name: '搜索引擎' } + ], + emphasis: { + itemStyle: { + shadowBlur: 10, + shadowOffsetX: 0, + shadowColor: 'rgba(0, 0, 0, 0.5)' + } + } + } + ] +}; +app.currentIndex = -1; +setInterval(function () { + var dataLen = option.series[0].data.length; + // 取消之前高亮的图形 + myChart.dispatchAction({ + type: 'downplay', + seriesIndex: 0, + dataIndex: app.currentIndex + }); + app.currentIndex = (app.currentIndex + 1) % dataLen; + // 高亮当前图形 + myChart.dispatchAction({ + type: 'highlight', + seriesIndex: 0, + dataIndex: app.currentIndex + }); + // 显示 tooltip + myChart.dispatchAction({ + type: 'showTip', + seriesIndex: 0, + dataIndex: app.currentIndex + }); +}, 1000); diff --git a/testdata/doc-example/pie-highlight.js.svg b/testdata/doc-example/pie-highlight.js.svg new file mode 100644 index 0000000..70e9162 --- /dev/null +++ b/testdata/doc-example/pie-highlight.js.svg @@ -0,0 +1,90 @@ + + + + + + + + + + + + +直接访问 +邮件营销 +联盟广告 +视频广告 +搜索引擎 + + +直接访问 + +邮件营销 + +联盟广告 + +视频广告 + +搜索引擎 + +饼图程序调用高亮示例 + + \ No newline at end of file diff --git a/testdata/doc-example/pie-label-bleedMargin.js b/testdata/doc-example/pie-label-bleedMargin.js new file mode 100644 index 0000000..7a30c8d --- /dev/null +++ b/testdata/doc-example/pie-label-bleedMargin.js @@ -0,0 +1,69 @@ +"use strict"; +var data = [{ + name: 'Apple Numbers', + value: 70 + }, { + name: 'Strawberry Numbers', + value: 68 + }, { + name: 'Banana Numbers', + value: 48 + }, { + name: 'Orange Numbers', + value: 40 + }, { + name: 'Pear Numbers', + value: 32 + }, { + name: 'Pineapple Numbers', + value: 27 + }, { + name: 'Grape Numbers', + value: 18 + }]; +option = { + title: [{ + text: 'Pie label margin' + }, { + subtext: 'bleedMargin: 50', + left: '25%', + top: '75%', + textAlign: 'center' + }, { + subtext: 'bleedMargin: 10', + left: '75%', + top: '75%', + textAlign: 'center' + }], + series: [{ + type: 'pie', + radius: '25%', + center: ['50%', '50%'], + data: data, + animation: false, + label: { + position: 'outer', + alignTo: 'labelLine', + bleedMargin: 50 + }, + left: 0, + right: '50%', + top: 0, + bottom: 0 + }, { + type: 'pie', + radius: '25%', + center: ['50%', '50%'], + data: data, + animation: false, + label: { + position: 'outer', + alignTo: 'labelLine', + bleedMargin: 10 + }, + left: '50%', + right: 0, + top: 0, + bottom: 0 + }] +}; diff --git a/testdata/doc-example/pie-label-bleedMargin.js.svg b/testdata/doc-example/pie-label-bleedMargin.js.svg new file mode 100644 index 0000000..717ff30 --- /dev/null +++ b/testdata/doc-example/pie-label-bleedMargin.js.svg @@ -0,0 +1,51 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Apple Numbers +Strawberry N... +Banana Nu... +Orange Nu... +Pear Numbers +Pineapple ... +Grape Num... +Apple Numbers +Strawberry Numbers +Banana Numbers +Orange Numbers +Pear Numbers +Pineapple Numbers +Grape Numbers + + + +Pie label margin +bleedMargin: 50 +bleedMargin: 10 + \ No newline at end of file diff --git a/testdata/doc-example/pie-label-distanceToLabelLine.js b/testdata/doc-example/pie-label-distanceToLabelLine.js new file mode 100644 index 0000000..7d28233 --- /dev/null +++ b/testdata/doc-example/pie-label-distanceToLabelLine.js @@ -0,0 +1,69 @@ +"use strict"; +var data = [{ + name: 'Apple Numbers', + value: 70 + }, { + name: 'Strawberry Numbers', + value: 68 + }, { + name: 'Banana Numbers', + value: 48 + }, { + name: 'Orange Numbers', + value: 40 + }, { + name: 'Pear Numbers', + value: 32 + }, { + name: 'Pineapple Numbers', + value: 27 + }, { + name: 'Grape Numbers', + value: 18 + }]; +option = { + title: [{ + text: 'Pie label margin' + }, { + subtext: 'distanceToLabelLine: 5', + left: '25%', + top: '75%', + textAlign: 'center' + }, { + subtext: 'distanceToLabelLine: 20', + left: '75%', + top: '75%', + textAlign: 'center' + }], + series: [{ + type: 'pie', + radius: '25%', + center: ['50%', '50%'], + data: data, + animation: false, + label: { + position: 'outer', + alignTo: 'labelLine', + distanceToLabelLine: 5 + }, + left: 0, + right: '50%', + top: 0, + bottom: 0 + }, { + type: 'pie', + radius: '25%', + center: ['50%', '50%'], + data: data, + animation: false, + label: { + position: 'outer', + alignTo: 'labelLine', + distanceToLabelLine: 20 + }, + left: '50%', + right: 0, + top: 0, + bottom: 0 + }] +}; diff --git a/testdata/doc-example/pie-label-distanceToLabelLine.js.svg b/testdata/doc-example/pie-label-distanceToLabelLine.js.svg new file mode 100644 index 0000000..c43e2f9 --- /dev/null +++ b/testdata/doc-example/pie-label-distanceToLabelLine.js.svg @@ -0,0 +1,51 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Apple Numbers +Strawberry Numbers +Banana Numbers +Orange Numbers +Pear Numbers +Pineapple Numbers +Grape Numbers +Apple Numbers +Strawberry Numbers +Banana Numbers +Orange Numbers +Pear Numbers +Pineapple Numb... +Grape Numbers + + + +Pie label margin +distanceToLabelLine: 5 +distanceToLabelLine: 20 + \ No newline at end of file diff --git a/testdata/doc-example/pie-label-margin.js b/testdata/doc-example/pie-label-margin.js new file mode 100644 index 0000000..6549aa5 --- /dev/null +++ b/testdata/doc-example/pie-label-margin.js @@ -0,0 +1,69 @@ +"use strict"; +var data = [{ + name: 'Apples', + value: 70 + }, { + name: 'Strawberries', + value: 68 + }, { + name: 'Bananas', + value: 48 + }, { + name: 'Oranges', + value: 40 + }, { + name: 'Pears', + value: 32 + }, { + name: 'Pineapples', + value: 27 + }, { + name: 'Grapes', + value: 18 + }]; +option = { + title: [{ + text: 'Pie label margin' + }, { + subtext: 'margin: "25%"', + left: '25%', + top: '75%', + textAlign: 'center' + }, { + subtext: 'margin: 10', + left: '75%', + top: '75%', + textAlign: 'center' + }], + series: [{ + type: 'pie', + radius: '25%', + center: ['50%', '50%'], + data: data, + animation: false, + label: { + position: 'outer', + alignTo: 'edge', + margin: '25%' + }, + left: 0, + right: '50%', + top: 0, + bottom: 0 + }, { + type: 'pie', + radius: '25%', + center: ['50%', '50%'], + data: data, + animation: false, + label: { + position: 'outer', + alignTo: 'edge', + margin: 10 + }, + left: '50%', + right: 0, + top: 0, + bottom: 0 + }] +}; diff --git a/testdata/doc-example/pie-label-margin.js.svg b/testdata/doc-example/pie-label-margin.js.svg new file mode 100644 index 0000000..87c3f2d --- /dev/null +++ b/testdata/doc-example/pie-label-margin.js.svg @@ -0,0 +1,51 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Apples +Str... +Bananas +Or... +P... +Pinea... +Grapes +Apples +Strawberries +Bananas +Oranges +Pears +Pineapples +Grapes + + + +Pie label margin +margin: "25%" +margin: 10 + \ No newline at end of file diff --git a/testdata/doc-example/pie-media.js b/testdata/doc-example/pie-media.js new file mode 100644 index 0000000..57d814a --- /dev/null +++ b/testdata/doc-example/pie-media.js @@ -0,0 +1,175 @@ +"use strict"; +$.when($.getScript(ROOT_PATH + '/data/asset/data/timelineGDP.js'), $.getScript(ROOT_PATH + '/data/asset/data/draggable.js')).done(function () { + draggable.init($('div[_echarts_instance_]')[0], myChart, { + width: 700, + height: 400, + throttle: 70 + }); + myChart.hideLoading(); + option = { + baseOption: { + title: { + text: '南丁格尔玫瑰图', + subtext: '纯属虚构', + x: 'center' + }, + tooltip: { + trigger: 'item', + formatter: "{a}
{b} : {c} ({d}%)" + }, + legend: { + data: ['rose1', 'rose2', 'rose3', 'rose4', 'rose5', 'rose6', 'rose7', 'rose8'] + }, + toolbox: { + show: true, + feature: { + mark: { show: true }, + dataView: { show: true, readOnly: false }, + magicType: { + show: true, + type: ['pie', 'funnel'] + }, + restore: { show: true }, + saveAsImage: { show: true } + } + }, + calculable: true, + series: [ + { + name: '半径模式', + type: 'pie', + roseType: 'radius', + label: { + normal: { + show: false + }, + emphasis: { + show: true + } + }, + lableLine: { + normal: { + show: false + }, + emphasis: { + show: true + } + }, + data: [ + { value: 10, name: 'rose1' }, + { value: 5, name: 'rose2' }, + { value: 15, name: 'rose3' }, + { value: 25, name: 'rose4' }, + { value: 20, name: 'rose5' }, + { value: 35, name: 'rose6' }, + { value: 30, name: 'rose7' }, + { value: 40, name: 'rose8' } + ] + }, + { + name: '面积模式', + type: 'pie', + roseType: 'area', + data: [ + { value: 10, name: 'rose1' }, + { value: 5, name: 'rose2' }, + { value: 15, name: 'rose3' }, + { value: 25, name: 'rose4' }, + { value: 20, name: 'rose5' }, + { value: 35, name: 'rose6' }, + { value: 30, name: 'rose7' }, + { value: 40, name: 'rose8' } + ] + } + ] + }, + media: [ + { + option: { + legend: { + right: 'center', + bottom: 0, + orient: 'horizontal' + }, + series: [ + { + radius: [20, '50%'], + center: ['25%', '50%'] + }, + { + radius: [30, '50%'], + center: ['75%', '50%'] + } + ] + } + }, + { + query: { + minAspectRatio: 1 + }, + option: { + legend: { + right: 'center', + bottom: 0, + orient: 'horizontal' + }, + series: [ + { + radius: [20, '50%'], + center: ['25%', '50%'] + }, + { + radius: [30, '50%'], + center: ['75%', '50%'] + } + ] + } + }, + { + query: { + maxAspectRatio: 1 + }, + option: { + legend: { + right: 'center', + bottom: 0, + orient: 'horizontal' + }, + series: [ + { + radius: [20, '50%'], + center: ['50%', '30%'] + }, + { + radius: [30, '50%'], + center: ['50%', '70%'] + } + ] + } + }, + { + query: { + maxWidth: 500 + }, + option: { + legend: { + right: 10, + top: '15%', + orient: 'vertical' + }, + series: [ + { + radius: [20, '50%'], + center: ['50%', '30%'] + }, + { + radius: [30, '50%'], + center: ['50%', '75%'] + } + ] + } + } + ] + }; + myChart.setOption(option); +}); diff --git a/testdata/doc-example/polar-anticlockwise.js b/testdata/doc-example/polar-anticlockwise.js new file mode 100644 index 0000000..ff0aeea --- /dev/null +++ b/testdata/doc-example/polar-anticlockwise.js @@ -0,0 +1,16 @@ +"use strict"; +option = { + polar: {}, + angleAxis: { + min: 0, + max: 360, + interval: 30, + clockwise: false + }, + radiusAxis: { + min: 0, + max: 10, + interval: 2 + }, + series: [] +}; diff --git a/testdata/doc-example/polar-anticlockwise.js.svg b/testdata/doc-example/polar-anticlockwise.js.svg new file mode 100644 index 0000000..afb68da --- /dev/null +++ b/testdata/doc-example/polar-anticlockwise.js.svg @@ -0,0 +1,32 @@ + + + +0 +30 +60 +90 +120 +150 +180 +210 +240 +270 +300 +330 + + + + + + + + + + +0 +2 +4 +6 +8 +10 + \ No newline at end of file diff --git a/testdata/doc-example/polar-start-angle.js b/testdata/doc-example/polar-start-angle.js new file mode 100644 index 0000000..3e997dd --- /dev/null +++ b/testdata/doc-example/polar-start-angle.js @@ -0,0 +1,16 @@ +"use strict"; +option = { + polar: {}, + angleAxis: { + min: 0, + max: 360, + interval: 30, + startAngle: 45 + }, + radiusAxis: { + min: 0, + max: 10, + interval: 2 + }, + series: [] +}; diff --git a/testdata/doc-example/polar-start-angle.js.svg b/testdata/doc-example/polar-start-angle.js.svg new file mode 100644 index 0000000..26cbb97 --- /dev/null +++ b/testdata/doc-example/polar-start-angle.js.svg @@ -0,0 +1,32 @@ + + + +0 +30 +60 +90 +120 +150 +180 +210 +240 +270 +300 +330 + + + + + + + + + + +0 +2 +4 +6 +8 +10 + \ No newline at end of file diff --git a/testdata/doc-example/radar.js b/testdata/doc-example/radar.js new file mode 100644 index 0000000..f48cb5d --- /dev/null +++ b/testdata/doc-example/radar.js @@ -0,0 +1,50 @@ +"use strict"; +option = { + radar: { + indicator: [ + { text: '指标一' }, + { text: '指标二' }, + { text: '指标三' }, + { text: '指标四' }, + { text: '指标五' } + ], + center: ['50%', '50%'], + radius: '80%', + startAngle: 90, + splitNumber: 4, + shape: 'circle', + name: { + formatter: '【{value}】', + textStyle: { + color: '#72ACD1' + } + }, + splitArea: { + areaStyle: { + color: ['#B8D3E4', '#96C5E3', '#7DB5DA', '#72ACD1'] + } + }, + axisTick: { + show: true, + lineStyle: { + color: 'rgba(255, 255, 255, 0.8)' + } + }, + axisLabel: { + show: true, + textStyle: { + color: 'white' + } + }, + axisLine: { + lineStyle: { + color: 'rgba(255, 255, 255, 0.4)' + } + }, + splitLine: { + lineStyle: { + color: 'rgba(255, 255, 255, 0.4)' + } + } + } +}; diff --git a/testdata/doc-example/radar.js.svg b/testdata/doc-example/radar.js.svg new file mode 100644 index 0000000..16789c2 --- /dev/null +++ b/testdata/doc-example/radar.js.svg @@ -0,0 +1,18 @@ + + + + + + + + +【指标一】 + +【指标二】 + +【指标三】 + +【指标四】 + +【指标五】 + \ No newline at end of file diff --git a/testdata/doc-example/scatter-dataZoom-all.js b/testdata/doc-example/scatter-dataZoom-all.js new file mode 100644 index 0000000..a77ff48 --- /dev/null +++ b/testdata/doc-example/scatter-dataZoom-all.js @@ -0,0 +1,105 @@ +"use strict"; +var data1 = []; +var data2 = []; +var data3 = []; +var random = function (max) { + return (Math.random() * max).toFixed(3); +}; +for (var i = 0; i < 500; i++) { + data1.push([random(15), random(10), random(1)]); + data2.push([random(10), random(10), random(1)]); + data3.push([random(15), random(10), random(1)]); +} +option = { + animation: false, + legend: { + data: ['scatter', 'scatter2', 'scatter3'] + }, + tooltip: {}, + xAxis: { + type: 'value', + min: 'dataMin', + max: 'dataMax', + splitLine: { + show: true + } + }, + yAxis: { + type: 'value', + min: 'dataMin', + max: 'dataMax', + splitLine: { + show: true + } + }, + dataZoom: [ + { + type: 'slider', + show: true, + xAxisIndex: [0], + start: 1, + end: 35 + }, + { + type: 'slider', + show: true, + yAxisIndex: [0], + left: '93%', + start: 29, + end: 36 + }, + { + type: 'inside', + xAxisIndex: [0], + start: 1, + end: 35 + }, + { + type: 'inside', + yAxisIndex: [0], + start: 29, + end: 36 + } + ], + series: [ + { + name: 'scatter', + type: 'scatter', + itemStyle: { + normal: { + opacity: 0.8 + } + }, + symbolSize: function (val) { + return val[2] * 40; + }, + data: data1 + }, + { + name: 'scatter2', + type: 'scatter', + itemStyle: { + normal: { + opacity: 0.8 + } + }, + symbolSize: function (val) { + return val[2] * 40; + }, + data: data2 + }, + { + name: 'scatter3', + type: 'scatter', + itemStyle: { + normal: { + opacity: 0.8, + } + }, + symbolSize: function (val) { + return val[2] * 40; + }, + data: data3 + } + ] +}; diff --git a/testdata/doc-example/scatter-dataZoom-all.js.svg b/testdata/doc-example/scatter-dataZoom-all.js.svg new file mode 100644 index 0000000..fda9156 --- /dev/null +++ b/testdata/doc-example/scatter-dataZoom-all.js.svg @@ -0,0 +1,167 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +2.9 +3 +3.1 +3.2 +3.3 +3.4 +3.5 +3.599 +0.154 +1 +2 +3 +4 +5 +5.252 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +scatter + +scatter2 + +scatter3 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/doc-example/scatter-tutorial-dataZoom-1.js b/testdata/doc-example/scatter-tutorial-dataZoom-1.js new file mode 100644 index 0000000..eb9ec37 --- /dev/null +++ b/testdata/doc-example/scatter-tutorial-dataZoom-1.js @@ -0,0 +1,31 @@ +"use strict"; +option = { + xAxis: { + type: 'value' + }, + yAxis: { + type: 'value' + }, + dataZoom: [ + { + type: 'slider', + start: 1, + end: 35 + } + ], + series: [ + { + name: 'scatter', + type: 'scatter', + itemStyle: { + normal: { + opacity: 0.8 + } + }, + symbolSize: function (val) { + return val[2] * 40; + }, + data: [["14.616", "7.241", "0.896"], ["3.958", "5.701", "0.955"], ["2.768", "8.971", "0.669"], ["9.051", "9.710", "0.171"], ["14.046", "4.182", "0.536"], ["12.295", "1.429", "0.962"], ["4.417", "8.167", "0.113"], ["0.492", "4.771", "0.785"], ["7.632", "2.605", "0.645"], ["14.242", "5.042", "0.368"]] + } + ] +}; diff --git a/testdata/doc-example/scatter-tutorial-dataZoom-1.js.svg b/testdata/doc-example/scatter-tutorial-dataZoom-1.js.svg new file mode 100644 index 0000000..409f77f --- /dev/null +++ b/testdata/doc-example/scatter-tutorial-dataZoom-1.js.svg @@ -0,0 +1,139 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +0 +2 +4 +6 +8 +10 +0.146 +1 +2 +3 +4 +5 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/doc-example/scatter-tutorial-dataZoom-2.js b/testdata/doc-example/scatter-tutorial-dataZoom-2.js new file mode 100644 index 0000000..237d558 --- /dev/null +++ b/testdata/doc-example/scatter-tutorial-dataZoom-2.js @@ -0,0 +1,36 @@ +"use strict"; +option = { + xAxis: { + type: 'value' + }, + yAxis: { + type: 'value' + }, + dataZoom: [ + { + type: 'slider', + start: 1, + end: 35 + }, + { + type: 'inside', + start: 1, + end: 35 + } + ], + series: [ + { + name: 'scatter', + type: 'scatter', + itemStyle: { + normal: { + opacity: 0.8 + } + }, + symbolSize: function (val) { + return val[2] * 40; + }, + data: [["14.616", "7.241", "0.896"], ["3.958", "5.701", "0.955"], ["2.768", "8.971", "0.669"], ["9.051", "9.710", "0.171"], ["14.046", "4.182", "0.536"], ["12.295", "1.429", "0.962"], ["4.417", "8.167", "0.113"], ["0.492", "4.771", "0.785"], ["7.632", "2.605", "0.645"], ["14.242", "5.042", "0.368"]] + } + ] +}; diff --git a/testdata/doc-example/scatter-tutorial-dataZoom-2.js.svg b/testdata/doc-example/scatter-tutorial-dataZoom-2.js.svg new file mode 100644 index 0000000..409f77f --- /dev/null +++ b/testdata/doc-example/scatter-tutorial-dataZoom-2.js.svg @@ -0,0 +1,139 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +0 +2 +4 +6 +8 +10 +0.146 +1 +2 +3 +4 +5 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/doc-example/scatter-tutorial-dataZoom-3.js b/testdata/doc-example/scatter-tutorial-dataZoom-3.js new file mode 100644 index 0000000..7e1422b --- /dev/null +++ b/testdata/doc-example/scatter-tutorial-dataZoom-3.js @@ -0,0 +1,50 @@ +"use strict"; +option = { + xAxis: { + type: 'value' + }, + yAxis: { + type: 'value' + }, + dataZoom: [ + { + type: 'slider', + xAxisIndex: 0, + start: 10, + end: 60 + }, + { + type: 'inside', + xAxisIndex: 0, + start: 10, + end: 60 + }, + { + type: 'slider', + yAxisIndex: 0, + start: 30, + end: 80 + }, + { + type: 'inside', + yAxisIndex: 0, + start: 30, + end: 80 + } + ], + series: [ + { + name: 'scatter', + type: 'scatter', + itemStyle: { + normal: { + opacity: 0.8 + } + }, + symbolSize: function (val) { + return val[2] * 40; + }, + data: [["14.616", "7.241", "0.896"], ["3.958", "5.701", "0.955"], ["2.768", "8.971", "0.669"], ["9.051", "9.710", "0.171"], ["14.046", "4.182", "0.536"], ["12.295", "1.429", "0.962"], ["4.417", "8.167", "0.113"], ["0.492", "4.771", "0.785"], ["7.632", "2.605", "0.645"], ["14.242", "5.042", "0.368"]] + } + ] +}; diff --git a/testdata/doc-example/scatter-tutorial-dataZoom-3.js.svg b/testdata/doc-example/scatter-tutorial-dataZoom-3.js.svg new file mode 100644 index 0000000..2ea1c52 --- /dev/null +++ b/testdata/doc-example/scatter-tutorial-dataZoom-3.js.svg @@ -0,0 +1,143 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +2.691 +3 +4 +5 +6 +7 +7.177 +1.462 +2 +3 +4 +5 +6 +7 +8 +8.77 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/doc-example/scatter-visualMap-categories.js b/testdata/doc-example/scatter-visualMap-categories.js new file mode 100644 index 0000000..5bc7feb --- /dev/null +++ b/testdata/doc-example/scatter-visualMap-categories.js @@ -0,0 +1,228 @@ +"use strict"; +// Schema: +// date,AQIindex,PM2.5,PM10,CO,NO2,SO2 +var schema = [ + { name: 'date', index: 0, text: '日' }, + { name: 'AQIindex', index: 1, text: 'AQI指数' }, + { name: 'PM25', index: 2, text: 'PM2.5' }, + { name: 'PM10', index: 3, text: 'PM10' }, + { name: 'CO', index: 4, text: '一氧化碳(CO)' }, + { name: 'NO2', index: 5, text: '二氧化氮(NO₂)' }, + { name: 'SO2', index: 6, text: '二氧化硫(SO₂)' } +]; +var dataBJ = [ + [1, 55, 9, 56, 0.46, 18, 6, '良'], + [2, 25, 11, 21, 0.65, 34, 9, '优'], + [3, 56, 7, 63, 0.3, 14, 5, '良'], + [4, 33, 7, 29, 0.33, 16, 6, '优'], + [5, 42, 24, 44, 0.76, 40, 16, '优'], + [6, 82, 58, 90, 1.77, 68, 33, '良'], + [7, 74, 49, 77, 1.46, 48, 27, '良'], + [8, 78, 55, 80, 1.29, 59, 29, '良'], + [9, 267, 216, 280, '-', 108, 64, '重度污染'], + [10, 185, 127, 216, 2.52, 61, 27, '中度污染'], + [11, 39, 19, 38, 0.57, 31, 15, '优'], + [12, 41, 11, 40, 0.43, 21, 7, '优'], + [13, 64, 38, 74, 1.04, 46, 22, '良'], + [14, 108, 79, 120, 1.7, 75, 41, '轻度污染'], + [15, 108, 63, 116, 1.48, 44, 26, '轻度污染'], + [16, 33, 6, 29, 0.34, 13, 5, '优'], + [17, 94, 66, 110, 1.54, 62, 31, '良'], + [18, 186, 142, 192, 3.88, 93, 79, '中度污染'], + [19, 57, 31, 54, 0.96, 32, 14, '良'], + [20, 22, 8, 17, 0.48, 23, 10, '优'], + [21, 39, 15, 36, 0.61, 29, 13, '优'], + [22, 94, 69, 114, 2.08, 73, 39, '良'], + [23, 99, 73, 110, 2.43, 76, 48, '良'], + [24, 31, 12, 30, 0.5, 32, 16, '优'], + [25, 42, 27, 43, 1, 53, 22, '优'], + [26, 154, 117, 157, 3.05, 92, 58, '中度污染'], + [27, 234, 185, 230, 4.09, 123, 69, '重度污染'], + [28, 160, 120, 186, 2.77, 91, 50, '中度污染'], + [29, 134, 96, 165, 2.76, 83, 41, '轻度污染'], + [30, 52, 24, 60, 1.03, 50, 21, '良'], + [31, 46, 5, 49, 0.28, 10, 6, '优'] +]; +var dataGZ = [ + [1, 26, 37, 27, 1.163, 27, 13, '优'], + [2, 85, 62, 71, 1.195, 60, 8, '良'], + [3, 78, 38, 74, 1.363, 37, 7, '良'], + [4, 21, 21, 36, 0.634, 40, 9, '优'], + [5, 41, 42, 46, 0.915, 81, 13, '优'], + [6, 56, 52, 69, 1.067, 92, 16, '良'], + [7, 64, 30, 28, 0.924, 51, 2, '良'], + [8, 55, 48, 74, 1.236, 75, 26, '良'], + [9, 76, 85, 113, 1.237, 114, 27, '良'], + [10, 91, 81, 104, 1.041, 56, 40, '良'], + [11, 84, 39, 60, 0.964, 25, 11, '良'], + [12, 64, 51, 101, 0.862, 58, 23, '良'], + [13, 70, 69, 120, 1.198, 65, 36, '良'], + [14, 77, 105, 178, 2.549, 64, 16, '良'], + [15, 109, 68, 87, 0.996, 74, 29, '轻度污染'], + [16, 73, 68, 97, 0.905, 51, 34, '良'], + [17, 54, 27, 47, 0.592, 53, 12, '良'], + [18, 51, 61, 97, 0.811, 65, 19, '良'], + [19, 91, 71, 121, 1.374, 43, 18, '良'], + [20, 73, 102, 182, 2.787, 44, 19, '良'], + [21, 73, 50, 76, 0.717, 31, 20, '良'], + [22, 84, 94, 140, 2.238, 68, 18, '良'], + [23, 93, 77, 104, 1.165, 53, 7, '良'], + [24, 99, 130, 227, 3.97, 55, 15, '良'], + [25, 146, 84, 139, 1.094, 40, 17, '轻度污染'], + [26, 113, 108, 137, 1.481, 48, 15, '轻度污染'], + [27, 81, 48, 62, 1.619, 26, 3, '良'], + [28, 56, 48, 68, 1.336, 37, 9, '良'], + [29, 82, 92, 174, 3.29, 0, 13, '良'], + [30, 106, 116, 188, 3.628, 101, 16, '轻度污染'], + [31, 118, 50, 0, 1.383, 76, 11, '轻度污染'] +]; +var dataSH = [ + [1, 91, 45, 125, 0.82, 34, 23, '良'], + [2, 65, 27, 78, 0.86, 45, 29, '良'], + [3, 83, 60, 84, 1.09, 73, 27, '良'], + [4, 109, 81, 121, 1.28, 68, 51, '轻度污染'], + [5, 106, 77, 114, 1.07, 55, 51, '轻度污染'], + [6, 109, 81, 121, 1.28, 68, 51, '轻度污染'], + [7, 106, 77, 114, 1.07, 55, 51, '轻度污染'], + [8, 89, 65, 78, 0.86, 51, 26, '良'], + [9, 53, 33, 47, 0.64, 50, 17, '良'], + [10, 80, 55, 80, 1.01, 75, 24, '良'], + [11, 117, 81, 124, 1.03, 45, 24, '轻度污染'], + [12, 99, 71, 142, 1.1, 62, 42, '良'], + [13, 95, 69, 130, 1.28, 74, 50, '良'], + [14, 116, 87, 131, 1.47, 84, 40, '轻度污染'], + [15, 108, 80, 121, 1.3, 85, 37, '轻度污染'], + [16, 134, 83, 167, 1.16, 57, 43, '轻度污染'], + [17, 79, 43, 107, 1.05, 59, 37, '良'], + [18, 71, 46, 89, 0.86, 64, 25, '良'], + [19, 97, 71, 113, 1.17, 88, 31, '良'], + [20, 84, 57, 91, 0.85, 55, 31, '良'], + [21, 87, 63, 101, 0.9, 56, 41, '良'], + [22, 104, 77, 119, 1.09, 73, 48, '轻度污染'], + [23, 87, 62, 100, 1, 72, 28, '良'], + [24, 168, 128, 172, 1.49, 97, 56, '中度污染'], + [25, 65, 45, 51, 0.74, 39, 17, '良'], + [26, 39, 24, 38, 0.61, 47, 17, '优'], + [27, 39, 24, 39, 0.59, 50, 19, '优'], + [28, 93, 68, 96, 1.05, 79, 29, '良'], + [29, 188, 143, 197, 1.66, 99, 51, '中度污染'], + [30, 174, 131, 174, 1.55, 108, 50, '中度污染'], + [31, 187, 143, 201, 1.39, 89, 53, '中度污染'] +]; +var itemStyle = { + normal: { + opacity: 0.8, + shadowBlur: 10, + shadowOffsetX: 0, + shadowOffsetY: 0, + shadowColor: 'rgba(0, 0, 0, 0.5)' + } +}; +option = { + color: ['#dd4444', '#fec42c', '#80F1BE'], + legend: { + top: 10, + data: ['北京', '上海', '广州'] + }, + grid: { + left: '10%', + right: 200, + top: '15%', + bottom: '10%' + }, + tooltip: { + padding: 10, + borderColor: '#777', + borderWidth: 1, + formatter: function (obj) { + var value = obj.value; + return '
' + + obj.seriesName + ' ' + value[0] + '日:' + + value[7] + + '
' + + schema[1].text + ':' + value[1] + '
' + + schema[2].text + ':' + value[2] + '
' + + schema[3].text + ':' + value[3] + '
' + + schema[4].text + ':' + value[4] + '
' + + schema[5].text + ':' + value[5] + '
' + + schema[6].text + ':' + value[6] + '
'; + } + }, + xAxis: { + type: 'value', + name: '日期', + nameGap: 16, + nameTextStyle: { + fontSize: 14 + }, + max: 31, + splitLine: { + show: false + }, + axisLabel: { + formatter: '{value}' + } + }, + yAxis: { + type: 'value', + name: 'AQI指数', + nameLocation: 'end', + nameGap: 20, + nameTextStyle: { + fontSize: 20 + }, + splitLine: { + show: false + } + }, + visualMap: [ + { + left: null, + right: 0, + dimension: 7, + selected: { + '严重污染': false, + '重度污染': false + }, + categories: ['严重污染', '重度污染', '中度污染', '轻度污染', '良', '优'], + inRange: { + symbolSize: 30, + symbol: { + '优': 'diamond', + '': 'circle' + } + }, + outOfRange: { + color: '#000', + symbolSize: { + '优': 50, + '': 30 + }, + symbol: { + '优': 'diamond', + '': 'circle' + } + } + } + ], + series: [ + { + name: '北京', + type: 'scatter', + itemStyle: itemStyle, + data: dataBJ + }, + { + name: '上海', + type: 'scatter', + itemStyle: itemStyle, + data: dataSH + }, + { + name: '广州', + type: 'scatter', + itemStyle: itemStyle, + data: dataGZ + } + ] +}; diff --git a/testdata/doc-example/scatter-visualMap-categories.js.svg b/testdata/doc-example/scatter-visualMap-categories.js.svg new file mode 100644 index 0000000..b8ee387 --- /dev/null +++ b/testdata/doc-example/scatter-visualMap-categories.js.svg @@ -0,0 +1,1368 @@ + + + +AQI指数 + +日期 + + + + + + + + + + + + + + + +0 +50 +100 +150 +200 +250 +300 +0 +5 +10 +15 +20 +25 +30 +31 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +严重污染 + +重度污染 + +中度污染 + +轻度污染 + + + + + +北京 + +上海 + +广州 + + + + + + + \ No newline at end of file diff --git a/testdata/doc-example/scatter-visualMap-piecewise.js b/testdata/doc-example/scatter-visualMap-piecewise.js new file mode 100644 index 0000000..c85baba --- /dev/null +++ b/testdata/doc-example/scatter-visualMap-piecewise.js @@ -0,0 +1,467 @@ +"use strict"; +var geoCoordMap = { + "海门": [121.15, 31.89], + "鄂尔多斯": [109.781327, 39.608266], + "招远": [120.38, 37.35], + "舟山": [122.207216, 29.985295], + "齐齐哈尔": [123.97, 47.33], + "盐城": [120.13, 33.38], + "赤峰": [118.87, 42.28], + "青岛": [120.33, 36.07], + "乳山": [121.52, 36.89], + "金昌": [102.188043, 38.520089], + "泉州": [118.58, 24.93], + "莱西": [120.53, 36.86], + "日照": [119.46, 35.42], + "胶南": [119.97, 35.88], + "南通": [121.05, 32.08], + "拉萨": [91.11, 29.97], + "云浮": [112.02, 22.93], + "梅州": [116.1, 24.55], + "文登": [122.05, 37.2], + "上海": [121.48, 31.22], + "攀枝花": [101.718637, 26.582347], + "威海": [122.1, 37.5], + "承德": [117.93, 40.97], + "厦门": [118.1, 24.46], + "汕尾": [115.375279, 22.786211], + "潮州": [116.63, 23.68], + "丹东": [124.37, 40.13], + "太仓": [121.1, 31.45], + "曲靖": [103.79, 25.51], + "烟台": [121.39, 37.52], + "福州": [119.3, 26.08], + "瓦房店": [121.979603, 39.627114], + "即墨": [120.45, 36.38], + "抚顺": [123.97, 41.97], + "玉溪": [102.52, 24.35], + "张家口": [114.87, 40.82], + "阳泉": [113.57, 37.85], + "莱州": [119.942327, 37.177017], + "湖州": [120.1, 30.86], + "汕头": [116.69, 23.39], + "昆山": [120.95, 31.39], + "宁波": [121.56, 29.86], + "湛江": [110.359377, 21.270708], + "揭阳": [116.35, 23.55], + "荣成": [122.41, 37.16], + "连云港": [119.16, 34.59], + "葫芦岛": [120.836932, 40.711052], + "常熟": [120.74, 31.64], + "东莞": [113.75, 23.04], + "河源": [114.68, 23.73], + "淮安": [119.15, 33.5], + "泰州": [119.9, 32.49], + "南宁": [108.33, 22.84], + "营口": [122.18, 40.65], + "惠州": [114.4, 23.09], + "江阴": [120.26, 31.91], + "蓬莱": [120.75, 37.8], + "韶关": [113.62, 24.84], + "嘉峪关": [98.289152, 39.77313], + "广州": [113.23, 23.16], + "延安": [109.47, 36.6], + "太原": [112.53, 37.87], + "清远": [113.01, 23.7], + "中山": [113.38, 22.52], + "昆明": [102.73, 25.04], + "寿光": [118.73, 36.86], + "盘锦": [122.070714, 41.119997], + "长治": [113.08, 36.18], + "深圳": [114.07, 22.62], + "珠海": [113.52, 22.3], + "宿迁": [118.3, 33.96], + "咸阳": [108.72, 34.36], + "铜川": [109.11, 35.09], + "平度": [119.97, 36.77], + "佛山": [113.11, 23.05], + "海口": [110.35, 20.02], + "江门": [113.06, 22.61], + "章丘": [117.53, 36.72], + "肇庆": [112.44, 23.05], + "大连": [121.62, 38.92], + "临汾": [111.5, 36.08], + "吴江": [120.63, 31.16], + "石嘴山": [106.39, 39.04], + "沈阳": [123.38, 41.8], + "苏州": [120.62, 31.32], + "茂名": [110.88, 21.68], + "嘉兴": [120.76, 30.77], + "长春": [125.35, 43.88], + "胶州": [120.03336, 36.264622], + "银川": [106.27, 38.47], + "张家港": [120.555821, 31.875428], + "三门峡": [111.19, 34.76], + "锦州": [121.15, 41.13], + "南昌": [115.89, 28.68], + "柳州": [109.4, 24.33], + "三亚": [109.511909, 18.252847], + "自贡": [104.778442, 29.33903], + "吉林": [126.57, 43.87], + "阳江": [111.95, 21.85], + "泸州": [105.39, 28.91], + "西宁": [101.74, 36.56], + "宜宾": [104.56, 29.77], + "呼和浩特": [111.65, 40.82], + "成都": [104.06, 30.67], + "大同": [113.3, 40.12], + "镇江": [119.44, 32.2], + "桂林": [110.28, 25.29], + "张家界": [110.479191, 29.117096], + "宜兴": [119.82, 31.36], + "北海": [109.12, 21.49], + "西安": [108.95, 34.27], + "金坛": [119.56, 31.74], + "东营": [118.49, 37.46], + "牡丹江": [129.58, 44.6], + "遵义": [106.9, 27.7], + "绍兴": [120.58, 30.01], + "扬州": [119.42, 32.39], + "常州": [119.95, 31.79], + "潍坊": [119.1, 36.62], + "重庆": [106.54, 29.59], + "台州": [121.420757, 28.656386], + "南京": [118.78, 32.04], + "滨州": [118.03, 37.36], + "贵阳": [106.71, 26.57], + "无锡": [120.29, 31.59], + "本溪": [123.73, 41.3], + "克拉玛依": [84.77, 45.59], + "渭南": [109.5, 34.52], + "马鞍山": [118.48, 31.56], + "宝鸡": [107.15, 34.38], + "焦作": [113.21, 35.24], + "句容": [119.16, 31.95], + "北京": [116.46, 39.92], + "徐州": [117.2, 34.26], + "衡水": [115.72, 37.72], + "包头": [110, 40.58], + "绵阳": [104.73, 31.48], + "乌鲁木齐": [87.68, 43.77], + "枣庄": [117.57, 34.86], + "杭州": [120.19, 30.26], + "淄博": [118.05, 36.78], + "鞍山": [122.85, 41.12], + "溧阳": [119.48, 31.43], + "库尔勒": [86.06, 41.68], + "安阳": [114.35, 36.1], + "开封": [114.35, 34.79], + "济南": [117, 36.65], + "德阳": [104.37, 31.13], + "温州": [120.65, 28.01], + "九江": [115.97, 29.71], + "邯郸": [114.47, 36.6], + "临安": [119.72, 30.23], + "兰州": [103.73, 36.03], + "沧州": [116.83, 38.33], + "临沂": [118.35, 35.05], + "南充": [106.110698, 30.837793], + "天津": [117.2, 39.13], + "富阳": [119.95, 30.07], + "泰安": [117.13, 36.18], + "诸暨": [120.23, 29.71], + "郑州": [113.65, 34.76], + "哈尔滨": [126.63, 45.75], + "聊城": [115.97, 36.45], + "芜湖": [118.38, 31.33], + "唐山": [118.02, 39.63], + "平顶山": [113.29, 33.75], + "邢台": [114.48, 37.05], + "德州": [116.29, 37.45], + "济宁": [116.59, 35.38], + "荆州": [112.239741, 30.335165], + "宜昌": [111.3, 30.7], + "义乌": [120.06, 29.32], + "丽水": [119.92, 28.45], + "洛阳": [112.44, 34.7], + "秦皇岛": [119.57, 39.95], + "株洲": [113.16, 27.83], + "石家庄": [114.48, 38.03], + "莱芜": [117.67, 36.19], + "常德": [111.69, 29.05], + "保定": [115.48, 38.85], + "湘潭": [112.91, 27.87], + "金华": [119.64, 29.12], + "岳阳": [113.09, 29.37], + "长沙": [113, 28.21], + "衢州": [118.88, 28.97], + "廊坊": [116.7, 39.53], + "菏泽": [115.480656, 35.23375], + "合肥": [117.27, 31.86], + "武汉": [114.31, 30.52], + "大庆": [125.03, 46.58] +}; +var convertData = function (data) { + var res = []; + for (var i = 0; i < data.length; i++) { + var geoCoord = geoCoordMap[data[i].name]; + if (geoCoord) { + res.push(geoCoord.concat(data[i].value)); + } + } + return res; +}; +option = { + backgroundColor: '#404a59', + title: { + text: '全国主要城市空气质量', + subtext: 'data from PM25.in', + sublink: 'http://www.pm25.in', + left: 'center', + textStyle: { + color: '#fff' + } + }, + tooltip: { + trigger: 'item' + }, + legend: { + orient: 'vertical', + top: 'bottom', + left: 'right', + data: ['pm2.5'], + textStyle: { + color: '#fff' + } + }, + visualMap: { + min: 0, + max: 300, + splitNumber: 5, + color: ['#d94e5d', '#eac736', '#50a3ba'], + textStyle: { + color: '#fff' + } + }, + geo: { + map: 'china', + label: { + emphasis: { + show: false + } + }, + itemStyle: { + normal: { + areaColor: '#323c48', + borderColor: '#111' + }, + emphasis: { + areaColor: '#2a333d' + } + } + }, + series: [ + { + name: 'pm2.5', + type: 'scatter', + coordinateSystem: 'geo', + data: convertData([ + { name: "海门", value: 9 }, + { name: "鄂尔多斯", value: 12 }, + { name: "招远", value: 12 }, + { name: "舟山", value: 12 }, + { name: "齐齐哈尔", value: 14 }, + { name: "盐城", value: 15 }, + { name: "赤峰", value: 16 }, + { name: "青岛", value: 18 }, + { name: "乳山", value: 18 }, + { name: "金昌", value: 19 }, + { name: "泉州", value: 21 }, + { name: "莱西", value: 21 }, + { name: "日照", value: 21 }, + { name: "胶南", value: 22 }, + { name: "南通", value: 23 }, + { name: "拉萨", value: 24 }, + { name: "云浮", value: 24 }, + { name: "梅州", value: 25 }, + { name: "文登", value: 25 }, + { name: "上海", value: 25 }, + { name: "攀枝花", value: 25 }, + { name: "威海", value: 25 }, + { name: "承德", value: 25 }, + { name: "厦门", value: 26 }, + { name: "汕尾", value: 26 }, + { name: "潮州", value: 26 }, + { name: "丹东", value: 27 }, + { name: "太仓", value: 27 }, + { name: "曲靖", value: 27 }, + { name: "烟台", value: 28 }, + { name: "福州", value: 29 }, + { name: "瓦房店", value: 30 }, + { name: "即墨", value: 30 }, + { name: "抚顺", value: 31 }, + { name: "玉溪", value: 31 }, + { name: "张家口", value: 31 }, + { name: "阳泉", value: 31 }, + { name: "莱州", value: 32 }, + { name: "湖州", value: 32 }, + { name: "汕头", value: 32 }, + { name: "昆山", value: 33 }, + { name: "宁波", value: 33 }, + { name: "湛江", value: 33 }, + { name: "揭阳", value: 34 }, + { name: "荣成", value: 34 }, + { name: "连云港", value: 35 }, + { name: "葫芦岛", value: 35 }, + { name: "常熟", value: 36 }, + { name: "东莞", value: 36 }, + { name: "河源", value: 36 }, + { name: "淮安", value: 36 }, + { name: "泰州", value: 36 }, + { name: "南宁", value: 37 }, + { name: "营口", value: 37 }, + { name: "惠州", value: 37 }, + { name: "江阴", value: 37 }, + { name: "蓬莱", value: 37 }, + { name: "韶关", value: 38 }, + { name: "嘉峪关", value: 38 }, + { name: "广州", value: 38 }, + { name: "延安", value: 38 }, + { name: "太原", value: 39 }, + { name: "清远", value: 39 }, + { name: "中山", value: 39 }, + { name: "昆明", value: 39 }, + { name: "寿光", value: 40 }, + { name: "盘锦", value: 40 }, + { name: "长治", value: 41 }, + { name: "深圳", value: 41 }, + { name: "珠海", value: 42 }, + { name: "宿迁", value: 43 }, + { name: "咸阳", value: 43 }, + { name: "铜川", value: 44 }, + { name: "平度", value: 44 }, + { name: "佛山", value: 44 }, + { name: "海口", value: 44 }, + { name: "江门", value: 45 }, + { name: "章丘", value: 45 }, + { name: "肇庆", value: 46 }, + { name: "大连", value: 47 }, + { name: "临汾", value: 47 }, + { name: "吴江", value: 47 }, + { name: "石嘴山", value: 49 }, + { name: "沈阳", value: 50 }, + { name: "苏州", value: 50 }, + { name: "茂名", value: 50 }, + { name: "嘉兴", value: 51 }, + { name: "长春", value: 51 }, + { name: "胶州", value: 52 }, + { name: "银川", value: 52 }, + { name: "张家港", value: 52 }, + { name: "三门峡", value: 53 }, + { name: "锦州", value: 54 }, + { name: "南昌", value: 54 }, + { name: "柳州", value: 54 }, + { name: "三亚", value: 54 }, + { name: "自贡", value: 56 }, + { name: "吉林", value: 56 }, + { name: "阳江", value: 57 }, + { name: "泸州", value: 57 }, + { name: "西宁", value: 57 }, + { name: "宜宾", value: 58 }, + { name: "呼和浩特", value: 58 }, + { name: "成都", value: 58 }, + { name: "大同", value: 58 }, + { name: "镇江", value: 59 }, + { name: "桂林", value: 59 }, + { name: "张家界", value: 59 }, + { name: "宜兴", value: 59 }, + { name: "北海", value: 60 }, + { name: "西安", value: 61 }, + { name: "金坛", value: 62 }, + { name: "东营", value: 62 }, + { name: "牡丹江", value: 63 }, + { name: "遵义", value: 63 }, + { name: "绍兴", value: 63 }, + { name: "扬州", value: 64 }, + { name: "常州", value: 64 }, + { name: "潍坊", value: 65 }, + { name: "重庆", value: 66 }, + { name: "台州", value: 67 }, + { name: "南京", value: 67 }, + { name: "滨州", value: 70 }, + { name: "贵阳", value: 71 }, + { name: "无锡", value: 71 }, + { name: "本溪", value: 71 }, + { name: "克拉玛依", value: 72 }, + { name: "渭南", value: 72 }, + { name: "马鞍山", value: 72 }, + { name: "宝鸡", value: 72 }, + { name: "焦作", value: 75 }, + { name: "句容", value: 75 }, + { name: "北京", value: 79 }, + { name: "徐州", value: 79 }, + { name: "衡水", value: 80 }, + { name: "包头", value: 80 }, + { name: "绵阳", value: 80 }, + { name: "乌鲁木齐", value: 84 }, + { name: "枣庄", value: 84 }, + { name: "杭州", value: 84 }, + { name: "淄博", value: 85 }, + { name: "鞍山", value: 86 }, + { name: "溧阳", value: 86 }, + { name: "库尔勒", value: 86 }, + { name: "安阳", value: 90 }, + { name: "开封", value: 90 }, + { name: "济南", value: 92 }, + { name: "德阳", value: 93 }, + { name: "温州", value: 95 }, + { name: "九江", value: 96 }, + { name: "邯郸", value: 98 }, + { name: "临安", value: 99 }, + { name: "兰州", value: 99 }, + { name: "沧州", value: 100 }, + { name: "临沂", value: 103 }, + { name: "南充", value: 104 }, + { name: "天津", value: 105 }, + { name: "富阳", value: 106 }, + { name: "泰安", value: 112 }, + { name: "诸暨", value: 112 }, + { name: "郑州", value: 113 }, + { name: "哈尔滨", value: 114 }, + { name: "聊城", value: 116 }, + { name: "芜湖", value: 117 }, + { name: "唐山", value: 119 }, + { name: "平顶山", value: 119 }, + { name: "邢台", value: 119 }, + { name: "德州", value: 120 }, + { name: "济宁", value: 120 }, + { name: "荆州", value: 127 }, + { name: "宜昌", value: 130 }, + { name: "义乌", value: 132 }, + { name: "丽水", value: 133 }, + { name: "洛阳", value: 134 }, + { name: "秦皇岛", value: 136 }, + { name: "株洲", value: 143 }, + { name: "石家庄", value: 147 }, + { name: "莱芜", value: 148 }, + { name: "常德", value: 152 }, + { name: "保定", value: 153 }, + { name: "湘潭", value: 154 }, + { name: "金华", value: 157 }, + { name: "岳阳", value: 169 }, + { name: "长沙", value: 175 }, + { name: "衢州", value: 177 }, + { name: "廊坊", value: 193 }, + { name: "菏泽", value: 194 }, + { name: "合肥", value: 229 }, + { name: "武汉", value: 273 }, + { name: "大庆", value: 279 } + ]), + symbolSize: 12, + label: { + normal: { + show: false + }, + emphasis: { + show: false + } + }, + itemStyle: { + emphasis: { + borderColor: '#fff', + borderWidth: 1 + } + } + } + ] +}; diff --git a/testdata/doc-example/sunburst-color.js b/testdata/doc-example/sunburst-color.js new file mode 100644 index 0000000..cb63e08 --- /dev/null +++ b/testdata/doc-example/sunburst-color.js @@ -0,0 +1,45 @@ +"use strict"; +option = { + series: { + type: 'sunburst', + data: [{ + name: 'A', + value: 10, + children: [{ + value: 3, + name: 'Aa', + itemStyle: { + color: 'red' + } + }, { + value: 5, + name: 'Ab' + }] + }, { + name: 'B', + children: [{ + name: 'Ba', + value: 4 + }, { + name: 'Bb', + value: 2 + }], + itemStyle: { + color: 'red' + } + }, { + name: 'C', + value: 3 + }], + itemStyle: { + color: '#aaa' + }, + levels: [{ + // 留给数据下钻的节点属性 + }, { + itemStyle: { + color: 'blue' + } + }] + } +}; diff --git a/testdata/doc-example/sunburst-color.js.svg b/testdata/doc-example/sunburst-color.js.svg new file mode 100644 index 0000000..3e0c043 --- /dev/null +++ b/testdata/doc-example/sunburst-color.js.svg @@ -0,0 +1,65 @@ + + + + + + + + + +A +Ab +Aa +B +Ba +Bb +C + + \ No newline at end of file diff --git a/testdata/doc-example/sunburst-highlight-ancestor.js b/testdata/doc-example/sunburst-highlight-ancestor.js new file mode 100644 index 0000000..3ffca71 --- /dev/null +++ b/testdata/doc-example/sunburst-highlight-ancestor.js @@ -0,0 +1,71 @@ +"use strict"; +option = { + silent: true, + series: { + radius: ['15%', '95%'], + center: ['50%', '60%'], + type: 'sunburst', + sort: null, + emphasis: { + focus: 'ancestor' + }, + data: [{ + value: 10, + children: [{ + value: 4, + children: [{ + value: 2, + children: [{ + name: 'target', + value: 1 + }] + }, { + value: 1 + }, { + value: 0.5 + }] + }, { + value: 2 + }] + }, { + value: 4, + children: [{ + children: [{ + value: 2 + }] + }] + }], + label: { + normal: { + rotate: 'none', + color: '#fff' + } + }, + levels: [], + itemStyle: { + color: 'yellow', + borderWidth: 2 + }, + emphasis: { + itemStyle: { + color: 'red' + } + }, + highlight: { + itemStyle: { + color: 'orange' + } + }, + downplay: { + itemStyle: { + color: '#ccc' + } + } + } +}; +setTimeout(function () { + myChart.dispatchAction({ + type: 'sunburstHighlight', + targetNodeId: 'target' + }); +}); diff --git a/testdata/doc-example/sunburst-highlight-ancestor.js.svg b/testdata/doc-example/sunburst-highlight-ancestor.js.svg new file mode 100644 index 0000000..06f680f --- /dev/null +++ b/testdata/doc-example/sunburst-highlight-ancestor.js.svg @@ -0,0 +1,128 @@ + + + + + + + + + + + + +target + + \ No newline at end of file diff --git a/testdata/doc-example/sunburst-highlight-descendant.js b/testdata/doc-example/sunburst-highlight-descendant.js new file mode 100644 index 0000000..51f2ec0 --- /dev/null +++ b/testdata/doc-example/sunburst-highlight-descendant.js @@ -0,0 +1,71 @@ +"use strict"; +option = { + silent: true, + series: { + radius: ['15%', '95%'], + center: ['50%', '60%'], + type: 'sunburst', + sort: null, + emphasis: { + focus: 'descendant' + }, + data: [{ + value: 10, + children: [{ + name: 'target', + value: 4, + children: [{ + value: 2, + children: [{ + value: 1 + }] + }, { + value: 1 + }, { + value: 0.5 + }] + }, { + value: 2 + }] + }, { + value: 4, + children: [{ + children: [{ + value: 2 + }] + }] + }], + label: { + normal: { + rotate: 'none', + color: '#fff' + } + }, + levels: [], + itemStyle: { + color: 'yellow', + borderWidth: 2 + }, + emphasis: { + itemStyle: { + color: 'red' + } + }, + highlight: { + itemStyle: { + color: 'orange' + } + }, + downplay: { + itemStyle: { + color: '#ccc' + } + } + } +}; +setTimeout(function () { + myChart.dispatchAction({ + type: 'sunburstHighlight', + targetNodeId: 'target' + }); +}); diff --git a/testdata/doc-example/sunburst-highlight-descendant.js.svg b/testdata/doc-example/sunburst-highlight-descendant.js.svg new file mode 100644 index 0000000..ed34f8d --- /dev/null +++ b/testdata/doc-example/sunburst-highlight-descendant.js.svg @@ -0,0 +1,128 @@ + + + + + + + + + + + + +target + + \ No newline at end of file diff --git a/testdata/doc-example/sunburst-label-align.js b/testdata/doc-example/sunburst-label-align.js new file mode 100644 index 0000000..34483bc --- /dev/null +++ b/testdata/doc-example/sunburst-label-align.js @@ -0,0 +1,33 @@ +"use strict"; +var data = []; +for (var i = 0; i < 8; ++i) { + data.push({ + name: 'left', + label: { + align: 'left', + position: 'inside' + }, + children: [{ + name: 'right', + value: 1, + label: { + align: 'right', + position: 'inside' + } + }] + }); +} +option = { + series: { + radius: ['20%', '90%'], + type: 'sunburst', + sort: null, + emphasis: { + focus: 'none' + }, + data: data, + label: { + fontSize: 14 + } + } +}; diff --git a/testdata/doc-example/sunburst-label-align.js.svg b/testdata/doc-example/sunburst-label-align.js.svg new file mode 100644 index 0000000..d863916 --- /dev/null +++ b/testdata/doc-example/sunburst-label-align.js.svg @@ -0,0 +1,215 @@ + + + + + + + + + + + + + + + + + + +left +right +left +right +left +right +left +right +left +right +left +right +left +right +left +right + + \ No newline at end of file diff --git a/testdata/doc-example/sunburst-simple.js b/testdata/doc-example/sunburst-simple.js new file mode 100644 index 0000000..e9f1c1c --- /dev/null +++ b/testdata/doc-example/sunburst-simple.js @@ -0,0 +1,29 @@ +"use strict"; +option = { + series: { + type: 'sunburst', + data: [{ + name: 'A', + value: 10, + children: [{ + value: 3, + name: 'Aa' + }, { + value: 5, + name: 'Ab' + }] + }, { + name: 'B', + children: [{ + name: 'Ba', + value: 4 + }, { + name: 'Bb', + value: 2 + }] + }, { + name: 'C', + value: 3 + }] + } +}; diff --git a/testdata/doc-example/sunburst-simple.js.svg b/testdata/doc-example/sunburst-simple.js.svg new file mode 100644 index 0000000..dea7d48 --- /dev/null +++ b/testdata/doc-example/sunburst-simple.js.svg @@ -0,0 +1,65 @@ + + + + + + + + + +A +Ab +Aa +B +Ba +Bb +C + + \ No newline at end of file diff --git a/testdata/doc-example/text-block-fragment.js b/testdata/doc-example/text-block-fragment.js new file mode 100644 index 0000000..6697f20 --- /dev/null +++ b/testdata/doc-example/text-block-fragment.js @@ -0,0 +1,65 @@ +"use strict"; +option = { + series: [ + { + type: 'scatter', + data: [[0, 0]], + symbolSize: 1, + label: { + show: true, + formatter: [ + 'The whole box is a {term|Text Block}, with', + 'red border and grey background.', + '{fragment1|A Text Fragment} {fragment2|Another Text Fragment}', + 'Text fragments can be customized.' + ].join('\n'), + backgroundColor: '#eee', + // borderColor: '#333', + borderColor: 'rgb(199,86,83)', + borderWidth: 2, + borderRadius: 5, + padding: 10, + color: '#000', + fontSize: 14, + shadowBlur: 3, + shadowColor: '#888', + shadowOffsetX: 0, + shadowOffsetY: 3, + lineHeight: 30, + rich: { + term: { + fontSize: 18, + color: 'rgb(199,86,83)' + }, + fragment1: { + backgroundColor: '#000', + color: 'yellow', + padding: 5 + }, + fragment2: { + backgroundColor: '#339911', + color: '#fff', + borderRadius: 15, + padding: 5 + } + } + } + } + ], + xAxis: { + axisLabel: { show: false }, + axisLine: { show: false }, + splitLine: { show: false }, + axisTick: { show: false }, + min: -1, + max: 1 + }, + yAxis: { + axisLabel: { show: false }, + axisLine: { show: false }, + splitLine: { show: false }, + axisTick: { show: false }, + min: -1, + max: 1 + } +}; diff --git a/testdata/doc-example/text-block-fragment.js.svg b/testdata/doc-example/text-block-fragment.js.svg new file mode 100644 index 0000000..958be92 --- /dev/null +++ b/testdata/doc-example/text-block-fragment.js.svg @@ -0,0 +1,37 @@ + + + + +The whole box is a +Text Block +, with +red border and grey background. + +A Text Fragment + + +Another Text Fragment +Text fragments can be customized. + + + + + + + \ No newline at end of file diff --git a/testdata/doc-example/text-fregment-align.js b/testdata/doc-example/text-fregment-align.js new file mode 100644 index 0000000..9566f16 --- /dev/null +++ b/testdata/doc-example/text-fregment-align.js @@ -0,0 +1,119 @@ +"use strict"; +option = { + series: [ + { + type: 'scatter', + data: [[0, 0]], + symbolSize: 1, + label: { + show: true, + formatter: [ + '{tc|height is specified as 30}{box|}', + '{lh|Biggest lineHeight} {vt|verticalAlign "top"} {vb|verticalAlign "bottom"} {vm|verticalAlign "middle"}', + '{l1|align "left"}{l2|align "left"}{c1|align "center"}{c2|align "center"}{r2|align "right"}{r1|align "right"}', + '{tc|height is specified as 30}{box|}' + ].join('\n'), + backgroundColor: '#ddd', + borderColor: '#555', + borderWidth: 1, + borderRadius: 5, + padding: [0, 20, 0, 20], + color: '#000', + fontSize: 14, + rich: { + box: { + backgroundColor: '#000', + height: 30, + padding: [0, 20, 0, 20], + align: 'right', + width: '100%', + color: '#eee' + }, + tc: { + align: 'center', + color: '#eee' + }, + lh: { + fontSize: 30, + color: 'rgb(199,86,83)', + borderWidth: 1, + borderColor: 'rgb(199,86,83)' + }, + vt: { + verticalAlign: 'top', + backgroundColor: '#991122', + color: '#fff', + padding: [1, 2, 1, 2] + }, + vb: { + verticalAlign: 'bottom', + backgroundColor: '#991122', + color: '#fff', + padding: [1, 2, 1, 2] + }, + vm: { + verticalAlign: 'middle', + backgroundColor: '#991122', + color: '#fff', + padding: [1, 2, 1, 2] + }, + l1: { + backgroundColor: '#7066FF', + color: '#fff', + padding: 5 + }, + l2: { + backgroundColor: '#339911', + color: '#fff', + borderRadius: 15, + padding: 5 + }, + r1: { + backgroundColor: '#7066FF', + align: 'right', + color: '#fff', + padding: 5 + }, + r2: { + backgroundColor: '#339911', + align: 'right', + color: '#fff', + borderRadius: 15, + padding: 5 + }, + c1: { + backgroundColor: '#7066FF', + align: 'center', + color: '#fff', + padding: 5, + width: 100 + }, + c2: { + backgroundColor: '#339911', + align: 'center', + color: '#fff', + borderRadius: 15, + padding: 5, + width: 100 + } + } + } + } + ], + xAxis: { + axisLabel: { show: false }, + axisLine: { show: false }, + splitLine: { show: false }, + axisTick: { show: false }, + min: -1, + max: 1 + }, + yAxis: { + axisLabel: { show: false }, + axisLine: { show: false }, + splitLine: { show: false }, + axisTick: { show: false }, + min: -1, + max: 1 + } +}; diff --git a/testdata/doc-example/text-fregment-align.js.svg b/testdata/doc-example/text-fregment-align.js.svg new file mode 100644 index 0000000..89c35e3 --- /dev/null +++ b/testdata/doc-example/text-fregment-align.js.svg @@ -0,0 +1,49 @@ + + + + + +height is specified as 30 + +Biggest lineHeight + + +verticalAlign "top" + + +verticalAlign "bottom" + + +verticalAlign "middle" + +align "left" + +align "left" + +align "right" + +align "right" + +align "center" + +align "center" + +height is specified as 30 + + \ No newline at end of file diff --git a/testdata/doc-example/text-options.js b/testdata/doc-example/text-options.js new file mode 100644 index 0000000..f7d0d79 --- /dev/null +++ b/testdata/doc-example/text-options.js @@ -0,0 +1,91 @@ +"use strict"; +option = { + series: [ + { + type: 'scatter', + symbolSize: 1, + data: [ + { + value: [0, 0], + label: { + show: true, + formatter: [ + 'Plain text', + '{textBorder|textBorderColor + textBorderWidth}', + '{textShadow|textShadowColor + textShadowBlur + textShadowOffsetX + textShadowOffsetY}', + '{bg|backgroundColor + borderRadius + padding}', + '{border|borderColor + borderWidth + borderRadius + padding}', + '{shadow|shadowColor + shadowBlur + shadowOffsetX + shadowOffsetY}' + ].join('\n'), + backgroundColor: '#eee', + borderColor: '#333', + borderWidth: 2, + borderRadius: 5, + padding: 10, + color: '#000', + fontSize: 14, + shadowBlur: 3, + shadowColor: '#888', + shadowOffsetX: 0, + shadowOffsetY: 3, + lineHeight: 30, + rich: { + textBorder: { + fontSize: 20, + textBorderColor: '#000', + textBorderWidth: 3, + color: '#fff' + }, + textShadow: { + fontSize: 16, + textShadowBlur: 5, + textShadowColor: '#000', + textShadowOffsetX: 3, + textShadowOffsetY: 3, + color: '#fff' + }, + bg: { + backgroundColor: '#339911', + color: '#fff', + borderRadius: 15, + padding: 5 + }, + border: { + color: '#000', + borderColor: '#449911', + borderWidth: 1, + borderRadius: 3, + padding: 5 + }, + shadow: { + backgroundColor: '#992233', + padding: 5, + color: '#fff', + shadowBlur: 5, + shadowColor: '#336699', + shadowOffsetX: 6, + shadowOffsetY: 6 + } + } + } + } + ] + } + ], + xAxis: { + axisLabel: { show: false }, + axisLine: { show: false }, + splitLine: { show: false }, + axisTick: { show: false }, + min: -1, + max: 1 + }, + yAxis: { + axisLabel: { show: false }, + axisLine: { show: false }, + splitLine: { show: false }, + axisTick: { show: false }, + min: -1, + max: 1 + } +}; diff --git a/testdata/doc-example/text-options.js.svg b/testdata/doc-example/text-options.js.svg new file mode 100644 index 0000000..a8517be --- /dev/null +++ b/testdata/doc-example/text-options.js.svg @@ -0,0 +1,42 @@ + + + + +Plain text +textBorderColor + textBorderWidth +textShadowColor + textShadowBlur + textShadowOffsetX + textShadowOffsetY + +backgroundColor + borderRadius + padding + +borderColor + borderWidth + borderRadius + padding + +shadowColor + shadowBlur + shadowOffsetX + shadowOffsetY + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/doc-example/timeline-dynamic-series.js b/testdata/doc-example/timeline-dynamic-series.js new file mode 100644 index 0000000..f0ffcca --- /dev/null +++ b/testdata/doc-example/timeline-dynamic-series.js @@ -0,0 +1,71 @@ +"use strict"; +option = { + baseOption: { + timeline: { + axisType: 'category', + // realtime: false, + // loop: false, + autoPlay: false, + // currentIndex: 2, + playInterval: 1000, + controlStyle: { + stopIcon: 'image://data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAGpJREFUWAntlkEKwDAIBKP+/znt82xrD6FIpSSHXDpCQBeXDXOyNQoCBQEz21T1eL7QivUuj/qkO1MTwUm6R3cvPbEw6tO3kJUaH4AABCAAAQhAAAIQgEBJQET2fJxe2udZPuvLWcz/IXACuUMWMJDzUAgAAAAASUVORK5CYII=', + playIcon: 'path://M41.365908,29.4271388 L41.3664843,29.4265626 L26.3794329,19.1497136 L26.3747509,19.1541315 C26.0642269,18.8592621 25.6429678,18.677793 25.1786824,18.677793 C24.2236284,18.677793 23.4494433,19.4443188 23.4494433,20.3905371 C23.4494433,20.910214 23.4270417,21.9276946 23.4494433,21.9056292 L23.4494433,30.6673861 L23.4494433,39.8901629 C23.4494433,39.8977982 23.4494433,40.4825908 23.4494433,40.9444991 C23.4494433,41.8901412 24.2236284,42.656691 25.1786824,42.656691 C25.6447205,42.656691 26.0677564,42.4740454 26.3782564,42.1764869 L26.3794329,42.1770872 L41.3664843,31.9005503 L41.3659081,31.8996379 C41.6917266,31.5882735 41.894997,31.1514078 41.894997,30.6670739 C41.894997,30.6658974 41.894997,30.6650091 41.894997,30.6635444 C41.894997,30.6623679 41.894997,30.6609273 41.894997,30.6600389 C41.894997,30.175657 41.6917265,29.7384792 41.365908,29.4271388 Z' + }, + replaceMerge: 'series', + data: [ + '2 series', '3 series', '1 series' + ], + }, + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'shadow' + } + }, + legend: {}, + calculable: true, + grid: { + top: 80, bottom: 100 + }, + toolbox: { + left: 'center', + top: 30, + feature: { + dataZoom: {} + } + }, + xAxis: { + type: 'category', + data: ['CityB', 'CityT', 'CityH', 'CityS'], + splitLine: { show: false } + }, + yAxis: [ + { + type: 'value', + name: 'GDP' + } + ], + series: [] + }, + options: [ + { + series: [ + { name: 'a', type: 'bar', data: [12, 33, 44, 55] }, + { name: 'b', type: 'bar', data: [55, 66, 77, 88] }, + ] + }, + { + series: [ + { name: 'a', type: 'bar', data: [22, 33, 44, 55] }, + { name: 'b', type: 'bar', data: [55, 66, 77, 88] }, + { name: 'c', type: 'bar', data: [55, 66, 77, 88] } + ] + }, + { + series: [ + { name: 'b', type: 'bar', data: [55, 66, 77, 88] } + ] + } + ] +}; diff --git a/testdata/doc-example/timeline-dynamic-series.js.svg b/testdata/doc-example/timeline-dynamic-series.js.svg new file mode 100644 index 0000000..19a59cc --- /dev/null +++ b/testdata/doc-example/timeline-dynamic-series.js.svg @@ -0,0 +1,151 @@ + + + + + + + + +GDP + + + + + + +0 +20 +40 +60 +80 +100 +CityB +CityT +CityH +CityS + + + + + + + + + + + + +2 series +3 series +1 series + +a + +b + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/doc-example/title-block.js b/testdata/doc-example/title-block.js new file mode 100644 index 0000000..449edb1 --- /dev/null +++ b/testdata/doc-example/title-block.js @@ -0,0 +1,126 @@ +"use strict"; +var weatherIcons = { + Sunny: ROOT_PATH + '/data/asset/img/weather/sunny_128.png', + Cloudy: ROOT_PATH + '/data/asset/img/weather/cloudy_128.png', + Showers: ROOT_PATH + '/data/asset/img/weather/showers_128.png' +}; +option = { + series: [ + { + type: 'scatter', + data: [ + { + value: [0, 0], + label: { + formatter: [ + '{tc|Center Title}{titleBg|}', + ' Content text xxxxxxxx {sunny|} xxxxxxxx {cloudy|} ', + '{hr|}', + ' xxxxx {showers|} xxxxxxxx xxxxxxxxx ' + ].join('\n'), + rich: { + titleBg: { + align: 'right' + } + } + } + }, + { + value: [0, 1], + label: { + formatter: [ + '{titleBg|Left Title}', + ' Content text xxxxxxxx {sunny|} xxxxxxxx {cloudy|} ', + '{hr|}', + ' xxxxx {showers|} xxxxxxxx xxxxxxxxx ' + ].join('\n') + } + }, + { + value: [0, 2], + label: { + formatter: [ + '{titleBg|Right Title}', + ' Content text xxxxxxxx {sunny|} xxxxxxxx {cloudy|} ', + '{hr|}', + ' xxxxx {showers|} xxxxxxxx xxxxxxxxx ' + ].join('\n'), + rich: { + titleBg: { + align: 'right' + } + } + } + } + ], + symbolSize: 1, + label: { + show: true, + backgroundColor: '#ddd', + borderColor: '#555', + borderWidth: 1, + borderRadius: 5, + color: '#000', + fontSize: 14, + rich: { + titleBg: { + backgroundColor: '#000', + height: 30, + borderRadius: [5, 5, 0, 0], + padding: [0, 10, 0, 10], + width: '100%', + color: '#eee' + }, + tc: { + align: 'center', + color: '#eee' + }, + hr: { + borderColor: '#777', + width: '100%', + borderWidth: 0.5, + height: 0 + }, + sunny: { + height: 30, + align: 'left', + backgroundColor: { + image: weatherIcons.Sunny + } + }, + cloudy: { + height: 30, + align: 'left', + backgroundColor: { + image: weatherIcons.Cloudy + } + }, + showers: { + height: 30, + align: 'left', + backgroundColor: { + image: weatherIcons.Showers + } + } + } + } + } + ], + xAxis: { + axisLabel: { show: false }, + axisLine: { show: false }, + splitLine: { show: false }, + axisTick: { show: false }, + min: -1, + max: 1 + }, + yAxis: { + axisLabel: { show: false }, + axisLine: { show: false }, + splitLine: { show: false }, + axisTick: { show: false }, + min: 0, + max: 2, + inverse: true + } +}; diff --git a/testdata/doc-example/treemap-borderColor.js b/testdata/doc-example/treemap-borderColor.js new file mode 100644 index 0000000..a136219 --- /dev/null +++ b/testdata/doc-example/treemap-borderColor.js @@ -0,0 +1,80 @@ +"use strict"; +myChart.showLoading(); +$.get(ROOT_PATH + '/data/asset/data/disk.tree.json', function (diskData) { + myChart.hideLoading(); + function colorMappingChange(value) { + var levelOption = getLevelOption(value); + chart.setOption({ + series: [{ + levels: levelOption + }] + }); + } + var formatUtil = echarts.format; + function getLevelOption() { + return [ + { + itemStyle: { + normal: { + borderWidth: 0, + gapWidth: 5 + } + } + }, + { + itemStyle: { + normal: { + gapWidth: 1 + } + } + }, + { + colorSaturation: [0.35, 0.5], + itemStyle: { + normal: { + gapWidth: 1, + borderColorSaturation: 0.6 + } + } + } + ]; + } + myChart.setOption(option = { + title: { + text: 'Disk Usage', + left: 'center' + }, + tooltip: { + formatter: function (info) { + var value = info.value; + var treePathInfo = info.treePathInfo; + var treePath = []; + for (var i = 1; i < treePathInfo.length; i++) { + treePath.push(treePathInfo[i].name); + } + return [ + '
' + formatUtil.encodeHTML(treePath.join('/')) + '
', + 'Disk Usage: ' + formatUtil.addCommas(value) + ' KB', + ].join(''); + } + }, + series: [ + { + name: 'Disk Usage', + type: 'treemap', + visibleMin: 300, + label: { + show: true, + formatter: '{b}' + }, + itemStyle: { + normal: { + borderColor: '#fff' + } + }, + levels: getLevelOption(), + data: diskData + } + ] + }); +}); diff --git a/testdata/doc-example/tutorial-async.js b/testdata/doc-example/tutorial-async.js new file mode 100644 index 0000000..6acc634 --- /dev/null +++ b/testdata/doc-example/tutorial-async.js @@ -0,0 +1,41 @@ +"use strict"; +function fetchData(cb) { + // 通过 setTimeout 模拟异步加载 + setTimeout(function () { + cb({ + categories: ["衬衫", "羊毛衫", "雪纺衫", "裤子", "高跟鞋", "袜子"], + data: [5, 20, 36, 10, 10, 20] + }); + }, 1000); +} +// 初始 option +option = { + title: { + text: '异步数据加载示例' + }, + tooltip: {}, + legend: { + data: ['销量'] + }, + xAxis: { + data: [] + }, + yAxis: {}, + series: [{ + name: '销量', + type: 'bar', + data: [] + }] +}; +fetchData(function (data) { + myChart.setOption({ + xAxis: { + data: data.categories + }, + series: [{ + // 根据名字对应到相应的系列 + name: '销量', + data: data.data + }] + }); +}); diff --git a/testdata/doc-example/tutorial-async.js.svg b/testdata/doc-example/tutorial-async.js.svg new file mode 100644 index 0000000..45b6120 --- /dev/null +++ b/testdata/doc-example/tutorial-async.js.svg @@ -0,0 +1,9 @@ + + + + + +销量 + +异步数据加载示例 + \ No newline at end of file diff --git a/testdata/doc-example/tutorial-dynamic-data.js b/testdata/doc-example/tutorial-dynamic-data.js new file mode 100644 index 0000000..940e416 --- /dev/null +++ b/testdata/doc-example/tutorial-dynamic-data.js @@ -0,0 +1,55 @@ +"use strict"; +var base = +new Date(2014, 9, 3); +var oneDay = 24 * 3600 * 1000; +var date = []; +var data = [Math.random() * 150]; +var now = new Date(base); +function addData(shift) { + now = [now.getFullYear(), now.getMonth() + 1, now.getDate()].join('/'); + date.push(now); + data.push((Math.random() - 0.4) * 10 + data[data.length - 1]); + if (shift) { + date.shift(); + data.shift(); + } + now = new Date(+new Date(now) + oneDay); +} +for (var i = 1; i < 100; i++) { + addData(); +} +option = { + xAxis: { + type: 'category', + boundaryGap: false, + data: date + }, + yAxis: { + boundaryGap: [0, '50%'], + type: 'value' + }, + series: [ + { + name: '成交', + type: 'line', + smooth: true, + symbol: 'none', + stack: 'a', + areaStyle: { + normal: {} + }, + data: data + } + ] +}; +setInterval(function () { + addData(true); + myChart.setOption({ + xAxis: { + data: date + }, + series: [{ + name: '成交', + data: data + }] + }); +}, 500); diff --git a/testdata/doc-example/tutorial-dynamic-data.js.svg b/testdata/doc-example/tutorial-dynamic-data.js.svg new file mode 100644 index 0000000..f35b16f --- /dev/null +++ b/testdata/doc-example/tutorial-dynamic-data.js.svg @@ -0,0 +1,54 @@ + + + + + + + + + + + + + + + + +0 +50 +100 +150 +200 +250 +2014/10/3 +NaN/NaN/NaN +NaN/NaN/NaN +NaN/NaN/NaN +NaN/NaN/NaN +NaN/NaN/NaN +NaN/NaN/NaN + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/doc-example/tutorial-loading.js b/testdata/doc-example/tutorial-loading.js new file mode 100644 index 0000000..31c76e2 --- /dev/null +++ b/testdata/doc-example/tutorial-loading.js @@ -0,0 +1,43 @@ +"use strict"; +function fetchData(cb) { + // 通过 setTimeout 模拟异步加载 + setTimeout(function () { + cb({ + categories: ["衬衫", "羊毛衫", "雪纺衫", "裤子", "高跟鞋", "袜子"], + data: [5, 20, 36, 10, 10, 20] + }); + }, 3000); +} +// 初始 option +option = { + title: { + text: '异步数据加载示例' + }, + tooltip: {}, + legend: { + data: ['销量'] + }, + xAxis: { + data: [] + }, + yAxis: {}, + series: [{ + name: '销量', + type: 'bar', + data: [] + }] +}; +myChart.showLoading(); +fetchData(function (data) { + myChart.hideLoading(); + myChart.setOption({ + xAxis: { + data: data.categories + }, + series: [{ + // 根据名字对应到相应的系列 + name: '销量', + data: data.data + }] + }); +}); diff --git a/testdata/doc-example/tutorial-styling-step0.js b/testdata/doc-example/tutorial-styling-step0.js new file mode 100644 index 0000000..e9c999a --- /dev/null +++ b/testdata/doc-example/tutorial-styling-step0.js @@ -0,0 +1,17 @@ +"use strict"; +option = { + series: [ + { + name: '访问来源', + type: 'pie', + radius: '55%', + data: [ + { value: 235, name: '视频广告' }, + { value: 274, name: '联盟广告' }, + { value: 310, name: '邮件营销' }, + { value: 335, name: '直接访问' }, + { value: 400, name: '搜索引擎' } + ] + } + ] +}; diff --git a/testdata/doc-example/tutorial-styling-step0.js.svg b/testdata/doc-example/tutorial-styling-step0.js.svg new file mode 100644 index 0000000..2360ef2 --- /dev/null +++ b/testdata/doc-example/tutorial-styling-step0.js.svg @@ -0,0 +1,77 @@ + + + + + + + + + + + + +视频广告 +联盟广告 +邮件营销 +直接访问 +搜索引擎 + + \ No newline at end of file diff --git a/testdata/doc-example/tutorial-styling-step1.js b/testdata/doc-example/tutorial-styling-step1.js new file mode 100644 index 0000000..12686c6 --- /dev/null +++ b/testdata/doc-example/tutorial-styling-step1.js @@ -0,0 +1,18 @@ +"use strict"; +option = { + series: [ + { + name: '访问来源', + type: 'pie', + radius: '55%', + roseType: 'angle', + data: [ + { value: 235, name: '视频广告' }, + { value: 274, name: '联盟广告' }, + { value: 310, name: '邮件营销' }, + { value: 335, name: '直接访问' }, + { value: 400, name: '搜索引擎' } + ] + } + ] +}; diff --git a/testdata/doc-example/tutorial-styling-step1.js.svg b/testdata/doc-example/tutorial-styling-step1.js.svg new file mode 100644 index 0000000..ff99914 --- /dev/null +++ b/testdata/doc-example/tutorial-styling-step1.js.svg @@ -0,0 +1,77 @@ + + + + + + + + + + + + +视频广告 +联盟广告 +邮件营销 +直接访问 +搜索引擎 + + \ No newline at end of file diff --git a/testdata/doc-example/tutorial-styling-step2.js b/testdata/doc-example/tutorial-styling-step2.js new file mode 100644 index 0000000..fd12b6a --- /dev/null +++ b/testdata/doc-example/tutorial-styling-step2.js @@ -0,0 +1,24 @@ +"use strict"; +option = { + series: [ + { + name: '访问来源', + type: 'pie', + radius: '55%', + data: [ + { value: 235, name: '视频广告' }, + { value: 274, name: '联盟广告' }, + { value: 310, name: '邮件营销' }, + { value: 335, name: '直接访问' }, + { value: 400, name: '搜索引擎' } + ], + roseType: 'angle', + itemStyle: { + normal: { + shadowBlur: 200, + shadowColor: 'rgba(0, 0, 0, 0.5)' + } + } + } + ] +}; diff --git a/testdata/doc-example/tutorial-styling-step2.js.svg b/testdata/doc-example/tutorial-styling-step2.js.svg new file mode 100644 index 0000000..2fd4308 --- /dev/null +++ b/testdata/doc-example/tutorial-styling-step2.js.svg @@ -0,0 +1,82 @@ + + + + + + + + + + + + +视频广告 +联盟广告 +邮件营销 +直接访问 +搜索引擎 + + + + + + + \ No newline at end of file diff --git a/testdata/doc-example/tutorial-styling-step3.js b/testdata/doc-example/tutorial-styling-step3.js new file mode 100644 index 0000000..e9186d6 --- /dev/null +++ b/testdata/doc-example/tutorial-styling-step3.js @@ -0,0 +1,39 @@ +"use strict"; +option = { + backgroundColor: '#2c343c', + series: [ + { + name: '访问来源', + type: 'pie', + radius: '55%', + data: [ + { value: 235, name: '视频广告' }, + { value: 274, name: '联盟广告' }, + { value: 310, name: '邮件营销' }, + { value: 335, name: '直接访问' }, + { value: 400, name: '搜索引擎' } + ], + roseType: 'angle', + label: { + normal: { + textStyle: { + color: 'rgba(255, 255, 255, 0.3)' + } + } + }, + labelLine: { + normal: { + lineStyle: { + color: 'rgba(255, 255, 255, 0.3)' + } + } + }, + itemStyle: { + normal: { + shadowBlur: 200, + shadowColor: 'rgba(0, 0, 0, 0.5)' + } + } + } + ] +}; diff --git a/testdata/doc-example/tutorial-styling-step3.js.svg b/testdata/doc-example/tutorial-styling-step3.js.svg new file mode 100644 index 0000000..982ada9 --- /dev/null +++ b/testdata/doc-example/tutorial-styling-step3.js.svg @@ -0,0 +1,82 @@ + + + + + + + + + + + + +视频广告 +联盟广告 +邮件营销 +直接访问 +搜索引擎 + + + + + + + \ No newline at end of file diff --git a/testdata/doc-example/tutorial-styling-step4.js b/testdata/doc-example/tutorial-styling-step4.js new file mode 100644 index 0000000..3b9ccba --- /dev/null +++ b/testdata/doc-example/tutorial-styling-step4.js @@ -0,0 +1,40 @@ +"use strict"; +option = { + backgroundColor: '#2c343c', + series: [ + { + name: '访问来源', + type: 'pie', + radius: '55%', + data: [ + { value: 235, name: '视频广告' }, + { value: 274, name: '联盟广告' }, + { value: 310, name: '邮件营销' }, + { value: 335, name: '直接访问' }, + { value: 400, name: '搜索引擎' } + ], + roseType: 'angle', + label: { + normal: { + textStyle: { + color: 'rgba(255, 255, 255, 0.3)' + } + } + }, + labelLine: { + normal: { + lineStyle: { + color: 'rgba(255, 255, 255, 0.3)' + } + } + }, + itemStyle: { + normal: { + color: '#c23531', + shadowBlur: 200, + shadowColor: 'rgba(0, 0, 0, 0.5)' + } + } + } + ] +}; diff --git a/testdata/doc-example/tutorial-styling-step4.js.svg b/testdata/doc-example/tutorial-styling-step4.js.svg new file mode 100644 index 0000000..a8c8bbf --- /dev/null +++ b/testdata/doc-example/tutorial-styling-step4.js.svg @@ -0,0 +1,82 @@ + + + + + + + + + + + + +视频广告 +联盟广告 +邮件营销 +直接访问 +搜索引擎 + + + + + + + \ No newline at end of file diff --git a/testdata/doc-example/tutorial-styling-step5.js b/testdata/doc-example/tutorial-styling-step5.js new file mode 100644 index 0000000..8dd3de0 --- /dev/null +++ b/testdata/doc-example/tutorial-styling-step5.js @@ -0,0 +1,48 @@ +"use strict"; +option = { + backgroundColor: '#2c343c', + visualMap: { + show: false, + min: 80, + max: 600, + inRange: { + colorLightness: [0, 1] + } + }, + series: [ + { + name: '访问来源', + type: 'pie', + radius: '55%', + data: [ + { value: 235, name: '视频广告' }, + { value: 274, name: '联盟广告' }, + { value: 310, name: '邮件营销' }, + { value: 335, name: '直接访问' }, + { value: 400, name: '搜索引擎' } + ], + roseType: 'angle', + label: { + normal: { + textStyle: { + color: 'rgba(255, 255, 255, 0.3)' + } + } + }, + labelLine: { + normal: { + lineStyle: { + color: 'rgba(255, 255, 255, 0.3)' + } + } + }, + itemStyle: { + normal: { + color: '#c23531', + shadowBlur: 200, + shadowColor: 'rgba(0, 0, 0, 0.5)' + } + } + } + ] +}; diff --git a/testdata/doc-example/tutorial-styling-step5.js.svg b/testdata/doc-example/tutorial-styling-step5.js.svg new file mode 100644 index 0000000..66eacf1 --- /dev/null +++ b/testdata/doc-example/tutorial-styling-step5.js.svg @@ -0,0 +1,82 @@ + + + + + + + + + + + + +视频广告 +联盟广告 +邮件营销 +直接访问 +搜索引擎 + + + + + + + \ No newline at end of file diff --git a/testdata/doc-example/value-animation-simple.js b/testdata/doc-example/value-animation-simple.js new file mode 100644 index 0000000..b3bec12 --- /dev/null +++ b/testdata/doc-example/value-animation-simple.js @@ -0,0 +1,58 @@ +"use strict"; +var Y_MAX = 1000; +var UPDATE_DURATION = 3000; +var initVal = makeRandomValue(); +option = { + xAxis: { + data: ['a'], + axisLabel: { show: false } + }, + yAxis: { + max: Y_MAX + }, + legend: { + bottom: 10 + }, + series: [{ + name: 'valueAnimation: true', + type: 'bar', + data: [initVal], + label: { + show: true, + valueAnimation: true, + position: 'top', + fontSize: 40 + }, + barWidth: 20, + barGap: '1000%', + barCategoryGap: 200, + animationDurationUpdate: UPDATE_DURATION * 0.7, + animationEasingUpdate: 'linear' + }, { + name: 'valueAnimation: false', + type: 'bar', + data: [initVal], + label: { + show: true, + valueAnimation: false, + position: 'top', + fontSize: 40 + }, + barWidth: 20, + animationDurationUpdate: UPDATE_DURATION * 0.7, + animationEasingUpdate: 'linear' + }], +}; +setInterval(function () { + var newVal = makeRandomValue(); + myChart.setOption({ + series: [{ + data: [newVal] + }, { + data: [newVal] + }] + }); +}, UPDATE_DURATION); +function makeRandomValue() { + return Math.round(Math.random() * Y_MAX); +} diff --git a/testdata/doc-example/value-animation-simple.js.svg b/testdata/doc-example/value-animation-simple.js.svg new file mode 100644 index 0000000..2a1e288 --- /dev/null +++ b/testdata/doc-example/value-animation-simple.js.svg @@ -0,0 +1,53 @@ + + + + + + + + + + + +0 +200 +400 +600 +800 +1,000 + + +774 +774 + + +valueAnimation: true + +valueAnimation: false + + \ No newline at end of file diff --git a/testdata/dynamic-data.js b/testdata/dynamic-data.js new file mode 100644 index 0000000..29f1c87 --- /dev/null +++ b/testdata/dynamic-data.js @@ -0,0 +1,144 @@ +/* +title: Dynamic Data +category: bar +titleCN: 动态数据 +difficulty: 6 +*/ +const categories = (function () { + let now = new Date(); + let res = []; + let len = 10; + while (len--) { + res.unshift(now.toLocaleTimeString().replace(/^\D*/, '')); + now = new Date(+now - 2000); + } + return res; +})(); +const categories2 = (function () { + let res = []; + let len = 10; + while (len--) { + res.push(10 - len - 1); + } + return res; +})(); +const data = (function () { + let res = []; + let len = 10; + while (len--) { + res.push(Math.round(Math.random() * 1000)); + } + return res; +})(); +const data2 = (function () { + let res = []; + let len = 0; + while (len < 10) { + res.push(+(Math.random() * 10 + 5).toFixed(1)); + len++; + } + return res; +})(); +option = { + title: { + text: 'Dynamic Data' + }, + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'cross', + label: { + backgroundColor: '#283b56' + } + } + }, + legend: {}, + toolbox: { + show: true, + feature: { + dataView: { readOnly: false }, + restore: {}, + saveAsImage: {} + } + }, + dataZoom: { + show: false, + start: 0, + end: 100 + }, + xAxis: [ + { + type: 'category', + boundaryGap: true, + data: categories + }, + { + type: 'category', + boundaryGap: true, + data: categories2 + } + ], + yAxis: [ + { + type: 'value', + scale: true, + name: 'Price', + max: 30, + min: 0, + boundaryGap: [0.2, 0.2] + }, + { + type: 'value', + scale: true, + name: 'Order', + max: 1200, + min: 0, + boundaryGap: [0.2, 0.2] + } + ], + series: [ + { + name: 'Dynamic Bar', + type: 'bar', + xAxisIndex: 1, + yAxisIndex: 1, + data: data + }, + { + name: 'Dynamic Line', + type: 'line', + data: data2 + } + ] +}; +app.count = 11; +setInterval(function () { + let axisData = new Date().toLocaleTimeString().replace(/^\D*/, ''); + data.shift(); + data.push(Math.round(Math.random() * 1000)); + data2.shift(); + data2.push(+(Math.random() * 10 + 5).toFixed(1)); + categories.shift(); + categories.push(axisData); + categories2.shift(); + categories2.push(app.count++); + myChart.setOption({ + xAxis: [ + { + data: categories + }, + { + data: categories2 + } + ], + series: [ + { + data: data + }, + { + data: data2 + } + ] + }); +}, 2100); +export {}; diff --git a/testdata/dynamic-data.js.svg b/testdata/dynamic-data.js.svg new file mode 100644 index 0000000..d0e23e0 --- /dev/null +++ b/testdata/dynamic-data.js.svg @@ -0,0 +1,242 @@ + + + + + + + + + + + + + + + + +Price +Order + + + + + + + + + + + + + + + + + + + + + + + + +0 +5 +10 +15 +20 +25 +30 +0 +200 +400 +600 +800 +1,000 +1,200 +10:32:06 +10:32:08 +10:32:10 +10:32:12 +10:32:14 +10:32:16 +10:32:18 +10:32:20 +10:32:22 +10:32:24 +0 +1 +2 +3 +4 +5 +6 +7 +8 +9 + + + + + + + + + + + + + + + + + + + + + + + + + +Dynamic Bar + + +Dynamic Line + + + + + +Dynamic Data + + + + + + + \ No newline at end of file diff --git a/testdata/dynamic-data2.js b/testdata/dynamic-data2.js new file mode 100644 index 0000000..fb4e05e --- /dev/null +++ b/testdata/dynamic-data2.js @@ -0,0 +1,81 @@ +/* +title: Dynamic Data + Time Axis +category: line +titleCN: 动态数据 + 时间坐标轴 +difficulty: 5 +*/ +function randomData() { + now = new Date(+now + oneDay); + value = value + Math.random() * 21 - 10; + return { + name: now.toString(), + value: [ + [now.getFullYear(), now.getMonth() + 1, now.getDate()].join('/'), + Math.round(value) + ] + }; +} +let data = []; +let now = new Date(1997, 9, 3); +let oneDay = 24 * 3600 * 1000; +let value = Math.random() * 1000; +for (var i = 0; i < 1000; i++) { + data.push(randomData()); +} +option = { + title: { + text: 'Dynamic Data & Time Axis' + }, + tooltip: { + trigger: 'axis', + formatter: function (params) { + params = params[0]; + var date = new Date(params.name); + return (date.getDate() + + '/' + + (date.getMonth() + 1) + + '/' + + date.getFullYear() + + ' : ' + + params.value[1]); + }, + axisPointer: { + animation: false + } + }, + xAxis: { + type: 'time', + splitLine: { + show: false + } + }, + yAxis: { + type: 'value', + boundaryGap: [0, '100%'], + splitLine: { + show: false + } + }, + series: [ + { + name: 'Fake Data', + type: 'line', + showSymbol: false, + data: data + } + ] +}; +setInterval(function () { + for (var i = 0; i < 5; i++) { + data.shift(); + data.push(randomData()); + } + myChart.setOption({ + series: [ + { + data: data + } + ] + }); +}, 1000); +export {}; diff --git a/testdata/dynamic-data2.js.svg b/testdata/dynamic-data2.js.svg new file mode 100644 index 0000000..e095ad6 --- /dev/null +++ b/testdata/dynamic-data2.js.svg @@ -0,0 +1,55 @@ + + + + + + + + + + + + + +0 +500 +1,000 +1,500 +2,000 +2,500 +Apr +Jul +Oct +Apr +Jul +Oct +Apr +1998 +1999 +2000 + + + + +Dynamic Data & Time Axis + + + + + + + \ No newline at end of file diff --git a/testdata/effectScatter-bmap.js b/testdata/effectScatter-bmap.js new file mode 100644 index 0000000..8bbb687 --- /dev/null +++ b/testdata/effectScatter-bmap.js @@ -0,0 +1,594 @@ +/* +title: Air Quality - Baidu Map +category: 'scatter, map' +tags: bmap +titleCN: 全国主要城市空气质量 - 百度地图 +difficulty: 10 +*/ +const data = [ + { name: '海门', value: 9 }, + { name: '鄂尔多斯', value: 12 }, + { name: '招远', value: 12 }, + { name: '舟山', value: 12 }, + { name: '齐齐哈尔', value: 14 }, + { name: '盐城', value: 15 }, + { name: '赤峰', value: 16 }, + { name: '青岛', value: 18 }, + { name: '乳山', value: 18 }, + { name: '金昌', value: 19 }, + { name: '泉州', value: 21 }, + { name: '莱西', value: 21 }, + { name: '日照', value: 21 }, + { name: '胶南', value: 22 }, + { name: '南通', value: 23 }, + { name: '拉萨', value: 24 }, + { name: '云浮', value: 24 }, + { name: '梅州', value: 25 }, + { name: '文登', value: 25 }, + { name: '上海', value: 25 }, + { name: '攀枝花', value: 25 }, + { name: '威海', value: 25 }, + { name: '承德', value: 25 }, + { name: '厦门', value: 26 }, + { name: '汕尾', value: 26 }, + { name: '潮州', value: 26 }, + { name: '丹东', value: 27 }, + { name: '太仓', value: 27 }, + { name: '曲靖', value: 27 }, + { name: '烟台', value: 28 }, + { name: '福州', value: 29 }, + { name: '瓦房店', value: 30 }, + { name: '即墨', value: 30 }, + { name: '抚顺', value: 31 }, + { name: '玉溪', value: 31 }, + { name: '张家口', value: 31 }, + { name: '阳泉', value: 31 }, + { name: '莱州', value: 32 }, + { name: '湖州', value: 32 }, + { name: '汕头', value: 32 }, + { name: '昆山', value: 33 }, + { name: '宁波', value: 33 }, + { name: '湛江', value: 33 }, + { name: '揭阳', value: 34 }, + { name: '荣成', value: 34 }, + { name: '连云港', value: 35 }, + { name: '葫芦岛', value: 35 }, + { name: '常熟', value: 36 }, + { name: '东莞', value: 36 }, + { name: '河源', value: 36 }, + { name: '淮安', value: 36 }, + { name: '泰州', value: 36 }, + { name: '南宁', value: 37 }, + { name: '营口', value: 37 }, + { name: '惠州', value: 37 }, + { name: '江阴', value: 37 }, + { name: '蓬莱', value: 37 }, + { name: '韶关', value: 38 }, + { name: '嘉峪关', value: 38 }, + { name: '广州', value: 38 }, + { name: '延安', value: 38 }, + { name: '太原', value: 39 }, + { name: '清远', value: 39 }, + { name: '中山', value: 39 }, + { name: '昆明', value: 39 }, + { name: '寿光', value: 40 }, + { name: '盘锦', value: 40 }, + { name: '长治', value: 41 }, + { name: '深圳', value: 41 }, + { name: '珠海', value: 42 }, + { name: '宿迁', value: 43 }, + { name: '咸阳', value: 43 }, + { name: '铜川', value: 44 }, + { name: '平度', value: 44 }, + { name: '佛山', value: 44 }, + { name: '海口', value: 44 }, + { name: '江门', value: 45 }, + { name: '章丘', value: 45 }, + { name: '肇庆', value: 46 }, + { name: '大连', value: 47 }, + { name: '临汾', value: 47 }, + { name: '吴江', value: 47 }, + { name: '石嘴山', value: 49 }, + { name: '沈阳', value: 50 }, + { name: '苏州', value: 50 }, + { name: '茂名', value: 50 }, + { name: '嘉兴', value: 51 }, + { name: '长春', value: 51 }, + { name: '胶州', value: 52 }, + { name: '银川', value: 52 }, + { name: '张家港', value: 52 }, + { name: '三门峡', value: 53 }, + { name: '锦州', value: 54 }, + { name: '南昌', value: 54 }, + { name: '柳州', value: 54 }, + { name: '三亚', value: 54 }, + { name: '自贡', value: 56 }, + { name: '吉林', value: 56 }, + { name: '阳江', value: 57 }, + { name: '泸州', value: 57 }, + { name: '西宁', value: 57 }, + { name: '宜宾', value: 58 }, + { name: '呼和浩特', value: 58 }, + { name: '成都', value: 58 }, + { name: '大同', value: 58 }, + { name: '镇江', value: 59 }, + { name: '桂林', value: 59 }, + { name: '张家界', value: 59 }, + { name: '宜兴', value: 59 }, + { name: '北海', value: 60 }, + { name: '西安', value: 61 }, + { name: '金坛', value: 62 }, + { name: '东营', value: 62 }, + { name: '牡丹江', value: 63 }, + { name: '遵义', value: 63 }, + { name: '绍兴', value: 63 }, + { name: '扬州', value: 64 }, + { name: '常州', value: 64 }, + { name: '潍坊', value: 65 }, + { name: '重庆', value: 66 }, + { name: '台州', value: 67 }, + { name: '南京', value: 67 }, + { name: '滨州', value: 70 }, + { name: '贵阳', value: 71 }, + { name: '无锡', value: 71 }, + { name: '本溪', value: 71 }, + { name: '克拉玛依', value: 72 }, + { name: '渭南', value: 72 }, + { name: '马鞍山', value: 72 }, + { name: '宝鸡', value: 72 }, + { name: '焦作', value: 75 }, + { name: '句容', value: 75 }, + { name: '北京', value: 79 }, + { name: '徐州', value: 79 }, + { name: '衡水', value: 80 }, + { name: '包头', value: 80 }, + { name: '绵阳', value: 80 }, + { name: '乌鲁木齐', value: 84 }, + { name: '枣庄', value: 84 }, + { name: '杭州', value: 84 }, + { name: '淄博', value: 85 }, + { name: '鞍山', value: 86 }, + { name: '溧阳', value: 86 }, + { name: '库尔勒', value: 86 }, + { name: '安阳', value: 90 }, + { name: '开封', value: 90 }, + { name: '济南', value: 92 }, + { name: '德阳', value: 93 }, + { name: '温州', value: 95 }, + { name: '九江', value: 96 }, + { name: '邯郸', value: 98 }, + { name: '临安', value: 99 }, + { name: '兰州', value: 99 }, + { name: '沧州', value: 100 }, + { name: '临沂', value: 103 }, + { name: '南充', value: 104 }, + { name: '天津', value: 105 }, + { name: '富阳', value: 106 }, + { name: '泰安', value: 112 }, + { name: '诸暨', value: 112 }, + { name: '郑州', value: 113 }, + { name: '哈尔滨', value: 114 }, + { name: '聊城', value: 116 }, + { name: '芜湖', value: 117 }, + { name: '唐山', value: 119 }, + { name: '平顶山', value: 119 }, + { name: '邢台', value: 119 }, + { name: '德州', value: 120 }, + { name: '济宁', value: 120 }, + { name: '荆州', value: 127 }, + { name: '宜昌', value: 130 }, + { name: '义乌', value: 132 }, + { name: '丽水', value: 133 }, + { name: '洛阳', value: 134 }, + { name: '秦皇岛', value: 136 }, + { name: '株洲', value: 143 }, + { name: '石家庄', value: 147 }, + { name: '莱芜', value: 148 }, + { name: '常德', value: 152 }, + { name: '保定', value: 153 }, + { name: '湘潭', value: 154 }, + { name: '金华', value: 157 }, + { name: '岳阳', value: 169 }, + { name: '长沙', value: 175 }, + { name: '衢州', value: 177 }, + { name: '廊坊', value: 193 }, + { name: '菏泽', value: 194 }, + { name: '合肥', value: 229 }, + { name: '武汉', value: 273 }, + { name: '大庆', value: 279 } +]; +const geoCoordMap = { + 海门: [121.15, 31.89], + 鄂尔多斯: [109.781327, 39.608266], + 招远: [120.38, 37.35], + 舟山: [122.207216, 29.985295], + 齐齐哈尔: [123.97, 47.33], + 盐城: [120.13, 33.38], + 赤峰: [118.87, 42.28], + 青岛: [120.33, 36.07], + 乳山: [121.52, 36.89], + 金昌: [102.188043, 38.520089], + 泉州: [118.58, 24.93], + 莱西: [120.53, 36.86], + 日照: [119.46, 35.42], + 胶南: [119.97, 35.88], + 南通: [121.05, 32.08], + 拉萨: [91.11, 29.97], + 云浮: [112.02, 22.93], + 梅州: [116.1, 24.55], + 文登: [122.05, 37.2], + 上海: [121.48, 31.22], + 攀枝花: [101.718637, 26.582347], + 威海: [122.1, 37.5], + 承德: [117.93, 40.97], + 厦门: [118.1, 24.46], + 汕尾: [115.375279, 22.786211], + 潮州: [116.63, 23.68], + 丹东: [124.37, 40.13], + 太仓: [121.1, 31.45], + 曲靖: [103.79, 25.51], + 烟台: [121.39, 37.52], + 福州: [119.3, 26.08], + 瓦房店: [121.979603, 39.627114], + 即墨: [120.45, 36.38], + 抚顺: [123.97, 41.97], + 玉溪: [102.52, 24.35], + 张家口: [114.87, 40.82], + 阳泉: [113.57, 37.85], + 莱州: [119.942327, 37.177017], + 湖州: [120.1, 30.86], + 汕头: [116.69, 23.39], + 昆山: [120.95, 31.39], + 宁波: [121.56, 29.86], + 湛江: [110.359377, 21.270708], + 揭阳: [116.35, 23.55], + 荣成: [122.41, 37.16], + 连云港: [119.16, 34.59], + 葫芦岛: [120.836932, 40.711052], + 常熟: [120.74, 31.64], + 东莞: [113.75, 23.04], + 河源: [114.68, 23.73], + 淮安: [119.15, 33.5], + 泰州: [119.9, 32.49], + 南宁: [108.33, 22.84], + 营口: [122.18, 40.65], + 惠州: [114.4, 23.09], + 江阴: [120.26, 31.91], + 蓬莱: [120.75, 37.8], + 韶关: [113.62, 24.84], + 嘉峪关: [98.289152, 39.77313], + 广州: [113.23, 23.16], + 延安: [109.47, 36.6], + 太原: [112.53, 37.87], + 清远: [113.01, 23.7], + 中山: [113.38, 22.52], + 昆明: [102.73, 25.04], + 寿光: [118.73, 36.86], + 盘锦: [122.070714, 41.119997], + 长治: [113.08, 36.18], + 深圳: [114.07, 22.62], + 珠海: [113.52, 22.3], + 宿迁: [118.3, 33.96], + 咸阳: [108.72, 34.36], + 铜川: [109.11, 35.09], + 平度: [119.97, 36.77], + 佛山: [113.11, 23.05], + 海口: [110.35, 20.02], + 江门: [113.06, 22.61], + 章丘: [117.53, 36.72], + 肇庆: [112.44, 23.05], + 大连: [121.62, 38.92], + 临汾: [111.5, 36.08], + 吴江: [120.63, 31.16], + 石嘴山: [106.39, 39.04], + 沈阳: [123.38, 41.8], + 苏州: [120.62, 31.32], + 茂名: [110.88, 21.68], + 嘉兴: [120.76, 30.77], + 长春: [125.35, 43.88], + 胶州: [120.03336, 36.264622], + 银川: [106.27, 38.47], + 张家港: [120.555821, 31.875428], + 三门峡: [111.19, 34.76], + 锦州: [121.15, 41.13], + 南昌: [115.89, 28.68], + 柳州: [109.4, 24.33], + 三亚: [109.511909, 18.252847], + 自贡: [104.778442, 29.33903], + 吉林: [126.57, 43.87], + 阳江: [111.95, 21.85], + 泸州: [105.39, 28.91], + 西宁: [101.74, 36.56], + 宜宾: [104.56, 29.77], + 呼和浩特: [111.65, 40.82], + 成都: [104.06, 30.67], + 大同: [113.3, 40.12], + 镇江: [119.44, 32.2], + 桂林: [110.28, 25.29], + 张家界: [110.479191, 29.117096], + 宜兴: [119.82, 31.36], + 北海: [109.12, 21.49], + 西安: [108.95, 34.27], + 金坛: [119.56, 31.74], + 东营: [118.49, 37.46], + 牡丹江: [129.58, 44.6], + 遵义: [106.9, 27.7], + 绍兴: [120.58, 30.01], + 扬州: [119.42, 32.39], + 常州: [119.95, 31.79], + 潍坊: [119.1, 36.62], + 重庆: [106.54, 29.59], + 台州: [121.420757, 28.656386], + 南京: [118.78, 32.04], + 滨州: [118.03, 37.36], + 贵阳: [106.71, 26.57], + 无锡: [120.29, 31.59], + 本溪: [123.73, 41.3], + 克拉玛依: [84.77, 45.59], + 渭南: [109.5, 34.52], + 马鞍山: [118.48, 31.56], + 宝鸡: [107.15, 34.38], + 焦作: [113.21, 35.24], + 句容: [119.16, 31.95], + 北京: [116.46, 39.92], + 徐州: [117.2, 34.26], + 衡水: [115.72, 37.72], + 包头: [110, 40.58], + 绵阳: [104.73, 31.48], + 乌鲁木齐: [87.68, 43.77], + 枣庄: [117.57, 34.86], + 杭州: [120.19, 30.26], + 淄博: [118.05, 36.78], + 鞍山: [122.85, 41.12], + 溧阳: [119.48, 31.43], + 库尔勒: [86.06, 41.68], + 安阳: [114.35, 36.1], + 开封: [114.35, 34.79], + 济南: [117, 36.65], + 德阳: [104.37, 31.13], + 温州: [120.65, 28.01], + 九江: [115.97, 29.71], + 邯郸: [114.47, 36.6], + 临安: [119.72, 30.23], + 兰州: [103.73, 36.03], + 沧州: [116.83, 38.33], + 临沂: [118.35, 35.05], + 南充: [106.110698, 30.837793], + 天津: [117.2, 39.13], + 富阳: [119.95, 30.07], + 泰安: [117.13, 36.18], + 诸暨: [120.23, 29.71], + 郑州: [113.65, 34.76], + 哈尔滨: [126.63, 45.75], + 聊城: [115.97, 36.45], + 芜湖: [118.38, 31.33], + 唐山: [118.02, 39.63], + 平顶山: [113.29, 33.75], + 邢台: [114.48, 37.05], + 德州: [116.29, 37.45], + 济宁: [116.59, 35.38], + 荆州: [112.239741, 30.335165], + 宜昌: [111.3, 30.7], + 义乌: [120.06, 29.32], + 丽水: [119.92, 28.45], + 洛阳: [112.44, 34.7], + 秦皇岛: [119.57, 39.95], + 株洲: [113.16, 27.83], + 石家庄: [114.48, 38.03], + 莱芜: [117.67, 36.19], + 常德: [111.69, 29.05], + 保定: [115.48, 38.85], + 湘潭: [112.91, 27.87], + 金华: [119.64, 29.12], + 岳阳: [113.09, 29.37], + 长沙: [113, 28.21], + 衢州: [118.88, 28.97], + 廊坊: [116.7, 39.53], + 菏泽: [115.480656, 35.23375], + 合肥: [117.27, 31.86], + 武汉: [114.31, 30.52], + 大庆: [125.03, 46.58] +}; +const convertData = function (data) { + var res = []; + for (var i = 0; i < data.length; i++) { + var geoCoord = geoCoordMap[data[i].name]; + if (geoCoord) { + res.push({ + name: data[i].name, + value: geoCoord.concat(data[i].value) + }); + } + } + return res; +}; +option = { + title: { + text: '全国主要城市空气质量 - 百度地图', + subtext: 'data from PM25.in', + sublink: 'http://www.pm25.in', + left: 'center' + }, + tooltip: { + trigger: 'item' + }, + bmap: { + center: [104.114129, 37.550339], + zoom: 5, + roam: true, + mapStyle: { + styleJson: [ + { + featureType: 'water', + elementType: 'all', + stylers: { + color: '#d1d1d1' + } + }, + { + featureType: 'land', + elementType: 'all', + stylers: { + color: '#f3f3f3' + } + }, + { + featureType: 'railway', + elementType: 'all', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'highway', + elementType: 'all', + stylers: { + color: '#fdfdfd' + } + }, + { + featureType: 'highway', + elementType: 'labels', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'arterial', + elementType: 'geometry', + stylers: { + color: '#fefefe' + } + }, + { + featureType: 'arterial', + elementType: 'geometry.fill', + stylers: { + color: '#fefefe' + } + }, + { + featureType: 'poi', + elementType: 'all', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'green', + elementType: 'all', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'subway', + elementType: 'all', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'manmade', + elementType: 'all', + stylers: { + color: '#d1d1d1' + } + }, + { + featureType: 'local', + elementType: 'all', + stylers: { + color: '#d1d1d1' + } + }, + { + featureType: 'arterial', + elementType: 'labels', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'boundary', + elementType: 'all', + stylers: { + color: '#fefefe' + } + }, + { + featureType: 'building', + elementType: 'all', + stylers: { + color: '#d1d1d1' + } + }, + { + featureType: 'label', + elementType: 'labels.text.fill', + stylers: { + color: '#999999' + } + } + ] + } + }, + series: [ + { + name: 'pm2.5', + type: 'scatter', + coordinateSystem: 'bmap', + data: convertData(data), + symbolSize: function (val) { + return val[2] / 10; + }, + encode: { + value: 2 + }, + label: { + formatter: '{b}', + position: 'right', + show: false + }, + emphasis: { + label: { + show: true + } + } + }, + { + name: 'Top 5', + type: 'effectScatter', + coordinateSystem: 'bmap', + data: convertData(data + .sort(function (a, b) { + return b.value - a.value; + }) + .slice(0, 6)), + symbolSize: function (val) { + return val[2] / 10; + }, + encode: { + value: 2 + }, + showEffectOn: 'render', + rippleEffect: { + brushType: 'stroke' + }, + label: { + formatter: '{b}', + position: 'right', + show: true + }, + itemStyle: { + shadowBlur: 10, + shadowColor: '#333' + }, + emphasis: { + scale: true + }, + zlevel: 1 + } + ] +}; +export {}; diff --git a/testdata/effectScatter-bmap.js.svg b/testdata/effectScatter-bmap.js.svg new file mode 100644 index 0000000..5de67df --- /dev/null +++ b/testdata/effectScatter-bmap.js.svg @@ -0,0 +1,6 @@ + + + +全国主要城市空气质量 - 百度地图 +data from PM25.in + \ No newline at end of file diff --git a/testdata/effectScatter-map.js b/testdata/effectScatter-map.js new file mode 100644 index 0000000..c078a44 --- /dev/null +++ b/testdata/effectScatter-map.js @@ -0,0 +1,505 @@ +/* +title: Air Quality +category: scatter +titleCN: 全国主要城市空气质量 +difficulty: 2 +*/ +const data = [ + { name: '海门', value: 9 }, + { name: '鄂尔多斯', value: 12 }, + { name: '招远', value: 12 }, + { name: '舟山', value: 12 }, + { name: '齐齐哈尔', value: 14 }, + { name: '盐城', value: 15 }, + { name: '赤峰', value: 16 }, + { name: '青岛', value: 18 }, + { name: '乳山', value: 18 }, + { name: '金昌', value: 19 }, + { name: '泉州', value: 21 }, + { name: '莱西', value: 21 }, + { name: '日照', value: 21 }, + { name: '胶南', value: 22 }, + { name: '南通', value: 23 }, + { name: '拉萨', value: 24 }, + { name: '云浮', value: 24 }, + { name: '梅州', value: 25 }, + { name: '文登', value: 25 }, + { name: '上海', value: 25 }, + { name: '攀枝花', value: 25 }, + { name: '威海', value: 25 }, + { name: '承德', value: 25 }, + { name: '厦门', value: 26 }, + { name: '汕尾', value: 26 }, + { name: '潮州', value: 26 }, + { name: '丹东', value: 27 }, + { name: '太仓', value: 27 }, + { name: '曲靖', value: 27 }, + { name: '烟台', value: 28 }, + { name: '福州', value: 29 }, + { name: '瓦房店', value: 30 }, + { name: '即墨', value: 30 }, + { name: '抚顺', value: 31 }, + { name: '玉溪', value: 31 }, + { name: '张家口', value: 31 }, + { name: '阳泉', value: 31 }, + { name: '莱州', value: 32 }, + { name: '湖州', value: 32 }, + { name: '汕头', value: 32 }, + { name: '昆山', value: 33 }, + { name: '宁波', value: 33 }, + { name: '湛江', value: 33 }, + { name: '揭阳', value: 34 }, + { name: '荣成', value: 34 }, + { name: '连云港', value: 35 }, + { name: '葫芦岛', value: 35 }, + { name: '常熟', value: 36 }, + { name: '东莞', value: 36 }, + { name: '河源', value: 36 }, + { name: '淮安', value: 36 }, + { name: '泰州', value: 36 }, + { name: '南宁', value: 37 }, + { name: '营口', value: 37 }, + { name: '惠州', value: 37 }, + { name: '江阴', value: 37 }, + { name: '蓬莱', value: 37 }, + { name: '韶关', value: 38 }, + { name: '嘉峪关', value: 38 }, + { name: '广州', value: 38 }, + { name: '延安', value: 38 }, + { name: '太原', value: 39 }, + { name: '清远', value: 39 }, + { name: '中山', value: 39 }, + { name: '昆明', value: 39 }, + { name: '寿光', value: 40 }, + { name: '盘锦', value: 40 }, + { name: '长治', value: 41 }, + { name: '深圳', value: 41 }, + { name: '珠海', value: 42 }, + { name: '宿迁', value: 43 }, + { name: '咸阳', value: 43 }, + { name: '铜川', value: 44 }, + { name: '平度', value: 44 }, + { name: '佛山', value: 44 }, + { name: '海口', value: 44 }, + { name: '江门', value: 45 }, + { name: '章丘', value: 45 }, + { name: '肇庆', value: 46 }, + { name: '大连', value: 47 }, + { name: '临汾', value: 47 }, + { name: '吴江', value: 47 }, + { name: '石嘴山', value: 49 }, + { name: '沈阳', value: 50 }, + { name: '苏州', value: 50 }, + { name: '茂名', value: 50 }, + { name: '嘉兴', value: 51 }, + { name: '长春', value: 51 }, + { name: '胶州', value: 52 }, + { name: '银川', value: 52 }, + { name: '张家港', value: 52 }, + { name: '三门峡', value: 53 }, + { name: '锦州', value: 54 }, + { name: '南昌', value: 54 }, + { name: '柳州', value: 54 }, + { name: '三亚', value: 54 }, + { name: '自贡', value: 56 }, + { name: '吉林', value: 56 }, + { name: '阳江', value: 57 }, + { name: '泸州', value: 57 }, + { name: '西宁', value: 57 }, + { name: '宜宾', value: 58 }, + { name: '呼和浩特', value: 58 }, + { name: '成都', value: 58 }, + { name: '大同', value: 58 }, + { name: '镇江', value: 59 }, + { name: '桂林', value: 59 }, + { name: '张家界', value: 59 }, + { name: '宜兴', value: 59 }, + { name: '北海', value: 60 }, + { name: '西安', value: 61 }, + { name: '金坛', value: 62 }, + { name: '东营', value: 62 }, + { name: '牡丹江', value: 63 }, + { name: '遵义', value: 63 }, + { name: '绍兴', value: 63 }, + { name: '扬州', value: 64 }, + { name: '常州', value: 64 }, + { name: '潍坊', value: 65 }, + { name: '重庆', value: 66 }, + { name: '台州', value: 67 }, + { name: '南京', value: 67 }, + { name: '滨州', value: 70 }, + { name: '贵阳', value: 71 }, + { name: '无锡', value: 71 }, + { name: '本溪', value: 71 }, + { name: '克拉玛依', value: 72 }, + { name: '渭南', value: 72 }, + { name: '马鞍山', value: 72 }, + { name: '宝鸡', value: 72 }, + { name: '焦作', value: 75 }, + { name: '句容', value: 75 }, + { name: '北京', value: 79 }, + { name: '徐州', value: 79 }, + { name: '衡水', value: 80 }, + { name: '包头', value: 80 }, + { name: '绵阳', value: 80 }, + { name: '乌鲁木齐', value: 84 }, + { name: '枣庄', value: 84 }, + { name: '杭州', value: 84 }, + { name: '淄博', value: 85 }, + { name: '鞍山', value: 86 }, + { name: '溧阳', value: 86 }, + { name: '库尔勒', value: 86 }, + { name: '安阳', value: 90 }, + { name: '开封', value: 90 }, + { name: '济南', value: 92 }, + { name: '德阳', value: 93 }, + { name: '温州', value: 95 }, + { name: '九江', value: 96 }, + { name: '邯郸', value: 98 }, + { name: '临安', value: 99 }, + { name: '兰州', value: 99 }, + { name: '沧州', value: 100 }, + { name: '临沂', value: 103 }, + { name: '南充', value: 104 }, + { name: '天津', value: 105 }, + { name: '富阳', value: 106 }, + { name: '泰安', value: 112 }, + { name: '诸暨', value: 112 }, + { name: '郑州', value: 113 }, + { name: '哈尔滨', value: 114 }, + { name: '聊城', value: 116 }, + { name: '芜湖', value: 117 }, + { name: '唐山', value: 119 }, + { name: '平顶山', value: 119 }, + { name: '邢台', value: 119 }, + { name: '德州', value: 120 }, + { name: '济宁', value: 120 }, + { name: '荆州', value: 127 }, + { name: '宜昌', value: 130 }, + { name: '义乌', value: 132 }, + { name: '丽水', value: 133 }, + { name: '洛阳', value: 134 }, + { name: '秦皇岛', value: 136 }, + { name: '株洲', value: 143 }, + { name: '石家庄', value: 147 }, + { name: '莱芜', value: 148 }, + { name: '常德', value: 152 }, + { name: '保定', value: 153 }, + { name: '湘潭', value: 154 }, + { name: '金华', value: 157 }, + { name: '岳阳', value: 169 }, + { name: '长沙', value: 175 }, + { name: '衢州', value: 177 }, + { name: '廊坊', value: 193 }, + { name: '菏泽', value: 194 }, + { name: '合肥', value: 229 }, + { name: '武汉', value: 273 }, + { name: '大庆', value: 279 } +]; +const geoCoordMap = { + 海门: [121.15, 31.89], + 鄂尔多斯: [109.781327, 39.608266], + 招远: [120.38, 37.35], + 舟山: [122.207216, 29.985295], + 齐齐哈尔: [123.97, 47.33], + 盐城: [120.13, 33.38], + 赤峰: [118.87, 42.28], + 青岛: [120.33, 36.07], + 乳山: [121.52, 36.89], + 金昌: [102.188043, 38.520089], + 泉州: [118.58, 24.93], + 莱西: [120.53, 36.86], + 日照: [119.46, 35.42], + 胶南: [119.97, 35.88], + 南通: [121.05, 32.08], + 拉萨: [91.11, 29.97], + 云浮: [112.02, 22.93], + 梅州: [116.1, 24.55], + 文登: [122.05, 37.2], + 上海: [121.48, 31.22], + 攀枝花: [101.718637, 26.582347], + 威海: [122.1, 37.5], + 承德: [117.93, 40.97], + 厦门: [118.1, 24.46], + 汕尾: [115.375279, 22.786211], + 潮州: [116.63, 23.68], + 丹东: [124.37, 40.13], + 太仓: [121.1, 31.45], + 曲靖: [103.79, 25.51], + 烟台: [121.39, 37.52], + 福州: [119.3, 26.08], + 瓦房店: [121.979603, 39.627114], + 即墨: [120.45, 36.38], + 抚顺: [123.97, 41.97], + 玉溪: [102.52, 24.35], + 张家口: [114.87, 40.82], + 阳泉: [113.57, 37.85], + 莱州: [119.942327, 37.177017], + 湖州: [120.1, 30.86], + 汕头: [116.69, 23.39], + 昆山: [120.95, 31.39], + 宁波: [121.56, 29.86], + 湛江: [110.359377, 21.270708], + 揭阳: [116.35, 23.55], + 荣成: [122.41, 37.16], + 连云港: [119.16, 34.59], + 葫芦岛: [120.836932, 40.711052], + 常熟: [120.74, 31.64], + 东莞: [113.75, 23.04], + 河源: [114.68, 23.73], + 淮安: [119.15, 33.5], + 泰州: [119.9, 32.49], + 南宁: [108.33, 22.84], + 营口: [122.18, 40.65], + 惠州: [114.4, 23.09], + 江阴: [120.26, 31.91], + 蓬莱: [120.75, 37.8], + 韶关: [113.62, 24.84], + 嘉峪关: [98.289152, 39.77313], + 广州: [113.23, 23.16], + 延安: [109.47, 36.6], + 太原: [112.53, 37.87], + 清远: [113.01, 23.7], + 中山: [113.38, 22.52], + 昆明: [102.73, 25.04], + 寿光: [118.73, 36.86], + 盘锦: [122.070714, 41.119997], + 长治: [113.08, 36.18], + 深圳: [114.07, 22.62], + 珠海: [113.52, 22.3], + 宿迁: [118.3, 33.96], + 咸阳: [108.72, 34.36], + 铜川: [109.11, 35.09], + 平度: [119.97, 36.77], + 佛山: [113.11, 23.05], + 海口: [110.35, 20.02], + 江门: [113.06, 22.61], + 章丘: [117.53, 36.72], + 肇庆: [112.44, 23.05], + 大连: [121.62, 38.92], + 临汾: [111.5, 36.08], + 吴江: [120.63, 31.16], + 石嘴山: [106.39, 39.04], + 沈阳: [123.38, 41.8], + 苏州: [120.62, 31.32], + 茂名: [110.88, 21.68], + 嘉兴: [120.76, 30.77], + 长春: [125.35, 43.88], + 胶州: [120.03336, 36.264622], + 银川: [106.27, 38.47], + 张家港: [120.555821, 31.875428], + 三门峡: [111.19, 34.76], + 锦州: [121.15, 41.13], + 南昌: [115.89, 28.68], + 柳州: [109.4, 24.33], + 三亚: [109.511909, 18.252847], + 自贡: [104.778442, 29.33903], + 吉林: [126.57, 43.87], + 阳江: [111.95, 21.85], + 泸州: [105.39, 28.91], + 西宁: [101.74, 36.56], + 宜宾: [104.56, 29.77], + 呼和浩特: [111.65, 40.82], + 成都: [104.06, 30.67], + 大同: [113.3, 40.12], + 镇江: [119.44, 32.2], + 桂林: [110.28, 25.29], + 张家界: [110.479191, 29.117096], + 宜兴: [119.82, 31.36], + 北海: [109.12, 21.49], + 西安: [108.95, 34.27], + 金坛: [119.56, 31.74], + 东营: [118.49, 37.46], + 牡丹江: [129.58, 44.6], + 遵义: [106.9, 27.7], + 绍兴: [120.58, 30.01], + 扬州: [119.42, 32.39], + 常州: [119.95, 31.79], + 潍坊: [119.1, 36.62], + 重庆: [106.54, 29.59], + 台州: [121.420757, 28.656386], + 南京: [118.78, 32.04], + 滨州: [118.03, 37.36], + 贵阳: [106.71, 26.57], + 无锡: [120.29, 31.59], + 本溪: [123.73, 41.3], + 克拉玛依: [84.77, 45.59], + 渭南: [109.5, 34.52], + 马鞍山: [118.48, 31.56], + 宝鸡: [107.15, 34.38], + 焦作: [113.21, 35.24], + 句容: [119.16, 31.95], + 北京: [116.46, 39.92], + 徐州: [117.2, 34.26], + 衡水: [115.72, 37.72], + 包头: [110, 40.58], + 绵阳: [104.73, 31.48], + 乌鲁木齐: [87.68, 43.77], + 枣庄: [117.57, 34.86], + 杭州: [120.19, 30.26], + 淄博: [118.05, 36.78], + 鞍山: [122.85, 41.12], + 溧阳: [119.48, 31.43], + 库尔勒: [86.06, 41.68], + 安阳: [114.35, 36.1], + 开封: [114.35, 34.79], + 济南: [117, 36.65], + 德阳: [104.37, 31.13], + 温州: [120.65, 28.01], + 九江: [115.97, 29.71], + 邯郸: [114.47, 36.6], + 临安: [119.72, 30.23], + 兰州: [103.73, 36.03], + 沧州: [116.83, 38.33], + 临沂: [118.35, 35.05], + 南充: [106.110698, 30.837793], + 天津: [117.2, 39.13], + 富阳: [119.95, 30.07], + 泰安: [117.13, 36.18], + 诸暨: [120.23, 29.71], + 郑州: [113.65, 34.76], + 哈尔滨: [126.63, 45.75], + 聊城: [115.97, 36.45], + 芜湖: [118.38, 31.33], + 唐山: [118.02, 39.63], + 平顶山: [113.29, 33.75], + 邢台: [114.48, 37.05], + 德州: [116.29, 37.45], + 济宁: [116.59, 35.38], + 荆州: [112.239741, 30.335165], + 宜昌: [111.3, 30.7], + 义乌: [120.06, 29.32], + 丽水: [119.92, 28.45], + 洛阳: [112.44, 34.7], + 秦皇岛: [119.57, 39.95], + 株洲: [113.16, 27.83], + 石家庄: [114.48, 38.03], + 莱芜: [117.67, 36.19], + 常德: [111.69, 29.05], + 保定: [115.48, 38.85], + 湘潭: [112.91, 27.87], + 金华: [119.64, 29.12], + 岳阳: [113.09, 29.37], + 长沙: [113, 28.21], + 衢州: [118.88, 28.97], + 廊坊: [116.7, 39.53], + 菏泽: [115.480656, 35.23375], + 合肥: [117.27, 31.86], + 武汉: [114.31, 30.52], + 大庆: [125.03, 46.58] +}; +var convertData = function (data) { + var res = []; + for (var i = 0; i < data.length; i++) { + var geoCoord = geoCoordMap[data[i].name]; + if (geoCoord) { + res.push({ + name: data[i].name, + value: geoCoord.concat(data[i].value) + }); + } + } + return res; +}; +option = { + backgroundColor: '#404a59', + title: { + text: '全国主要城市空气质量', + subtext: 'data from PM25.in', + sublink: 'http://www.pm25.in', + left: 'center', + textStyle: { + color: '#fff' + } + }, + tooltip: { + trigger: 'item' + }, + legend: { + orient: 'vertical', + top: 'bottom', + left: 'right', + data: ['pm2.5'], + textStyle: { + color: '#fff' + } + }, + geo: { + map: 'china', + roam: true, + label: { + show: false + }, + itemStyle: { + areaColor: '#323c48', + borderColor: '#111' + }, + emphasis: { + itemStyle: { + areaColor: '#2a333d' + } + } + }, + series: [ + { + name: 'pm2.5', + type: 'scatter', + coordinateSystem: 'geo', + data: convertData(data), + encode: { + value: 2 + }, + symbolSize: function (val) { + return val[2] / 10; + }, + label: { + formatter: '{b}', + position: 'right', + show: false + }, + itemStyle: { + color: '#ddb926' + }, + emphasis: { + label: { + show: true + } + } + }, + { + name: 'Top 5', + type: 'effectScatter', + coordinateSystem: 'geo', + data: convertData(data + .sort(function (a, b) { + return b.value - a.value; + }) + .slice(0, 6)), + encode: { + value: 2 + }, + symbolSize: function (val) { + return val[2] / 10; + }, + showEffectOn: 'render', + rippleEffect: { + brushType: 'stroke' + }, + emphasis: { + scale: true + }, + label: { + formatter: '{b}', + position: 'right', + show: true + }, + itemStyle: { + color: '#f4e925', + shadowBlur: 10, + shadowColor: '#333' + }, + zlevel: 1 + } + ] +}; +export {}; diff --git a/testdata/flame-graph.js b/testdata/flame-graph.js new file mode 100644 index 0000000..32a2ee3 --- /dev/null +++ b/testdata/flame-graph.js @@ -0,0 +1,202 @@ +/* +title: Flame graph +category: custom +titleCN: 火焰图 +difficulty: 4 +*/ +const ColorTypes = { + root: '#8fd3e8', + genunix: '#d95850', + unix: '#eb8146', + ufs: '#ffb248', + FSS: '#f2d643', + namefs: '#ebdba4', + doorfs: '#fcce10', + lofs: '#b5c334', + zfs: '#1bca93' +}; +const filterJson = (json, id) => { + if (id == null) { + return json; + } + const recur = (item, id) => { + if (item.id === id) { + return item; + } + for (const child of item.children || []) { + const temp = recur(child, id); + if (temp) { + item.children = [temp]; + item.value = temp.value; // change the parents' values + return item; + } + } + }; + return recur(json, id) || json; +}; +const recursionJson = (jsonObj, id) => { + const data = []; + const filteredJson = filterJson(structuredClone(jsonObj), id); + const rootVal = filteredJson.value; + const recur = (item, start = 0, level = 0) => { + const temp = { + name: item.id, + // [level, start_val, end_val, name, percentage] + value: [ + level, + start, + start + item.value, + item.name, + (item.value / rootVal) * 100 + ], + itemStyle: { + color: ColorTypes[item.name.split(' ')[0]] + } + }; + data.push(temp); + let prevStart = start; + for (const child of item.children || []) { + recur(child, prevStart, level + 1); + prevStart = prevStart + child.value; + } + }; + recur(filteredJson); + return data; +}; +const heightOfJson = (json) => { + const recur = (item, level = 0) => { + if ((item.children || []).length === 0) { + return level; + } + let maxLevel = level; + for (const child of item.children) { + const tempLevel = recur(child, level + 1); + maxLevel = Math.max(maxLevel, tempLevel); + } + return maxLevel; + }; + return recur(json); +}; +const renderItem = (params, api) => { + const level = api.value(0); + const start = api.coord([api.value(1), level]); + const end = api.coord([api.value(2), level]); + const height = ((api.size && api.size([0, 1])) || [0, 20])[1]; + const width = end[0] - start[0]; + return { + type: 'rect', + transition: ['shape'], + shape: { + x: start[0], + y: start[1] - height / 2, + width, + height: height - 2 /* itemGap */, + r: 2 + }, + style: { + fill: api.visual('color') + }, + emphasis: { + style: { + stroke: '#000' + } + }, + textConfig: { + position: 'insideLeft' + }, + textContent: { + style: { + text: api.value(3), + fontFamily: 'Verdana', + fill: '#000', + width: width - 4, + overflow: 'truncate', + ellipsis: '..', + truncateMinChar: 1 + }, + emphasis: { + style: { + stroke: '#000', + lineWidth: 0.5 + } + } + } + }; +}; +myChart.showLoading(); +$.get(ROOT_PATH + '/data/asset/data/stack-trace.json', (stackTrace) => { + myChart.hideLoading(); + const levelOfOriginalJson = heightOfJson(stackTrace); + option = { + backgroundColor: { + type: 'linear', + x: 0, + y: 0, + x2: 0, + y2: 1, + colorStops: [ + { + offset: 0.05, + color: '#eee' + }, + { + offset: 0.95, + color: '#eeeeb0' + } + ] + }, + tooltip: { + formatter: (params) => { + const samples = params.value[2] - params.value[1]; + return `${params.marker} ${params.value[3]}: (${echarts.format.addCommas(samples)} samples, ${+params.value[4].toFixed(2)}%)`; + } + }, + title: [ + { + text: 'Flame Graph', + left: 'center', + top: 10, + textStyle: { + fontFamily: 'Verdana', + fontWeight: 'normal', + fontSize: 20 + } + } + ], + toolbox: { + feature: { + restore: {} + }, + right: 20, + top: 10 + }, + xAxis: { + show: false + }, + yAxis: { + show: false, + max: levelOfOriginalJson + }, + series: [ + { + type: 'custom', + renderItem, + encode: { + x: [0, 1, 2], + y: 0 + }, + data: recursionJson(stackTrace) + } + ] + }; + myChart.setOption(option); + myChart.on('click', (params) => { + const data = recursionJson(stackTrace, params.data.name); + const rootValue = data[0].value[2]; + myChart.setOption({ + xAxis: { max: rootValue }, + series: [{ data }] + }); + }); +}); +export {}; diff --git a/testdata/funnel-align.js b/testdata/funnel-align.js new file mode 100644 index 0000000..bcbacde --- /dev/null +++ b/testdata/funnel-align.js @@ -0,0 +1,101 @@ +/* +title: Funnel Compare +category: funnel +titleCN: 漏斗图(对比) +*/ +option = { + title: { + text: 'Funnel Compare', + subtext: 'Fake Data', + left: 'left', + top: 'bottom' + }, + tooltip: { + trigger: 'item', + formatter: '{a}
{b} : {c}%' + }, + toolbox: { + show: true, + orient: 'vertical', + top: 'center', + feature: { + dataView: { readOnly: false }, + restore: {}, + saveAsImage: {} + } + }, + legend: { + orient: 'vertical', + left: 'left', + data: ['Prod A', 'Prod B', 'Prod C', 'Prod D', 'Prod E'] + }, + series: [ + { + name: 'Funnel', + type: 'funnel', + width: '40%', + height: '45%', + left: '5%', + top: '50%', + funnelAlign: 'right', + data: [ + { value: 60, name: 'Prod C' }, + { value: 30, name: 'Prod D' }, + { value: 10, name: 'Prod E' }, + { value: 80, name: 'Prod B' }, + { value: 100, name: 'Prod A' } + ] + }, + { + name: 'Pyramid', + type: 'funnel', + width: '40%', + height: '45%', + left: '5%', + top: '5%', + sort: 'ascending', + funnelAlign: 'right', + data: [ + { value: 60, name: 'Prod C' }, + { value: 30, name: 'Prod D' }, + { value: 10, name: 'Prod E' }, + { value: 80, name: 'Prod B' }, + { value: 100, name: 'Prod A' } + ] + }, + { + name: 'Funnel', + type: 'funnel', + width: '40%', + height: '45%', + left: '55%', + top: '5%', + funnelAlign: 'left', + data: [ + { value: 60, name: 'Prod C' }, + { value: 30, name: 'Prod D' }, + { value: 10, name: 'Prod E' }, + { value: 80, name: 'Prod B' }, + { value: 100, name: 'Prod A' } + ] + }, + { + name: 'Pyramid', + type: 'funnel', + width: '40%', + height: '45%', + left: '55%', + top: '50%', + sort: 'ascending', + funnelAlign: 'left', + data: [ + { value: 60, name: 'Prod C' }, + { value: 30, name: 'Prod D' }, + { value: 10, name: 'Prod E' }, + { value: 80, name: 'Prod B' }, + { value: 100, name: 'Prod A' } + ] + } + ] +}; +export {}; diff --git a/testdata/funnel-align.js.svg b/testdata/funnel-align.js.svg new file mode 100644 index 0000000..55c72f0 --- /dev/null +++ b/testdata/funnel-align.js.svg @@ -0,0 +1,305 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Prod C +Prod D +Prod E +Prod B +Prod A +Prod C +Prod D +Prod E +Prod B +Prod A +Prod C +Prod D +Prod E +Prod B +Prod A +Prod C +Prod D +Prod E +Prod B +Prod A + + +Prod A + +Prod B + +Prod C + +Prod D + +Prod E + + + + + +Funnel Compare +Fake Data + + \ No newline at end of file diff --git a/testdata/funnel-customize.js b/testdata/funnel-customize.js new file mode 100644 index 0000000..02ed0d3 --- /dev/null +++ b/testdata/funnel-customize.js @@ -0,0 +1,87 @@ +/* +title: Customized Funnel +category: funnel +titleCN: 漏斗图 +*/ +option = { + title: { + text: 'Funnel' + }, + tooltip: { + trigger: 'item', + formatter: '{a}
{b} : {c}%' + }, + toolbox: { + feature: { + dataView: { readOnly: false }, + restore: {}, + saveAsImage: {} + } + }, + legend: { + data: ['Show', 'Click', 'Visit', 'Inquiry', 'Order'] + }, + series: [ + { + name: 'Expected', + type: 'funnel', + left: '10%', + width: '80%', + label: { + formatter: '{b}Expected' + }, + labelLine: { + show: false + }, + itemStyle: { + opacity: 0.7 + }, + emphasis: { + label: { + position: 'inside', + formatter: '{b}Expected: {c}%' + } + }, + data: [ + { value: 60, name: 'Visit' }, + { value: 40, name: 'Inquiry' }, + { value: 20, name: 'Order' }, + { value: 80, name: 'Click' }, + { value: 100, name: 'Show' } + ] + }, + { + name: 'Actual', + type: 'funnel', + left: '10%', + width: '80%', + maxSize: '80%', + label: { + position: 'inside', + formatter: '{c}%', + color: '#fff' + }, + itemStyle: { + opacity: 0.5, + borderColor: '#fff', + borderWidth: 2 + }, + emphasis: { + label: { + position: 'inside', + formatter: '{b}Actual: {c}%' + } + }, + data: [ + { value: 30, name: 'Visit' }, + { value: 10, name: 'Inquiry' }, + { value: 5, name: 'Order' }, + { value: 50, name: 'Click' }, + { value: 80, name: 'Show' } + ], + // Ensure outer shape will not be over inner shape when hover. + z: 100 + } + ] +}; +export {}; diff --git a/testdata/funnel-customize.js.svg b/testdata/funnel-customize.js.svg new file mode 100644 index 0000000..f33181d --- /dev/null +++ b/testdata/funnel-customize.js.svg @@ -0,0 +1,159 @@ + + + + + + + +VisitExpected +InquiryExpected +OrderExpected +ClickExpected +ShowExpected + + +Show + +Click + +Visit + +Inquiry + +Order + + + + + +Funnel + + + + + + + + + + +30% +10% +5% +50% +80% + + \ No newline at end of file diff --git a/testdata/funnel-mutiple.js b/testdata/funnel-mutiple.js new file mode 100644 index 0000000..8c4f759 --- /dev/null +++ b/testdata/funnel-mutiple.js @@ -0,0 +1,101 @@ +/* +title: Multiple Funnels +category: funnel +titleCN: Funnel +*/ +option = { + title: { + text: 'Funnel', + left: 'left', + top: 'bottom' + }, + tooltip: { + trigger: 'item', + formatter: '{a}
{b} : {c}%' + }, + toolbox: { + orient: 'vertical', + top: 'center', + feature: { + dataView: { readOnly: false }, + restore: {}, + saveAsImage: {} + } + }, + legend: { + orient: 'vertical', + left: 'left', + data: ['Show', 'Click', 'Visit', 'Inquiry', 'Order'] + }, + series: [ + { + name: 'Funnel', + type: 'funnel', + width: '40%', + height: '45%', + left: '5%', + top: '50%', + data: [ + { value: 60, name: 'Visit' }, + { value: 30, name: 'Inquiry' }, + { value: 10, name: 'Order' }, + { value: 80, name: 'Click' }, + { value: 100, name: 'Show' } + ] + }, + { + name: 'Pyramid', + type: 'funnel', + width: '40%', + height: '45%', + left: '5%', + top: '5%', + sort: 'ascending', + data: [ + { value: 60, name: 'Visit' }, + { value: 30, name: 'Inquiry' }, + { value: 10, name: 'Order' }, + { value: 80, name: 'Click' }, + { value: 100, name: 'Show' } + ] + }, + { + name: 'Funnel', + type: 'funnel', + width: '40%', + height: '45%', + left: '55%', + top: '5%', + label: { + position: 'left' + }, + data: [ + { value: 60, name: 'Visit' }, + { value: 30, name: 'Inquiry' }, + { value: 10, name: 'Order' }, + { value: 80, name: 'Click' }, + { value: 100, name: 'Show' } + ] + }, + { + name: 'Pyramid', + type: 'funnel', + width: '40%', + height: '45%', + left: '55%', + top: '50%', + sort: 'ascending', + label: { + position: 'left' + }, + data: [ + { value: 60, name: 'Visit' }, + { value: 30, name: 'Inquiry' }, + { value: 10, name: 'Order' }, + { value: 80, name: 'Click' }, + { value: 100, name: 'Show' } + ] + } + ] +}; +export {}; diff --git a/testdata/funnel-mutiple.js.svg b/testdata/funnel-mutiple.js.svg new file mode 100644 index 0000000..c229465 --- /dev/null +++ b/testdata/funnel-mutiple.js.svg @@ -0,0 +1,304 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Visit +Inquiry +Order +Click +Show +Visit +Inquiry +Order +Click +Show +Visit +Inquiry +Order +Click +Show +Visit +Inquiry +Order +Click +Show + + +Show + +Click + +Visit + +Inquiry + +Order + + + + + +Funnel + + \ No newline at end of file diff --git a/testdata/funnel.js b/testdata/funnel.js new file mode 100644 index 0000000..cfe0efd --- /dev/null +++ b/testdata/funnel.js @@ -0,0 +1,68 @@ +"use strict"; +/* +title: Funnel Chart +category: funnel +titleCN: 漏斗图 +*/ +option = { + title: { + text: 'Funnel' + }, + tooltip: { + trigger: 'item', + formatter: '{a}
{b} : {c}%' + }, + toolbox: { + feature: { + dataView: { readOnly: false }, + restore: {}, + saveAsImage: {} + } + }, + legend: { + data: ['Show', 'Click', 'Visit', 'Inquiry', 'Order'] + }, + series: [ + { + name: 'Funnel', + type: 'funnel', + left: '10%', + top: 60, + bottom: 60, + width: '80%', + min: 0, + max: 100, + minSize: '0%', + maxSize: '100%', + sort: 'descending', + gap: 2, + label: { + show: true, + position: 'inside' + }, + labelLine: { + length: 10, + lineStyle: { + width: 1, + type: 'solid' + } + }, + itemStyle: { + borderColor: '#fff', + borderWidth: 1 + }, + emphasis: { + label: { + fontSize: 20 + } + }, + data: [ + { value: 60, name: 'Visit' }, + { value: 40, name: 'Inquiry' }, + { value: 20, name: 'Order' }, + { value: 80, name: 'Click' }, + { value: 100, name: 'Show' } + ] + } + ] +}; diff --git a/testdata/funnel.js.svg b/testdata/funnel.js.svg new file mode 100644 index 0000000..f399bbf --- /dev/null +++ b/testdata/funnel.js.svg @@ -0,0 +1,94 @@ + + + + + + + + + + + + +Visit +Inquiry +Order +Click +Show + + +Show + +Click + +Visit + +Inquiry + +Order + + + + + +Funnel + + \ No newline at end of file diff --git a/testdata/gauge-barometer.js b/testdata/gauge-barometer.js new file mode 100644 index 0000000..d8ae163 --- /dev/null +++ b/testdata/gauge-barometer.js @@ -0,0 +1,131 @@ +/* +title: Gauge Barometer chart +titleCN: 气压表 +category: gauge +difficulty: 6 +*/ +option = { + series: [ + { + type: 'gauge', + min: 0, + max: 100, + splitNumber: 10, + radius: '80%', + axisLine: { + lineStyle: { + color: [[1, '#f00']], + width: 3 + } + }, + splitLine: { + distance: -18, + length: 18, + lineStyle: { + color: '#f00' + } + }, + axisTick: { + distance: -12, + length: 10, + lineStyle: { + color: '#f00' + } + }, + axisLabel: { + distance: -50, + color: '#f00', + fontSize: 25 + }, + anchor: { + show: true, + size: 20, + itemStyle: { + borderColor: '#000', + borderWidth: 2 + } + }, + pointer: { + offsetCenter: [0, '10%'], + icon: 'path://M2090.36389,615.30999 L2090.36389,615.30999 C2091.48372,615.30999 2092.40383,616.194028 2092.44859,617.312956 L2096.90698,728.755929 C2097.05155,732.369577 2094.2393,735.416212 2090.62566,735.56078 C2090.53845,735.564269 2090.45117,735.566014 2090.36389,735.566014 L2090.36389,735.566014 C2086.74736,735.566014 2083.81557,732.63423 2083.81557,729.017692 C2083.81557,728.930412 2083.81732,728.84314 2083.82081,728.755929 L2088.2792,617.312956 C2088.32396,616.194028 2089.24407,615.30999 2090.36389,615.30999 Z', + length: '115%', + itemStyle: { + color: '#000' + } + }, + detail: { + valueAnimation: true, + precision: 1 + }, + title: { + offsetCenter: [0, '-50%'] + }, + data: [ + { + value: 58.46, + name: 'PLP' + } + ] + }, + { + type: 'gauge', + min: 0, + max: 60, + splitNumber: 6, + axisLine: { + lineStyle: { + color: [[1, '#000']], + width: 3 + } + }, + splitLine: { + distance: -3, + length: 18, + lineStyle: { + color: '#000' + } + }, + axisTick: { + distance: 0, + length: 10, + lineStyle: { + color: '#000' + } + }, + axisLabel: { + distance: 10, + fontSize: 25, + color: '#000' + }, + pointer: { + show: false + }, + title: { + show: false + }, + anchor: { + show: true, + size: 14, + itemStyle: { + color: '#000' + } + } + } + ] +}; +setInterval(function () { + myChart.setOption({ + series: [ + { + type: 'gauge', + data: [ + { + value: +(Math.random() * 100).toFixed(2), + name: 'PLP' + } + ] + } + ] + }); +}, 2000); +export {}; diff --git a/testdata/gauge-barometer.js.svg b/testdata/gauge-barometer.js.svg new file mode 100644 index 0000000..d1fb8b6 --- /dev/null +++ b/testdata/gauge-barometer.js.svg @@ -0,0 +1,158 @@ + + + + +0 + + + + + + + +10 + + + + + + + +20 + + + + + + + +30 + + + + + + + +40 + + + + + + + +50 + + + + + + + +60 + + + + + + + +70 + + + + + + + +80 + + + + + + + +90 + + + + + + + +100 +PLP + +58.46 + + + + +0 + + + + + + + +10 + + + + + + + +20 + + + + + + + +30 + + + + + + + +40 + + + + + + + +50 + + + + + + + +60 + + + \ No newline at end of file diff --git a/testdata/gauge-car.js b/testdata/gauge-car.js new file mode 100644 index 0000000..97814d4 --- /dev/null +++ b/testdata/gauge-car.js @@ -0,0 +1,519 @@ +/* +title: Gauge Car +category: gauge +titleCN: Gauge Car +difficulty: 8 +*/ +option = { + backgroundColor: '#000', + tooltip: { + formatter: '{a}
{b} : {c}%' + }, + toolbox: { + feature: { + restore: {}, + saveAsImage: {} + } + }, + series: [ + // left + { + name: 'gauge 0', + type: 'gauge', + min: -200, + max: 250, + startAngle: -30, + endAngle: -315, + splitNumber: 9, + radius: '35%', + center: ['21%', '55%'], + axisLine: { + lineStyle: { + color: [[1, '#AE96A6']] + } + }, + splitLine: { + show: false + }, + axisTick: { + show: false + }, + axisLabel: { + show: false + }, + anchor: {}, + pointer: { + show: false + }, + detail: { + show: false + }, + title: { + fontSize: 12, + fontWeight: 800, + fontFamily: 'Arial', + color: '#fff', + offsetCenter: [0, '-60%'] + }, + progress: { + show: true, + width: 3, + itemStyle: { + color: '#fff' + } + }, + data: [ + { + value: 250, + name: 'km/h' + } + ] + }, + { + name: 'gauge 1', + type: 'gauge', + min: 0, + max: 250, + startAngle: -140, + endAngle: -305, + splitNumber: 5, + radius: '35%', + center: ['21%', '55%'], + axisLine: { + lineStyle: { + color: [[1, '#AE96A6']] + } + }, + splitLine: { + distance: -7, + length: 12, + lineStyle: { + color: '#fff', + width: 4 + } + }, + axisTick: { + distance: -8, + length: 8, + lineStyle: { + color: '#fff', + width: 2 + } + }, + axisLabel: { + distance: 14, + fontSize: 18, + fontWeight: 800, + fontFamily: 'Arial', + color: '#fff' + }, + anchor: {}, + pointer: { + icon: 'path://M-36.5,23.9L-41,4.4c-0.1-0.4-0.4-0.7-0.7-0.7c-0.5-0.1-1.1,0.2-1.2,0.7l-4.5,19.5c0,0.1,0,0.1,0,0.2v92.3c0,0.6,0.4,1,1,1h9c0.6,0,1-0.4,1-1V24.1C-36.5,24-36.5,23.9-36.5,23.9z M-39.5,114.6h-5v-85h5V114.6z', + width: 5, + length: '40%', + offsetCenter: [0, '-58%'], + itemStyle: { + color: '#f00', + shadowColor: 'rgba(255, 0, 0)', + shadowBlur: 5, + shadowOffsetY: 2 + } + }, + title: { + color: '#fff', + fontSize: 14, + fontWeight: 800, + fontFamily: 'Arial', + offsetCenter: [0, 0] + }, + detail: { + show: false + }, + data: [ + { + value: 0, + name: '当前位置:\n \n 中科路' + } + ] + }, + // middle + { + name: 'gauge 2', + type: 'gauge', + min: 0, + max: 8, + z: 10, + startAngle: 210, + endAngle: -30, + splitNumber: 8, + radius: '50%', + center: ['50%', '50%'], + axisLine: { + show: true, + lineStyle: { + width: 0, + color: [ + [0.825, '#fff'], + [1, '#f00'] + ] + } + }, + splitLine: { + distance: 20, + length: 15, + lineStyle: { + color: 'auto', + width: 4, + shadowColor: 'rgba(255, 255, 255, 0.5)', + shadowBlur: 15, + shadowOffsetY: -10 + } + }, + axisTick: { + distance: 20, + length: 8, + lineStyle: { + color: 'auto', + width: 2, + shadowColor: 'rgba(255, 255, 255)', + shadowBlur: 10, + shadowOffsetY: -10 + } + }, + axisLabel: { + distance: 10, + fontSize: 35, + fontWeight: 800, + fontFamily: 'Arial', + color: '#fff' + }, + anchor: {}, + pointer: { + icon: 'path://M-36.5,23.9L-41,4.4c-0.1-0.4-0.4-0.7-0.7-0.7c-0.5-0.1-1.1,0.2-1.2,0.7l-4.5,19.5c0,0.1,0,0.1,0,0.2v92.3c0,0.6,0.4,1,1,1h9c0.6,0,1-0.4,1-1V24.1C-36.5,24-36.5,23.9-36.5,23.9z M-39.5,114.6h-5v-85h5V114.6z', + width: 10, + offsetCenter: [0, '-10%'], + length: '75%', + itemStyle: { + color: '#f00', + shadowColor: 'rgba(255, 0, 0)', + shadowBlur: 5, + shadowOffsetY: 3 + } + }, + title: { + color: '#fff', + fontSize: 12, + fontWeight: 800, + fontFamily: 'Arial', + offsetCenter: [0, '-50%'] + }, + data: [ + { + value: 0.6, + name: '1/min x 1000' + } + ], + detail: { + show: false + } + }, + { + name: 'gauge 3', + type: 'gauge', + min: 0, + max: 8, + z: 10, + splitNumber: 8, + radius: '50%', + axisLine: { + lineStyle: { + width: 14, + color: [[1, '#000']] + } + }, + splitLine: { + show: false + }, + axisTick: { + show: false + }, + axisLabel: { + show: false + }, + anchor: {}, + pointer: { + show: false + }, + title: { + show: false + }, + detail: { + offsetCenter: ['25%', '50%'], + formatter: '{a|{value}}{b|km/h}', + rich: { + a: { + fontSize: 60, + fontWeight: 800, + fontFamily: 'Arial', + color: '#fff', + align: 'center', + padding: [0, 5, 0, 0] + }, + b: { + fontSize: 14, + fontWeight: 800, + fontFamily: 'Arial', + color: '#fff', + padding: [0, 0, 20, 0] + } + } + }, + // value is speed + data: [ + { + value: 0, + name: '' + } + ] + }, + // right + { + name: 'gauge 4', + type: 'gauge', + min: 0, + max: 8, + startAngle: 135, + endAngle: -150, + splitNumber: 8, + radius: '35%', + center: ['79%', '55%'], + axisLine: { + lineStyle: { + color: [[1, '#AE96A6']] + } + }, + splitLine: { + show: false + }, + axisTick: { + show: false + }, + axisLabel: { + show: false + }, + anchor: {}, + pointer: { + show: false + }, + title: {}, + detail: { + offsetCenter: ['-15%', 0], + formatter: [ + '{a| 00:00}', + '{a|行驶时间 0:00}{b| h}', + '{a|行驶距离 0.0}{b| km}', + '{a|平均耗能 ---}{b| 1/100km}', + '{a|平均速度 ---}{b| km/h}' + ].join('\n'), + rich: { + a: { + fontSize: 14, + fontWeight: 800, + fontFamily: 'Arial', + lineHeight: 22, + color: '#fff', + align: 'left' + }, + b: { + fontWeight: 600, + fontFamily: 'Arial', + lineHeight: 22, + color: '#fff', + align: 'left' + } + } + }, + progress: { + show: true, + width: 3, + itemStyle: { + color: '#fff' + } + }, + data: [ + { + value: 250, + name: '' + } + ] + }, + { + name: 'gauge 5', + type: 'gauge', + min: 0, + max: 1, + startAngle: 125, + endAngle: 55, + splitNumber: 2, + radius: '34%', + center: ['79%', '55.3%'], + axisLine: { + lineStyle: { + width: 9, + color: [ + [0.15, '#f00'], + [1, 'rgba(255, 0, 0, 0)'] + ] + } + }, + splitLine: { + distance: -14, + length: 16, + lineStyle: { + color: '#fff', + width: 4 + } + }, + axisTick: { + distance: -14, + length: 10, + lineStyle: { + color: '#fff', + width: 2 + } + }, + axisLabel: { + distance: 12, + fontSize: 18, + fontWeight: 800, + fontFamily: 'Arial', + color: '#fff', + formatter: function (value) { + if (value === 0.5) { + return '2/4'; + } + if (value === 1) { + return '4/4'; + } + return value + ''; + } + }, + progress: { + show: true, + width: 5, + itemStyle: { + color: '#fff' + } + }, + anchor: { + show: true, + itemStyle: {}, + offsetCenter: ['-22%', '-57%'], + size: 18, + icon: 'path://M1.11979167,1.11111112 C1.11979167,0.497461393 1.61725306,0 2.23090279,0 L12.2309028,0 C12.8445525,1.43824153e-08 13.3420139,0.497461403 13.3420139,1.11111112 L13.3420139,10 L15.5642361,10 C16.7915356,10 17.7864583,10.9949228 17.7864583,12.2222222 L17.7864583,16.6666667 C17.7865523,17.28025 18.2839861,17.7776077 18.8975694,17.7776077 C19.5111527,17.7776077 20.0085866,17.28025 20.0086805,16.6666667 L20.0086805,8.88888888 L17.7864583,8.88888888 C17.1728086,8.88888888 16.6753472,8.3914275 16.6753472,7.77777779 L16.6753472,3.79333333 L15.6197917,2.73777777 C15.1859413,2.30392741 15.1859413,1.60051702 15.6197917,1.16666667 L15.6197917,1.16666667 C16.053642,0.732816318 16.7570524,0.732816318 17.1909028,1.16666667 L21.9053472,5.88111112 C22.1140468,6.08922811 22.2312072,6.37193273 22.2309028,6.66666667 L22.2309028,16.6666667 C22.2309028,18.5076158 20.7385186,20 18.8975695,20 C17.0566203,20 15.5642361,18.5076158 15.5642361,16.6666667 L15.5642361,12.2222222 L13.3420139,12.2222222 L13.3420139,17.7777778 L13.3420139,17.7777778 C13.9556636,17.7777778 14.453125,18.2752392 14.453125,18.8888889 L14.453125,18.8888889 C14.453125,19.5025386 13.9556636,20 13.3420139,20 L1.11979165,20 C0.506141934,20 0.00868054688,19.5025386 0.00868054687,18.8888889 L0.00868054687,18.8888889 C0.00868054688,18.2752392 0.506141934,17.7777778 1.11979165,17.7777778 L1.11979167,17.7777778 L1.11979167,1.11111112 Z M3.34201388,2.22222221 L3.34201388,8.88888888 L11.1197917,8.88888888 L11.1197917,2.22222221 L3.34201388,2.22222221 Z' + }, + pointer: { + show: false + }, + title: {}, + detail: { + offsetCenter: ['10%', '-56%'], + formatter: '{a|831}{b| km}', + rich: { + a: { + fontSize: 15, + fontWeight: 800, + fontFamily: 'Arial', + color: '#fff' + }, + b: { + fontWeight: 600, + fontFamily: 'Arial', + color: '#fff' + } + } + }, + data: [ + { + value: 0.85, + name: '' + } + ] + }, + { + name: 'gauge 6', + type: 'gauge', + min: -120, + max: -60, + startAngle: 230, + endAngle: 310, + clockwise: false, + splitNumber: 2, + radius: '35%', + center: ['79%', '55%'], + axisLine: { + lineStyle: { + color: [ + [1, '#AE96A6'], + [1.1, '#f00'] + ] + } + }, + splitLine: { + distance: -8, + length: 12, + lineStyle: { + color: '#fff', + width: 4 + } + }, + axisTick: { + splitNumber: 3, + length: 8, + distance: -8, + lineStyle: { + color: '#fff', + width: 2 + } + }, + axisLabel: { + distance: 14, + fontSize: 18, + fontWeight: 800, + fontFamily: 'Arial', + color: '#fff', + formatter: function (value) { + return -value + ''; + } + }, + anchor: { + show: true, + itemStyle: {}, + offsetCenter: [0, '55%'], + size: 20, + icon: 'path://M-34.1-1.1L-34.1-1.1c0-0.3-0.3-0.6-0.6-0.6h-3.6v-1.5c0-0.5-0.2-0.9-0.6-1.1s-0.9-0.2-1.3,0c-0.4,0.2-0.6,0.7-0.6,1.1V7.9c0,0,0,0.1,0,0.1c-0.8,0.5-1.2,1.5-0.9,2.5c0.3,0.9,1.1,1.6,2.1,1.6c1,0,1.8-0.6,2.1-1.5c0.3-0.9,0-1.9-0.8-2.5V6.3h3.5c0.4,0,0.7-0.3,0.7-0.7l0,0c0-0.4-0.3-0.7-0.7-0.7h-3.5V2.9h3.5c0.4,0,0.7-0.3,0.7-0.7l0,0c0-0.4-0.3-0.7-0.7-0.7h-3.5v-2.1h3.6C-34.4-0.5-34.1-0.8-34.1-1.1z M-44.9,11.6c-0.7,0-1.4-0.2-2-0.6c-0.4-0.3-0.9-0.4-1.4-0.4c-0.4,0-0.9,0.2-1.2,0.4c-0.4,0.2-1.4-0.9-0.9-1.3c0.6-0.4,1.3-0.6,2-0.7c0.8,0,1.5,0.2,2.2,0.5c0.4,0.3,0.9,0.4,1.3,0.4c0.6,0,1.1-0.2,1.5-0.6s1.6,0.7,0.9,1.3S-44,11.6-44.9,11.6L-44.9,11.6z M-34.3,11.6c-0.7,0-1.4-0.3-2-0.7c-0.6-0.4,0.5-1.6,0.9-1.3s0.8,0.4,1.2,0.4c0.5,0,1-0.1,1.4-0.4c0.6-0.3,1.3-0.5,2-0.6h0c0.9,0,1.7,0.3,2.4,0.9c0.7,0.5-0.5,1.6-0.9,1.3c-0.4-0.3-1-0.6-1.5-0.6h0c-0.5,0-0.9,0.2-1.3,0.4c-0.6,0.3-1.3,0.5-2,0.6H-34.3z M-33.5,16.3c-0.7,0-1.4-0.3-1.9-0.8c-0.4-0.3-0.6-0.5-1-0.5c-0.4,0-0.7,0.2-1,0.4c-0.6,0.5-1.3,0.7-2,0.7c-0.7,0-1.4-0.3-1.9-0.8c-0.2-0.3-0.6-0.4-0.9-0.4c-0.4,0-0.7,0.1-1.1,0.5c-0.6,0.5-1.3,0.7-2.1,0.7c-0.7-0.1-1.4-0.4-1.9-0.9c-0.4-0.3-0.6-0.5-1-0.5c-0.3,0-0.6,0.2-0.9,0.4s-1.6-0.7-1.1-1.2c0.5-0.5,1.2-0.8,1.9-0.9c1-0.1,1.6,0.4,2.1,0.8c0.3,0.3,0.6,0.5,1,0.5c0.4,0,0.6-0.1,1-0.4c0.6-0.5,1.4-0.8,2.1-0.8c0.7,0,1.4,0.3,1.9,0.8c0.2,0.2,0.6,0.4,0.9,0.4c0.4,0,0.6-0.1,1-0.4c0.6-0.5,1.3-0.7,2-0.7c0.8,0,1.5,0.3,2,0.9c0.4,0.3,0.6,0.4,0.9,0.4c0.3,0,0.7-0.2,1.1-0.5c0.5-0.4,1.2-0.9,2.3-0.8c0.7,0,1.4,0.3,1.9,0.7c0.5,0.4-0.7,1.5-1,1.3s-0.6-0.4-1-0.4c-0.4,0-0.7,0.2-1.2,0.5C-32,15.9-32.7,16.2-33.5,16.3L-33.5,16.3z' + }, + pointer: { + icon: 'path://M2.9,0.7L2.9,0.7c1.4,0,2.6,1.2,2.6,2.6v115c0,1.4-1.2,2.6-2.6,2.6l0,0c-1.4,0-2.6-1.2-2.6-2.6V3.3C0.3,1.9,1.4,0.7,2.9,0.7z', + width: 15, + length: '4', + offsetCenter: [0, '-90%'], + itemStyle: { + color: '#f00' + } + }, + title: {}, + detail: { + show: false + }, + data: [ + { + value: -120, + name: '' + } + ] + } + ] +}; +export {}; diff --git a/testdata/gauge-car.js.svg b/testdata/gauge-car.js.svg new file mode 100644 index 0000000..e0f2dab --- /dev/null +++ b/testdata/gauge-car.js.svg @@ -0,0 +1,223 @@ + + + +km/h + + +0 + + + + + + + +50 + + + + + + + +100 + + + + + + + +150 + + + + + + + +200 + + + + + + + +250 +当前位置: + + 中科路 + + + + + 00:00 + +行驶时间 0:00 + + h + +行驶距离 0.0 + + km + +平均耗能 --- + + 1/100km + +平均速度 --- + + km/h + + + +0 + + + + + + + +0.5 + + + + + + + +1 + +831 + km + + + + +-120 + + + + + +-90 + + + + + +-60 + + + + + + + + + + + +0 + + + + + + + +1 + + + + + + + +2 + + + + + + + +3 + + + + + + + +4 + + + + + + + +5 + + + + + + + +6 + + + + + + + +7 + + + + + + + +8 +1/min x 1000 + + + +0 +km/h + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/gauge-clock.js b/testdata/gauge-clock.js new file mode 100644 index 0000000..0a64fcf --- /dev/null +++ b/testdata/gauge-clock.js @@ -0,0 +1,227 @@ +/* +title: Clock +titleCN: 时钟仪表盘 +category: gauge +shotWidth: 1000 +difficulty: 7 +videoStart: 2000 +videoEnd: 8000 +*/ +option = { + series: [ + { + name: 'hour', + type: 'gauge', + startAngle: 90, + endAngle: -270, + min: 0, + max: 12, + splitNumber: 12, + clockwise: true, + axisLine: { + lineStyle: { + width: 15, + color: [[1, 'rgba(0,0,0,0.7)']], + shadowColor: 'rgba(0, 0, 0, 0.5)', + shadowBlur: 15 + } + }, + splitLine: { + lineStyle: { + shadowColor: 'rgba(0, 0, 0, 0.3)', + shadowBlur: 3, + shadowOffsetX: 1, + shadowOffsetY: 2 + } + }, + axisLabel: { + fontSize: 50, + distance: 25, + formatter: function (value) { + if (value === 0) { + return ''; + } + return value + ''; + } + }, + anchor: { + show: true, + icon: 'path://M532.8,70.8C532.8,70.8,532.8,70.8,532.8,70.8L532.8,70.8C532.7,70.8,532.8,70.8,532.8,70.8z M456.1,49.6c-2.2-6.2-8.1-10.6-15-10.6h-37.5v10.6h37.5l0,0c2.9,0,5.3,2.4,5.3,5.3c0,2.9-2.4,5.3-5.3,5.3v0h-22.5c-1.5,0.1-3,0.4-4.3,0.9c-4.5,1.6-8.1,5.2-9.7,9.8c-0.6,1.7-0.9,3.4-0.9,5.3v16h10.6v-16l0,0l0,0c0-2.7,2.1-5,4.7-5.3h10.3l10.4,21.2h11.8l-10.4-21.2h0c6.9,0,12.8-4.4,15-10.6c0.6-1.7,0.9-3.5,0.9-5.3C457,53,456.7,51.2,456.1,49.6z M388.9,92.1h11.3L381,39h-3.6h-11.3L346.8,92v0h11.3l3.9-10.7h7.3h7.7l3.9-10.6h-7.7h-7.3l7.7-21.2v0L388.9,92.1z M301,38.9h-10.6v53.1H301V70.8h28.4l3.7-10.6H301V38.9zM333.2,38.9v10.6v10.7v31.9h10.6V38.9H333.2z M249.5,81.4L249.5,81.4L249.5,81.4c-2.9,0-5.3-2.4-5.3-5.3h0V54.9h0l0,0c0-2.9,2.4-5.3,5.3-5.3l0,0l0,0h33.6l3.9-10.6h-37.5c-1.9,0-3.6,0.3-5.3,0.9c-4.5,1.6-8.1,5.2-9.7,9.7c-0.6,1.7-0.9,3.5-0.9,5.3l0,0v21.3c0,1.9,0.3,3.6,0.9,5.3c1.6,4.5,5.2,8.1,9.7,9.7c1.7,0.6,3.5,0.9,5.3,0.9h33.6l3.9-10.6H249.5z M176.8,38.9v10.6h49.6l3.9-10.6H176.8z M192.7,81.4L192.7,81.4L192.7,81.4c-2.9,0-5.3-2.4-5.3-5.3l0,0v-5.3h38.9l3.9-10.6h-53.4v10.6v5.3l0,0c0,1.9,0.3,3.6,0.9,5.3c1.6,4.5,5.2,8.1,9.7,9.7c1.7,0.6,3.4,0.9,5.3,0.9h23.4h10.2l3.9-10.6l0,0H192.7z M460.1,38.9v10.6h21.4v42.5h10.6V49.6h17.5l3.8-10.6H460.1z M541.6,68.2c-0.2,0.1-0.4,0.3-0.7,0.4C541.1,68.4,541.4,68.3,541.6,68.2L541.6,68.2z M554.3,60.2h-21.6v0l0,0c-2.9,0-5.3-2.4-5.3-5.3c0-2.9,2.4-5.3,5.3-5.3l0,0l0,0h33.6l3.8-10.6h-37.5l0,0c-6.9,0-12.8,4.4-15,10.6c-0.6,1.7-0.9,3.5-0.9,5.3c0,1.9,0.3,3.7,0.9,5.3c2.2,6.2,8.1,10.6,15,10.6h21.6l0,0c2.9,0,5.3,2.4,5.3,5.3c0,2.9-2.4,5.3-5.3,5.3l0,0h-37.5v10.6h37.5c6.9,0,12.8-4.4,15-10.6c0.6-1.7,0.9-3.5,0.9-5.3c0-1.9-0.3-3.7-0.9-5.3C567.2,64.6,561.3,60.2,554.3,60.2z', + showAbove: false, + offsetCenter: [0, '-35%'], + size: 120, + keepAspect: true, + itemStyle: { + color: '#707177' + } + }, + pointer: { + icon: 'path://M2.9,0.7L2.9,0.7c1.4,0,2.6,1.2,2.6,2.6v115c0,1.4-1.2,2.6-2.6,2.6l0,0c-1.4,0-2.6-1.2-2.6-2.6V3.3C0.3,1.9,1.4,0.7,2.9,0.7z', + width: 12, + length: '55%', + offsetCenter: [0, '8%'], + itemStyle: { + color: '#C0911F', + shadowColor: 'rgba(0, 0, 0, 0.3)', + shadowBlur: 8, + shadowOffsetX: 2, + shadowOffsetY: 4 + } + }, + detail: { + show: false + }, + title: { + offsetCenter: [0, '30%'] + }, + data: [ + { + value: 0 + } + ] + }, + { + name: 'minute', + type: 'gauge', + startAngle: 90, + endAngle: -270, + min: 0, + max: 60, + clockwise: true, + axisLine: { + show: false + }, + splitLine: { + show: false + }, + axisTick: { + show: false + }, + axisLabel: { + show: false + }, + pointer: { + icon: 'path://M2.9,0.7L2.9,0.7c1.4,0,2.6,1.2,2.6,2.6v115c0,1.4-1.2,2.6-2.6,2.6l0,0c-1.4,0-2.6-1.2-2.6-2.6V3.3C0.3,1.9,1.4,0.7,2.9,0.7z', + width: 8, + length: '70%', + offsetCenter: [0, '8%'], + itemStyle: { + color: '#C0911F', + shadowColor: 'rgba(0, 0, 0, 0.3)', + shadowBlur: 8, + shadowOffsetX: 2, + shadowOffsetY: 4 + } + }, + anchor: { + show: true, + size: 20, + showAbove: false, + itemStyle: { + borderWidth: 15, + borderColor: '#C0911F', + shadowColor: 'rgba(0, 0, 0, 0.3)', + shadowBlur: 8, + shadowOffsetX: 2, + shadowOffsetY: 4 + } + }, + detail: { + show: false + }, + title: { + offsetCenter: ['0%', '-40%'] + }, + data: [ + { + value: 0 + } + ] + }, + { + name: 'second', + type: 'gauge', + startAngle: 90, + endAngle: -270, + min: 0, + max: 60, + animationEasingUpdate: 'bounceOut', + clockwise: true, + axisLine: { + show: false + }, + splitLine: { + show: false + }, + axisTick: { + show: false + }, + axisLabel: { + show: false + }, + pointer: { + icon: 'path://M2.9,0.7L2.9,0.7c1.4,0,2.6,1.2,2.6,2.6v115c0,1.4-1.2,2.6-2.6,2.6l0,0c-1.4,0-2.6-1.2-2.6-2.6V3.3C0.3,1.9,1.4,0.7,2.9,0.7z', + width: 4, + length: '85%', + offsetCenter: [0, '8%'], + itemStyle: { + color: '#C0911F', + shadowColor: 'rgba(0, 0, 0, 0.3)', + shadowBlur: 8, + shadowOffsetX: 2, + shadowOffsetY: 4 + } + }, + anchor: { + show: true, + size: 15, + showAbove: true, + itemStyle: { + color: '#C0911F', + shadowColor: 'rgba(0, 0, 0, 0.3)', + shadowBlur: 8, + shadowOffsetX: 2, + shadowOffsetY: 4 + } + }, + detail: { + show: false + }, + title: { + offsetCenter: ['0%', '-40%'] + }, + data: [ + { + value: 0 + } + ] + } + ] +}; +setInterval(function () { + var date = new Date(); + var second = date.getSeconds(); + var minute = date.getMinutes() + second / 60; + var hour = (date.getHours() % 12) + minute / 60; + option.animationDurationUpdate = 300; + myChart.setOption({ + series: [ + { + name: 'hour', + animation: hour !== 0, + data: [{ value: hour }] + }, + { + name: 'minute', + animation: minute !== 0, + data: [{ value: minute }] + }, + { + animation: second !== 0, + name: 'second', + data: [{ value: second }] + } + ] + }); +}, 1000); +export {}; diff --git a/testdata/gauge-clock.js.svg b/testdata/gauge-clock.js.svg new file mode 100644 index 0000000..95e0eb1 --- /dev/null +++ b/testdata/gauge-clock.js.svg @@ -0,0 +1,119 @@ + + + + +0 + + + + + + + +1 + + + + + + + +2 + + + + + + + +3 + + + + + + + +4 + + + + + + + +5 + + + + + + + +6 + + + + + + + +7 + + + + + + + +8 + + + + + + + +9 + + + + + + + +10 + + + + + + + +11 + + + + + + + +12 + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/gauge-grade.js b/testdata/gauge-grade.js new file mode 100644 index 0000000..2ec6e64 --- /dev/null +++ b/testdata/gauge-grade.js @@ -0,0 +1,96 @@ +/* +title: Grade Gauge +titleCN: 等级仪表盘 +category: gauge +shotWidth: 800 +difficulty: 4 +*/ +option = { + series: [ + { + type: 'gauge', + startAngle: 180, + endAngle: 0, + center: ['50%', '75%'], + radius: '90%', + min: 0, + max: 1, + splitNumber: 8, + axisLine: { + lineStyle: { + width: 6, + color: [ + [0.25, '#FF6E76'], + [0.5, '#FDDD60'], + [0.75, '#58D9F9'], + [1, '#7CFFB2'] + ] + } + }, + pointer: { + icon: 'path://M12.8,0.7l12,40.1H0.7L12.8,0.7z', + length: '12%', + width: 20, + offsetCenter: [0, '-60%'], + itemStyle: { + color: 'auto' + } + }, + axisTick: { + length: 12, + lineStyle: { + color: 'auto', + width: 2 + } + }, + splitLine: { + length: 20, + lineStyle: { + color: 'auto', + width: 5 + } + }, + axisLabel: { + color: '#464646', + fontSize: 20, + distance: -60, + rotate: 'tangential', + formatter: function (value) { + if (value === 0.875) { + return 'Grade A'; + } + else if (value === 0.625) { + return 'Grade B'; + } + else if (value === 0.375) { + return 'Grade C'; + } + else if (value === 0.125) { + return 'Grade D'; + } + return ''; + } + }, + title: { + offsetCenter: [0, '-10%'], + fontSize: 20 + }, + detail: { + fontSize: 30, + offsetCenter: [0, '-35%'], + valueAnimation: true, + formatter: function (value) { + return Math.round(value * 100) + ''; + }, + color: 'inherit' + }, + data: [ + { + value: 0.7, + name: 'Grade Rating' + } + ] + } + ] +}; +export {}; diff --git a/testdata/gauge-grade.js.svg b/testdata/gauge-grade.js.svg new file mode 100644 index 0000000..a1965f9 --- /dev/null +++ b/testdata/gauge-grade.js.svg @@ -0,0 +1,92 @@ + + + + + + + +0 + + + + + + + +0.125 + + + + + + + +0.25 + + + + + + + +0.375 + + + + + + + +0.5 + + + + + + + +0.625 + + + + + + + +0.75 + + + + + + + +0.875 + + + + + + + +1 +Grade Rating + +0.7 + + + \ No newline at end of file diff --git a/testdata/gauge-multi-title.js b/testdata/gauge-multi-title.js new file mode 100644 index 0000000..0ec6727 --- /dev/null +++ b/testdata/gauge-multi-title.js @@ -0,0 +1,93 @@ +/* +title: Multi Title Gauge +titleCN: 多标题仪表盘 +category: gauge +difficulty: 4 +*/ +const gaugeData = [ + { + value: 20, + name: 'Good', + title: { + offsetCenter: ['-40%', '80%'] + }, + detail: { + offsetCenter: ['-40%', '95%'] + } + }, + { + value: 40, + name: 'Better', + title: { + offsetCenter: ['0%', '80%'] + }, + detail: { + offsetCenter: ['0%', '95%'] + } + }, + { + value: 60, + name: 'Perfect', + title: { + offsetCenter: ['40%', '80%'] + }, + detail: { + offsetCenter: ['40%', '95%'] + } + } +]; +option = { + series: [ + { + type: 'gauge', + anchor: { + show: true, + showAbove: true, + size: 18, + itemStyle: { + color: '#FAC858' + } + }, + pointer: { + icon: 'path://M2.9,0.7L2.9,0.7c1.4,0,2.6,1.2,2.6,2.6v115c0,1.4-1.2,2.6-2.6,2.6l0,0c-1.4,0-2.6-1.2-2.6-2.6V3.3C0.3,1.9,1.4,0.7,2.9,0.7z', + width: 8, + length: '80%', + offsetCenter: [0, '8%'] + }, + progress: { + show: true, + overlap: true, + roundCap: true + }, + axisLine: { + roundCap: true + }, + data: gaugeData, + title: { + fontSize: 14 + }, + detail: { + width: 40, + height: 14, + fontSize: 14, + color: '#fff', + backgroundColor: 'inherit', + borderRadius: 3, + formatter: '{value}%' + } + } + ] +}; +setInterval(function () { + gaugeData[0].value = +(Math.random() * 100).toFixed(2); + gaugeData[1].value = +(Math.random() * 100).toFixed(2); + gaugeData[2].value = +(Math.random() * 100).toFixed(2); + myChart.setOption({ + series: [ + { + data: gaugeData + } + ] + }); +}, 2000); +export {}; diff --git a/testdata/gauge-multi-title.js.svg b/testdata/gauge-multi-title.js.svg new file mode 100644 index 0000000..fc1995a --- /dev/null +++ b/testdata/gauge-multi-title.js.svg @@ -0,0 +1,172 @@ + + + + +0 + + + + + + + +10 + + + + + + + +20 + + + + + + + +30 + + + + + + + +40 + + + + + + + +50 + + + + + + + +60 + + + + + + + +70 + + + + + + + +80 + + + + + + + +90 + + + + + + + +100 +Good + +20% +Better + +40% +Perfect + +60% + + + + + + + + + \ No newline at end of file diff --git a/testdata/gauge-progress.js b/testdata/gauge-progress.js new file mode 100644 index 0000000..132397f --- /dev/null +++ b/testdata/gauge-progress.js @@ -0,0 +1,97 @@ +/* +title: Progress Gauge +titleCN: 进度仪表盘 +category: gauge +shotWidth: 800 +difficulty: 3 +*/ +option = { + series: [ + { + type: 'gauge', + startAngle: 180, + endAngle: 0, + min: 0, + max: 240, + splitNumber: 12, + itemStyle: { + color: '#58D9F9', + shadowColor: 'rgba(0,138,255,0.45)', + shadowBlur: 10, + shadowOffsetX: 2, + shadowOffsetY: 2 + }, + progress: { + show: true, + roundCap: true, + width: 18 + }, + pointer: { + icon: 'path://M2090.36389,615.30999 L2090.36389,615.30999 C2091.48372,615.30999 2092.40383,616.194028 2092.44859,617.312956 L2096.90698,728.755929 C2097.05155,732.369577 2094.2393,735.416212 2090.62566,735.56078 C2090.53845,735.564269 2090.45117,735.566014 2090.36389,735.566014 L2090.36389,735.566014 C2086.74736,735.566014 2083.81557,732.63423 2083.81557,729.017692 C2083.81557,728.930412 2083.81732,728.84314 2083.82081,728.755929 L2088.2792,617.312956 C2088.32396,616.194028 2089.24407,615.30999 2090.36389,615.30999 Z', + length: '75%', + width: 16, + offsetCenter: [0, '5%'] + }, + axisLine: { + roundCap: true, + lineStyle: { + width: 18 + } + }, + axisTick: { + splitNumber: 2, + lineStyle: { + width: 2, + color: '#999' + } + }, + splitLine: { + length: 12, + lineStyle: { + width: 3, + color: '#999' + } + }, + axisLabel: { + distance: 30, + color: '#999', + fontSize: 20 + }, + title: { + show: false + }, + detail: { + backgroundColor: '#fff', + borderColor: '#999', + borderWidth: 2, + width: '60%', + lineHeight: 40, + height: 40, + borderRadius: 8, + offsetCenter: [0, '35%'], + valueAnimation: true, + formatter: function (value) { + return '{value|' + value.toFixed(0) + '}{unit|km/h}'; + }, + rich: { + value: { + fontSize: 50, + fontWeight: 'bolder', + color: '#777' + }, + unit: { + fontSize: 20, + color: '#999', + padding: [0, 0, -20, 10] + } + } + }, + data: [ + { + value: 100 + } + ] + } + ] +}; +export {}; diff --git a/testdata/gauge-progress.js.svg b/testdata/gauge-progress.js.svg new file mode 100644 index 0000000..5634f53 --- /dev/null +++ b/testdata/gauge-progress.js.svg @@ -0,0 +1,101 @@ + + + + +0 + + + + +20 + + + + +40 + + + + +60 + + + + +80 + + + + +100 + + + + +120 + + + + +140 + + + + +160 + + + + +180 + + + + +200 + + + + +220 + + + + +240 + +100 + + + + + + + + + \ No newline at end of file diff --git a/testdata/gauge-ring.js b/testdata/gauge-ring.js new file mode 100644 index 0000000..15c861a --- /dev/null +++ b/testdata/gauge-ring.js @@ -0,0 +1,112 @@ +/* +title: Ring Gauge +titleCN: 得分环 +category: gauge +difficulty: 5 +videoStart: 1000 +videoEnd: 8000 +*/ +const gaugeData = [ + { + value: 20, + name: 'Perfect', + title: { + offsetCenter: ['0%', '-30%'] + }, + detail: { + valueAnimation: true, + offsetCenter: ['0%', '-20%'] + } + }, + { + value: 40, + name: 'Good', + title: { + offsetCenter: ['0%', '0%'] + }, + detail: { + valueAnimation: true, + offsetCenter: ['0%', '10%'] + } + }, + { + value: 60, + name: 'Commonly', + title: { + offsetCenter: ['0%', '30%'] + }, + detail: { + valueAnimation: true, + offsetCenter: ['0%', '40%'] + } + } +]; +option = { + series: [ + { + type: 'gauge', + startAngle: 90, + endAngle: -270, + pointer: { + show: false + }, + progress: { + show: true, + overlap: false, + roundCap: true, + clip: false, + itemStyle: { + borderWidth: 1, + borderColor: '#464646' + } + }, + axisLine: { + lineStyle: { + width: 40 + } + }, + splitLine: { + show: false, + distance: 0, + length: 10 + }, + axisTick: { + show: false + }, + axisLabel: { + show: false, + distance: 50 + }, + data: gaugeData, + title: { + fontSize: 14 + }, + detail: { + width: 50, + height: 14, + fontSize: 14, + color: 'inherit', + borderColor: 'inherit', + borderRadius: 20, + borderWidth: 1, + formatter: '{value}%' + } + } + ] +}; +setInterval(function () { + gaugeData[0].value = +(Math.random() * 100).toFixed(2); + gaugeData[1].value = +(Math.random() * 100).toFixed(2); + gaugeData[2].value = +(Math.random() * 100).toFixed(2); + myChart.setOption({ + series: [ + { + data: gaugeData, + pointer: { + show: false + } + } + ] + }); +}, 2000); +export {}; diff --git a/testdata/gauge-ring.js.svg b/testdata/gauge-ring.js.svg new file mode 100644 index 0000000..916c6b0 --- /dev/null +++ b/testdata/gauge-ring.js.svg @@ -0,0 +1,53 @@ + + + +Perfect + +20% +Good + +40% +Commonly + +60% + + + + + \ No newline at end of file diff --git a/testdata/gauge-simple.js b/testdata/gauge-simple.js new file mode 100644 index 0000000..f97fcce --- /dev/null +++ b/testdata/gauge-simple.js @@ -0,0 +1,33 @@ +/* +title: Simple Gauge +titleCN: 带标签数字动画的基础仪表盘 +category: gauge +difficulty: 1 +videoStart: 0 +videoEnd: 1000 +*/ +option = { + tooltip: { + formatter: '{a}
{b} : {c}%' + }, + series: [ + { + name: 'Pressure', + type: 'gauge', + progress: { + show: true + }, + detail: { + valueAnimation: true, + formatter: '{value}' + }, + data: [ + { + value: 50, + name: 'SCORE' + } + ] + } + ] +}; +export {}; diff --git a/testdata/gauge-simple.js.svg b/testdata/gauge-simple.js.svg new file mode 100644 index 0000000..ee5c0b7 --- /dev/null +++ b/testdata/gauge-simple.js.svg @@ -0,0 +1,106 @@ + + + + +0 + + + + + + + +10 + + + + + + + +20 + + + + + + + +30 + + + + + + + +40 + + + + + + + +50 + + + + + + + +60 + + + + + + + +70 + + + + + + + +80 + + + + + + + +90 + + + + + + + +100 +SCORE + +50 + + + + \ No newline at end of file diff --git a/testdata/gauge-speed.js b/testdata/gauge-speed.js new file mode 100644 index 0000000..0369800 --- /dev/null +++ b/testdata/gauge-speed.js @@ -0,0 +1,59 @@ +/* +title: Speed Gauge +titleCN: 速度仪表盘 +category: gauge +difficulty: 2 +*/ +option = { + series: [ + { + type: 'gauge', + progress: { + show: true, + width: 18 + }, + axisLine: { + lineStyle: { + width: 18 + } + }, + axisTick: { + show: false + }, + splitLine: { + length: 15, + lineStyle: { + width: 2, + color: '#999' + } + }, + axisLabel: { + distance: 25, + color: '#999', + fontSize: 20 + }, + anchor: { + show: true, + showAbove: true, + size: 25, + itemStyle: { + borderWidth: 10 + } + }, + title: { + show: false + }, + detail: { + valueAnimation: true, + fontSize: 80, + offsetCenter: [0, '70%'] + }, + data: [ + { + value: 70 + } + ] + } + ] +}; +export {}; diff --git a/testdata/gauge-speed.js.svg b/testdata/gauge-speed.js.svg new file mode 100644 index 0000000..3ba2dba --- /dev/null +++ b/testdata/gauge-speed.js.svg @@ -0,0 +1,46 @@ + + + + +0 + +10 + +20 + +30 + +40 + +50 + +60 + +70 + +80 + +90 + +100 + +70 + + + + + \ No newline at end of file diff --git a/testdata/gauge-stage.js b/testdata/gauge-stage.js new file mode 100644 index 0000000..59fbd9b --- /dev/null +++ b/testdata/gauge-stage.js @@ -0,0 +1,73 @@ +"use strict"; +/* +title: Stage Speed Gauge +titleCN: 阶段速度仪表盘 +category: gauge +difficulty: 3 +*/ +option = { + series: [ + { + type: 'gauge', + axisLine: { + lineStyle: { + width: 30, + color: [ + [0.3, '#67e0e3'], + [0.7, '#37a2da'], + [1, '#fd666d'] + ] + } + }, + pointer: { + itemStyle: { + color: 'auto' + } + }, + axisTick: { + distance: -30, + length: 8, + lineStyle: { + color: '#fff', + width: 2 + } + }, + splitLine: { + distance: -30, + length: 30, + lineStyle: { + color: '#fff', + width: 4 + } + }, + axisLabel: { + color: 'inherit', + distance: 40, + fontSize: 20 + }, + detail: { + valueAnimation: true, + formatter: '{value} km/h', + color: 'inherit' + }, + data: [ + { + value: 70 + } + ] + } + ] +}; +setInterval(function () { + myChart.setOption({ + series: [ + { + data: [ + { + value: +(Math.random() * 100).toFixed(2) + } + ] + } + ] + }); +}, 2000); diff --git a/testdata/gauge-stage.js.svg b/testdata/gauge-stage.js.svg new file mode 100644 index 0000000..b627fcd --- /dev/null +++ b/testdata/gauge-stage.js.svg @@ -0,0 +1,106 @@ + + + + + + +0 + + + + + + + +10 + + + + + + + +20 + + + + + + + +30 + + + + + + + +40 + + + + + + + +50 + + + + + + + +60 + + + + + + + +70 + + + + + + + +80 + + + + + + + +90 + + + + + + + +100 + +70 km/h + + + \ No newline at end of file diff --git a/testdata/gauge-temperature.js b/testdata/gauge-temperature.js new file mode 100644 index 0000000..6a925bc --- /dev/null +++ b/testdata/gauge-temperature.js @@ -0,0 +1,139 @@ +/* +title: Temperature Gauge chart +titleCN: 气温仪表盘 +category: gauge +difficulty: 4 +videoStart: 2000 +videoEnd: 5000 +*/ +option = { + series: [ + { + type: 'gauge', + center: ['50%', '60%'], + startAngle: 200, + endAngle: -20, + min: 0, + max: 60, + splitNumber: 12, + itemStyle: { + color: '#FFAB91' + }, + progress: { + show: true, + width: 30 + }, + pointer: { + show: false + }, + axisLine: { + lineStyle: { + width: 30 + } + }, + axisTick: { + distance: -45, + splitNumber: 5, + lineStyle: { + width: 2, + color: '#999' + } + }, + splitLine: { + distance: -52, + length: 14, + lineStyle: { + width: 3, + color: '#999' + } + }, + axisLabel: { + distance: -20, + color: '#999', + fontSize: 20 + }, + anchor: { + show: false + }, + title: { + show: false + }, + detail: { + valueAnimation: true, + width: '60%', + lineHeight: 40, + borderRadius: 8, + offsetCenter: [0, '-15%'], + fontSize: 60, + fontWeight: 'bolder', + formatter: '{value} °C', + color: 'inherit' + }, + data: [ + { + value: 20 + } + ] + }, + { + type: 'gauge', + center: ['50%', '60%'], + startAngle: 200, + endAngle: -20, + min: 0, + max: 60, + itemStyle: { + color: '#FD7347' + }, + progress: { + show: true, + width: 8 + }, + pointer: { + show: false + }, + axisLine: { + show: false + }, + axisTick: { + show: false + }, + splitLine: { + show: false + }, + axisLabel: { + show: false + }, + detail: { + show: false + }, + data: [ + { + value: 20 + } + ] + } + ] +}; +setInterval(function () { + const random = +(Math.random() * 60).toFixed(2); + myChart.setOption({ + series: [ + { + data: [ + { + value: random + } + ] + }, + { + data: [ + { + value: random + } + ] + } + ] + }); +}, 2000); +export {}; diff --git a/testdata/gauge-temperature.js.svg b/testdata/gauge-temperature.js.svg new file mode 100644 index 0000000..0c21d7e --- /dev/null +++ b/testdata/gauge-temperature.js.svg @@ -0,0 +1,106 @@ + + + + +0 + + + + + + + +5 + + + + + + + +10 + + + + + + + +15 + + + + + + + +20 + + + + + + + +25 + + + + + + + +30 + + + + + + + +35 + + + + + + + +40 + + + + + + + +45 + + + + + + + +50 + + + + + + + +55 + + + + + + + +60 + +20 °C + + + \ No newline at end of file diff --git a/testdata/gauge.js b/testdata/gauge.js new file mode 100644 index 0000000..fee0a7c --- /dev/null +++ b/testdata/gauge.js @@ -0,0 +1,27 @@ +/* +title: Gauge Basic chart +titleCN: 基础仪表盘 +category: gauge +difficulty: 1 +*/ +option = { + tooltip: { + formatter: '{a}
{b} : {c}%' + }, + series: [ + { + name: 'Pressure', + type: 'gauge', + detail: { + formatter: '{value}' + }, + data: [ + { + value: 50, + name: 'SCORE' + } + ] + } + ] +}; +export {}; diff --git a/testdata/gauge.js.svg b/testdata/gauge.js.svg new file mode 100644 index 0000000..e59f8e0 --- /dev/null +++ b/testdata/gauge.js.svg @@ -0,0 +1,105 @@ + + + + +0 + + + + + + + +10 + + + + + + + +20 + + + + + + + +30 + + + + + + + +40 + + + + + + + +50 + + + + + + + +60 + + + + + + + +70 + + + + + + + +80 + + + + + + + +90 + + + + + + + +100 +SCORE + +50 + + + \ No newline at end of file diff --git a/testdata/geo-beef-cuts.js b/testdata/geo-beef-cuts.js new file mode 100644 index 0000000..01717ca --- /dev/null +++ b/testdata/geo-beef-cuts.js @@ -0,0 +1,71 @@ +/* +title: GEO Beef Cuts +category: map +titleCN: 庖丁解牛 +*/ +$.get(ROOT_PATH + '/data/asset/geo/Beef_cuts_France.svg', function (svg) { + echarts.registerMap('Beef_cuts_France', { svg: svg }); + option = { + tooltip: {}, + visualMap: { + left: 'center', + bottom: '10%', + min: 5, + max: 100, + orient: 'horizontal', + text: ['', 'Price'], + realtime: true, + calculable: true, + inRange: { + color: ['#dbac00', '#db6e00', '#cf0000'] + } + }, + series: [ + { + name: 'French Beef Cuts', + type: 'map', + map: 'Beef_cuts_France', + roam: true, + emphasis: { + label: { + show: false + } + }, + selectedMode: false, + data: [ + { name: 'Queue', value: 15 }, + { name: 'Langue', value: 35 }, + { name: 'Plat de joue', value: 15 }, + { name: 'Gros bout de poitrine', value: 25 }, + { name: 'Jumeau à pot-au-feu', value: 45 }, + { name: 'Onglet', value: 85 }, + { name: 'Plat de tranche', value: 25 }, + { name: 'Araignée', value: 15 }, + { name: 'Gîte à la noix', value: 55 }, + { name: "Bavette d'aloyau", value: 25 }, + { name: 'Tende de tranche', value: 65 }, + { name: 'Rond de gîte', value: 45 }, + { name: 'Bavettede de flanchet', value: 85 }, + { name: 'Flanchet', value: 35 }, + { name: 'Hampe', value: 75 }, + { name: 'Plat de côtes', value: 65 }, + { name: 'Tendron Milieu de poitrine', value: 65 }, + { name: 'Macreuse à pot-au-feu', value: 85 }, + { name: 'Rumsteck', value: 75 }, + { name: 'Faux-filet', value: 65 }, + { name: 'Côtes Entrecôtes', value: 55 }, + { name: 'Basses côtes', value: 45 }, + { name: 'Collier', value: 85 }, + { name: 'Jumeau à biftek', value: 15 }, + { name: 'Paleron', value: 65 }, + { name: 'Macreuse à bifteck', value: 45 }, + { name: 'Gîte', value: 85 }, + { name: 'Aiguillette baronne', value: 65 }, + { name: 'Filet', value: 95 } + ] + } + ] + }; + myChart.setOption(option); +}); +export {}; diff --git a/testdata/geo-lines.js b/testdata/geo-lines.js new file mode 100644 index 0000000..8dd3c49 --- /dev/null +++ b/testdata/geo-lines.js @@ -0,0 +1,292 @@ +"use strict"; +/* +title: Migration +category: map +titleCN: 模拟迁徙 +*/ +var geoCoordMap = { + 上海: [121.4648, 31.2891], + 东莞: [113.8953, 22.901], + 东营: [118.7073, 37.5513], + 中山: [113.4229, 22.478], + 临汾: [111.4783, 36.1615], + 临沂: [118.3118, 35.2936], + 丹东: [124.541, 40.4242], + 丽水: [119.5642, 28.1854], + 乌鲁木齐: [87.9236, 43.5883], + 佛山: [112.8955, 23.1097], + 保定: [115.0488, 39.0948], + 兰州: [103.5901, 36.3043], + 包头: [110.3467, 41.4899], + 北京: [116.4551, 40.2539], + 北海: [109.314, 21.6211], + 南京: [118.8062, 31.9208], + 南宁: [108.479, 23.1152], + 南昌: [116.0046, 28.6633], + 南通: [121.1023, 32.1625], + 厦门: [118.1689, 24.6478], + 台州: [121.1353, 28.6688], + 合肥: [117.29, 32.0581], + 呼和浩特: [111.4124, 40.4901], + 咸阳: [108.4131, 34.8706], + 哈尔滨: [127.9688, 45.368], + 唐山: [118.4766, 39.6826], + 嘉兴: [120.9155, 30.6354], + 大同: [113.7854, 39.8035], + 大连: [122.2229, 39.4409], + 天津: [117.4219, 39.4189], + 太原: [112.3352, 37.9413], + 威海: [121.9482, 37.1393], + 宁波: [121.5967, 29.6466], + 宝鸡: [107.1826, 34.3433], + 宿迁: [118.5535, 33.7775], + 常州: [119.4543, 31.5582], + 广州: [113.5107, 23.2196], + 廊坊: [116.521, 39.0509], + 延安: [109.1052, 36.4252], + 张家口: [115.1477, 40.8527], + 徐州: [117.5208, 34.3268], + 德州: [116.6858, 37.2107], + 惠州: [114.6204, 23.1647], + 成都: [103.9526, 30.7617], + 扬州: [119.4653, 32.8162], + 承德: [117.5757, 41.4075], + 拉萨: [91.1865, 30.1465], + 无锡: [120.3442, 31.5527], + 日照: [119.2786, 35.5023], + 昆明: [102.9199, 25.4663], + 杭州: [119.5313, 29.8773], + 枣庄: [117.323, 34.8926], + 柳州: [109.3799, 24.9774], + 株洲: [113.5327, 27.0319], + 武汉: [114.3896, 30.6628], + 汕头: [117.1692, 23.3405], + 江门: [112.6318, 22.1484], + 沈阳: [123.1238, 42.1216], + 沧州: [116.8286, 38.2104], + 河源: [114.917, 23.9722], + 泉州: [118.3228, 25.1147], + 泰安: [117.0264, 36.0516], + 泰州: [120.0586, 32.5525], + 济南: [117.1582, 36.8701], + 济宁: [116.8286, 35.3375], + 海口: [110.3893, 19.8516], + 淄博: [118.0371, 36.6064], + 淮安: [118.927, 33.4039], + 深圳: [114.5435, 22.5439], + 清远: [112.9175, 24.3292], + 温州: [120.498, 27.8119], + 渭南: [109.7864, 35.0299], + 湖州: [119.8608, 30.7782], + 湘潭: [112.5439, 27.7075], + 滨州: [117.8174, 37.4963], + 潍坊: [119.0918, 36.524], + 烟台: [120.7397, 37.5128], + 玉溪: [101.9312, 23.8898], + 珠海: [113.7305, 22.1155], + 盐城: [120.2234, 33.5577], + 盘锦: [121.9482, 41.0449], + 石家庄: [114.4995, 38.1006], + 福州: [119.4543, 25.9222], + 秦皇岛: [119.2126, 40.0232], + 绍兴: [120.564, 29.7565], + 聊城: [115.9167, 36.4032], + 肇庆: [112.1265, 23.5822], + 舟山: [122.2559, 30.2234], + 苏州: [120.6519, 31.3989], + 莱芜: [117.6526, 36.2714], + 菏泽: [115.6201, 35.2057], + 营口: [122.4316, 40.4297], + 葫芦岛: [120.1575, 40.578], + 衡水: [115.8838, 37.7161], + 衢州: [118.6853, 28.8666], + 西宁: [101.4038, 36.8207], + 西安: [109.1162, 34.2004], + 贵阳: [106.6992, 26.7682], + 连云港: [119.1248, 34.552], + 邢台: [114.8071, 37.2821], + 邯郸: [114.4775, 36.535], + 郑州: [113.4668, 34.6234], + 鄂尔多斯: [108.9734, 39.2487], + 重庆: [107.7539, 30.1904], + 金华: [120.0037, 29.1028], + 铜川: [109.0393, 35.1947], + 银川: [106.3586, 38.1775], + 镇江: [119.4763, 31.9702], + 长春: [125.8154, 44.2584], + 长沙: [113.0823, 28.2568], + 长治: [112.8625, 36.4746], + 阳泉: [113.4778, 38.0951], + 青岛: [120.4651, 36.3373], + 韶关: [113.7964, 24.7028] +}; +var BJData = [ + [{ name: '北京' }, { name: '上海', value: 95 }], + [{ name: '北京' }, { name: '广州', value: 90 }], + [{ name: '北京' }, { name: '大连', value: 80 }], + [{ name: '北京' }, { name: '南宁', value: 70 }], + [{ name: '北京' }, { name: '南昌', value: 60 }], + [{ name: '北京' }, { name: '拉萨', value: 50 }], + [{ name: '北京' }, { name: '长春', value: 40 }], + [{ name: '北京' }, { name: '包头', value: 30 }], + [{ name: '北京' }, { name: '重庆', value: 20 }], + [{ name: '北京' }, { name: '常州', value: 10 }] +]; +var SHData = [ + [{ name: '上海' }, { name: '包头', value: 95 }], + [{ name: '上海' }, { name: '昆明', value: 90 }], + [{ name: '上海' }, { name: '广州', value: 80 }], + [{ name: '上海' }, { name: '郑州', value: 70 }], + [{ name: '上海' }, { name: '长春', value: 60 }], + [{ name: '上海' }, { name: '重庆', value: 50 }], + [{ name: '上海' }, { name: '长沙', value: 40 }], + [{ name: '上海' }, { name: '北京', value: 30 }], + [{ name: '上海' }, { name: '丹东', value: 20 }], + [{ name: '上海' }, { name: '大连', value: 10 }] +]; +var GZData = [ + [{ name: '广州' }, { name: '福州', value: 95 }], + [{ name: '广州' }, { name: '太原', value: 90 }], + [{ name: '广州' }, { name: '长春', value: 80 }], + [{ name: '广州' }, { name: '重庆', value: 70 }], + [{ name: '广州' }, { name: '西安', value: 60 }], + [{ name: '广州' }, { name: '成都', value: 50 }], + [{ name: '广州' }, { name: '常州', value: 40 }], + [{ name: '广州' }, { name: '北京', value: 30 }], + [{ name: '广州' }, { name: '北海', value: 20 }], + [{ name: '广州' }, { name: '海口', value: 10 }] +]; +var planePath = 'path://M1705.06,1318.313v-89.254l-319.9-221.799l0.073-208.063c0.521-84.662-26.629-121.796-63.961-121.491c-37.332-0.305-64.482,36.829-63.961,121.491l0.073,208.063l-319.9,221.799v89.254l330.343-157.288l12.238,241.308l-134.449,92.931l0.531,42.034l175.125-42.917l175.125,42.917l0.531-42.034l-134.449-92.931l12.238-241.308L1705.06,1318.313z'; +var convertData = function (data) { + var res = []; + for (var i = 0; i < data.length; i++) { + var dataItem = data[i]; + var fromCoord = geoCoordMap[dataItem[0].name]; + var toCoord = geoCoordMap[dataItem[1].name]; + if (fromCoord && toCoord) { + res.push({ + fromName: dataItem[0].name, + toName: dataItem[1].name, + coords: [fromCoord, toCoord] + }); + } + } + return res; +}; +var color = ['#a6c84c', '#ffa022', '#46bee9']; +var series = []; +[ + ['北京', BJData], + ['上海', SHData], + ['广州', GZData] +].forEach(function (item, i) { + series.push({ + name: item[0] + ' Top10', + type: 'lines', + zlevel: 1, + effect: { + show: true, + period: 6, + trailLength: 0.7, + color: '#fff', + symbolSize: 3 + }, + lineStyle: { + normal: { + color: color[i], + width: 0, + curveness: 0.2 + } + }, + data: convertData(item[1]) + }, { + name: item[0] + ' Top10', + type: 'lines', + zlevel: 2, + symbol: ['none', 'arrow'], + symbolSize: 10, + effect: { + show: true, + period: 6, + trailLength: 0, + symbol: planePath, + symbolSize: 15 + }, + lineStyle: { + color: color[i], + width: 1, + opacity: 0.6, + curveness: 0.2 + }, + data: convertData(item[1]) + }, { + name: item[0] + ' Top10', + type: 'effectScatter', + coordinateSystem: 'geo', + zlevel: 2, + rippleEffect: { + brushType: 'stroke' + }, + label: { + show: true, + position: 'right', + formatter: '{b}' + }, + symbolSize: function (val) { + return val[2] / 8; + }, + itemStyle: { + color: color[i] + }, + data: item[1].map(function (dataItem) { + return { + name: dataItem[1].name, + value: geoCoordMap[dataItem[1].name].concat([dataItem[1].value]) + }; + }) + }); +}); +option = { + backgroundColor: '#404a59', + title: { + text: '模拟迁徙', + subtext: '数据纯属虚构', + left: 'center', + textStyle: { + color: '#fff' + } + }, + tooltip: { + trigger: 'item' + }, + legend: { + orient: 'vertical', + top: 'bottom', + left: 'right', + data: ['北京 Top10', '上海 Top10', '广州 Top10'], + textStyle: { + color: '#fff' + }, + selectedMode: 'single' + }, + geo: { + map: 'china', + label: { + show: false + }, + roam: true, + itemStyle: { + areaColor: '#323c48', + borderColor: '#404a59' + }, + emphasis: { + label: { + show: true + }, + itemStyle: { + areaColor: '#2a333d' + } + } + }, + series: series +}; diff --git a/testdata/geo-map-scatter.js b/testdata/geo-map-scatter.js new file mode 100644 index 0000000..66b2b89 --- /dev/null +++ b/testdata/geo-map-scatter.js @@ -0,0 +1,343 @@ +"use strict"; +/* +title: map and scatter share a geo +category: map +titleCN: map and scatter share a geo +*/ +var data = [ + { name: '海门', value: 9 }, + { name: '鄂尔多斯', value: 12 }, + { name: '招远', value: 12 }, + { name: '舟山', value: 12 }, + { name: '齐齐哈尔', value: 14 }, + { name: '盐城', value: 15 }, + { name: '赤峰', value: 16 }, + { name: '青岛', value: 18 }, + { name: '乳山', value: 18 }, + { name: '金昌', value: 19 }, + { name: '泉州', value: 21 }, + { name: '南通', value: 23 }, + { name: '拉萨', value: 24 }, + { name: '云浮', value: 24 }, + { name: '上海', value: 25 }, + { name: '攀枝花', value: 25 }, + { name: '承德', value: 25 }, + { name: '汕尾', value: 26 }, + { name: '丹东', value: 27 }, + { name: '瓦房店', value: 30 }, + { name: '延安', value: 38 }, + { name: '咸阳', value: 43 }, + { name: '南昌', value: 54 }, + { name: '柳州', value: 54 }, + { name: '三亚', value: 54 }, + { name: '泸州', value: 57 }, + { name: '克拉玛依', value: 72 } +]; +var geoCoordMap = { + 海门: [121.15, 31.89], + 鄂尔多斯: [109.781327, 39.608266], + 招远: [120.38, 37.35], + 舟山: [122.207216, 29.985295], + 齐齐哈尔: [123.97, 47.33], + 盐城: [120.13, 33.38], + 赤峰: [118.87, 42.28], + 青岛: [120.33, 36.07], + 乳山: [121.52, 36.89], + 金昌: [102.188043, 38.520089], + 泉州: [118.58, 24.93], + 莱西: [120.53, 36.86], + 日照: [119.46, 35.42], + 胶南: [119.97, 35.88], + 南通: [121.05, 32.08], + 拉萨: [91.11, 29.97], + 云浮: [112.02, 22.93], + 梅州: [116.1, 24.55], + 文登: [122.05, 37.2], + 上海: [121.48, 31.22], + 攀枝花: [101.718637, 26.582347], + 威海: [122.1, 37.5], + 承德: [117.93, 40.97], + 厦门: [118.1, 24.46], + 汕尾: [115.375279, 22.786211], + 潮州: [116.63, 23.68], + 丹东: [124.37, 40.13], + 太仓: [121.1, 31.45], + 曲靖: [103.79, 25.51], + 烟台: [121.39, 37.52], + 福州: [119.3, 26.08], + 瓦房店: [121.979603, 39.627114], + 即墨: [120.45, 36.38], + 抚顺: [123.97, 41.97], + 玉溪: [102.52, 24.35], + 张家口: [114.87, 40.82], + 阳泉: [113.57, 37.85], + 莱州: [119.942327, 37.177017], + 湖州: [120.1, 30.86], + 汕头: [116.69, 23.39], + 昆山: [120.95, 31.39], + 宁波: [121.56, 29.86], + 湛江: [110.359377, 21.270708], + 揭阳: [116.35, 23.55], + 荣成: [122.41, 37.16], + 连云港: [119.16, 34.59], + 葫芦岛: [120.836932, 40.711052], + 常熟: [120.74, 31.64], + 东莞: [113.75, 23.04], + 河源: [114.68, 23.73], + 淮安: [119.15, 33.5], + 泰州: [119.9, 32.49], + 南宁: [108.33, 22.84], + 营口: [122.18, 40.65], + 惠州: [114.4, 23.09], + 江阴: [120.26, 31.91], + 蓬莱: [120.75, 37.8], + 韶关: [113.62, 24.84], + 嘉峪关: [98.289152, 39.77313], + 广州: [113.23, 23.16], + 延安: [109.47, 36.6], + 太原: [112.53, 37.87], + 清远: [113.01, 23.7], + 中山: [113.38, 22.52], + 昆明: [102.73, 25.04], + 寿光: [118.73, 36.86], + 盘锦: [122.070714, 41.119997], + 长治: [113.08, 36.18], + 深圳: [114.07, 22.62], + 珠海: [113.52, 22.3], + 宿迁: [118.3, 33.96], + 咸阳: [108.72, 34.36], + 铜川: [109.11, 35.09], + 平度: [119.97, 36.77], + 佛山: [113.11, 23.05], + 海口: [110.35, 20.02], + 江门: [113.06, 22.61], + 章丘: [117.53, 36.72], + 肇庆: [112.44, 23.05], + 大连: [121.62, 38.92], + 临汾: [111.5, 36.08], + 吴江: [120.63, 31.16], + 石嘴山: [106.39, 39.04], + 沈阳: [123.38, 41.8], + 苏州: [120.62, 31.32], + 茂名: [110.88, 21.68], + 嘉兴: [120.76, 30.77], + 长春: [125.35, 43.88], + 胶州: [120.03336, 36.264622], + 银川: [106.27, 38.47], + 张家港: [120.555821, 31.875428], + 三门峡: [111.19, 34.76], + 锦州: [121.15, 41.13], + 南昌: [115.89, 28.68], + 柳州: [109.4, 24.33], + 三亚: [109.511909, 18.252847], + 自贡: [104.778442, 29.33903], + 吉林: [126.57, 43.87], + 阳江: [111.95, 21.85], + 泸州: [105.39, 28.91], + 西宁: [101.74, 36.56], + 宜宾: [104.56, 29.77], + 呼和浩特: [111.65, 40.82], + 成都: [104.06, 30.67], + 大同: [113.3, 40.12], + 镇江: [119.44, 32.2], + 桂林: [110.28, 25.29], + 张家界: [110.479191, 29.117096], + 宜兴: [119.82, 31.36], + 北海: [109.12, 21.49], + 西安: [108.95, 34.27], + 金坛: [119.56, 31.74], + 东营: [118.49, 37.46], + 牡丹江: [129.58, 44.6], + 遵义: [106.9, 27.7], + 绍兴: [120.58, 30.01], + 扬州: [119.42, 32.39], + 常州: [119.95, 31.79], + 潍坊: [119.1, 36.62], + 重庆: [106.54, 29.59], + 台州: [121.420757, 28.656386], + 南京: [118.78, 32.04], + 滨州: [118.03, 37.36], + 贵阳: [106.71, 26.57], + 无锡: [120.29, 31.59], + 本溪: [123.73, 41.3], + 克拉玛依: [84.77, 45.59], + 渭南: [109.5, 34.52], + 马鞍山: [118.48, 31.56], + 宝鸡: [107.15, 34.38], + 焦作: [113.21, 35.24], + 句容: [119.16, 31.95], + 北京: [116.46, 39.92], + 徐州: [117.2, 34.26], + 衡水: [115.72, 37.72], + 包头: [110, 40.58], + 绵阳: [104.73, 31.48], + 乌鲁木齐: [87.68, 43.77], + 枣庄: [117.57, 34.86], + 杭州: [120.19, 30.26], + 淄博: [118.05, 36.78], + 鞍山: [122.85, 41.12], + 溧阳: [119.48, 31.43], + 库尔勒: [86.06, 41.68], + 安阳: [114.35, 36.1], + 开封: [114.35, 34.79], + 济南: [117, 36.65], + 德阳: [104.37, 31.13], + 温州: [120.65, 28.01], + 九江: [115.97, 29.71], + 邯郸: [114.47, 36.6], + 临安: [119.72, 30.23], + 兰州: [103.73, 36.03], + 沧州: [116.83, 38.33], + 临沂: [118.35, 35.05], + 南充: [106.110698, 30.837793], + 天津: [117.2, 39.13], + 富阳: [119.95, 30.07], + 泰安: [117.13, 36.18], + 诸暨: [120.23, 29.71], + 郑州: [113.65, 34.76], + 哈尔滨: [126.63, 45.75], + 聊城: [115.97, 36.45], + 芜湖: [118.38, 31.33], + 唐山: [118.02, 39.63], + 平顶山: [113.29, 33.75], + 邢台: [114.48, 37.05], + 德州: [116.29, 37.45], + 济宁: [116.59, 35.38], + 荆州: [112.239741, 30.335165], + 宜昌: [111.3, 30.7], + 义乌: [120.06, 29.32], + 丽水: [119.92, 28.45], + 洛阳: [112.44, 34.7], + 秦皇岛: [119.57, 39.95], + 株洲: [113.16, 27.83], + 石家庄: [114.48, 38.03], + 莱芜: [117.67, 36.19], + 常德: [111.69, 29.05], + 保定: [115.48, 38.85], + 湘潭: [112.91, 27.87], + 金华: [119.64, 29.12], + 岳阳: [113.09, 29.37], + 长沙: [113, 28.21], + 衢州: [118.88, 28.97], + 廊坊: [116.7, 39.53], + 菏泽: [115.480656, 35.23375], + 合肥: [117.27, 31.86], + 武汉: [114.31, 30.52], + 大庆: [125.03, 46.58] +}; +function convertData(data) { + var res = []; + for (var i = 0; i < data.length; i++) { + var geoCoord = geoCoordMap[data[i].name]; + if (geoCoord) { + res.push({ + name: data[i].name, + value: geoCoord.concat(data[i].value) + }); + } + } + return res; +} +function randomValue() { + return Math.round(Math.random() * 1000); +} +option = { + tooltip: {}, + visualMap: { + min: 0, + max: 1500, + left: 'left', + top: 'bottom', + text: ['High', 'Low'], + seriesIndex: [1], + inRange: { + color: ['#e0ffff', '#006edd'] + }, + calculable: true + }, + geo: { + map: 'china', + roam: true, + label: { + show: true, + color: 'rgba(0,0,0,0.4)' + }, + itemStyle: { + borderColor: 'rgba(0, 0, 0, 0.2)' + }, + emphasis: { + itemStyle: { + areaColor: null, + shadowOffsetX: 0, + shadowOffsetY: 0, + shadowBlur: 20, + borderWidth: 0, + shadowColor: 'rgba(0, 0, 0, 0.5)' + } + } + }, + series: [ + { + type: 'scatter', + coordinateSystem: 'geo', + data: convertData(data), + symbolSize: 20, + symbol: 'path://M1705.06,1318.313v-89.254l-319.9-221.799l0.073-208.063c0.521-84.662-26.629-121.796-63.961-121.491c-37.332-0.305-64.482,36.829-63.961,121.491l0.073,208.063l-319.9,221.799v89.254l330.343-157.288l12.238,241.308l-134.449,92.931l0.531,42.034l175.125-42.917l175.125,42.917l0.531-42.034l-134.449-92.931l12.238-241.308L1705.06,1318.313z', + symbolRotate: 35, + label: { + formatter: '{b}', + position: 'right', + show: false + }, + itemStyle: { + color: '#F06C00' + }, + emphasis: { + label: { + show: true + } + } + }, + { + name: 'categoryA', + type: 'map', + geoIndex: 0, + data: [ + { name: '北京', value: randomValue() }, + { name: '天津', value: randomValue() }, + { name: '上海', value: randomValue() }, + { name: '重庆', value: randomValue() }, + { name: '河北', value: randomValue() }, + { name: '河南', value: randomValue() }, + { name: '云南', value: randomValue() }, + { name: '辽宁', value: randomValue() }, + { name: '黑龙江', value: randomValue() }, + { name: '湖南', value: randomValue() }, + { name: '安徽', value: randomValue() }, + { name: '山东', value: randomValue() }, + { name: '新疆', value: randomValue() }, + { name: '江苏', value: randomValue() }, + { name: '浙江', value: randomValue() }, + { name: '江西', value: randomValue() }, + { name: '湖北', value: randomValue() }, + { name: '广西', value: randomValue() }, + { name: '甘肃', value: randomValue() }, + { name: '山西', value: randomValue() }, + { name: '内蒙古', value: randomValue() }, + { name: '陕西', value: randomValue() }, + { name: '吉林', value: randomValue() }, + { name: '福建', value: randomValue() }, + { name: '贵州', value: randomValue() }, + { name: '广东', value: randomValue() }, + { name: '青海', value: randomValue() }, + { name: '西藏', value: randomValue() }, + { name: '四川', value: randomValue() }, + { name: '宁夏', value: randomValue() }, + { name: '海南', value: randomValue() }, + { name: '台湾', value: randomValue() }, + { name: '香港', value: randomValue() }, + { name: '澳门', value: randomValue() } + ] + } + ] +}; diff --git a/testdata/geo-organ.js b/testdata/geo-organ.js new file mode 100644 index 0000000..2b31995 --- /dev/null +++ b/testdata/geo-organ.js @@ -0,0 +1,82 @@ +"use strict"; +/* +title: Organ Data with SVG +category: map +titleCN: 内脏数据(SVG) +*/ +$.get(ROOT_PATH + '/data/asset/geo/Veins_Medical_Diagram_clip_art.svg', function (svg) { + echarts.registerMap('organ_diagram', { svg: svg }); + option = { + tooltip: {}, + geo: { + left: 10, + right: '50%', + map: 'organ_diagram', + selectedMode: 'multiple', + emphasis: { + focus: 'self', + itemStyle: { + color: null + }, + label: { + position: 'bottom', + distance: 0, + textBorderColor: '#fff', + textBorderWidth: 2 + } + }, + blur: {}, + select: { + itemStyle: { + color: '#b50205' + }, + label: { + show: false, + textBorderColor: '#fff', + textBorderWidth: 2 + } + } + }, + grid: { + left: '60%', + top: '20%', + bottom: '20%' + }, + xAxis: {}, + yAxis: { + data: [ + 'heart', + 'large-intestine', + 'small-intestine', + 'spleen', + 'kidney', + 'lung', + 'liver' + ] + }, + series: [ + { + type: 'bar', + emphasis: { + focus: 'self' + }, + data: [121, 321, 141, 52, 198, 289, 139] + } + ] + }; + myChart.setOption(option); + myChart.on('mouseover', { seriesIndex: 0 }, function (event) { + myChart.dispatchAction({ + type: 'highlight', + geoIndex: 0, + name: event.name + }); + }); + myChart.on('mouseout', { seriesIndex: 0 }, function (event) { + myChart.dispatchAction({ + type: 'downplay', + geoIndex: 0, + name: event.name + }); + }); +}); diff --git a/testdata/geo-seatmap-flight.js b/testdata/geo-seatmap-flight.js new file mode 100644 index 0000000..fffa640 --- /dev/null +++ b/testdata/geo-seatmap-flight.js @@ -0,0 +1,83 @@ +/* +title: Flight Seatmap with SVG +category: map +titleCN: 航班选座(SVG) +*/ +$.get(ROOT_PATH + '/data/asset/geo/flight-seats.svg', function (svg) { + echarts.registerMap('flight-seats', { svg: svg }); + const takenSeatNames = ['26E', '26D', '26C', '25D', '23C', '21A', '20F']; + option = { + tooltip: {}, + geo: { + map: 'flight-seats', + roam: true, + selectedMode: 'multiple', + layoutCenter: ['50%', '50%'], + layoutSize: '95%', + tooltip: { + show: true + }, + itemStyle: { + color: '#fff' + }, + emphasis: { + itemStyle: { + color: undefined, + borderColor: 'green', + borderWidth: 2 + }, + label: { + show: false + } + }, + select: { + itemStyle: { + color: 'green' + }, + label: { + show: false, + textBorderColor: '#fff', + textBorderWidth: 2 + } + }, + regions: makeTakenRegions(takenSeatNames) + } + }; + function makeTakenRegions(takenSeatNames) { + var regions = []; + for (var i = 0; i < takenSeatNames.length; i++) { + regions.push({ + name: takenSeatNames[i], + silent: true, + itemStyle: { + color: '#bf0e08' + }, + emphasis: { + itemStyle: { + borderColor: '#aaa', + borderWidth: 1 + } + }, + select: { + itemStyle: { + color: '#bf0e08' + } + } + }); + } + return regions; + } + myChart.setOption(option); + // Get selected seats. + myChart.on('geoselectchanged', function (params) { + const selectedNames = params.allSelected[0].name.slice(); + // Remove taken seats. + for (var i = selectedNames.length - 1; i >= 0; i--) { + if (takenSeatNames.indexOf(selectedNames[i]) >= 0) { + selectedNames.splice(i, 1); + } + } + console.log('selected', selectedNames); + }); +}); +export {}; diff --git a/testdata/geo-svg-custom-effect.js b/testdata/geo-svg-custom-effect.js new file mode 100644 index 0000000..a51955a --- /dev/null +++ b/testdata/geo-svg-custom-effect.js @@ -0,0 +1,122 @@ +/* +title: GEO SVG with Customized Effect +category: custom +titleCN: 自定义特效 +videoStart: 1000 +videoEnd: 3000 +shotWidth: 400 +*/ +$.get(ROOT_PATH + '/data/asset/geo/Map_of_Iceland.svg', function (svg) { + echarts.registerMap('iceland_svg', { svg: svg }); + option = { + tooltip: {}, + geo: { + tooltip: { + show: true + }, + map: 'iceland_svg', + roam: true + }, + series: { + type: 'custom', + coordinateSystem: 'geo', + geoIndex: 0, + zlevel: 1, + data: [ + [488.2358421078053, 459.70913833075736, 100], + [770.3415644319939, 757.9672194986475, 30], + [1180.0329284196291, 743.6141808346214, 80], + [894.03790632245, 1188.1985153835008, 61], + [1372.98925630313, 477.3839988649537, 70], + [1378.62251255796, 935.6708486282843, 81] + ], + renderItem(params, api) { + const coord = api.coord([ + api.value(0, params.dataIndex), + api.value(1, params.dataIndex) + ]); + const circles = []; + for (let i = 0; i < 5; i++) { + circles.push({ + type: 'circle', + shape: { + cx: 0, + cy: 0, + r: 30 + }, + style: { + stroke: 'red', + fill: 'none', + lineWidth: 2 + }, + // Ripple animation + keyframeAnimation: { + duration: 4000, + loop: true, + delay: (-i / 4) * 4000, + keyframes: [ + { + percent: 0, + scaleX: 0, + scaleY: 0, + style: { + opacity: 1 + } + }, + { + percent: 1, + scaleX: 1, + scaleY: 0.4, + style: { + opacity: 0 + } + } + ] + } + }); + } + return { + type: 'group', + x: coord[0], + y: coord[1], + children: [ + ...circles, + { + type: 'path', + shape: { + d: 'M16 0c-5.523 0-10 4.477-10 10 0 10 10 22 10 22s10-12 10-22c0-5.523-4.477-10-10-10zM16 16c-3.314 0-6-2.686-6-6s2.686-6 6-6 6 2.686 6 6-2.686 6-6 6z', + x: -10, + y: -35, + width: 20, + height: 40 + }, + style: { + fill: 'red' + }, + // Jump animation. + keyframeAnimation: { + duration: 1000, + loop: true, + delay: Math.random() * 1000, + keyframes: [ + { + y: -10, + percent: 0.5, + easing: 'cubicOut' + }, + { + y: 0, + percent: 1, + easing: 'bounceOut' + } + ] + } + } + ] + }; + } + } + }; + myChart.setOption(option); +}); +export {}; diff --git a/testdata/geo-svg-lines.js b/testdata/geo-svg-lines.js new file mode 100644 index 0000000..45e00b1 --- /dev/null +++ b/testdata/geo-svg-lines.js @@ -0,0 +1,83 @@ +/* +title: GEO SVG Lines +category: map +titleCN: GEO 路径图(SVG) +*/ +$.get(ROOT_PATH + '/data/asset/geo/MacOdrum-LV5-floorplan-web.svg', function (svg) { + echarts.registerMap('MacOdrum-LV5-floorplan-web', { svg: svg }); + option = { + title: { + text: 'Visit Route', + left: 'center', + bottom: 10 + }, + tooltip: {}, + geo: { + map: 'MacOdrum-LV5-floorplan-web', + roam: true, + emphasis: { + itemStyle: { + color: undefined + }, + label: { + show: false + } + } + }, + series: [ + { + name: 'Route', + type: 'lines', + coordinateSystem: 'geo', + geoIndex: 0, + emphasis: { + label: { + show: false + } + }, + polyline: true, + lineStyle: { + color: '#c46e54', + width: 5, + opacity: 1, + type: 'dotted' + }, + effect: { + show: true, + period: 8, + color: '#a10000', + constantSpeed: 80, + trailLength: 0, + symbolSize: [20, 12], + symbol: 'path://M35.5 40.5c0-22.16 17.84-40 40-40s40 17.84 40 40c0 1.6939-.1042 3.3626-.3067 5H35.8067c-.2025-1.6374-.3067-3.3061-.3067-5zm90.9621-2.6663c-.62-1.4856-.9621-3.1182-.9621-4.8337 0-6.925 5.575-12.5 12.5-12.5s12.5 5.575 12.5 12.5a12.685 12.685 0 0 1-.1529 1.9691l.9537.5506-15.6454 27.0986-.1554-.0897V65.5h-28.7285c-7.318 9.1548-18.587 15-31.2715 15s-23.9535-5.8452-31.2715-15H15.5v-2.8059l-.0937.0437-8.8727-19.0274C2.912 41.5258.5 37.5549.5 33c0-6.925 5.575-12.5 12.5-12.5S25.5 26.075 25.5 33c0 .9035-.0949 1.784-.2753 2.6321L29.8262 45.5h92.2098z' + }, + data: [ + { + coords: [ + [110.6189462165178, 456.64349563895087], + [124.10988522879458, 450.8570048730469], + [123.9272226116071, 389.9520693708147], + [61.58708083147317, 386.87942320312504], + [61.58708083147317, 72.8954315876116], + [258.29514854771196, 72.8954315876116], + [260.75457021484374, 336.8559607533482], + [280.5277985253906, 410.2406672084263], + [275.948185765904, 528.0254369698661], + [111.06907909458701, 552.795792593471], + [118.87138231445309, 701.365737015904], + [221.36468155133926, 758.7870354617745], + [307.86195445452006, 742.164737297712], + [366.8489324762834, 560.9895157073103], + [492.8750778390066, 560.9895157073103], + [492.8750778390066, 827.9639780566406], + [294.9255269587053, 827.9639780566406], + [282.79803391043527, 868.2476088113839] + ] + } + ] + } + ] + }; + myChart.setOption(option); +}); +export {}; diff --git a/testdata/geo-svg-map.js b/testdata/geo-svg-map.js new file mode 100644 index 0000000..f0c8ce5 --- /dev/null +++ b/testdata/geo-svg-map.js @@ -0,0 +1,204 @@ +/* +title: GEO SVG Map +category: map +titleCN: 地图(SVG) +*/ +$.get(ROOT_PATH + '/data/asset/geo/Sicily_prehellenic_topographic_map.svg', function (svg) { + echarts.registerMap('sicily', { svg: svg }); + option = { + tooltip: { + formatter: function (params) { + console.log(params); + return [ + params.name + ':', + 'xxxxxxxxxxxxxxxx', + 'xxxxxxxxxxxxxxxx', + 'xxxxxxxxxxxxxxxx' + ].join('
'); + } + }, + geo: [ + { + map: 'sicily', + roam: true, + layoutCenter: ['50%', '50%'], + layoutSize: '100%', + selectedMode: 'single', + tooltip: { + show: true, + confine: true, + formatter: function (params) { + return [ + 'This is the introduction:', + 'xxxxxxxxxxxxxxxxxxxxx', + 'xxxxxxxxxxxxxxxxxxxxx', + 'xxxxxxxxxxxxxxxxxxxxx', + 'xxxxxxxxxxxxxxxxxxxxx', + 'xxxxxxxxxxxxxxxxxxxxx', + 'xxxxxxxxxxxxxxxxxxxxx', + 'xxxxxxxxxxxxxxxxxxxxx', + 'xxxxxxxxxxxxxxxxxxxxx', + 'xxxxxxxxxxxxxxxxxxxxx', + 'xxxxxxxxxxxxxxxxxxxxx' + ].join('
'); + } + }, + itemStyle: { + color: undefined + }, + emphasis: { + label: { + show: false + } + }, + select: { + itemStyle: { + color: '#b50205' + }, + label: { + show: false + } + }, + regions: [ + { + name: 'route1', + itemStyle: { + borderWidth: 0 + }, + select: { + itemStyle: { + color: '#b5280d', + borderWidth: 0 + } + }, + tooltip: { + position: 'right', + alwaysShowContent: true, + enterable: true, + extraCssText: 'user-select: text', + formatter: [ + 'Route 1:', + 'xxxxxxxxxxxxxxxxxxxxxxxxxxx', + 'xxxxxxxxxxxxxxxxxxxxxxxxxxx', + 'xxxxxxxxxxxxxxxxxxxxxxxxxxx', + 'xxxxxxxxxxxxxxxxxxxxxxxxxxx', + 'xxxxxxxxxxxxxxxxxxxxxxxxxxx' + ].join('
') + } + }, + { + name: 'route2', + itemStyle: { + borderWidth: 0 + }, + select: { + itemStyle: { + color: '#b5280d', + borderWidth: 0 + } + }, + tooltip: { + position: 'left', + alwaysShowContent: true, + enterable: true, + extraCssText: 'user-select: text', + formatter: [ + 'Route 2:', + 'xxxxxxxxxxxxxx', + 'xxxxxxxxxxxxxx', + 'xxxxxxxxxxxxxx', + 'xxxxxxxxxxxxxx', + 'xxxxxxxxxxxxxx', + 'xxxxxxxxxxxxxx', + 'xxxxxxxxxxxxxx', + 'xxxxxxxxxxxxxx' + ].join('
') + } + } + ] + } + ], + // ------------- + // Make buttons + grid: { + top: 10, + left: 'center', + width: 80, + height: 20 + }, + xAxis: { + axisLine: { show: false }, + splitLine: { show: false }, + axisLabel: { show: false }, + axisTick: { show: false } + }, + yAxis: { + axisLine: { show: false }, + splitLine: { show: false }, + axisLabel: { show: false }, + axisTick: { show: false } + }, + series: { + type: 'scatter', + itemStyle: {}, + label: { + show: true, + borderColor: '#999', + borderWidth: 1, + borderRadius: 2, + backgroundColor: '#fff', + padding: [3, 5], + fontSize: 18, + opacity: 1, + color: '#333' + }, + encode: { + label: 2 + }, + symbolSize: 0, + tooltip: { show: false }, + selectedMode: 'single', + select: { + label: { + color: '#fff', + borderColor: '#555', + backgroundColor: '#555' + } + }, + data: [ + [0, 0, 'route1'], + [1, 0, 'route2'] + ] + } + // Make buttons end + // ----------------- + }; + myChart.setOption(option); + myChart.on('selectchanged', function (params) { + if (!params.selected.length) { + myChart.dispatchAction({ + type: 'hideTip' + }); + myChart.dispatchAction({ + type: 'geoSelect', + geoIndex: 0 + // Use no name to unselect. + }); + } + else { + var btnDataIdx = params.selected[0].dataIndex[0]; + var name = option.series.data[btnDataIdx][2]; + myChart.dispatchAction({ + type: 'geoSelect', + geoIndex: 0, + name: name + }); + myChart.dispatchAction({ + type: 'showTip', + geoIndex: 0, + name: name + }); + } + }); +}); +export {}; diff --git a/testdata/geo-svg-scatter-simple.js b/testdata/geo-svg-scatter-simple.js new file mode 100644 index 0000000..2fc410d --- /dev/null +++ b/testdata/geo-svg-scatter-simple.js @@ -0,0 +1,47 @@ +/* +title: GEO SVG Scatter +category: map +titleCN: 散点图(SVG) +*/ +$.get(ROOT_PATH + '/data/asset/geo/Map_of_Iceland.svg', function (svg) { + echarts.registerMap('iceland_svg', { svg: svg }); + option = { + tooltip: {}, + geo: { + tooltip: { + show: true + }, + map: 'iceland_svg', + roam: true + }, + series: { + type: 'effectScatter', + coordinateSystem: 'geo', + geoIndex: 0, + symbolSize: function (params) { + return (params[2] / 100) * 15 + 5; + }, + itemStyle: { + color: '#b02a02' + }, + encode: { + tooltip: 2 + }, + data: [ + [488.2358421078053, 459.70913833075736, 100], + [770.3415644319939, 757.9672194986475, 30], + [1180.0329284196291, 743.6141808346214, 80], + [894.03790632245, 1188.1985153835008, 61], + [1372.98925630313, 477.3839988649537, 70], + [1378.62251255796, 935.6708486282843, 81] + ] + } + }; + myChart.setOption(option); + myChart.getZr().on('click', function (params) { + var pixelPoint = [params.offsetX, params.offsetY]; + var dataPoint = myChart.convertFromPixel({ geoIndex: 0 }, pixelPoint); + console.log(dataPoint); + }); +}); +export {}; diff --git a/testdata/geo-svg-traffic.js b/testdata/geo-svg-traffic.js new file mode 100644 index 0000000..62b9c6a --- /dev/null +++ b/testdata/geo-svg-traffic.js @@ -0,0 +1,167 @@ +/* +title: GEO SVG Traffic +category: map +titleCN: 交通(SVG) +*/ +$.get(ROOT_PATH + '/data/asset/geo/ksia-ext-plan-min.svg', function (svg) { + echarts.registerMap('ksia-ext-plan', { svg: svg }); + option = { + tooltip: {}, + geo: { + map: 'ksia-ext-plan', + roam: true, + layoutCenter: ['50%', '50%'], + layoutSize: '100%' + }, + series: [ + { + name: 'Route', + type: 'lines', + coordinateSystem: 'geo', + geoIndex: 0, + emphasis: { + label: { + show: false + } + }, + polyline: true, + lineStyle: { + color: '#c46e54', + width: 0 + }, + effect: { + show: true, + period: 8, + color: '#a10000', + // constantSpeed: 80, + trailLength: 0, + symbolSize: [12, 30], + symbol: 'path://M87.1667 3.8333L80.5.5h-60l-6.6667 3.3333L.5 70.5v130l10 10h80l10 -10v-130zM15.5 190.5l15 -20h40l15 20zm75 -65l-15 5v35l15 15zm-80 0l15 5v35l-15 15zm65 0l15 -5v-40l-15 20zm-50 0l-15 -5v-40l15 20zm 65,-55 -15,25 c -15,-5 -35,-5 -50,0 l -15,-25 c 25,-15 55,-15 80,0 z' + }, + z: 100, + data: [ + { + effect: { + color: '#a10000', + constantSpeed: 100, + delay: 0 + }, + coords: [ + [50.875133928571415, 242.66287667410717], + [62.03696428571425, 264.482421875], + [72.63357421874997, 273.62779017857144], + [92.78291852678569, 285.869140625], + [113.43637834821425, 287.21854073660717], + [141.44788783482142, 288.92947823660717], + [191.71686104910714, 289.5507114955357], + [198.3060072544643, 294.0673828125], + [204.99699497767858, 304.60288783482144], + [210.79177734375003, 316.7373046875], + [212.45179408482142, 329.3656529017857], + [210.8885267857143, 443.3925083705358], + [215.35936941964286, 453.00634765625], + [224.38761997767858, 452.15087890625], + [265.71490792410714, 452.20179966517856], + [493.3408844866072, 453.77525111607144], + [572.8892940848216, 448.77992466517856], + [608.9513755580358, 448.43366350446433], + [619.99099609375, 450.8778599330358], + [624.2479715401787, 456.2194475446429], + [628.1434095982145, 463.9899553571429], + [629.8492550223216, 476.0276227678571], + [631.2750362723216, 535.7322126116071], + [624.6757059151787, 546.6496233258929], + [617.1801702008929, 552.6480887276786], + [603.7269056919645, 554.5066964285714], + [588.0178515625, 557.5517578125], + [529.4386104910716, 556.2991071428571], + [422.1994921875001, 551.38525390625], + [291.66921875, 552.5767996651786], + [219.4279380580357, 547.4949079241071], + [209.53912667410714, 541.5931919642858], + [206.70793247767858, 526.1947544642858], + [206.70793247767858, 507.4049944196429], + [206.12234375000003, 468.7663225446429], + [204.48778738839286, 459.44782366071433], + [197.56256417410714, 452.8943219866071], + [170.31995814732142, 456.27546037946433], + [1.8078906249999704, 460.5935407366071] + ] + }, + { + effect: { + color: '#00067d', + constantSpeed: 80, + delay: 0 + }, + coords: [ + [779.4595368303574, 287.98744419642856], + [689.07009765625, 291.0477818080357], + [301.83300223214286, 290.49783761160717], + [229.31165736607142, 291.73011997767856], + [220.73660156250003, 297.4077845982143], + [214.74832031250003, 308.52378627232144], + [213.82156250000003, 421.35400390625], + [213.19523716517858, 443.0564313616071], + [222.31005301339286, 455.95465959821433], + [271.71846540178575, 454.37611607142856], + [359.64843191964286, 455.9393833705358], + [580.2524358258929, 448.11286272321433], + [627.7156752232145, 460.7463030133929], + [632.3290959821429, 536.6386021205358], + [628.9123130580358, 548.4776785714286], + [612.5667494419645, 556.8235909598214], + [543.7167912946429, 555.4741908482143], + [429.1756361607143, 551.9402901785714], + [293.42089285714286, 551.2172154017858], + [226.20039899553575, 556.0699637276786], + [215.49176339285714, 562.7253069196429], + [213.21051339285714, 591.6024693080358], + [212.00878348214286, 625.6735491071429], + [197.43017020089286, 645.0743582589286], + [187.41405691964286, 647.0857282366071], + [101.79589285714286, 649.0207170758929], + [69.96023437499997, 650.1613420758929], + [56.48150948660714, 656.8268694196429], + [51.11446149553569, 665.2542550223214] + ] + }, + { + effect: { + color: '#997405', + constantSpeed: 60, + delay: 0 + }, + coords: [ + [2.5920703124999704, 450.66908482142856], + [204.0651450892857, 453.13364955357144], + [378.72844029017864, 453.13874162946433], + [551.1817745535716, 456.1532505580358], + [578.3734598214287, 456.91196986607144], + [601.2317885044645, 458.9895368303571], + [614.1503850446429, 462.1669921875], + [618.99294921875, 479.68882533482144], + [620.0826534598216, 513.5969587053571], + [615.6932840401787, 528.7306082589286], + [608.4829045758929, 533.2625558035714], + [592.7127455357145, 534.9582170758929], + [583.09890625, 527.5492466517858], + [578.6535239955358, 516.4077845982143], + [578.6535239955358, 498.36146763392856], + [577.9966462053571, 477.0613141741071], + [575.3691350446429, 469.1940569196429], + [569.0753292410716, 462.63037109375], + [553.9518638392858, 460.6444614955358], + [298.10051060267864, 465.61432756696433], + [193.49908761160714, 460.1759905133929], + [116.40505859374997, 465.78236607142856], + [3.5137360491071092, 463.47565569196433] + ] + } + ] + } + ] + }; + myChart.setOption(option); +}); +export {}; diff --git a/testdata/graph-circular-layout.js b/testdata/graph-circular-layout.js new file mode 100644 index 0000000..bcb78fb --- /dev/null +++ b/testdata/graph-circular-layout.js @@ -0,0 +1,58 @@ +/* +title: Les Miserables +category: graph +titleCN: 悲惨世界人物关系图(环形布局) +shotWidth: 900 +difficulty: 5 +*/ +myChart.showLoading(); +$.getJSON(ROOT_PATH + '/data/asset/data/les-miserables.json', function (graph) { + myChart.hideLoading(); + graph.nodes.forEach(function (node) { + node.label = { + show: node.symbolSize > 30 + }; + }); + option = { + title: { + text: 'Les Miserables', + subtext: 'Circular layout', + top: 'bottom', + left: 'right' + }, + tooltip: {}, + legend: [ + { + data: graph.categories.map(function (a) { + return a.name; + }) + } + ], + animationDurationUpdate: 1500, + animationEasingUpdate: 'quinticInOut', + series: [ + { + name: 'Les Miserables', + type: 'graph', + layout: 'circular', + circular: { + rotateLabel: true + }, + data: graph.nodes, + links: graph.links, + categories: graph.categories, + roam: true, + label: { + position: 'right', + formatter: '{b}' + }, + lineStyle: { + color: 'source', + curveness: 0.3 + } + } + ] + }; + myChart.setOption(option); +}); +export {}; diff --git a/testdata/graph-force-dynamic.js b/testdata/graph-force-dynamic.js new file mode 100644 index 0000000..452cd47 --- /dev/null +++ b/testdata/graph-force-dynamic.js @@ -0,0 +1,59 @@ +/* +title: Graph Dynamic +category: graph +shotDelay: 5000 +titleCN: 动态增加图节点 +difficulty: 6 +*/ +const data = [ + { + fixed: true, + x: myChart.getWidth() / 2, + y: myChart.getHeight() / 2, + symbolSize: 20, + id: '-1' + } +]; +const edges = []; +option = { + series: [ + { + type: 'graph', + layout: 'force', + animation: false, + data: data, + force: { + // initLayout: 'circular' + // gravity: 0 + repulsion: 100, + edgeLength: 5 + }, + edges: edges + } + ] +}; +setInterval(function () { + data.push({ + id: data.length + '' + }); + var source = Math.round((data.length - 1) * Math.random()); + var target = Math.round((data.length - 1) * Math.random()); + if (source !== target) { + edges.push({ + source: source, + target: target + }); + } + myChart.setOption({ + series: [ + { + roam: true, + data: data, + edges: edges + } + ] + }); + // console.log('nodes: ' + data.length); + // console.log('links: ' + data.length); +}, 200); +export {}; diff --git a/testdata/graph-force.js b/testdata/graph-force.js new file mode 100644 index 0000000..fe57890 --- /dev/null +++ b/testdata/graph-force.js @@ -0,0 +1,49 @@ +/* +title: Force Layout +category: graph +titleCN: 力引导布局 +difficulty: 3 +*/ +myChart.showLoading(); +$.get(ROOT_PATH + '/data/asset/data/les-miserables.json', function (graph) { + myChart.hideLoading(); + graph.nodes.forEach(function (node) { + node.symbolSize = 5; + }); + option = { + title: { + text: 'Les Miserables', + subtext: 'Default layout', + top: 'bottom', + left: 'right' + }, + tooltip: {}, + legend: [ + { + // selectedMode: 'single', + data: graph.categories.map(function (a) { + return a.name; + }) + } + ], + series: [ + { + name: 'Les Miserables', + type: 'graph', + layout: 'force', + data: graph.nodes, + links: graph.links, + categories: graph.categories, + roam: true, + label: { + position: 'right' + }, + force: { + repulsion: 100 + } + } + ] + }; + myChart.setOption(option); +}); +export {}; diff --git a/testdata/graph-force2.js b/testdata/graph-force2.js new file mode 100644 index 0000000..0f18254 --- /dev/null +++ b/testdata/graph-force2.js @@ -0,0 +1,59 @@ +/* +title: Force Layout +category: graph +titleCN: 力引导布局 +difficulty: 1 +*/ +function createNodes(count) { + var nodes = []; + for (var i = 0; i < count; i++) { + nodes.push({ + id: i + '' + }); + } + return nodes; +} +function createEdges(count) { + var edges = []; + if (count === 2) { + return [[0, 1]]; + } + for (var i = 0; i < count; i++) { + edges.push([i, (i + 1) % count]); + } + return edges; +} +var datas = []; +for (var i = 0; i < 16; i++) { + datas.push({ + nodes: createNodes(i + 2), + edges: createEdges(i + 2) + }); +} +option = { + series: datas.map(function (item, idx) { + return { + type: 'graph', + layout: 'force', + animation: false, + data: item.nodes, + left: (idx % 4) * 25 + '%', + top: Math.floor(idx / 4) * 25 + '%', + width: '25%', + height: '25%', + force: { + // initLayout: 'circular' + // gravity: 0 + repulsion: 60, + edgeLength: 2 + }, + edges: item.edges.map(function (e) { + return { + source: e[0] + '', + target: e[1] + '' + }; + }) + }; + }) +}; +export {}; diff --git a/testdata/graph-force2.js.svg b/testdata/graph-force2.js.svg new file mode 100644 index 0000000..454e309 --- /dev/null +++ b/testdata/graph-force2.js.svg @@ -0,0 +1,306 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/graph-grid.js b/testdata/graph-grid.js new file mode 100644 index 0000000..e7ca4ed --- /dev/null +++ b/testdata/graph-grid.js @@ -0,0 +1,50 @@ +/* +title: Graph on Cartesian +category: graph +titleCN: 笛卡尔坐标系上的 Graph +difficulty: 2 +*/ +const axisData = ['Mon', 'Tue', 'Wed', 'Very Loooong Thu', 'Fri', 'Sat', 'Sun']; +const data = axisData.map(function (item, i) { + return Math.round(Math.random() * 1000 * (i + 1)); +}); +const links = data.map(function (item, i) { + return { + source: i, + target: i + 1 + }; +}); +links.pop(); +option = { + title: { + text: 'Graph on Cartesian' + }, + tooltip: {}, + xAxis: { + type: 'category', + boundaryGap: false, + data: axisData + }, + yAxis: { + type: 'value' + }, + series: [ + { + type: 'graph', + layout: 'none', + coordinateSystem: 'cartesian2d', + symbolSize: 40, + label: { + show: true + }, + edgeSymbol: ['circle', 'arrow'], + edgeSymbolSize: [4, 10], + data: data, + links: links, + lineStyle: { + color: '#2f4554' + } + } + ] +}; +export {}; diff --git a/testdata/graph-grid.js.svg b/testdata/graph-grid.js.svg new file mode 100644 index 0000000..6cb28e9 --- /dev/null +++ b/testdata/graph-grid.js.svg @@ -0,0 +1,151 @@ + + + + + + + + + + + + +0 +1,000 +2,000 +3,000 +4,000 +Mon +Wed +Fri +Sun + + + + + + + + + + + + + + + + + + + + + + + + + +Mon +Tue +Wed +Very Loooong Thu +Fri +Sat +Sun + +Graph on Cartesian + + \ No newline at end of file diff --git a/testdata/graph-label-overlap.js b/testdata/graph-label-overlap.js new file mode 100644 index 0000000..165e238 --- /dev/null +++ b/testdata/graph-label-overlap.js @@ -0,0 +1,49 @@ +/* +title: Hide Overlapped Label +category: graph +titleCN: 关系图自动隐藏重叠标签 +difficulty: 3 +*/ +myChart.showLoading(); +$.getJSON(ROOT_PATH + '/data/asset/data/les-miserables.json', function (graph) { + myChart.hideLoading(); + option = { + tooltip: {}, + legend: [ + { + data: graph.categories.map(function (a) { + return a.name; + }) + } + ], + series: [ + { + name: 'Les Miserables', + type: 'graph', + layout: 'none', + data: graph.nodes, + links: graph.links, + categories: graph.categories, + roam: true, + label: { + show: true, + position: 'right', + formatter: '{b}' + }, + labelLayout: { + hideOverlap: true + }, + scaleLimit: { + min: 0.4, + max: 2 + }, + lineStyle: { + color: 'source', + curveness: 0.3 + } + } + ] + }; + myChart.setOption(option); +}); +export {}; diff --git a/testdata/graph-life-expectancy.js b/testdata/graph-life-expectancy.js new file mode 100644 index 0000000..52f2836 --- /dev/null +++ b/testdata/graph-life-expectancy.js @@ -0,0 +1,98 @@ +/* +title: Graph Life Expectancy +category: graph +titleCN: Graph Life Expectancy +difficulty: 7 +*/ +$.get(ROOT_PATH + '/data/asset/data/life-expectancy.json', function (rawData) { + const series = []; + rawData.counties.forEach(function (country) { + const data = rawData.series.map(function (yearData) { + const item = yearData.filter(function (item) { + return item[3] === country; + })[0]; + return { + label: { + show: +item[4] % 20 === 0 && +item[4] > 1940, + position: 'top' + }, + emphasis: { + label: { + show: true + } + }, + name: item[4], + value: item + }; + }); + var links = data.map(function (item, idx) { + return { + source: idx, + target: idx + 1 + }; + }); + links.pop(); + series.push({ + name: country, + type: 'graph', + coordinateSystem: 'cartesian2d', + data: data, + links: links, + edgeSymbol: ['none', 'arrow'], + edgeSymbolSize: 5, + legendHoverLink: false, + lineStyle: { + color: '#333' + }, + itemStyle: { + borderWidth: 1, + borderColor: '#333' + }, + label: { + color: '#333', + position: 'right' + }, + symbolSize: 10, + animationDelay: function (idx) { + return idx * 100; + } + }); + }); + option = { + visualMap: { + show: false, + min: 0, + max: 100, + dimension: 1 + }, + legend: { + data: rawData.counties, + selectedMode: 'single', + right: 100 + }, + grid: { + left: 0, + bottom: 0, + containLabel: true, + top: 80 + }, + xAxis: { + type: 'value' + }, + yAxis: { + type: 'value', + scale: true + }, + toolbox: { + feature: { + dataZoom: {} + } + }, + dataZoom: { + type: 'inside' + }, + series: series + }; + myChart.setOption(option); +}); +export {}; diff --git a/testdata/graph-npm.js b/testdata/graph-npm.js new file mode 100644 index 0000000..942a486 --- /dev/null +++ b/testdata/graph-npm.js @@ -0,0 +1,56 @@ +/* +title: NPM Dependencies +category: graph +titleCN: NPM 依赖关系图 +difficulty: 9 +*/ +myChart.showLoading(); +$.getJSON(ROOT_PATH + '/data/asset/data/npmdepgraph.min10.json', function (json) { + myChart.hideLoading(); + myChart.setOption((option = { + title: { + text: 'NPM Dependencies' + }, + animationDurationUpdate: 1500, + animationEasingUpdate: 'quinticInOut', + series: [ + { + type: 'graph', + layout: 'none', + // progressiveThreshold: 700, + data: json.nodes.map(function (node) { + return { + x: node.x, + y: node.y, + id: node.id, + name: node.label, + symbolSize: node.size, + itemStyle: { + color: node.color + } + }; + }), + edges: json.edges.map(function (edge) { + return { + source: edge.sourceID, + target: edge.targetID + }; + }), + emphasis: { + focus: 'adjacency', + label: { + position: 'right', + show: true + } + }, + roam: true, + lineStyle: { + width: 0.5, + curveness: 0.3, + opacity: 0.7 + } + } + ] + }), true); +}); +export {}; diff --git a/testdata/graph-simple.js b/testdata/graph-simple.js new file mode 100644 index 0000000..62c0b9d --- /dev/null +++ b/testdata/graph-simple.js @@ -0,0 +1,99 @@ +/* +title: Simple Graph +category: graph +titleCN: Graph 简单示例 +difficulty: 2 +*/ +option = { + title: { + text: 'Basic Graph' + }, + tooltip: {}, + animationDurationUpdate: 1500, + animationEasingUpdate: 'quinticInOut', + series: [ + { + type: 'graph', + layout: 'none', + symbolSize: 50, + roam: true, + label: { + show: true + }, + edgeSymbol: ['circle', 'arrow'], + edgeSymbolSize: [4, 10], + edgeLabel: { + fontSize: 20 + }, + data: [ + { + name: 'Node 1', + x: 300, + y: 300 + }, + { + name: 'Node 2', + x: 800, + y: 300 + }, + { + name: 'Node 3', + x: 550, + y: 100 + }, + { + name: 'Node 4', + x: 550, + y: 500 + } + ], + // links: [], + links: [ + { + source: 0, + target: 1, + symbolSize: [5, 20], + label: { + show: true + }, + lineStyle: { + width: 5, + curveness: 0.2 + } + }, + { + source: 'Node 2', + target: 'Node 1', + label: { + show: true + }, + lineStyle: { + curveness: 0.2 + } + }, + { + source: 'Node 1', + target: 'Node 3' + }, + { + source: 'Node 2', + target: 'Node 3' + }, + { + source: 'Node 2', + target: 'Node 4' + }, + { + source: 'Node 1', + target: 'Node 4' + } + ], + lineStyle: { + opacity: 0.9, + width: 2, + curveness: 0 + } + } + ] +}; +export {}; diff --git a/testdata/graph-simple.js.svg b/testdata/graph-simple.js.svg new file mode 100644 index 0000000..c8ece39 --- /dev/null +++ b/testdata/graph-simple.js.svg @@ -0,0 +1,89 @@ + + + + + + + + + + + + + + + + + + + + + + + + +Node 1 +Node 2 +Node 3 +Node 4 +0 > 1 +Node 2 > Node 1 + +Basic Graph + + \ No newline at end of file diff --git a/testdata/graph-webkit-dep.js b/testdata/graph-webkit-dep.js new file mode 100644 index 0000000..11f427b --- /dev/null +++ b/testdata/graph-webkit-dep.js @@ -0,0 +1,42 @@ +/* +title: Graph Webkit Dep +category: graph +titleCN: WebKit 模块关系依赖图 +shotWidth: 900 +difficulty: 8 +*/ +myChart.showLoading(); +myChart.showLoading(); +$.get(ROOT_PATH + '/data/asset/data/webkit-dep.json', function (webkitDep) { + myChart.hideLoading(); + option = { + legend: { + data: ['HTMLElement', 'WebGL', 'SVG', 'CSS', 'Other'] + }, + series: [ + { + type: 'graph', + layout: 'force', + animation: false, + label: { + position: 'right', + formatter: '{b}' + }, + draggable: true, + data: webkitDep.nodes.map(function (node, idx) { + node.id = idx; + return node; + }), + categories: webkitDep.categories, + force: { + edgeLength: 5, + repulsion: 20, + gravity: 0.2 + }, + edges: webkitDep.links + } + ] + }; + myChart.setOption(option); +}); +export {}; diff --git a/testdata/graph.js b/testdata/graph.js new file mode 100644 index 0000000..fa64939 --- /dev/null +++ b/testdata/graph.js @@ -0,0 +1,61 @@ +/* +title: Les Miserables +category: graph +titleCN: 悲惨世界人物关系图 +difficulty: 4 +*/ +myChart.showLoading(); +$.getJSON(ROOT_PATH + '/data/asset/data/les-miserables.json', function (graph) { + myChart.hideLoading(); + graph.nodes.forEach(function (node) { + node.label = { + show: node.symbolSize > 30 + }; + }); + option = { + title: { + text: 'Les Miserables', + subtext: 'Default layout', + top: 'bottom', + left: 'right' + }, + tooltip: {}, + legend: [ + { + // selectedMode: 'single', + data: graph.categories.map(function (a) { + return a.name; + }) + } + ], + animationDuration: 1500, + animationEasingUpdate: 'quinticInOut', + series: [ + { + name: 'Les Miserables', + type: 'graph', + layout: 'none', + data: graph.nodes, + links: graph.links, + categories: graph.categories, + roam: true, + label: { + position: 'right', + formatter: '{b}' + }, + lineStyle: { + color: 'source', + curveness: 0.3 + }, + emphasis: { + focus: 'adjacency', + lineStyle: { + width: 10 + } + } + } + ] + }; + myChart.setOption(option); +}); +export {}; diff --git a/testdata/graphic-loading.js b/testdata/graphic-loading.js new file mode 100644 index 0000000..0a37f2d --- /dev/null +++ b/testdata/graphic-loading.js @@ -0,0 +1,51 @@ +"use strict"; +/* +title: Customized Loading Animation +category: graphic +titleCN: 加载动画 +difficulty: 6 +videoStart: 1000 +videoEnd: 3200 +shotWidth: 400 +*/ +option = { + graphic: { + elements: [ + { + type: 'group', + left: 'center', + top: 'center', + children: new Array(7).fill(0).map((val, i) => ({ + type: 'rect', + x: i * 20, + shape: { + x: 0, + y: -40, + width: 10, + height: 80 + }, + style: { + fill: '#5470c6' + }, + keyframeAnimation: { + duration: 1000, + delay: i * 200, + loop: true, + keyframes: [ + { + percent: 0.5, + scaleY: 0.3, + easing: 'cubicIn' + }, + { + percent: 1, + scaleY: 1, + easing: 'cubicOut' + } + ] + } + })) + } + ] + } +}; diff --git a/testdata/graphic-loading.js.svg b/testdata/graphic-loading.js.svg new file mode 100644 index 0000000..9104da6 --- /dev/null +++ b/testdata/graphic-loading.js.svg @@ -0,0 +1,10 @@ + + + + + + + + + + \ No newline at end of file diff --git a/testdata/graphic-stroke-animation.js b/testdata/graphic-stroke-animation.js new file mode 100644 index 0000000..663027d --- /dev/null +++ b/testdata/graphic-stroke-animation.js @@ -0,0 +1,57 @@ +"use strict"; +/* +title: Stroke Animation +category: graphic +titleCN: 关键帧描边动画 +difficulty: 5 +videoStart: 1000 +videoEnd: 3000 +*/ +option = { + graphic: { + elements: [ + { + type: 'text', + left: 'center', + top: 'center', + style: { + text: 'Apache ECharts', + fontSize: 80, + fontWeight: 'bold', + lineDash: [0, 200], + lineDashOffset: 0, + fill: 'transparent', + stroke: '#000', + lineWidth: 1 + }, + keyframeAnimation: { + duration: 3000, + loop: true, + keyframes: [ + { + percent: 0.7, + style: { + fill: 'transparent', + lineDashOffset: 200, + lineDash: [200, 0] + } + }, + { + // Stop for a while. + percent: 0.8, + style: { + fill: 'transparent' + } + }, + { + percent: 1, + style: { + fill: 'black' + } + } + ] + } + } + ] + } +}; diff --git a/testdata/graphic-stroke-animation.js.svg b/testdata/graphic-stroke-animation.js.svg new file mode 100644 index 0000000..5298e0a --- /dev/null +++ b/testdata/graphic-stroke-animation.js.svg @@ -0,0 +1,4 @@ + + +Apache ECharts + \ No newline at end of file diff --git a/testdata/graphic-wave-animation.js b/testdata/graphic-wave-animation.js new file mode 100644 index 0000000..f7ce98d --- /dev/null +++ b/testdata/graphic-wave-animation.js @@ -0,0 +1,198 @@ +/* +title: Wave Animation +category: graphic +titleCN: +difficulty: 10 +videoStart: 1000 +videoEnd: 5000 +shotWidth: 1000 +*/ +let noise = getNoiseHelper(); +let config = (app.config = { + frequency: 500, + offsetX: 0, + offsetY: 100, + minSize: 5, + maxSize: 22, + duration: 4000, + color0: '#fff', + color1: '#000', + backgroundColor: '#fff', + onChange() { + myChart.setOption({ + backgroundColor: config.backgroundColor, + graphic: { + elements: createElements() + } + }); + } +}); +noise.seed(Math.random()); +function createElements() { + const elements = []; + for (let x = 20; x < myChart.getWidth(); x += 40) { + for (let y = 20; y < myChart.getHeight(); y += 40) { + const rand = noise.perlin2(x / config.frequency + config.offsetX, y / config.frequency + config.offsetY); + elements.push({ + type: 'circle', + x, + y, + style: { + fill: config.color1 + }, + shape: { + r: config.maxSize + }, + keyframeAnimation: { + duration: config.duration, + loop: true, + delay: (rand - 1) * 4000, + keyframes: [ + { + percent: 0.5, + easing: 'sinusoidalInOut', + style: { + fill: config.color0 + }, + scaleX: config.minSize / config.maxSize, + scaleY: config.minSize / config.maxSize + }, + { + percent: 1, + easing: 'sinusoidalInOut', + style: { + fill: config.color1 + }, + scaleX: 1, + scaleY: 1 + } + ] + } + }); + } + } + return elements; +} +option = { + backgroundColor: config.backgroundColor, + graphic: { + elements: createElements() + } +}; +app.configParameters = { + frequency: { min: 10, max: 1000 }, + offsetX: { min: 0, max: 1000 }, + offsetY: { min: 0, max: 1000 }, + minSize: { min: 0, max: 100 }, + maxSize: { min: 0, max: 100 }, + duration: { min: 100, max: 100000 } +}; +/////////////////////////////////////////////////////////////////////////// +// Simplex and perlin noise helper from https://github.com/josephg/noisejs +/////////////////////////////////////////////////////////////////////////// +function getNoiseHelper() { + class Grad { + constructor(x, y, z) { + this.x = x; + this.y = y; + this.z = z; + } + dot2(x, y) { + return this.x * x + this.y * y; + } + dot3(x, y, z) { + return this.x * x + this.y * y + this.z * z; + } + } + const grad3 = [ + new Grad(1, 1, 0), + new Grad(-1, 1, 0), + new Grad(1, -1, 0), + new Grad(-1, -1, 0), + new Grad(1, 0, 1), + new Grad(-1, 0, 1), + new Grad(1, 0, -1), + new Grad(-1, 0, -1), + new Grad(0, 1, 1), + new Grad(0, -1, 1), + new Grad(0, 1, -1), + new Grad(0, -1, -1) + ]; + const p = [ + 151, 160, 137, 91, 90, 15, 131, 13, 201, 95, 96, 53, 194, 233, 7, 225, 140, + 36, 103, 30, 69, 142, 8, 99, 37, 240, 21, 10, 23, 190, 6, 148, 247, 120, + 234, 75, 0, 26, 197, 62, 94, 252, 219, 203, 117, 35, 11, 32, 57, 177, 33, + 88, 237, 149, 56, 87, 174, 20, 125, 136, 171, 168, 68, 175, 74, 165, 71, + 134, 139, 48, 27, 166, 77, 146, 158, 231, 83, 111, 229, 122, 60, 211, 133, + 230, 220, 105, 92, 41, 55, 46, 245, 40, 244, 102, 143, 54, 65, 25, 63, 161, + 1, 216, 80, 73, 209, 76, 132, 187, 208, 89, 18, 169, 200, 196, 135, 130, + 116, 188, 159, 86, 164, 100, 109, 198, 173, 186, 3, 64, 52, 217, 226, 250, + 124, 123, 5, 202, 38, 147, 118, 126, 255, 82, 85, 212, 207, 206, 59, 227, + 47, 16, 58, 17, 182, 189, 28, 42, 223, 183, 170, 213, 119, 248, 152, 2, 44, + 154, 163, 70, 221, 153, 101, 155, 167, 43, 172, 9, 129, 22, 39, 253, 19, 98, + 108, 110, 79, 113, 224, 232, 178, 185, 112, 104, 218, 246, 97, 228, 251, 34, + 242, 193, 238, 210, 144, 12, 191, 179, 162, 241, 81, 51, 145, 235, 249, 14, + 239, 107, 49, 192, 214, 31, 181, 199, 106, 157, 184, 84, 204, 176, 115, 121, + 50, 45, 127, 4, 150, 254, 138, 236, 205, 93, 222, 114, 67, 29, 24, 72, 243, + 141, 128, 195, 78, 66, 215, 61, 156, 180 + ]; + // To remove the need for index wrapping, double the permutation table length + let perm = new Array(512); + let gradP = new Array(512); + // This isn't a very good seeding function, but it works ok. It supports 2^16 + // different seed values. Write something better if you need more seeds. + function seed(seed) { + if (seed > 0 && seed < 1) { + // Scale the seed out + seed *= 65536; + } + seed = Math.floor(seed); + if (seed < 256) { + seed |= seed << 8; + } + for (let i = 0; i < 256; i++) { + let v; + if (i & 1) { + v = p[i] ^ (seed & 255); + } + else { + v = p[i] ^ ((seed >> 8) & 255); + } + perm[i] = perm[i + 256] = v; + gradP[i] = gradP[i + 256] = grad3[v % 12]; + } + } + seed(0); + // ##### Perlin noise stuff + function fade(t) { + return t * t * t * (t * (t * 6 - 15) + 10); + } + function lerp(a, b, t) { + return (1 - t) * a + t * b; + } + // 2D Perlin Noise + function perlin2(x, y) { + // Find unit grid cell containing point + let X = Math.floor(x), Y = Math.floor(y); + // Get relative xy coordinates of point within that cell + x = x - X; + y = y - Y; + // Wrap the integer cells at 255 (smaller integer period can be introduced here) + X = X & 255; + Y = Y & 255; + // Calculate noise contributions from each of the four corners + let n00 = gradP[X + perm[Y]].dot2(x, y); + let n01 = gradP[X + perm[Y + 1]].dot2(x, y - 1); + let n10 = gradP[X + 1 + perm[Y]].dot2(x - 1, y); + let n11 = gradP[X + 1 + perm[Y + 1]].dot2(x - 1, y - 1); + // Compute the fade curve value for x + let u = fade(x); + // Interpolate the four results + return lerp(lerp(n00, n10, u), lerp(n01, n11, u), fade(y)); + } + return { + seed, + perlin2 + }; +} +export {}; diff --git a/testdata/grid-multiple.js b/testdata/grid-multiple.js new file mode 100644 index 0000000..b730065 --- /dev/null +++ b/testdata/grid-multiple.js @@ -0,0 +1,178 @@ +/* +title: Rainfall vs Evaporation +category: line +titleCN: 雨量Evaporation关系图 +difficulty: 4 +*/ +// prettier-ignore +let timeData = [ + '2009/6/12 2:00', '2009/6/12 3:00', '2009/6/12 4:00', '2009/6/12 5:00', '2009/6/12 6:00', '2009/6/12 7:00', '2009/6/12 8:00', '2009/6/12 9:00', '2009/6/12 10:00', '2009/6/12 11:00', '2009/6/12 12:00', '2009/6/12 13:00', '2009/6/12 14:00', '2009/6/12 15:00', '2009/6/12 16:00', '2009/6/12 17:00', '2009/6/12 18:00', '2009/6/12 19:00', '2009/6/12 20:00', '2009/6/12 21:00', '2009/6/12 22:00', '2009/6/12 23:00', + '2009/6/13 0:00', '2009/6/13 1:00', '2009/6/13 2:00', '2009/6/13 3:00', '2009/6/13 4:00', '2009/6/13 5:00', '2009/6/13 6:00', '2009/6/13 7:00', '2009/6/13 8:00', '2009/6/13 9:00', '2009/6/13 10:00', '2009/6/13 11:00', '2009/6/13 12:00', '2009/6/13 13:00', '2009/6/13 14:00', '2009/6/13 15:00', '2009/6/13 16:00', '2009/6/13 17:00', '2009/6/13 18:00', '2009/6/13 19:00', '2009/6/13 20:00', '2009/6/13 21:00', '2009/6/13 22:00', '2009/6/13 23:00', + '2009/6/14 0:00', '2009/6/14 1:00', '2009/6/14 2:00', '2009/6/14 3:00', '2009/6/14 4:00', '2009/6/14 5:00', '2009/6/14 6:00', '2009/6/14 7:00', '2009/6/14 8:00', '2009/6/14 9:00', '2009/6/14 10:00', '2009/6/14 11:00', '2009/6/14 12:00', '2009/6/14 13:00', '2009/6/14 14:00', '2009/6/14 15:00', '2009/6/14 16:00', '2009/6/14 17:00', '2009/6/14 18:00', '2009/6/14 19:00', '2009/6/14 20:00', '2009/6/14 21:00', '2009/6/14 22:00', '2009/6/14 23:00', + '2009/6/15 0:00', '2009/6/15 1:00', '2009/6/15 2:00', '2009/6/15 3:00', '2009/6/15 4:00', '2009/6/15 5:00', '2009/6/15 6:00', '2009/6/15 7:00', '2009/6/15 8:00', '2009/6/15 9:00', '2009/6/15 10:00', '2009/6/15 11:00', '2009/6/15 12:00', '2009/6/15 13:00', '2009/6/15 14:00', '2009/6/15 15:00', '2009/6/15 16:00', '2009/6/15 17:00', '2009/6/15 18:00', '2009/6/15 19:00', '2009/6/15 20:00', '2009/6/15 21:00', '2009/6/15 22:00', '2009/6/15 23:00', + '2009/6/15 0:00', '2009/6/16 1:00', '2009/6/16 2:00', '2009/6/16 3:00', '2009/6/16 4:00', '2009/6/16 5:00', '2009/6/16 6:00', '2009/6/16 7:00', '2009/6/16 8:00', '2009/6/16 9:00', '2009/6/16 10:00', '2009/6/16 11:00', '2009/6/16 12:00', '2009/6/16 13:00', '2009/6/16 14:00', '2009/6/16 15:00', '2009/6/16 16:00', '2009/6/16 17:00', '2009/6/16 18:00', '2009/6/16 19:00', '2009/6/16 20:00', '2009/6/16 21:00', '2009/6/16 22:00', '2009/6/16 23:00', + '2009/6/15 0:00', '2009/6/17 1:00', '2009/6/17 2:00', '2009/6/17 3:00', '2009/6/17 4:00', '2009/6/17 5:00', '2009/6/17 6:00', '2009/6/17 7:00', '2009/6/17 8:00', '2009/6/17 9:00', '2009/6/17 10:00', '2009/6/17 11:00', '2009/6/17 12:00', '2009/6/17 13:00', '2009/6/17 14:00', '2009/6/17 15:00', '2009/6/17 16:00', '2009/6/17 17:00', '2009/6/17 18:00', '2009/6/17 19:00', '2009/6/17 20:00', '2009/6/17 21:00', '2009/6/17 22:00', '2009/6/17 23:00', + '2009/6/18 0:00', '2009/6/18 1:00', '2009/6/18 2:00', '2009/6/18 3:00', '2009/6/18 4:00', '2009/6/18 5:00', '2009/6/18 6:00', '2009/6/18 7:00', '2009/6/18 8:00', '2009/6/18 9:00', '2009/6/18 10:00', '2009/6/18 11:00', '2009/6/18 12:00', '2009/6/18 13:00', '2009/6/18 14:00', '2009/6/18 15:00', '2009/6/18 16:00', '2009/6/18 17:00', '2009/6/18 18:00', '2009/6/18 19:00', '2009/6/18 20:00', '2009/6/18 21:00', '2009/6/18 22:00', '2009/6/18 23:00', + '2009/6/15 0:00', '2009/6/19 1:00', '2009/6/19 2:00', '2009/6/19 3:00', '2009/6/19 4:00', '2009/6/19 5:00', '2009/6/19 6:00', '2009/6/19 7:00', '2009/6/19 8:00', '2009/6/19 9:00', '2009/6/19 10:00', '2009/6/19 11:00', '2009/6/19 12:00', '2009/6/19 13:00', '2009/6/19 14:00', '2009/6/19 15:00', '2009/6/19 16:00', '2009/6/19 17:00', '2009/6/19 18:00', '2009/6/19 19:00', '2009/6/19 20:00', '2009/6/19 21:00', '2009/6/19 22:00', '2009/6/19 23:00', + '2009/6/20 0:00', '2009/6/20 1:00', '2009/6/20 2:00', '2009/6/20 3:00', '2009/6/20 4:00', '2009/6/20 5:00', '2009/6/20 6:00', '2009/6/20 7:00', '2009/6/20 8:00', '2009/6/20 9:00', '2009/6/20 10:00', '2009/6/20 11:00', '2009/6/20 12:00', '2009/6/20 13:00', '2009/6/20 14:00', '2009/6/20 15:00', '2009/6/20 16:00', '2009/6/20 17:00', '2009/6/20 18:00', '2009/6/20 19:00', '2009/6/20 20:00', '2009/6/20 21:00', '2009/6/20 22:00', '2009/6/20 23:00', + '2009/6/21 0:00', '2009/6/21 1:00', '2009/6/21 2:00', '2009/6/21 3:00', '2009/6/21 4:00', '2009/6/21 5:00', '2009/6/21 6:00', '2009/6/21 7:00', '2009/6/21 8:00', '2009/6/21 9:00', '2009/6/21 10:00', '2009/6/21 11:00', '2009/6/21 12:00', '2009/6/21 13:00', '2009/6/21 14:00', '2009/6/21 15:00', '2009/6/21 16:00', '2009/6/21 17:00', '2009/6/21 18:00', '2009/6/21 19:00', '2009/6/21 20:00', '2009/6/21 21:00', '2009/6/21 22:00', '2009/6/21 23:00', + '2009/6/22 0:00', '2009/6/22 1:00', '2009/6/22 2:00', '2009/6/22 3:00', '2009/6/22 4:00', '2009/6/22 5:00', '2009/6/22 6:00', '2009/6/22 7:00', '2009/6/22 8:00', '2009/6/22 9:00', '2009/6/22 10:00', '2009/6/22 11:00', '2009/6/22 12:00', '2009/6/22 13:00', '2009/6/22 14:00', '2009/6/22 15:00', '2009/6/22 16:00', '2009/6/22 17:00', '2009/6/22 18:00', '2009/6/22 19:00', '2009/6/22 20:00', '2009/6/22 21:00', '2009/6/22 22:00', '2009/6/22 23:00', + '2009/6/23 0:00', '2009/6/23 1:00', '2009/6/23 2:00', '2009/6/23 3:00', '2009/6/23 4:00', '2009/6/23 5:00', '2009/6/23 6:00', '2009/6/23 7:00', '2009/6/23 8:00', '2009/6/23 9:00', '2009/6/23 10:00', '2009/6/23 11:00', '2009/6/23 12:00', '2009/6/23 13:00', '2009/6/23 14:00', '2009/6/23 15:00', '2009/6/23 16:00', '2009/6/23 17:00', '2009/6/23 18:00', '2009/6/23 19:00', '2009/6/23 20:00', '2009/6/23 21:00', '2009/6/23 22:00', '2009/6/23 23:00', + '2009/6/24 0:00', '2009/6/24 1:00', '2009/6/24 2:00', '2009/6/24 3:00', '2009/6/24 4:00', '2009/6/24 5:00', '2009/6/24 6:00', '2009/6/24 7:00', '2009/6/24 8:00', '2009/6/24 9:00', '2009/6/24 10:00', '2009/6/24 11:00', '2009/6/24 12:00', '2009/6/24 13:00', '2009/6/24 14:00', '2009/6/24 15:00', '2009/6/24 16:00', '2009/6/24 17:00', '2009/6/24 18:00', '2009/6/24 19:00', '2009/6/24 20:00', '2009/6/24 21:00', '2009/6/24 22:00', '2009/6/24 23:00', + '2009/6/25 0:00', '2009/6/25 1:00', '2009/6/25 2:00', '2009/6/25 3:00', '2009/6/25 4:00', '2009/6/25 5:00', '2009/6/25 6:00', '2009/6/25 7:00', '2009/6/25 8:00', '2009/6/25 9:00', '2009/6/25 10:00', '2009/6/25 11:00', '2009/6/25 12:00', '2009/6/25 13:00', '2009/6/25 14:00', '2009/6/25 15:00', '2009/6/25 16:00', '2009/6/25 17:00', '2009/6/25 18:00', '2009/6/25 19:00', '2009/6/25 20:00', '2009/6/25 21:00', '2009/6/25 22:00', '2009/6/25 23:00', + '2009/6/26 0:00', '2009/6/26 1:00', '2009/6/26 2:00', '2009/6/26 3:00', '2009/6/26 4:00', '2009/6/26 5:00', '2009/6/26 6:00', '2009/6/26 7:00', '2009/6/26 8:00', '2009/6/26 9:00', '2009/6/26 10:00', '2009/6/26 11:00', '2009/6/26 12:00', '2009/6/26 13:00', '2009/6/26 14:00', '2009/6/26 15:00', '2009/6/26 16:00', '2009/6/26 17:00', '2009/6/26 18:00', '2009/6/26 19:00', '2009/6/26 20:00', '2009/6/26 21:00', '2009/6/26 22:00', '2009/6/26 23:00', + '2009/6/27 0:00', '2009/6/27 1:00', '2009/6/27 2:00', '2009/6/27 3:00', '2009/6/27 4:00', '2009/6/27 5:00', '2009/6/27 6:00', '2009/6/27 7:00', '2009/6/27 8:00', '2009/6/27 9:00', '2009/6/27 10:00', '2009/6/27 11:00', '2009/6/27 12:00', '2009/6/27 13:00', '2009/6/27 14:00', '2009/6/27 15:00', '2009/6/27 16:00', '2009/6/27 17:00', '2009/6/27 18:00', '2009/6/27 19:00', '2009/6/27 20:00', '2009/6/27 21:00', '2009/6/27 22:00', '2009/6/27 23:00', + '2009/6/28 0:00', '2009/6/28 1:00', '2009/6/28 2:00', '2009/6/28 3:00', '2009/6/28 4:00', '2009/6/28 5:00', '2009/6/28 6:00', '2009/6/28 7:00', '2009/6/28 8:00', '2009/6/28 9:00', '2009/6/28 10:00', '2009/6/28 11:00', '2009/6/28 12:00', '2009/6/28 13:00', '2009/6/28 14:00', '2009/6/28 15:00', '2009/6/28 16:00', '2009/6/28 17:00', '2009/6/28 18:00', '2009/6/28 19:00', '2009/6/28 20:00', '2009/6/28 21:00', '2009/6/28 22:00', '2009/6/28 23:00', + '2009/6/29 0:00', '2009/6/29 1:00', '2009/6/29 2:00', '2009/6/29 3:00', '2009/6/29 4:00', '2009/6/29 5:00', '2009/6/29 6:00', '2009/6/29 7:00', '2009/6/29 8:00', '2009/6/29 9:00', '2009/6/29 10:00', '2009/6/29 11:00', '2009/6/29 12:00', '2009/6/29 13:00', '2009/6/29 14:00', '2009/6/29 15:00', '2009/6/29 16:00', '2009/6/29 17:00', '2009/6/29 18:00', '2009/6/29 19:00', '2009/6/29 20:00', '2009/6/29 21:00', '2009/6/29 22:00', '2009/6/29 23:00', + '2009/6/30 0:00', '2009/6/30 1:00', '2009/6/30 2:00', '2009/6/30 3:00', '2009/6/30 4:00', '2009/6/30 5:00', '2009/6/30 6:00', '2009/6/30 7:00', '2009/6/30 8:00', '2009/6/30 9:00', '2009/6/30 10:00', '2009/6/30 11:00', '2009/6/30 12:00', '2009/6/30 13:00', '2009/6/30 14:00', '2009/6/30 15:00', '2009/6/30 16:00', '2009/6/30 17:00', '2009/6/30 18:00', '2009/6/30 19:00', '2009/6/30 20:00', '2009/6/30 21:00', '2009/6/30 22:00', '2009/6/30 23:00', + '2009/7/1 0:00', '2009/7/1 1:00', '2009/7/1 2:00', '2009/7/1 3:00', '2009/7/1 4:00', '2009/7/1 5:00', '2009/7/1 6:00', '2009/7/1 7:00', '2009/7/1 8:00', '2009/7/1 9:00', '2009/7/1 10:00', '2009/7/1 11:00', '2009/7/1 12:00', '2009/7/1 13:00', '2009/7/1 14:00', '2009/7/1 15:00', '2009/7/1 16:00', '2009/7/1 17:00', '2009/7/1 18:00', '2009/7/1 19:00', '2009/7/1 20:00', '2009/7/1 21:00', '2009/7/1 22:00', '2009/7/1 23:00', + '2009/7/2 0:00', '2009/7/2 1:00', '2009/7/2 2:00', '2009/7/2 3:00', '2009/7/2 4:00', '2009/7/2 5:00', '2009/7/2 6:00', '2009/7/2 7:00', '2009/7/2 8:00', '2009/7/2 9:00', '2009/7/2 10:00', '2009/7/2 11:00', '2009/7/2 12:00', '2009/7/2 13:00', '2009/7/2 14:00', '2009/7/2 15:00', '2009/7/2 16:00', '2009/7/2 17:00', '2009/7/2 18:00', '2009/7/2 19:00', '2009/7/2 20:00', '2009/7/2 21:00', '2009/7/2 22:00', '2009/7/2 23:00', + '2009/7/3 0:00', '2009/7/3 1:00', '2009/7/3 2:00', '2009/7/3 3:00', '2009/7/3 4:00', '2009/7/3 5:00', '2009/7/3 6:00', '2009/7/3 7:00', '2009/7/3 8:00', '2009/7/3 9:00', '2009/7/3 10:00', '2009/7/3 11:00', '2009/7/3 12:00', '2009/7/3 13:00', '2009/7/3 14:00', '2009/7/3 15:00', '2009/7/3 16:00', '2009/7/3 17:00', '2009/7/3 18:00', '2009/7/3 19:00', '2009/7/3 20:00', '2009/7/3 21:00', '2009/7/3 22:00', '2009/7/3 23:00', + '2009/7/4 0:00', '2009/7/4 1:00', '2009/7/4 2:00', '2009/7/4 3:00', '2009/7/4 4:00', '2009/7/4 5:00', '2009/7/4 6:00', '2009/7/4 7:00', '2009/7/4 8:00', '2009/7/4 9:00', '2009/7/4 10:00', '2009/7/4 11:00', '2009/7/4 12:00', '2009/7/4 13:00', '2009/7/4 14:00', '2009/7/4 15:00', '2009/7/4 16:00', '2009/7/4 17:00', '2009/7/4 18:00', '2009/7/4 19:00', '2009/7/4 20:00', '2009/7/4 21:00', '2009/7/4 22:00', '2009/7/4 23:00', + '2009/7/5 0:00', '2009/7/5 1:00', '2009/7/5 2:00', '2009/7/5 3:00', '2009/7/5 4:00', '2009/7/5 5:00', '2009/7/5 6:00', '2009/7/5 7:00', '2009/7/5 8:00', '2009/7/5 9:00', '2009/7/5 10:00', '2009/7/5 11:00', '2009/7/5 12:00', '2009/7/5 13:00', '2009/7/5 14:00', '2009/7/5 15:00', '2009/7/5 16:00', '2009/7/5 17:00', '2009/7/5 18:00', '2009/7/5 19:00', '2009/7/5 20:00', '2009/7/5 21:00', '2009/7/5 22:00', '2009/7/5 23:00', + '2009/7/6 0:00', '2009/7/6 1:00', '2009/7/6 2:00', '2009/7/6 3:00', '2009/7/6 4:00', '2009/7/6 5:00', '2009/7/6 6:00', '2009/7/6 7:00', '2009/7/6 8:00', '2009/7/6 9:00', '2009/7/6 10:00', '2009/7/6 11:00', '2009/7/6 12:00', '2009/7/6 13:00', '2009/7/6 14:00', '2009/7/6 15:00', '2009/7/6 16:00', '2009/7/6 17:00', '2009/7/6 18:00', '2009/7/6 19:00', '2009/7/6 20:00', '2009/7/6 21:00', '2009/7/6 22:00', '2009/7/6 23:00', + '2009/7/7 0:00', '2009/7/7 1:00', '2009/7/7 2:00', '2009/7/7 3:00', '2009/7/7 4:00', '2009/7/7 5:00', '2009/7/7 6:00', '2009/7/7 7:00', '2009/7/7 8:00', '2009/7/7 9:00', '2009/7/7 10:00', '2009/7/7 11:00', '2009/7/7 12:00', '2009/7/7 13:00', '2009/7/7 14:00', '2009/7/7 15:00', '2009/7/7 16:00', '2009/7/7 17:00', '2009/7/7 18:00', '2009/7/7 19:00', '2009/7/7 20:00', '2009/7/7 21:00', '2009/7/7 22:00', '2009/7/7 23:00', + '2009/7/8 0:00', '2009/7/8 1:00', '2009/7/8 2:00', '2009/7/8 3:00', '2009/7/8 4:00', '2009/7/8 5:00', '2009/7/8 6:00', '2009/7/8 7:00', '2009/7/8 8:00', '2009/7/8 9:00', '2009/7/8 10:00', '2009/7/8 11:00', '2009/7/8 12:00', '2009/7/8 13:00', '2009/7/8 14:00', '2009/7/8 15:00', '2009/7/8 16:00', '2009/7/8 17:00', '2009/7/8 18:00', '2009/7/8 19:00', '2009/7/8 20:00', '2009/7/8 21:00', '2009/7/8 22:00', '2009/7/8 23:00', + '2009/7/9 0:00', '2009/7/9 1:00', '2009/7/9 2:00', '2009/7/9 3:00', '2009/7/9 4:00', '2009/7/9 5:00', '2009/7/9 6:00', '2009/7/9 7:00', '2009/7/9 8:00', '2009/7/9 9:00', '2009/7/9 10:00', '2009/7/9 11:00', '2009/7/9 12:00', '2009/7/9 13:00', '2009/7/9 14:00', '2009/7/9 15:00', '2009/7/9 16:00', '2009/7/9 17:00', '2009/7/9 18:00', '2009/7/9 19:00', '2009/7/9 20:00', '2009/7/9 21:00', '2009/7/9 22:00', '2009/7/9 23:00', + '2009/7/10 0:00', '2009/7/10 1:00', '2009/7/10 2:00', '2009/7/10 3:00', '2009/7/10 4:00', '2009/7/10 5:00', '2009/7/10 6:00', '2009/7/10 7:00', '2009/7/10 8:00', '2009/7/10 9:00', '2009/7/10 10:00', '2009/7/10 11:00', '2009/7/10 12:00', '2009/7/10 13:00', '2009/7/10 14:00', '2009/7/10 15:00', '2009/7/10 16:00', '2009/7/10 17:00', '2009/7/10 18:00', '2009/7/10 19:00', '2009/7/10 20:00', '2009/7/10 21:00', '2009/7/10 22:00', '2009/7/10 23:00', + '2009/7/11 0:00', '2009/7/11 1:00', '2009/7/11 2:00', '2009/7/11 3:00', '2009/7/11 4:00', '2009/7/11 5:00', '2009/7/11 6:00', '2009/7/11 7:00', '2009/7/11 8:00', '2009/7/11 9:00', '2009/7/11 10:00', '2009/7/11 11:00', '2009/7/11 12:00', '2009/7/11 13:00', '2009/7/11 14:00', '2009/7/11 15:00', '2009/7/11 16:00', '2009/7/11 17:00', '2009/7/11 18:00', '2009/7/11 19:00', '2009/7/11 20:00', '2009/7/11 21:00', '2009/7/11 22:00', '2009/7/11 23:00', + '2009/7/12 0:00', '2009/7/12 1:00', '2009/7/12 2:00', '2009/7/12 3:00', '2009/7/12 4:00', '2009/7/12 5:00', '2009/7/12 6:00', '2009/7/12 7:00', '2009/7/12 8:00', '2009/7/12 9:00', '2009/7/12 10:00', '2009/7/12 11:00', '2009/7/12 12:00', '2009/7/12 13:00', '2009/7/12 14:00', '2009/7/12 15:00', '2009/7/12 16:00', '2009/7/12 17:00', '2009/7/12 18:00', '2009/7/12 19:00', '2009/7/12 20:00', '2009/7/12 21:00', '2009/7/12 22:00', '2009/7/12 23:00', + '2009/7/13 0:00', '2009/7/13 1:00', '2009/7/13 2:00', '2009/7/13 3:00', '2009/7/13 4:00', '2009/7/13 5:00', '2009/7/13 6:00', '2009/7/13 7:00', '2009/7/13 8:00', '2009/7/13 9:00', '2009/7/13 10:00', '2009/7/13 11:00', '2009/7/13 12:00', '2009/7/13 13:00', '2009/7/13 14:00', '2009/7/13 15:00', '2009/7/13 16:00', '2009/7/13 17:00', '2009/7/13 18:00', '2009/7/13 19:00', '2009/7/13 20:00', '2009/7/13 21:00', '2009/7/13 22:00', '2009/7/13 23:00', + '2009/7/14 0:00', '2009/7/14 1:00', '2009/7/14 2:00', '2009/7/14 3:00', '2009/7/14 4:00', '2009/7/14 5:00', '2009/7/14 6:00', '2009/7/14 7:00', '2009/7/14 8:00', '2009/7/14 9:00', '2009/7/14 10:00', '2009/7/14 11:00', '2009/7/14 12:00', '2009/7/14 13:00', '2009/7/14 14:00', '2009/7/14 15:00', '2009/7/14 16:00', '2009/7/14 17:00', '2009/7/14 18:00', '2009/7/14 19:00', '2009/7/14 20:00', '2009/7/14 21:00', '2009/7/14 22:00', '2009/7/14 23:00', + '2009/7/15 0:00', '2009/7/15 1:00', '2009/7/15 2:00', '2009/7/15 3:00', '2009/7/15 4:00', '2009/7/15 5:00', '2009/7/15 6:00', '2009/7/15 7:00', '2009/7/15 8:00', '2009/7/15 9:00', '2009/7/15 10:00', '2009/7/15 11:00', '2009/7/15 12:00', '2009/7/15 13:00', '2009/7/15 14:00', '2009/7/15 15:00', '2009/7/15 16:00', '2009/7/15 17:00', '2009/7/15 18:00', '2009/7/15 19:00', '2009/7/15 20:00', '2009/7/15 21:00', '2009/7/15 22:00', '2009/7/15 23:00', + '2009/7/16 0:00', '2009/7/16 1:00', '2009/7/16 2:00', '2009/7/16 3:00', '2009/7/16 4:00', '2009/7/16 5:00', '2009/7/16 6:00', '2009/7/16 7:00', '2009/7/16 8:00', '2009/7/16 9:00', '2009/7/16 10:00', '2009/7/16 11:00', '2009/7/16 12:00', '2009/7/16 13:00', '2009/7/16 14:00', '2009/7/16 15:00', '2009/7/16 16:00', '2009/7/16 17:00', '2009/7/16 18:00', '2009/7/16 19:00', '2009/7/16 20:00', '2009/7/16 21:00', '2009/7/16 22:00', '2009/7/16 23:00', + '2009/7/17 0:00', '2009/7/17 1:00', '2009/7/17 2:00', '2009/7/17 3:00', '2009/7/17 4:00', '2009/7/17 5:00', '2009/7/17 6:00', '2009/7/17 7:00', '2009/7/17 8:00', '2009/7/17 9:00', '2009/7/17 10:00', '2009/7/17 11:00', '2009/7/17 12:00', '2009/7/17 13:00', '2009/7/17 14:00', '2009/7/17 15:00', '2009/7/17 16:00', '2009/7/17 17:00', '2009/7/17 18:00', '2009/7/17 19:00', '2009/7/17 20:00', '2009/7/17 21:00', '2009/7/17 22:00', '2009/7/17 23:00', + '2009/7/18 0:00', '2009/7/18 1:00', '2009/7/18 2:00', '2009/7/18 3:00', '2009/7/18 4:00', '2009/7/18 5:00', '2009/7/18 6:00', '2009/7/18 7:00', '2009/7/18 8:00', '2009/7/18 9:00', '2009/7/18 10:00', '2009/7/18 11:00', '2009/7/18 12:00', '2009/7/18 13:00', '2009/7/18 14:00', '2009/7/18 15:00', '2009/7/18 16:00', '2009/7/18 17:00', '2009/7/18 18:00', '2009/7/18 19:00', '2009/7/18 20:00', '2009/7/18 21:00', '2009/7/18 22:00', '2009/7/18 23:00', + '2009/7/19 0:00', '2009/7/19 1:00', '2009/7/19 2:00', '2009/7/19 3:00', '2009/7/19 4:00', '2009/7/19 5:00', '2009/7/19 6:00', '2009/7/19 7:00', '2009/7/19 8:00', '2009/7/19 9:00', '2009/7/19 10:00', '2009/7/19 11:00', '2009/7/19 12:00', '2009/7/19 13:00', '2009/7/19 14:00', '2009/7/19 15:00', '2009/7/19 16:00', '2009/7/19 17:00', '2009/7/19 18:00', '2009/7/19 19:00', '2009/7/19 20:00', '2009/7/19 21:00', '2009/7/19 22:00', '2009/7/19 23:00', + '2009/7/20 0:00', '2009/7/20 1:00', '2009/7/20 2:00', '2009/7/20 3:00', '2009/7/20 4:00', '2009/7/20 5:00', '2009/7/20 6:00', '2009/7/20 7:00', '2009/7/20 8:00', '2009/7/20 9:00', '2009/7/20 10:00', '2009/7/20 11:00', '2009/7/20 12:00', '2009/7/20 13:00', '2009/7/20 14:00', '2009/7/20 15:00', '2009/7/20 16:00', '2009/7/20 17:00', '2009/7/20 18:00', '2009/7/20 19:00', '2009/7/20 20:00', '2009/7/20 21:00', '2009/7/20 22:00', '2009/7/20 23:00', + '2009/7/21 0:00', '2009/7/21 1:00', '2009/7/21 2:00', '2009/7/21 3:00', '2009/7/21 4:00', '2009/7/21 5:00', '2009/7/21 6:00', '2009/7/21 7:00', '2009/7/21 8:00', '2009/7/21 9:00', '2009/7/21 10:00', '2009/7/21 11:00', '2009/7/21 12:00', '2009/7/21 13:00', '2009/7/21 14:00', '2009/7/21 15:00', '2009/7/21 16:00', '2009/7/21 17:00', '2009/7/21 18:00', '2009/7/21 19:00', '2009/7/21 20:00', '2009/7/21 21:00', '2009/7/21 22:00', '2009/7/21 23:00', + '2009/7/22 0:00', '2009/7/22 1:00', '2009/7/22 2:00', '2009/7/22 3:00', '2009/7/22 4:00', '2009/7/22 5:00', '2009/7/22 6:00', '2009/7/22 7:00', '2009/7/22 8:00', '2009/7/22 9:00', '2009/7/22 10:00', '2009/7/22 11:00', '2009/7/22 12:00', '2009/7/22 13:00', '2009/7/22 14:00', '2009/7/22 15:00', '2009/7/22 16:00', '2009/7/22 17:00', '2009/7/22 18:00', '2009/7/22 19:00', '2009/7/22 20:00', '2009/7/22 21:00', '2009/7/22 22:00', '2009/7/22 23:00', + '2009/7/23 0:00', '2009/7/23 1:00', '2009/7/23 2:00', '2009/7/23 3:00', '2009/7/23 4:00', '2009/7/23 5:00', '2009/7/23 6:00', '2009/7/23 7:00', '2009/7/23 8:00', '2009/7/23 9:00', '2009/7/23 10:00', '2009/7/23 11:00', '2009/7/23 12:00', '2009/7/23 13:00', '2009/7/23 14:00', '2009/7/23 15:00', '2009/7/23 16:00', '2009/7/23 17:00', '2009/7/23 18:00', '2009/7/23 19:00', '2009/7/23 20:00', '2009/7/23 21:00', '2009/7/23 22:00', '2009/7/23 23:00', + '2009/7/24 0:00', '2009/7/24 1:00', '2009/7/24 2:00', '2009/7/24 3:00', '2009/7/24 4:00', '2009/7/24 5:00', '2009/7/24 6:00', '2009/7/24 7:00', '2009/7/24 8:00', '2009/7/24 9:00', '2009/7/24 10:00', '2009/7/24 11:00', '2009/7/24 12:00', '2009/7/24 13:00', '2009/7/24 14:00', '2009/7/24 15:00', '2009/7/24 16:00', '2009/7/24 17:00', '2009/7/24 18:00', '2009/7/24 19:00', '2009/7/24 20:00', '2009/7/24 21:00', '2009/7/24 22:00', '2009/7/24 23:00', + '2009/7/25 0:00', '2009/7/25 1:00', '2009/7/25 2:00', '2009/7/25 3:00', '2009/7/25 4:00', '2009/7/25 5:00', '2009/7/25 6:00', '2009/7/25 7:00', '2009/7/25 8:00', '2009/7/25 9:00', '2009/7/25 10:00', '2009/7/25 11:00', '2009/7/25 12:00', '2009/7/25 13:00', '2009/7/25 14:00', '2009/7/25 15:00', '2009/7/25 16:00', '2009/7/25 17:00', '2009/7/25 18:00', '2009/7/25 19:00', '2009/7/25 20:00', '2009/7/25 21:00', '2009/7/25 22:00', '2009/7/25 23:00', + '2009/7/26 0:00', '2009/7/26 1:00', '2009/7/26 2:00', '2009/7/26 3:00', '2009/7/26 4:00', '2009/7/26 5:00', '2009/7/26 6:00', '2009/7/26 7:00', '2009/7/26 8:00', '2009/7/26 9:00', '2009/7/26 10:00', '2009/7/26 11:00', '2009/7/26 12:00', '2009/7/26 13:00', '2009/7/26 14:00', '2009/7/26 15:00', '2009/7/26 16:00', '2009/7/26 17:00', '2009/7/26 18:00', '2009/7/26 19:00', '2009/7/26 20:00', '2009/7/26 21:00', '2009/7/26 22:00', '2009/7/26 23:00', + '2009/7/27 0:00', '2009/7/27 1:00', '2009/7/27 2:00', '2009/7/27 3:00', '2009/7/27 4:00', '2009/7/27 5:00', '2009/7/27 6:00', '2009/7/27 7:00', '2009/7/27 8:00', '2009/7/27 9:00', '2009/7/27 10:00', '2009/7/27 11:00', '2009/7/27 12:00', '2009/7/27 13:00', '2009/7/27 14:00', '2009/7/27 15:00', '2009/7/27 16:00', '2009/7/27 17:00', '2009/7/27 18:00', '2009/7/27 19:00', '2009/7/27 20:00', '2009/7/27 21:00', '2009/7/27 22:00', '2009/7/27 23:00', + '2009/7/28 0:00', '2009/7/28 1:00', '2009/7/28 2:00', '2009/7/28 3:00', '2009/7/28 4:00', '2009/7/28 5:00', '2009/7/28 6:00', '2009/7/28 7:00', '2009/7/28 8:00', '2009/7/28 9:00', '2009/7/28 10:00', '2009/7/28 11:00', '2009/7/28 12:00', '2009/7/28 13:00', '2009/7/28 14:00', '2009/7/28 15:00', '2009/7/28 16:00', '2009/7/28 17:00', '2009/7/28 18:00', '2009/7/28 19:00', '2009/7/28 20:00', '2009/7/28 21:00', '2009/7/28 22:00', '2009/7/28 23:00', + '2009/7/29 0:00', '2009/7/29 1:00', '2009/7/29 2:00', '2009/7/29 3:00', '2009/7/29 4:00', '2009/7/29 5:00', '2009/7/29 6:00', '2009/7/29 7:00', '2009/7/29 8:00', '2009/7/29 9:00', '2009/7/29 10:00', '2009/7/29 11:00', '2009/7/29 12:00', '2009/7/29 13:00', '2009/7/29 14:00', '2009/7/29 15:00', '2009/7/29 16:00', '2009/7/29 17:00', '2009/7/29 18:00', '2009/7/29 19:00', '2009/7/29 20:00', '2009/7/29 21:00', '2009/7/29 22:00', '2009/7/29 23:00', + '2009/7/30 0:00', '2009/7/30 1:00', '2009/7/30 2:00', '2009/7/30 3:00', '2009/7/30 4:00', '2009/7/30 5:00', '2009/7/30 6:00', '2009/7/30 7:00', '2009/7/30 8:00', '2009/7/30 9:00', '2009/7/30 10:00', '2009/7/30 11:00', '2009/7/30 12:00', '2009/7/30 13:00', '2009/7/30 14:00', '2009/7/30 15:00', '2009/7/30 16:00', '2009/7/30 17:00', '2009/7/30 18:00', '2009/7/30 19:00', '2009/7/30 20:00', '2009/7/30 21:00', '2009/7/30 22:00', '2009/7/30 23:00', + '2009/7/31 0:00', '2009/7/31 1:00', '2009/7/31 2:00', '2009/7/31 3:00', '2009/7/31 4:00', '2009/7/31 5:00', '2009/7/31 6:00', '2009/7/31 7:00', '2009/7/31 8:00', '2009/7/31 9:00', '2009/7/31 10:00', '2009/7/31 11:00', '2009/7/31 12:00', '2009/7/31 13:00', '2009/7/31 14:00', '2009/7/31 15:00', '2009/7/31 16:00', '2009/7/31 17:00', '2009/7/31 18:00', '2009/7/31 19:00', '2009/7/31 20:00', '2009/7/31 21:00', '2009/7/31 22:00', '2009/7/31 23:00', + '2009/8/1 0:00', '2009/8/1 1:00', '2009/8/1 2:00', '2009/8/1 3:00', '2009/8/1 4:00', '2009/8/1 5:00', '2009/8/1 6:00', '2009/8/1 7:00', '2009/8/1 8:00', '2009/8/1 9:00', '2009/8/1 10:00', '2009/8/1 11:00', '2009/8/1 12:00', '2009/8/1 13:00', '2009/8/1 14:00', '2009/8/1 15:00', '2009/8/1 16:00', '2009/8/1 17:00', '2009/8/1 18:00', '2009/8/1 19:00', '2009/8/1 20:00', '2009/8/1 21:00', '2009/8/1 22:00', '2009/8/1 23:00', '2009/8/2 0:00', '2009/8/2 1:00', '2009/8/2 2:00', '2009/8/2 3:00', '2009/8/2 4:00', '2009/8/2 5:00', '2009/8/2 6:00', '2009/8/2 7:00', '2009/8/2 8:00', '2009/8/2 9:00', '2009/8/2 10:00', '2009/8/2 11:00', '2009/8/2 12:00', '2009/8/2 13:00', '2009/8/2 14:00', '2009/8/2 15:00', '2009/8/2 16:00', '2009/8/2 17:00', '2009/8/2 18:00', '2009/8/2 19:00', '2009/8/2 20:00', '2009/8/2 21:00', '2009/8/2 22:00', '2009/8/2 23:00', '2009/8/3 0:00', '2009/8/3 1:00', '2009/8/3 2:00', '2009/8/3 3:00', '2009/8/3 4:00', '2009/8/3 5:00', '2009/8/3 6:00', '2009/8/3 7:00', '2009/8/3 8:00', '2009/8/3 9:00', '2009/8/3 10:00', '2009/8/3 11:00', '2009/8/3 12:00', '2009/8/3 13:00', '2009/8/3 14:00', '2009/8/3 15:00', '2009/8/3 16:00', '2009/8/3 17:00', '2009/8/3 18:00', '2009/8/3 19:00', '2009/8/3 20:00', '2009/8/3 21:00', '2009/8/3 22:00', '2009/8/3 23:00', '2009/8/4 0:00', '2009/8/4 1:00', '2009/8/4 2:00', '2009/8/4 3:00', '2009/8/4 4:00', '2009/8/4 5:00', '2009/8/4 6:00', '2009/8/4 7:00', '2009/8/4 8:00', '2009/8/4 9:00', '2009/8/4 10:00', '2009/8/4 11:00', '2009/8/4 12:00', '2009/8/4 13:00', '2009/8/4 14:00', '2009/8/4 15:00', '2009/8/4 16:00', '2009/8/4 17:00', '2009/8/4 18:00', '2009/8/4 19:00', '2009/8/4 20:00', '2009/8/4 21:00', '2009/8/4 22:00', '2009/8/4 23:00', '2009/8/5 0:00', '2009/8/5 1:00', '2009/8/5 2:00', '2009/8/5 3:00', '2009/8/5 4:00', '2009/8/5 5:00', '2009/8/5 6:00', '2009/8/5 7:00', '2009/8/5 8:00', '2009/8/5 9:00', '2009/8/5 10:00', '2009/8/5 11:00', '2009/8/5 12:00', '2009/8/5 13:00', '2009/8/5 14:00', '2009/8/5 15:00', '2009/8/5 16:00', '2009/8/5 17:00', '2009/8/5 18:00', '2009/8/5 19:00', '2009/8/5 20:00', '2009/8/5 21:00', '2009/8/5 22:00', '2009/8/5 23:00', '2009/8/6 0:00', '2009/8/6 1:00', '2009/8/6 2:00', '2009/8/6 3:00', '2009/8/6 4:00', '2009/8/6 5:00', '2009/8/6 6:00', '2009/8/6 7:00', '2009/8/6 8:00', '2009/8/6 9:00', '2009/8/6 10:00', '2009/8/6 11:00', '2009/8/6 12:00', '2009/8/6 13:00', '2009/8/6 14:00', '2009/8/6 15:00', '2009/8/6 16:00', '2009/8/6 17:00', '2009/8/6 18:00', '2009/8/6 19:00', '2009/8/6 20:00', '2009/8/6 21:00', '2009/8/6 22:00', '2009/8/6 23:00', '2009/8/7 0:00', '2009/8/7 1:00', '2009/8/7 2:00', '2009/8/7 3:00', '2009/8/7 4:00', '2009/8/7 5:00', '2009/8/7 6:00', '2009/8/7 7:00', '2009/8/7 8:00', '2009/8/7 9:00', '2009/8/7 10:00', '2009/8/7 11:00', '2009/8/7 12:00', '2009/8/7 13:00', '2009/8/7 14:00', '2009/8/7 15:00', '2009/8/7 16:00', '2009/8/7 17:00', '2009/8/7 18:00', '2009/8/7 19:00', '2009/8/7 20:00', '2009/8/7 21:00', '2009/8/7 22:00', '2009/8/7 23:00', '2009/8/8 0:00', '2009/8/8 1:00', '2009/8/8 2:00', '2009/8/8 3:00', '2009/8/8 4:00', '2009/8/8 5:00', '2009/8/8 6:00', '2009/8/8 7:00', '2009/8/8 8:00', '2009/8/8 9:00', '2009/8/8 10:00', '2009/8/8 11:00', '2009/8/8 12:00', '2009/8/8 13:00', '2009/8/8 14:00', '2009/8/8 15:00', '2009/8/8 16:00', '2009/8/8 17:00', '2009/8/8 18:00', '2009/8/8 19:00', '2009/8/8 20:00', '2009/8/8 21:00', '2009/8/8 22:00', '2009/8/8 23:00', '2009/8/9 0:00', '2009/8/9 1:00', '2009/8/9 2:00', '2009/8/9 3:00', '2009/8/9 4:00', '2009/8/9 5:00', '2009/8/9 6:00', '2009/8/9 7:00', '2009/8/9 8:00', '2009/8/9 9:00', '2009/8/9 10:00', '2009/8/9 11:00', '2009/8/9 12:00', '2009/8/9 13:00', '2009/8/9 14:00', '2009/8/9 15:00', '2009/8/9 16:00', '2009/8/9 17:00', '2009/8/9 18:00', '2009/8/9 19:00', '2009/8/9 20:00', '2009/8/9 21:00', '2009/8/9 22:00', '2009/8/9 23:00', '2009/8/10 0:00', '2009/8/10 1:00', '2009/8/10 2:00', '2009/8/10 3:00', '2009/8/10 4:00', '2009/8/10 5:00', '2009/8/10 6:00', '2009/8/10 7:00', '2009/8/10 8:00', '2009/8/10 9:00', '2009/8/10 10:00', '2009/8/10 11:00', '2009/8/10 12:00', '2009/8/10 13:00', '2009/8/10 14:00', '2009/8/10 15:00', '2009/8/10 16:00', '2009/8/10 17:00', '2009/8/10 18:00', '2009/8/10 19:00', '2009/8/10 20:00', '2009/8/10 21:00', '2009/8/10 22:00', '2009/8/10 23:00', '2009/8/11 0:00', '2009/8/11 1:00', '2009/8/11 2:00', '2009/8/11 3:00', '2009/8/11 4:00', '2009/8/11 5:00', '2009/8/11 6:00', '2009/8/11 7:00', '2009/8/11 8:00', '2009/8/11 9:00', '2009/8/11 10:00', '2009/8/11 11:00', '2009/8/11 12:00', '2009/8/11 13:00', '2009/8/11 14:00', '2009/8/11 15:00', '2009/8/11 16:00', '2009/8/11 17:00', '2009/8/11 18:00', '2009/8/11 19:00', '2009/8/11 20:00', '2009/8/11 21:00', '2009/8/11 22:00', '2009/8/11 23:00', '2009/8/12 0:00', '2009/8/12 1:00', '2009/8/12 2:00', '2009/8/12 3:00', '2009/8/12 4:00', '2009/8/12 5:00', '2009/8/12 6:00', '2009/8/12 7:00', '2009/8/12 8:00', '2009/8/12 9:00', '2009/8/12 10:00', '2009/8/12 11:00', '2009/8/12 12:00', '2009/8/12 13:00', '2009/8/12 14:00', '2009/8/12 15:00', '2009/8/12 16:00', '2009/8/12 17:00', '2009/8/12 18:00', '2009/8/12 19:00', '2009/8/12 20:00', '2009/8/12 21:00', '2009/8/12 22:00', '2009/8/12 23:00', '2009/8/13 0:00', '2009/8/13 1:00', '2009/8/13 2:00', '2009/8/13 3:00', '2009/8/13 4:00', '2009/8/13 5:00', '2009/8/13 6:00', '2009/8/13 7:00', '2009/8/13 8:00', '2009/8/13 9:00', '2009/8/13 10:00', '2009/8/13 11:00', '2009/8/13 12:00', '2009/8/13 13:00', '2009/8/13 14:00', '2009/8/13 15:00', '2009/8/13 16:00', '2009/8/13 17:00', '2009/8/13 18:00', '2009/8/13 19:00', '2009/8/13 20:00', '2009/8/13 21:00', '2009/8/13 22:00', '2009/8/13 23:00', '2009/8/14 0:00', '2009/8/14 1:00', '2009/8/14 2:00', '2009/8/14 3:00', '2009/8/14 4:00', '2009/8/14 5:00', '2009/8/14 6:00', '2009/8/14 7:00', '2009/8/14 8:00', '2009/8/14 9:00', '2009/8/14 10:00', '2009/8/14 11:00', '2009/8/14 12:00', '2009/8/14 13:00', '2009/8/14 14:00', '2009/8/14 15:00', '2009/8/14 16:00', '2009/8/14 17:00', '2009/8/14 18:00', '2009/8/14 19:00', '2009/8/14 20:00', '2009/8/14 21:00', '2009/8/14 22:00', '2009/8/14 23:00', '2009/8/15 0:00', '2009/8/15 1:00', '2009/8/15 2:00', '2009/8/15 3:00', '2009/8/15 4:00', '2009/8/15 5:00', '2009/8/15 6:00', '2009/8/15 7:00', '2009/8/15 8:00', '2009/8/15 9:00', '2009/8/15 10:00', '2009/8/15 11:00', '2009/8/15 12:00', '2009/8/15 13:00', '2009/8/15 14:00', '2009/8/15 15:00', '2009/8/15 16:00', '2009/8/15 17:00', '2009/8/15 18:00', '2009/8/15 19:00', '2009/8/15 20:00', '2009/8/15 21:00', '2009/8/15 22:00', '2009/8/15 23:00', '2009/8/16 0:00', '2009/8/16 1:00', '2009/8/16 2:00', '2009/8/16 3:00', '2009/8/16 4:00', '2009/8/16 5:00', '2009/8/16 6:00', '2009/8/16 7:00', '2009/8/16 8:00', '2009/8/16 9:00', '2009/8/16 10:00', '2009/8/16 11:00', '2009/8/16 12:00', '2009/8/16 13:00', '2009/8/16 14:00', '2009/8/16 15:00', '2009/8/16 16:00', '2009/8/16 17:00', '2009/8/16 18:00', '2009/8/16 19:00', '2009/8/16 20:00', '2009/8/16 21:00', '2009/8/16 22:00', '2009/8/16 23:00', '2009/8/17 0:00', '2009/8/17 1:00', '2009/8/17 2:00', '2009/8/17 3:00', '2009/8/17 4:00', '2009/8/17 5:00', '2009/8/17 6:00', '2009/8/17 7:00', '2009/8/17 8:00', '2009/8/17 9:00', '2009/8/17 10:00', '2009/8/17 11:00', '2009/8/17 12:00', '2009/8/17 13:00', '2009/8/17 14:00', '2009/8/17 15:00', '2009/8/17 16:00', '2009/8/17 17:00', '2009/8/17 18:00', '2009/8/17 19:00', '2009/8/17 20:00', '2009/8/17 21:00', '2009/8/17 22:00', '2009/8/17 23:00', '2009/8/18 0:00', '2009/8/18 1:00', '2009/8/18 2:00', '2009/8/18 3:00', '2009/8/18 4:00', '2009/8/18 5:00', '2009/8/18 6:00', '2009/8/18 7:00', '2009/8/18 8:00', '2009/8/18 9:00', '2009/8/18 10:00', '2009/8/18 11:00', '2009/8/18 12:00', '2009/8/18 13:00', '2009/8/18 14:00', '2009/8/18 15:00', '2009/8/18 16:00', '2009/8/18 17:00', '2009/8/18 18:00', '2009/8/18 19:00', '2009/8/18 20:00', '2009/8/18 21:00', '2009/8/18 22:00', '2009/8/18 23:00', '2009/8/19 0:00', '2009/8/19 1:00', '2009/8/19 2:00', '2009/8/19 3:00', '2009/8/19 4:00', '2009/8/19 5:00', '2009/8/19 6:00', '2009/8/19 7:00', '2009/8/19 8:00', '2009/8/19 9:00', '2009/8/19 10:00', '2009/8/19 11:00', '2009/8/19 12:00', '2009/8/19 13:00', '2009/8/19 14:00', '2009/8/19 15:00', '2009/8/19 16:00', '2009/8/19 17:00', '2009/8/19 18:00', '2009/8/19 19:00', '2009/8/19 20:00', '2009/8/19 21:00', '2009/8/19 22:00', '2009/8/19 23:00', '2009/8/20 0:00', '2009/8/20 1:00', '2009/8/20 2:00', '2009/8/20 3:00', '2009/8/20 4:00', '2009/8/20 5:00', '2009/8/20 6:00', '2009/8/20 7:00', '2009/8/20 8:00', '2009/8/20 9:00', '2009/8/20 10:00', '2009/8/20 11:00', '2009/8/20 12:00', '2009/8/20 13:00', '2009/8/20 14:00', '2009/8/20 15:00', '2009/8/20 16:00', '2009/8/20 17:00', '2009/8/20 18:00', '2009/8/20 19:00', '2009/8/20 20:00', '2009/8/20 21:00', '2009/8/20 22:00', '2009/8/20 23:00', '2009/8/21 0:00', '2009/8/21 1:00', '2009/8/21 2:00', '2009/8/21 3:00', '2009/8/21 4:00', '2009/8/21 5:00', '2009/8/21 6:00', '2009/8/21 7:00', '2009/8/21 8:00', '2009/8/21 9:00', '2009/8/21 10:00', '2009/8/21 11:00', '2009/8/21 12:00', '2009/8/21 13:00', '2009/8/21 14:00', '2009/8/21 15:00', '2009/8/21 16:00', '2009/8/21 17:00', '2009/8/21 18:00', '2009/8/21 19:00', '2009/8/21 20:00', '2009/8/21 21:00', '2009/8/21 22:00', '2009/8/21 23:00', '2009/8/22 0:00', '2009/8/22 1:00', '2009/8/22 2:00', '2009/8/22 3:00', '2009/8/22 4:00', '2009/8/22 5:00', '2009/8/22 6:00', '2009/8/22 7:00', '2009/8/22 8:00', '2009/8/22 9:00', '2009/8/22 10:00', '2009/8/22 11:00', '2009/8/22 12:00', '2009/8/22 13:00', '2009/8/22 14:00', '2009/8/22 15:00', '2009/8/22 16:00', '2009/8/22 17:00', '2009/8/22 18:00', '2009/8/22 19:00', '2009/8/22 20:00', '2009/8/22 21:00', '2009/8/22 22:00', '2009/8/22 23:00', '2009/8/23 0:00', '2009/8/23 1:00', '2009/8/23 2:00', '2009/8/23 3:00', '2009/8/23 4:00', '2009/8/23 5:00', '2009/8/23 6:00', '2009/8/23 7:00', '2009/8/23 8:00', '2009/8/23 9:00', '2009/8/23 10:00', '2009/8/23 11:00', '2009/8/23 12:00', '2009/8/23 13:00', '2009/8/23 14:00', '2009/8/23 15:00', '2009/8/23 16:00', '2009/8/23 17:00', '2009/8/23 18:00', '2009/8/23 19:00', '2009/8/23 20:00', '2009/8/23 21:00', '2009/8/23 22:00', '2009/8/23 23:00', '2009/8/24 0:00', '2009/8/24 1:00', '2009/8/24 2:00', '2009/8/24 3:00', '2009/8/24 4:00', '2009/8/24 5:00', '2009/8/24 6:00', '2009/8/24 7:00', '2009/8/24 8:00', '2009/8/24 9:00', '2009/8/24 10:00', '2009/8/24 11:00', '2009/8/24 12:00', '2009/8/24 13:00', '2009/8/24 14:00', '2009/8/24 15:00', '2009/8/24 16:00', '2009/8/24 17:00', '2009/8/24 18:00', '2009/8/24 19:00', '2009/8/24 20:00', '2009/8/24 21:00', '2009/8/24 22:00', '2009/8/24 23:00', '2009/8/25 0:00', '2009/8/25 1:00', '2009/8/25 2:00', '2009/8/25 3:00', '2009/8/25 4:00', '2009/8/25 5:00', '2009/8/25 6:00', '2009/8/25 7:00', '2009/8/25 8:00', '2009/8/25 9:00', '2009/8/25 10:00', '2009/8/25 11:00', '2009/8/25 12:00', '2009/8/25 13:00', '2009/8/25 14:00', '2009/8/25 15:00', '2009/8/25 16:00', '2009/8/25 17:00', '2009/8/25 18:00', '2009/8/25 19:00', '2009/8/25 20:00', '2009/8/25 21:00', '2009/8/25 22:00', '2009/8/25 23:00', '2009/8/26 0:00', '2009/8/26 1:00', '2009/8/26 2:00', '2009/8/26 3:00', '2009/8/26 4:00', '2009/8/26 5:00', '2009/8/26 6:00', '2009/8/26 7:00', '2009/8/26 8:00', '2009/8/26 9:00', '2009/8/26 10:00', '2009/8/26 11:00', '2009/8/26 12:00', '2009/8/26 13:00', '2009/8/26 14:00', '2009/8/26 15:00', '2009/8/26 16:00', '2009/8/26 17:00', '2009/8/26 18:00', '2009/8/26 19:00', '2009/8/26 20:00', '2009/8/26 21:00', '2009/8/26 22:00', '2009/8/26 23:00', '2009/8/27 0:00', '2009/8/27 1:00', '2009/8/27 2:00', '2009/8/27 3:00', '2009/8/27 4:00', '2009/8/27 5:00', '2009/8/27 6:00', '2009/8/27 7:00', '2009/8/27 8:00', '2009/8/27 9:00', '2009/8/27 10:00', '2009/8/27 11:00', '2009/8/27 12:00', '2009/8/27 13:00', '2009/8/27 14:00', '2009/8/27 15:00', '2009/8/27 16:00', '2009/8/27 17:00', '2009/8/27 18:00', '2009/8/27 19:00', '2009/8/27 20:00', '2009/8/27 21:00', '2009/8/27 22:00', '2009/8/27 23:00', '2009/8/28 0:00', '2009/8/28 1:00', '2009/8/28 2:00', '2009/8/28 3:00', '2009/8/28 4:00', '2009/8/28 5:00', '2009/8/28 6:00', '2009/8/28 7:00', '2009/8/28 8:00', '2009/8/28 9:00', '2009/8/28 10:00', '2009/8/28 11:00', '2009/8/28 12:00', '2009/8/28 13:00', '2009/8/28 14:00', '2009/8/28 15:00', '2009/8/28 16:00', '2009/8/28 17:00', '2009/8/28 18:00', '2009/8/28 19:00', '2009/8/28 20:00', '2009/8/28 21:00', '2009/8/28 22:00', '2009/8/28 23:00', '2009/8/29 0:00', '2009/8/29 1:00', '2009/8/29 2:00', '2009/8/29 3:00', '2009/8/29 4:00', '2009/8/29 5:00', '2009/8/29 6:00', '2009/8/29 7:00', '2009/8/29 8:00', '2009/8/29 9:00', '2009/8/29 10:00', '2009/8/29 11:00', '2009/8/29 12:00', '2009/8/29 13:00', '2009/8/29 14:00', '2009/8/29 15:00', '2009/8/29 16:00', '2009/8/29 17:00', '2009/8/29 18:00', '2009/8/29 19:00', '2009/8/29 20:00', '2009/8/29 21:00', '2009/8/29 22:00', '2009/8/29 23:00', '2009/8/30 0:00', '2009/8/30 1:00', '2009/8/30 2:00', '2009/8/30 3:00', '2009/8/30 4:00', '2009/8/30 5:00', '2009/8/30 6:00', '2009/8/30 7:00', '2009/8/30 8:00', '2009/8/30 9:00', '2009/8/30 10:00', '2009/8/30 11:00', '2009/8/30 12:00', '2009/8/30 13:00', '2009/8/30 14:00', '2009/8/30 15:00', '2009/8/30 16:00', '2009/8/30 17:00', '2009/8/30 18:00', '2009/8/30 19:00', '2009/8/30 20:00', '2009/8/30 21:00', '2009/8/30 22:00', '2009/8/30 23:00', '2009/8/31 0:00', '2009/8/31 1:00', '2009/8/31 2:00', '2009/8/31 3:00', '2009/8/31 4:00', '2009/8/31 5:00', '2009/8/31 6:00', '2009/8/31 7:00', '2009/8/31 8:00', '2009/8/31 9:00', '2009/8/31 10:00', '2009/8/31 11:00', '2009/8/31 12:00', '2009/8/31 13:00', '2009/8/31 14:00', '2009/8/31 15:00', '2009/8/31 16:00', '2009/8/31 17:00', '2009/8/31 18:00', '2009/8/31 19:00', '2009/8/31 20:00', '2009/8/31 21:00', '2009/8/31 22:00', '2009/8/31 23:00', + '2009/9/1 0:00', '2009/9/1 1:00', '2009/9/1 2:00', '2009/9/1 3:00', '2009/9/1 4:00', '2009/9/1 5:00', '2009/9/1 6:00', '2009/9/1 7:00', '2009/9/1 8:00', '2009/9/1 9:00', '2009/9/1 10:00', '2009/9/1 11:00', '2009/9/1 12:00', '2009/9/1 13:00', '2009/9/1 14:00', '2009/9/1 15:00', '2009/9/1 16:00', '2009/9/1 17:00', '2009/9/1 18:00', '2009/9/1 19:00', '2009/9/1 20:00', '2009/9/1 21:00', '2009/9/1 22:00', '2009/9/1 23:00', '2009/9/2 0:00', '2009/9/2 1:00', '2009/9/2 2:00', '2009/9/2 3:00', '2009/9/2 4:00', '2009/9/2 5:00', '2009/9/2 6:00', '2009/9/2 7:00', '2009/9/2 8:00', '2009/9/2 9:00', '2009/9/2 10:00', '2009/9/2 11:00', '2009/9/2 12:00', '2009/9/2 13:00', '2009/9/2 14:00', '2009/9/2 15:00', '2009/9/2 16:00', '2009/9/2 17:00', '2009/9/2 18:00', '2009/9/2 19:00', '2009/9/2 20:00', '2009/9/2 21:00', '2009/9/2 22:00', '2009/9/2 23:00', '2009/9/3 0:00', '2009/9/3 1:00', '2009/9/3 2:00', '2009/9/3 3:00', '2009/9/3 4:00', '2009/9/3 5:00', '2009/9/3 6:00', '2009/9/3 7:00', '2009/9/3 8:00', '2009/9/3 9:00', '2009/9/3 10:00', '2009/9/3 11:00', '2009/9/3 12:00', '2009/9/3 13:00', '2009/9/3 14:00', '2009/9/3 15:00', '2009/9/3 16:00', '2009/9/3 17:00', '2009/9/3 18:00', '2009/9/3 19:00', '2009/9/3 20:00', '2009/9/3 21:00', '2009/9/3 22:00', '2009/9/3 23:00', '2009/9/4 0:00', '2009/9/4 1:00', '2009/9/4 2:00', '2009/9/4 3:00', '2009/9/4 4:00', '2009/9/4 5:00', '2009/9/4 6:00', '2009/9/4 7:00', '2009/9/4 8:00', '2009/9/4 9:00', '2009/9/4 10:00', '2009/9/4 11:00', '2009/9/4 12:00', '2009/9/4 13:00', '2009/9/4 14:00', '2009/9/4 15:00', '2009/9/4 16:00', '2009/9/4 17:00', '2009/9/4 18:00', '2009/9/4 19:00', '2009/9/4 20:00', '2009/9/4 21:00', '2009/9/4 22:00', '2009/9/4 23:00', '2009/9/5 0:00', '2009/9/5 1:00', '2009/9/5 2:00', '2009/9/5 3:00', '2009/9/5 4:00', '2009/9/5 5:00', '2009/9/5 6:00', '2009/9/5 7:00', '2009/9/5 8:00', '2009/9/5 9:00', '2009/9/5 10:00', '2009/9/5 11:00', '2009/9/5 12:00', '2009/9/5 13:00', '2009/9/5 14:00', '2009/9/5 15:00', '2009/9/5 16:00', '2009/9/5 17:00', '2009/9/5 18:00', '2009/9/5 19:00', '2009/9/5 20:00', '2009/9/5 21:00', '2009/9/5 22:00', '2009/9/5 23:00', '2009/9/6 0:00', '2009/9/6 1:00', '2009/9/6 2:00', '2009/9/6 3:00', '2009/9/6 4:00', '2009/9/6 5:00', '2009/9/6 6:00', '2009/9/6 7:00', '2009/9/6 8:00', '2009/9/6 9:00', '2009/9/6 10:00', '2009/9/6 11:00', '2009/9/6 12:00', '2009/9/6 13:00', '2009/9/6 14:00', '2009/9/6 15:00', '2009/9/6 16:00', '2009/9/6 17:00', '2009/9/6 18:00', '2009/9/6 19:00', '2009/9/6 20:00', '2009/9/6 21:00', '2009/9/6 22:00', '2009/9/6 23:00', '2009/9/7 0:00', '2009/9/7 1:00', '2009/9/7 2:00', '2009/9/7 3:00', '2009/9/7 4:00', '2009/9/7 5:00', '2009/9/7 6:00', '2009/9/7 7:00', '2009/9/7 8:00', '2009/9/7 9:00', '2009/9/7 10:00', '2009/9/7 11:00', '2009/9/7 12:00', '2009/9/7 13:00', '2009/9/7 14:00', '2009/9/7 15:00', '2009/9/7 16:00', '2009/9/7 17:00', '2009/9/7 18:00', '2009/9/7 19:00', '2009/9/7 20:00', '2009/9/7 21:00', '2009/9/7 22:00', '2009/9/7 23:00', '2009/9/8 0:00', '2009/9/8 1:00', '2009/9/8 2:00', '2009/9/8 3:00', '2009/9/8 4:00', '2009/9/8 5:00', '2009/9/8 6:00', '2009/9/8 7:00', '2009/9/8 8:00', '2009/9/8 9:00', '2009/9/8 10:00', '2009/9/8 11:00', '2009/9/8 12:00', '2009/9/8 13:00', '2009/9/8 14:00', '2009/9/8 15:00', '2009/9/8 16:00', '2009/9/8 17:00', '2009/9/8 18:00', '2009/9/8 19:00', '2009/9/8 20:00', '2009/9/8 21:00', '2009/9/8 22:00', '2009/9/8 23:00', '2009/9/9 0:00', '2009/9/9 1:00', '2009/9/9 2:00', '2009/9/9 3:00', '2009/9/9 4:00', '2009/9/9 5:00', '2009/9/9 6:00', '2009/9/9 7:00', '2009/9/9 8:00', '2009/9/9 9:00', '2009/9/9 10:00', '2009/9/9 11:00', '2009/9/9 12:00', '2009/9/9 13:00', '2009/9/9 14:00', '2009/9/9 15:00', '2009/9/9 16:00', '2009/9/9 17:00', '2009/9/9 18:00', '2009/9/9 19:00', '2009/9/9 20:00', '2009/9/9 21:00', '2009/9/9 22:00', '2009/9/9 23:00', '2009/9/10 0:00', '2009/9/10 1:00', '2009/9/10 2:00', '2009/9/10 3:00', '2009/9/10 4:00', '2009/9/10 5:00', '2009/9/10 6:00', '2009/9/10 7:00', '2009/9/10 8:00', '2009/9/10 9:00', '2009/9/10 10:00', '2009/9/10 11:00', '2009/9/10 12:00', '2009/9/10 13:00', '2009/9/10 14:00', '2009/9/10 15:00', '2009/9/10 16:00', '2009/9/10 17:00', '2009/9/10 18:00', '2009/9/10 19:00', '2009/9/10 20:00', '2009/9/10 21:00', '2009/9/10 22:00', '2009/9/10 23:00', '2009/9/11 0:00', '2009/9/11 1:00', '2009/9/11 2:00', '2009/9/11 3:00', '2009/9/11 4:00', '2009/9/11 5:00', '2009/9/11 6:00', '2009/9/11 7:00', '2009/9/11 8:00', '2009/9/11 9:00', '2009/9/11 10:00', '2009/9/11 11:00', '2009/9/11 12:00', '2009/9/11 13:00', '2009/9/11 14:00', '2009/9/11 15:00', '2009/9/11 16:00', '2009/9/11 17:00', '2009/9/11 18:00', '2009/9/11 19:00', '2009/9/11 20:00', '2009/9/11 21:00', '2009/9/11 22:00', '2009/9/11 23:00', '2009/9/12 0:00', '2009/9/12 1:00', '2009/9/12 2:00', '2009/9/12 3:00', '2009/9/12 4:00', '2009/9/12 5:00', '2009/9/12 6:00', '2009/9/12 7:00', '2009/9/12 8:00', '2009/9/12 9:00', '2009/9/12 10:00', '2009/9/12 11:00', '2009/9/12 12:00', '2009/9/12 13:00', '2009/9/12 14:00', '2009/9/12 15:00', '2009/9/12 16:00', '2009/9/12 17:00', '2009/9/12 18:00', '2009/9/12 19:00', '2009/9/12 20:00', '2009/9/12 21:00', '2009/9/12 22:00', '2009/9/12 23:00', '2009/9/13 0:00', '2009/9/13 1:00', '2009/9/13 2:00', '2009/9/13 3:00', '2009/9/13 4:00', '2009/9/13 5:00', '2009/9/13 6:00', '2009/9/13 7:00', '2009/9/13 8:00', '2009/9/13 9:00', '2009/9/13 10:00', '2009/9/13 11:00', '2009/9/13 12:00', '2009/9/13 13:00', '2009/9/13 14:00', '2009/9/13 15:00', '2009/9/13 16:00', '2009/9/13 17:00', '2009/9/13 18:00', '2009/9/13 19:00', '2009/9/13 20:00', '2009/9/13 21:00', '2009/9/13 22:00', '2009/9/13 23:00', '2009/9/14 0:00', '2009/9/14 1:00', '2009/9/14 2:00', '2009/9/14 3:00', '2009/9/14 4:00', '2009/9/14 5:00', '2009/9/14 6:00', '2009/9/14 7:00', '2009/9/14 8:00', '2009/9/14 9:00', '2009/9/14 10:00', '2009/9/14 11:00', '2009/9/14 12:00', '2009/9/14 13:00', '2009/9/14 14:00', '2009/9/14 15:00', '2009/9/14 16:00', '2009/9/14 17:00', '2009/9/14 18:00', '2009/9/14 19:00', '2009/9/14 20:00', '2009/9/14 21:00', '2009/9/14 22:00', '2009/9/14 23:00', '2009/9/15 0:00', '2009/9/15 1:00', '2009/9/15 2:00', '2009/9/15 3:00', '2009/9/15 4:00', '2009/9/15 5:00', '2009/9/15 6:00', '2009/9/15 7:00', '2009/9/15 8:00', '2009/9/15 9:00', '2009/9/15 10:00', '2009/9/15 11:00', '2009/9/15 12:00', '2009/9/15 13:00', '2009/9/15 14:00', '2009/9/15 15:00', '2009/9/15 16:00', '2009/9/15 17:00', '2009/9/15 18:00', '2009/9/15 19:00', '2009/9/15 20:00', '2009/9/15 21:00', '2009/9/15 22:00', '2009/9/15 23:00', '2009/9/16 0:00', '2009/9/16 1:00', '2009/9/16 2:00', '2009/9/16 3:00', '2009/9/16 4:00', '2009/9/16 5:00', '2009/9/16 6:00', '2009/9/16 7:00', '2009/9/16 8:00', '2009/9/16 9:00', '2009/9/16 10:00', '2009/9/16 11:00', '2009/9/16 12:00', '2009/9/16 13:00', '2009/9/16 14:00', '2009/9/16 15:00', '2009/9/16 16:00', '2009/9/16 17:00', '2009/9/16 18:00', '2009/9/16 19:00', '2009/9/16 20:00', '2009/9/16 21:00', '2009/9/16 22:00', '2009/9/16 23:00', '2009/9/17 0:00', '2009/9/17 1:00', '2009/9/17 2:00', '2009/9/17 3:00', '2009/9/17 4:00', '2009/9/17 5:00', '2009/9/17 6:00', '2009/9/17 7:00', '2009/9/17 8:00', '2009/9/17 9:00', '2009/9/17 10:00', '2009/9/17 11:00', '2009/9/17 12:00', '2009/9/17 13:00', '2009/9/17 14:00', '2009/9/17 15:00', '2009/9/17 16:00', '2009/9/17 17:00', '2009/9/17 18:00', '2009/9/17 19:00', '2009/9/17 20:00', '2009/9/17 21:00', '2009/9/17 22:00', '2009/9/17 23:00', '2009/9/18 0:00', '2009/9/18 1:00', '2009/9/18 2:00', '2009/9/18 3:00', '2009/9/18 4:00', '2009/9/18 5:00', '2009/9/18 6:00', '2009/9/18 7:00', '2009/9/18 8:00', '2009/9/18 9:00', '2009/9/18 10:00', '2009/9/18 11:00', '2009/9/18 12:00', '2009/9/18 13:00', '2009/9/18 14:00', '2009/9/18 15:00', '2009/9/18 16:00', '2009/9/18 17:00', '2009/9/18 18:00', '2009/9/18 19:00', '2009/9/18 20:00', '2009/9/18 21:00', '2009/9/18 22:00', '2009/9/18 23:00', '2009/9/19 0:00', '2009/9/19 1:00', '2009/9/19 2:00', '2009/9/19 3:00', '2009/9/19 4:00', '2009/9/19 5:00', '2009/9/19 6:00', '2009/9/19 7:00', '2009/9/19 8:00', '2009/9/19 9:00', '2009/9/19 10:00', '2009/9/19 11:00', '2009/9/19 12:00', '2009/9/19 13:00', '2009/9/19 14:00', '2009/9/19 15:00', '2009/9/19 16:00', '2009/9/19 17:00', '2009/9/19 18:00', '2009/9/19 19:00', '2009/9/19 20:00', '2009/9/19 21:00', '2009/9/19 22:00', '2009/9/19 23:00', '2009/9/20 0:00', '2009/9/20 1:00', '2009/9/20 2:00', '2009/9/20 3:00', '2009/9/20 4:00', '2009/9/20 5:00', '2009/9/20 6:00', '2009/9/20 7:00', '2009/9/20 8:00', '2009/9/20 9:00', '2009/9/20 10:00', '2009/9/20 11:00', '2009/9/20 12:00', '2009/9/20 13:00', '2009/9/20 14:00', '2009/9/20 15:00', '2009/9/20 16:00', '2009/9/20 17:00', '2009/9/20 18:00', '2009/9/20 19:00', '2009/9/20 20:00', '2009/9/20 21:00', '2009/9/20 22:00', '2009/9/20 23:00', '2009/9/21 0:00', '2009/9/21 1:00', '2009/9/21 2:00', '2009/9/21 3:00', '2009/9/21 4:00', '2009/9/21 5:00', '2009/9/21 6:00', '2009/9/21 7:00', '2009/9/21 8:00', '2009/9/21 9:00', '2009/9/21 10:00', '2009/9/21 11:00', '2009/9/21 12:00', '2009/9/21 13:00', '2009/9/21 14:00', '2009/9/21 15:00', '2009/9/21 16:00', '2009/9/21 17:00', '2009/9/21 18:00', '2009/9/21 19:00', '2009/9/21 20:00', '2009/9/21 21:00', '2009/9/21 22:00', '2009/9/21 23:00', '2009/9/22 0:00', '2009/9/22 1:00', '2009/9/22 2:00', '2009/9/22 3:00', '2009/9/22 4:00', '2009/9/22 5:00', '2009/9/22 6:00', '2009/9/22 7:00', '2009/9/22 8:00', '2009/9/22 9:00', '2009/9/22 10:00', '2009/9/22 11:00', '2009/9/22 12:00', '2009/9/22 13:00', '2009/9/22 14:00', '2009/9/22 15:00', '2009/9/22 16:00', '2009/9/22 17:00', '2009/9/22 18:00', '2009/9/22 19:00', '2009/9/22 20:00', '2009/9/22 21:00', '2009/9/22 22:00', '2009/9/22 23:00', '2009/9/23 0:00', '2009/9/23 1:00', '2009/9/23 2:00', '2009/9/23 3:00', '2009/9/23 4:00', '2009/9/23 5:00', '2009/9/23 6:00', '2009/9/23 7:00', '2009/9/23 8:00', '2009/9/23 9:00', '2009/9/23 10:00', '2009/9/23 11:00', '2009/9/23 12:00', '2009/9/23 13:00', '2009/9/23 14:00', '2009/9/23 15:00', '2009/9/23 16:00', '2009/9/23 17:00', '2009/9/23 18:00', '2009/9/23 19:00', '2009/9/23 20:00', '2009/9/23 21:00', '2009/9/23 22:00', '2009/9/23 23:00', '2009/9/24 0:00', '2009/9/24 1:00', '2009/9/24 2:00', '2009/9/24 3:00', '2009/9/24 4:00', '2009/9/24 5:00', '2009/9/24 6:00', '2009/9/24 7:00', '2009/9/24 8:00', '2009/9/24 9:00', '2009/9/24 10:00', '2009/9/24 11:00', '2009/9/24 12:00', '2009/9/24 13:00', '2009/9/24 14:00', '2009/9/24 15:00', '2009/9/24 16:00', '2009/9/24 17:00', '2009/9/24 18:00', '2009/9/24 19:00', '2009/9/24 20:00', '2009/9/24 21:00', '2009/9/24 22:00', '2009/9/24 23:00', '2009/9/25 0:00', '2009/9/25 1:00', '2009/9/25 2:00', '2009/9/25 3:00', '2009/9/25 4:00', '2009/9/25 5:00', '2009/9/25 6:00', '2009/9/25 7:00', '2009/9/25 8:00', '2009/9/25 9:00', '2009/9/25 10:00', '2009/9/25 11:00', '2009/9/25 12:00', '2009/9/25 13:00', '2009/9/25 14:00', '2009/9/25 15:00', '2009/9/25 16:00', '2009/9/25 17:00', '2009/9/25 18:00', '2009/9/25 19:00', '2009/9/25 20:00', '2009/9/25 21:00', '2009/9/25 22:00', '2009/9/25 23:00', '2009/9/26 0:00', '2009/9/26 1:00', '2009/9/26 2:00', '2009/9/26 3:00', '2009/9/26 4:00', '2009/9/26 5:00', '2009/9/26 6:00', '2009/9/26 7:00', '2009/9/26 8:00', '2009/9/26 9:00', '2009/9/26 10:00', '2009/9/26 11:00', '2009/9/26 12:00', '2009/9/26 13:00', '2009/9/26 14:00', '2009/9/26 15:00', '2009/9/26 16:00', '2009/9/26 17:00', '2009/9/26 18:00', '2009/9/26 19:00', '2009/9/26 20:00', '2009/9/26 21:00', '2009/9/26 22:00', '2009/9/26 23:00', '2009/9/27 0:00', '2009/9/27 1:00', '2009/9/27 2:00', '2009/9/27 3:00', '2009/9/27 4:00', '2009/9/27 5:00', '2009/9/27 6:00', '2009/9/27 7:00', '2009/9/27 8:00', '2009/9/27 9:00', '2009/9/27 10:00', '2009/9/27 11:00', '2009/9/27 12:00', '2009/9/27 13:00', '2009/9/27 14:00', '2009/9/27 15:00', '2009/9/27 16:00', '2009/9/27 17:00', '2009/9/27 18:00', '2009/9/27 19:00', '2009/9/27 20:00', '2009/9/27 21:00', '2009/9/27 22:00', '2009/9/27 23:00', '2009/9/28 0:00', '2009/9/28 1:00', '2009/9/28 2:00', '2009/9/28 3:00', '2009/9/28 4:00', '2009/9/28 5:00', '2009/9/28 6:00', '2009/9/28 7:00', '2009/9/28 8:00', '2009/9/28 9:00', '2009/9/28 10:00', '2009/9/28 11:00', '2009/9/28 12:00', '2009/9/28 13:00', '2009/9/28 14:00', '2009/9/28 15:00', '2009/9/28 16:00', '2009/9/28 17:00', '2009/9/28 18:00', '2009/9/28 19:00', '2009/9/28 20:00', '2009/9/28 21:00', '2009/9/28 22:00', '2009/9/28 23:00', '2009/9/29 0:00', '2009/9/29 1:00', '2009/9/29 2:00', '2009/9/29 3:00', '2009/9/29 4:00', '2009/9/29 5:00', '2009/9/29 6:00', '2009/9/29 7:00', '2009/9/29 8:00', '2009/9/29 9:00', '2009/9/29 10:00', '2009/9/29 11:00', '2009/9/29 12:00', '2009/9/29 13:00', '2009/9/29 14:00', '2009/9/29 15:00', '2009/9/29 16:00', '2009/9/29 17:00', '2009/9/29 18:00', '2009/9/29 19:00', '2009/9/29 20:00', '2009/9/29 21:00', '2009/9/29 22:00', '2009/9/29 23:00', '2009/9/30 0:00', '2009/9/30 1:00', '2009/9/30 2:00', '2009/9/30 3:00', '2009/9/30 4:00', '2009/9/30 5:00', '2009/9/30 6:00', '2009/9/30 7:00', '2009/9/30 8:00', '2009/9/30 9:00', '2009/9/30 10:00', '2009/9/30 11:00', '2009/9/30 12:00', '2009/9/30 13:00', '2009/9/30 14:00', '2009/9/30 15:00', '2009/9/30 16:00', '2009/9/30 17:00', '2009/9/30 18:00', '2009/9/30 19:00', '2009/9/30 20:00', '2009/9/30 21:00', '2009/9/30 22:00', '2009/9/30 23:00', + '2009/10/1 0:00', '2009/10/1 1:00', '2009/10/1 2:00', '2009/10/1 3:00', '2009/10/1 4:00', '2009/10/1 5:00', '2009/10/1 6:00', '2009/10/1 7:00', '2009/10/1 8:00', '2009/10/1 9:00', '2009/10/1 10:00', '2009/10/1 11:00', '2009/10/1 12:00', '2009/10/1 13:00', '2009/10/1 14:00', '2009/10/1 15:00', '2009/10/1 16:00', '2009/10/1 17:00', '2009/10/1 18:00', '2009/10/1 19:00', '2009/10/1 20:00', '2009/10/1 21:00', '2009/10/1 22:00', '2009/10/1 23:00', '2009/10/2 0:00', '2009/10/2 1:00', '2009/10/2 2:00', '2009/10/2 3:00', '2009/10/2 4:00', '2009/10/2 5:00', '2009/10/2 6:00', '2009/10/2 7:00', '2009/10/2 8:00', '2009/10/2 9:00', '2009/10/2 10:00', '2009/10/2 11:00', '2009/10/2 12:00', '2009/10/2 13:00', '2009/10/2 14:00', '2009/10/2 15:00', '2009/10/2 16:00', '2009/10/2 17:00', '2009/10/2 18:00', '2009/10/2 19:00', '2009/10/2 20:00', '2009/10/2 21:00', '2009/10/2 22:00', '2009/10/2 23:00', '2009/10/3 0:00', '2009/10/3 1:00', '2009/10/3 2:00', '2009/10/3 3:00', '2009/10/3 4:00', '2009/10/3 5:00', '2009/10/3 6:00', '2009/10/3 7:00', '2009/10/3 8:00', '2009/10/3 9:00', '2009/10/3 10:00', '2009/10/3 11:00', '2009/10/3 12:00', '2009/10/3 13:00', '2009/10/3 14:00', '2009/10/3 15:00', '2009/10/3 16:00', '2009/10/3 17:00', '2009/10/3 18:00', '2009/10/3 19:00', '2009/10/3 20:00', '2009/10/3 21:00', '2009/10/3 22:00', '2009/10/3 23:00', '2009/10/4 0:00', '2009/10/4 1:00', '2009/10/4 2:00', '2009/10/4 3:00', '2009/10/4 4:00', '2009/10/4 5:00', '2009/10/4 6:00', '2009/10/4 7:00', '2009/10/4 8:00', '2009/10/4 9:00', '2009/10/4 10:00', '2009/10/4 11:00', '2009/10/4 12:00', '2009/10/4 13:00', '2009/10/4 14:00', '2009/10/4 15:00', '2009/10/4 16:00', '2009/10/4 17:00', '2009/10/4 18:00', '2009/10/4 19:00', '2009/10/4 20:00', '2009/10/4 21:00', '2009/10/4 22:00', '2009/10/4 23:00', '2009/10/5 0:00', '2009/10/5 1:00', '2009/10/5 2:00', '2009/10/5 3:00', '2009/10/5 4:00', '2009/10/5 5:00', '2009/10/5 6:00', '2009/10/5 7:00', '2009/10/5 8:00', '2009/10/5 9:00', '2009/10/5 10:00', '2009/10/5 11:00', '2009/10/5 12:00', '2009/10/5 13:00', '2009/10/5 14:00', '2009/10/5 15:00', '2009/10/5 16:00', '2009/10/5 17:00', '2009/10/5 18:00', '2009/10/5 19:00', '2009/10/5 20:00', '2009/10/5 21:00', '2009/10/5 22:00', '2009/10/5 23:00', '2009/10/6 0:00', '2009/10/6 1:00', '2009/10/6 2:00', '2009/10/6 3:00', '2009/10/6 4:00', '2009/10/6 5:00', '2009/10/6 6:00', '2009/10/6 7:00', '2009/10/6 8:00', '2009/10/6 9:00', '2009/10/6 10:00', '2009/10/6 11:00', '2009/10/6 12:00', '2009/10/6 13:00', '2009/10/6 14:00', '2009/10/6 15:00', '2009/10/6 16:00', '2009/10/6 17:00', '2009/10/6 18:00', '2009/10/6 19:00', '2009/10/6 20:00', '2009/10/6 21:00', '2009/10/6 22:00', '2009/10/6 23:00', '2009/10/7 0:00', '2009/10/7 1:00', '2009/10/7 2:00', '2009/10/7 3:00', '2009/10/7 4:00', '2009/10/7 5:00', '2009/10/7 6:00', '2009/10/7 7:00', '2009/10/7 8:00', '2009/10/7 9:00', '2009/10/7 10:00', '2009/10/7 11:00', '2009/10/7 12:00', '2009/10/7 13:00', '2009/10/7 14:00', '2009/10/7 15:00', '2009/10/7 16:00', '2009/10/7 17:00', '2009/10/7 18:00', '2009/10/7 19:00', '2009/10/7 20:00', '2009/10/7 21:00', '2009/10/7 22:00', '2009/10/7 23:00', '2009/10/8 0:00', '2009/10/8 1:00', '2009/10/8 2:00', '2009/10/8 3:00', '2009/10/8 4:00', '2009/10/8 5:00', '2009/10/8 6:00', '2009/10/8 7:00', '2009/10/8 8:00', '2009/10/8 9:00', '2009/10/8 10:00', '2009/10/8 11:00', '2009/10/8 12:00', '2009/10/8 13:00', '2009/10/8 14:00', '2009/10/8 15:00', '2009/10/8 16:00', '2009/10/8 17:00', '2009/10/8 18:00', '2009/10/8 19:00', '2009/10/8 20:00', '2009/10/8 21:00', '2009/10/8 22:00', '2009/10/8 23:00', '2009/10/9 0:00', '2009/10/9 1:00', '2009/10/9 2:00', '2009/10/9 3:00', '2009/10/9 4:00', '2009/10/9 5:00', '2009/10/9 6:00', '2009/10/9 7:00', '2009/10/9 8:00', '2009/10/9 9:00', '2009/10/9 10:00', '2009/10/9 11:00', '2009/10/9 12:00', '2009/10/9 13:00', '2009/10/9 14:00', '2009/10/9 15:00', '2009/10/9 16:00', '2009/10/9 17:00', '2009/10/9 18:00', '2009/10/9 19:00', '2009/10/9 20:00', '2009/10/9 21:00', '2009/10/9 22:00', '2009/10/9 23:00', '2009/10/10 0:00', '2009/10/10 1:00', '2009/10/10 2:00', '2009/10/10 3:00', '2009/10/10 4:00', '2009/10/10 5:00', '2009/10/10 6:00', '2009/10/10 7:00', '2009/10/10 8:00', '2009/10/10 9:00', '2009/10/10 10:00', '2009/10/10 11:00', '2009/10/10 12:00', '2009/10/10 13:00', '2009/10/10 14:00', '2009/10/10 15:00', '2009/10/10 16:00', '2009/10/10 17:00', '2009/10/10 18:00', '2009/10/10 19:00', '2009/10/10 20:00', '2009/10/10 21:00', '2009/10/10 22:00', '2009/10/10 23:00', '2009/10/11 0:00', '2009/10/11 1:00', '2009/10/11 2:00', '2009/10/11 3:00', '2009/10/11 4:00', '2009/10/11 5:00', '2009/10/11 6:00', '2009/10/11 7:00', '2009/10/11 8:00', '2009/10/11 9:00', '2009/10/11 10:00', '2009/10/11 11:00', '2009/10/11 12:00', '2009/10/11 13:00', '2009/10/11 14:00', '2009/10/11 15:00', '2009/10/11 16:00', '2009/10/11 17:00', '2009/10/11 18:00', '2009/10/11 19:00', '2009/10/11 20:00', '2009/10/11 21:00', '2009/10/11 22:00', '2009/10/11 23:00', '2009/10/12 0:00', '2009/10/12 1:00', '2009/10/12 2:00', '2009/10/12 3:00', '2009/10/12 4:00', '2009/10/12 5:00', '2009/10/12 6:00', '2009/10/12 7:00', '2009/10/12 8:00', '2009/10/12 9:00', '2009/10/12 10:00', '2009/10/12 11:00', '2009/10/12 12:00', '2009/10/12 13:00', '2009/10/12 14:00', '2009/10/12 15:00', '2009/10/12 16:00', '2009/10/12 17:00', '2009/10/12 18:00', '2009/10/12 19:00', '2009/10/12 20:00', '2009/10/12 21:00', '2009/10/12 22:00', '2009/10/12 23:00', '2009/10/13 0:00', '2009/10/13 1:00', '2009/10/13 2:00', '2009/10/13 3:00', '2009/10/13 4:00', '2009/10/13 5:00', '2009/10/13 6:00', '2009/10/13 7:00', '2009/10/13 8:00', '2009/10/13 9:00', '2009/10/13 10:00', '2009/10/13 11:00', '2009/10/13 12:00', '2009/10/13 13:00', '2009/10/13 14:00', '2009/10/13 15:00', '2009/10/13 16:00', '2009/10/13 17:00', '2009/10/13 18:00', '2009/10/13 19:00', '2009/10/13 20:00', '2009/10/13 21:00', '2009/10/13 22:00', '2009/10/13 23:00', '2009/10/14 0:00', '2009/10/14 1:00', '2009/10/14 2:00', '2009/10/14 3:00', '2009/10/14 4:00', '2009/10/14 5:00', '2009/10/14 6:00', '2009/10/14 7:00', '2009/10/14 8:00', '2009/10/14 9:00', '2009/10/14 10:00', '2009/10/14 11:00', '2009/10/14 12:00', '2009/10/14 13:00', '2009/10/14 14:00', '2009/10/14 15:00', '2009/10/14 16:00', '2009/10/14 17:00', '2009/10/14 18:00', '2009/10/14 19:00', '2009/10/14 20:00', '2009/10/14 21:00', '2009/10/14 22:00', '2009/10/14 23:00', '2009/10/15 0:00', '2009/10/15 1:00', '2009/10/15 2:00', '2009/10/15 3:00', '2009/10/15 4:00', '2009/10/15 5:00', '2009/10/15 6:00', '2009/10/15 7:00', '2009/10/15 8:00', '2009/10/15 9:00', '2009/10/15 10:00', '2009/10/15 11:00', '2009/10/15 12:00', '2009/10/15 13:00', '2009/10/15 14:00', '2009/10/15 15:00', '2009/10/15 16:00', '2009/10/15 17:00', '2009/10/15 18:00', '2009/10/15 19:00', '2009/10/15 20:00', '2009/10/15 21:00', '2009/10/15 22:00', '2009/10/15 23:00', '2009/10/16 0:00', '2009/10/16 1:00', '2009/10/16 2:00', '2009/10/16 3:00', '2009/10/16 4:00', '2009/10/16 5:00', '2009/10/16 6:00', '2009/10/16 7:00', '2009/10/16 8:00', '2009/10/16 9:00', '2009/10/16 10:00', '2009/10/16 11:00', '2009/10/16 12:00', '2009/10/16 13:00', '2009/10/16 14:00', '2009/10/16 15:00', '2009/10/16 16:00', '2009/10/16 17:00', '2009/10/16 18:00', '2009/10/16 19:00', '2009/10/16 20:00', '2009/10/16 21:00', '2009/10/16 22:00', '2009/10/16 23:00', '2009/10/17 0:00', '2009/10/17 1:00', '2009/10/17 2:00', '2009/10/17 3:00', '2009/10/17 4:00', '2009/10/17 5:00', '2009/10/17 6:00', '2009/10/17 7:00', '2009/10/17 8:00', '2009/10/17 9:00', '2009/10/17 10:00', '2009/10/17 11:00', '2009/10/17 12:00', '2009/10/17 13:00', '2009/10/17 14:00', '2009/10/17 15:00', '2009/10/17 16:00', '2009/10/17 17:00', '2009/10/17 18:00', '2009/10/17 19:00', '2009/10/17 20:00', '2009/10/17 21:00', '2009/10/17 22:00', '2009/10/17 23:00', '2009/10/18 0:00', '2009/10/18 1:00', '2009/10/18 2:00', '2009/10/18 3:00', '2009/10/18 4:00', '2009/10/18 5:00', '2009/10/18 6:00', '2009/10/18 7:00', '2009/10/18 8:00' +]; +timeData = timeData.map(function (str) { + return str.replace('2009/', ''); +}); +option = { + title: { + text: 'Rainfall vs Evaporation', + left: 'center' + }, + tooltip: { + trigger: 'axis', + axisPointer: { + animation: false + } + }, + legend: { + data: ['Evaporation', 'Rainfall'], + left: 10 + }, + toolbox: { + feature: { + dataZoom: { + yAxisIndex: 'none' + }, + restore: {}, + saveAsImage: {} + } + }, + axisPointer: { + link: [ + { + xAxisIndex: 'all' + } + ] + }, + dataZoom: [ + { + show: true, + realtime: true, + start: 30, + end: 70, + xAxisIndex: [0, 1] + }, + { + type: 'inside', + realtime: true, + start: 30, + end: 70, + xAxisIndex: [0, 1] + } + ], + grid: [ + { + left: 60, + right: 50, + height: '35%' + }, + { + left: 60, + right: 50, + top: '55%', + height: '35%' + } + ], + xAxis: [ + { + type: 'category', + boundaryGap: false, + axisLine: { onZero: true }, + data: timeData + }, + { + gridIndex: 1, + type: 'category', + boundaryGap: false, + axisLine: { onZero: true }, + data: timeData, + position: 'top' + } + ], + yAxis: [ + { + name: 'Evaporation(m³/s)', + type: 'value', + max: 500 + }, + { + gridIndex: 1, + name: 'Rainfall(mm)', + type: 'value', + inverse: true + } + ], + series: [ + { + name: 'Evaporation', + type: 'line', + symbolSize: 8, + // prettier-ignore + data: [ + 0.97, 0.96, 0.96, 0.95, 0.95, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.93, 0.92, 0.91, 0.9, 0.89, 0.88, 0.87, 0.87, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.87, 0.88, 0.9, 0.93, 0.96, 0.99, 1.03, 1.06, 1.1, 1.14, 1.17, 1.2, 1.23, 1.26, 1.29, 1.33, 1.36, 1.4, 1.43, 1.45, 1.48, 1.49, 1.51, 1.51, 1.5, 1.49, 1.47, 1.44, 1.41, 1.37, 1.34, 1.3, 1.27, 1.24, 1.22, 1.2, 1.19, 1.18, 1.16, 1.15, 1.14, 1.13, 1.12, 1.11, 1.11, 1.1, 1.1, 1.1, 1.1, 1.1, 1.1, 1.1, 1.1, 1.1, 1.1, 1.1, 1.1, 1.1, 1.1, 1.1, 1.1, 1.1, 1.09, 1.09, 1.08, 1.07, 1.06, 1.05, 1.04, 1.03, 1.03, 1.02, 1.01, 1.01, 1, 0.99, 0.98, 0.97, 0.96, 0.96, 0.95, 0.95, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.93, 0.92, 0.91, 0.9, 0.89, 0.88, 0.87, 0.87, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.85, 0.84, 0.83, 0.82, 0.81, 0.8, 0.8, 0.79, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.77, 0.75, 0.73, 0.71, 0.68, 0.65, 0.63, 0.61, 0.59, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.57, 0.57, 0.57, 0.56, 0.55, 0.55, 0.54, 0.54, 0.53, 0.52, 0.52, 0.51, 0.51, 0.5, 0.5, 0.49, 0.48, 0.48, 0.47, 0.47, 0.47, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.46, 0.52, 0.67, 0.9, 1.19, 1.52, 1.87, 2.22, 2.55, 2.84, 3.07, 3.22, 3.28, 3.28, 3.28, 3.28, 3.28, 3.28, 3.28, 3.28, 3.28, 3.28, 3.28, 3.28, 3.28, 3.24, 3.13, 2.97, 2.77, 2.54, 2.3, 2.05, 1.82, 1.62, 1.46, 1.35, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.31, 1.3, 1.26, 1.21, 1.14, 1.06, 0.97, 0.89, 0.81, 0.74, 0.69, 0.65, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.63, 0.63, 0.62, 0.62, 0.61, 0.6, 0.59, 0.59, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.59, 0.61, 0.63, 0.65, 0.68, 0.71, 0.73, 0.75, 0.77, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.77, 0.75, 0.73, 0.71, 0.68, 0.65, 0.63, 0.61, 0.59, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.58, 0.59, 0.59, 0.6, 0.61, 0.62, 0.62, 0.63, 0.63, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.65, 0.66, 0.68, 0.69, 0.71, 0.73, 0.74, 0.76, 0.77, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.79, 0.81, 0.82, 0.84, 0.86, 0.88, 0.9, 0.92, 0.93, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.94, 0.93, 0.92, 0.91, 0.9, 0.89, 0.88, 0.87, 0.87, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.86, 0.85, 0.84, 0.82, 0.8, 0.78, 0.76, 0.75, 0.73, 0.72, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.72, 0.73, 0.74, 0.76, 0.78, 0.79, 0.82, 0.84, 0.86, 0.89, 0.91, 0.94, 0.97, 1, 1.02, 1.05, 1.08, 1.11, 1.14, 1.17, 1.19, 1.22, 1.25, 1.27, 1.29, 1.31, 1.33, 1.35, 1.36, 1.38, 1.39, 1.39, 1.4, 1.4, 1.4, 1.39, 1.37, 1.35, 1.32, 1.29, 1.26, 1.22, 1.18, 1.14, 1.1, 1.05, 1.01, 0.97, 0.93, 0.89, 0.85, 0.82, 0.78, 0.76, 0.74, 0.72, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.72, 0.73, 0.74, 0.75, 0.77, 0.78, 0.8, 0.82, 0.84, 0.87, 0.89, 0.92, 0.94, 0.97, 0.99, 1.02, 1.05, 1.08, 1.1, 1.13, 1.16, 1.18, 1.21, 1.23, 1.26, 1.28, 1.3, 1.32, 1.34, 1.35, 1.37, 1.38, 1.39, 1.4, 1.41, 1.41, 1.42, 1.42, 1.43, 1.43, 1.43, 1.44, 1.44, 1.44, 1.44, 1.45, 1.45, 1.45, 1.46, 1.46, 1.46, 1.47, 1.47, 1.48, 1.48, 1.49, 1.5, 1.51, 1.54, 1.62, 1.73, 1.88, 2.05, 2.24, 2.45, 2.67, 2.89, 3.11, 3.31, 3.51, 3.69, 3.86, 4.03, 4.18, 4.33, 4.48, 4.62, 4.76, 4.89, 5.02, 5.16, 5.29, 5.43, 5.57, 5.71, 5.86, 6.02, 6.18, 6.36, 6.54, 6.73, 6.93, 7.15, 7.38, 7.62, 7.88, 8.16, 8.46, 8.77, 9.11, 9.46, 9.84, 10.24, 10.67, 11.12, 11.6, 12.3, 13.66, 16, 38.43, 82.21, 146.6, 218.7, 226, 225.23, 223.08, 219.78, 212, 199.82, 184.6, 168, 151.65, 137.21, 126.31, 119.94, 115.52, 112.06, 108.92, 105.44, 101, 94.56, 86.36, 77.67, 69.76, 63.9, 60.38, 57.41, 54.84, 52.57, 50.56, 48.71, 46.97, 45.25, 43.48, 41.6, 39.5, 37.19, 34.81, 32.46, 30.27, 28.36, 26.85, 25.86, 25.5, 25.5, 25.5, 25.5, 25.5, 25.5, 25.5, 25.5, 25.5, 25.5, 25.5, 25.5, 25.5, 25.27, 24.65, 23.7, 22.52, 21.17, 19.75, 18.33, 16.98, 15.8, 14.85, 14.23, 14, 14.02, 14.08, 14.17, 14.29, 14.44, 14.61, 14.8, 15.01, 15.23, 15.47, 15.71, 15.95, 16.19, 16.43, 16.67, 16.89, 17.1, 17.29, 17.46, 17.61, 17.73, 17.82, 17.88, 17.9, 17.63, 16.88, 15.75, 14.33, 12.71, 10.98, 9.23, 7.56, 6.05, 4.81, 3.92, 3.47, 3.28, 3.1, 2.93, 2.76, 2.61, 2.46, 2.32, 2.19, 2.07, 1.96, 1.85, 1.75, 1.66, 1.58, 1.51, 1.44, 1.39, 1.34, 1.29, 1.26, 1.23, 1.22, 1.2, 1.2, 1.2, 1.2, 1.2, 1.2, 1.21, 1.21, 1.21, 1.21, 1.22, 1.22, 1.22, 1.23, 1.23, 1.23, 1.24, 1.24, 1.25, 1.25, 1.25, 1.26, 1.26, 1.27, 1.27, 1.27, 1.28, 1.28, 1.28, 1.29, 1.29, 1.29, 1.29, 1.3, 1.3, 1.3, 1.3, 1.3, 1.3, 1.3, 1.3, 1.3, 1.3, 1.3, 1.29, 1.29, 1.29, 1.29, 1.28, 1.28, 1.28, 1.27, 1.27, 1.26, 1.25, 1.25, 1.24, 1.23, 1.23, 1.22, 1.21, 1.2, 1.16, 1.06, 0.95, 0.83, 0.74, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.71, 0.7, 0.7, 0.7, 0.7, 0.7, 0.7, 0.7, 0.7, 0.7, 0.7, 0.7, 0.69, 0.69, 0.69, 0.69, 0.69, 0.69, 0.69, 0.69, 0.68, 0.68, 0.68, 0.68, 0.68, 0.68, 0.67, 0.67, 0.67, 0.67, 0.67, 0.67, 0.67, 0.66, 0.66, 0.66, 0.66, 0.66, 0.66, 0.66, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.65, 0.66, 0.68, 0.69, 0.71, 0.73, 0.74, 0.76, 0.77, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.78, 0.8, 0.86, 0.95, 1.08, 1.25, 1.46, 1.7, 1.97, 2.28, 2.63, 3.01, 3.42, 3.87, 4.35, 4.86, 5.4, 5.98, 6.59, 7.92, 10.49, 14.04, 18.31, 23.04, 27.98, 32.87, 37.45, 41.46, 44.64, 46.74, 47.5, 46.86, 45.16, 42.77, 40.04, 37.33, 35, 32.74, 30.21, 27.7, 25.5, 23.9, 23.2, 23.06, 22.94, 22.84, 22.77, 22.72, 22.7, 22.8, 23.23, 23.95, 24.91, 26.04, 27.3, 28.76, 30.7, 33.39, 37.12, 42.15, 48.77, 65.22, 252.1, 257, 237.32, 221.19, 212, 208.67, 206.89, 205.2, 202.15, 189.82, 172, 165.3, 160.49, 156.8, 153.44, 149.62, 144.6, 138.27, 131, 123.11, 114.9, 106.69, 98.79, 91.5, 85.13, 80, 75.53, 71.03, 66.65, 62.54, 58.85, 55.73, 53.31, 51.75, 51.2, 56.53, 68.25, 80, 91.01, 102.03, 109, 112.37, 115.29, 117.68, 119.48, 120.61, 121, 119.45, 115.57, 110.52, 105.47, 101.58, 100, 99.97, 99.94, 99.92, 99.9, 99.88, 99.86, 99.85, 99.84, 99.83, 99.82, 99.81, 99.81, 99.8, 99.8, 99.8, 122.15, 163.65, 186, 182.96, 175.15, 164.56, 153.18, 143, 136, 131.37, 126.98, 122.81, 118.85, 115.09, 111.52, 108.13, 104.9, 101.83, 98.9, 96.11, 93.44, 90.87, 88.41, 86.04, 83.74, 81.51, 79.33, 77.2, 75.1, 73.02, 70.95, 68.88, 66.8, 64.87, 63.14, 61.4, 59.53, 57.67, 56, 54.6, 53.36, 52.2, 51.05, 49.85, 48.5, 46.87, 44.92, 42.74, 40.42, 38.04, 35.69, 33.46, 31.44, 29.72, 28.38, 27.51, 27.2, 27.2, 27.2, 27.2, 27.2, 27.2, 27.2, 27.2, 27.2, 27.2, 27.2, 27.2, 27.2, 27.14, 26.97, 26.7, 26.35, 25.95, 25.49, 25.02, 24.53, 24.04, 23.58, 23.16, 22.8, 22.46, 22.11, 21.75, 21.39, 21.03, 20.69, 20.36, 20.05, 19.78, 19.54, 19.35, 19.2, 19.09, 19, 18.92, 18.85, 18.79, 18.74, 18.68, 18.62, 18.56, 18.49, 18.4, 18.3, 18.17, 18.02, 17.83, 17.63, 17.41, 17.18, 16.93, 16.68, 16.43, 16.18, 15.93, 15.7, 15.47, 15.22, 14.97, 14.71, 14.45, 14.18, 13.93, 13.68, 13.44, 13.21, 13, 12.8, 12.62, 12.46, 12.31, 12.16, 12.03, 11.89, 11.76, 11.62, 11.48, 11.33, 11.17, 11, 10.81, 10.59, 10.36, 10.12, 9.86, 9.61, 9.36, 9.12, 8.89, 8.68, 8.5, 8.35, 8.21, 8.08, 7.94, 7.81, 7.68, 7.56, 7.46, 7.36, 7.29, 7.23, 7.19, 7.18, 7.51, 8.42, 9.81, 11.58, 13.63, 15.86, 18.16, 20.44, 22.58, 24.49, 26.06, 27.2, 28.08, 28.95, 29.81, 30.65, 31.48, 32.28, 33.07, 33.82, 34.55, 35.25, 35.92, 36.56, 37.15, 37.71, 38.23, 38.7, 39.13, 39.5, 39.83, 40.1, 40.31, 40.47, 40.57, 40.6, 40.49, 40.16, 39.64, 38.94, 38.09, 37.1, 36, 34.79, 33.51, 32.17, 30.79, 29.39, 27.99, 26.6, 25.25, 23.96, 22.75, 21.63, 20.63, 19.76, 19.04, 18.49, 18.14, 18, 17.97, 17.95, 17.94, 17.92, 17.91, 17.9, 17.89, 17.88, 17.87, 17.85, 17.83, 17.8, 17.7, 17.46, 17.13, 16.7, 16.21, 15.68, 15.13, 14.57, 14.04, 13.56, 13.14, 12.8, 12.52, 12.27, 12.02, 11.79, 11.57, 11.37, 11.16, 10.97, 10.78, 10.59, 10.39, 10.2, 10.01, 9.81, 9.63, 9.44, 9.26, 9.08, 8.9, 8.73, 8.56, 8.39, 8.22, 8.06, 7.9, 7.73, 7.57, 7.41, 7.25, 7.09, 6.94, 6.79, 6.65, 6.52, 6.4, 6.28, 6.17, 6.08, 5.98, 5.9, 5.81, 5.73, 5.65, 5.57, 5.49, 5.41, 5.32, 5.23, 5.14, 5.04, 4.94, 4.84, 4.74, 4.63, 4.53, 4.43, 4.33, 4.23, 4.13, 4.03, 3.93, 3.81, 3.69, 3.57, 3.45, 3.33, 3.22, 3.12, 3.04, 2.98, 2.93, 2.92, 2.92, 2.92, 2.92, 2.92, 2.92, 2.92, 2.92, 2.92, 2.92, 2.92, 2.92, 2.92, 2.9, 2.86, 2.8, 2.71, 2.62, 2.52, 2.42, 2.33, 2.24, 2.18, 2.14, 2.12, 2.12, 2.12, 2.12, 2.12, 2.12, 2.12, 2.12, 2.12, 2.12, 2.12, 2.12, 2.12, 2.1, 2.06, 2, 1.91, 1.82, 1.71, 1.61, 1.5, 1.4, 1.32, 1.25, 1.2, 1.16, 1.13, 1.1, 1.06, 1.03, 1, 0.97, 0.93, 0.9, 0.87, 0.85, 0.82, 0.79, 0.77, 0.74, 0.72, 0.69, 0.67, 0.65, 0.63, 0.61, 0.59, 0.58, 0.56, 0.54, 0.53, 0.52, 0.51, 0.5, 0.49, 0.48, 0.48, 0.47, 0.47, 0.46, 0.46, 0.47, 0.48, 0.5, 0.53, 0.56, 0.59, 0.62, 0.64, 0.67, 0.69, 0.7, 0.71, 0.71, 0.71, 0.71, 0.7, 0.7, 0.7, 0.69, 0.69, 0.69, 0.68, 0.68, 0.67, 0.67, 0.67, 0.66, 0.66, 0.65, 0.65, 0.65, 0.65, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.64, 0.65, 0.65, 0.65, 0.66, 0.66, 0.67, 0.68, 0.69, 0.69, 0.7, 0.71, 0.73, 0.74, 0.75, 0.76, 0.78, 0.8, 0.81, 0.83, 0.85, 0.87, 0.89, 0.92, 0.94, 0.97, 0.99, 1.02, 1.05, 1.08, 1.11, 1.15, 1.18, 1.32, 1.66, 2.21, 2.97, 3.94, 5.11, 6.5, 8.1, 9.9, 11.92, 14.15, 16.6, 22.3, 22.8, 24.48, 30.38, 35.74, 42.4, 57.14, 94.04, 112.9, 123.4, 130.4, 130, 119.4, 120.7, 116.8, 118.1, 119.4, 124.8, 143.5, 204, 294, 319.2, 328.4, 365, 350.8, 347.6, 347.6, 325, 331.6, 319.2, 308, 308, 308, 308, 296.8, 300, 281, 278.4, 270.6, 271, 253.6, 233.5, 219.2, 207.8, 205.9, 204, 189.6, 178.8, 173.4, 160, 154.4, 146, 145, 140.5, 130.4, 126.2, 116.8, 112.9, 106.5, 101.6, 98.51, 82.67, 67.3, 80.05, 76.12, 72.3, 71.02, 69.78, 67.3, 67.3, 68.54, 57.6, 71.02, 66.06, 59.12, 57.14, 55.16, 55.16, 52.19, 52.19, 51.2, 48.56, 44.16, 43, 45.92, 49.44, 44.16, 36.48, 35.74, 35, 32.36, 37.22, 32.36, 32.36, 32.36, 33.68, 32.36, 31.7, 35.74, 29.72, 32.36, 30.38, 29.72, 28.4, 28.4, 28.4, 27.28, 25.6, 25.04, 23.92, 22.3, 21.8, 21.8, 21.8, 22.8, 21.8, 25.6, 22.8, 22.8, 17.8, 16.04, 16.04, 16.04, 16.04, 16.04, 16.04, 16.04, 16.04, 16.04, 16.04, 15.02, 14, 14.03, 14.11, 14.25, 14.45, 14.72, 15.06, 15.46, 15.95, 16.51, 17.15, 17.87, 18.69, 19.59, 20.59, 21.69, 22.88, 24.18, 25.59, 27.1, 28.73, 30.48, 32.34, 34.33, 36.44, 38.69, 41.06, 43.57, 46.22, 49.01, 51.95, 55.04, 58.27, 61.66, 65.21, 68.92, 72.8, 88.09, 104.9, 105.7, 110.3, 111.6, 110.3, 106.5, 105.7, 103.3, 100, 97.02, 98.8, 91.07, 83.98, 88.09, 81.36, 78.74, 77.43, 77.43, 73.5, 74.81, 72.63, 68.58, 66.4, 68.54, 69.78, 67.3, 64.82, 61.1, 59.12, 56.15, 53.18, 50.32, 49.44, 44.16, 36.5, 42.4, 37.96, 37.22, 33.68, 36.48, 35.74, 35, 35, 37.22, 37.22, 39.44, 32.6, 34.54, 36.48, 35.74, 34.34, 33.68, 33.02, 31.04, 29.72, 29.72, 29.72, 26.16, 25.6, 29.72, 18.3, 22.3, 21.3, 21.8, 21.8, 20.3, 20.8, 25.04, 25.04, 25.6, 25.6, 25.04, 25.6, 25.04, 25.6, 23.92, 25.04, 21.3, 21.8, 22.3, 21.8, 20.8, 16.1, 20.3, 18.3, 13.22, 19.3, 19.3, 18.3, 14.4, 13.86, 13.36, 12.9, 12.48, 12.1, 11.75, 11.43, 11.15, 10.9, 10.67, 10.48, 10.31, 10.16, 10.04, 9.93, 9.85, 9.78, 9.73, 9.69, 9.67, 9.65, 9.65, 12.08, 8.67, 11.7, 11.38, 10.65, 9.84, 9.32, 9.07, 8.85, 8.66, 8.49, 8.35, 8.22, 8.1, 7.98, 7.86, 7.74, 7.61, 7.47, 7.31, 7.14, 6.96, 6.78, 6.58, 6.39, 6.19, 5.99, 5.78, 5.58, 5.39, 5.2, 5.01, 4.83, 4.67, 4.51, 4.37, 4.24, 4.12, 4.02, 3.95, 3.89, 3.85, 3.84, 4.41, 5.77, 7.39, 8.75, 9.32, 9.18, 9, 8.94, 8.88, 8.83, 8.78, 8.73, 8.68, 8.64, 8.6, 8.56, 8.53, 8.5, 8.47, 8.45, 8.42, 8.4, 8.39, 8.37, 8.36, 8.35, 8.35, 8.34, 8.34, 8.67, 9.65, 9.62, 9.53, 9.4, 9.21, 8.98, 8.7, 8.4, 8.06, 7.69, 7.3, 6.89, 6.47, 6.03, 5.59, 5.14, 4.7, 4.26, 3.83, 3.42, 3.02, 2.65, 2.3, 1.98, 1.7, 1.45, 1.25, 1.09, 0.99, 0.94, 0.92, 0.91, 0.89, 0.87, 0.85, 0.84, 0.82, 0.81, 0.79, 0.78, 0.77, 0.75, 0.74, 0.73, 0.72, 0.71, 0.7, 0.69, 0.68, 0.67, 0.66, 0.65, 0.64, 0.64, 0.63, 0.63, 0.62, 0.62, 0.61, 0.61, 0.61, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.6, 0.61, 0.61, 0.61, 0.61, 0.61, 0.61, 0.62, 0.62, 0.62, 0.62, 0.63, 0.63, 0.63, 0.63, 0.63, 0.64, 0.64, 0.64, 0.64, 0.64, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.65, 0.64, 0.63, 0.62, 0.6, 0.59, 0.57, 0.55, 0.54, 0.53, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.51, 0.51, 0.51, 0.5, 0.5, 0.49, 0.48, 0.47, 0.47, 0.46, 0.45, 0.45, 0.44, 0.43, 0.42, 0.42, 0.41, 0.41, 0.41, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.41, 0.42, 0.43, 0.44, 0.46, 0.48, 0.5, 0.53, 0.55, 0.58, 0.61, 0.64, 0.67, 0.7, 0.73, 0.77, 0.8, 0.83, 0.87, 0.9, 0.93, 0.96, 0.99, 1.02, 1.05, 1.08, 1.1, 1.12, 1.14, 1.16, 1.17, 1.18, 1.19, 1.2, 1.2, 1.2, 1.19, 1.17, 1.15, 1.12, 1.09, 1.06, 1.02, 0.98, 0.94, 0.9, 0.86, 0.82, 0.78, 0.74, 0.7, 0.66, 0.63, 0.6, 0.57, 0.55, 0.53, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.52, 0.51, 0.51, 0.5, 0.5, 0.49, 0.49, 0.48, 0.47, 0.47, 0.47, 0.46, 0.46, 0.45, 0.45, 0.45, 0.44, 0.44, 0.44, 0.43, 0.43, 0.43, 0.42, 0.42, 0.42, 0.41, 0.41, 0.41, 0.41, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.4, 0.41, 0.41, 0.41, 0.41, 0.41, 0.41, 0.41, 0.41, 0.41, 0.41, 0.41, 0.41, 0.41, 0.41, 0.41, 0.42, 0.42, 0.42, 0.42, 0.42, 0.42, 0.42, 0.42, 0.42, 0.43, 0.43, 0.43, 0.43, 0.43, 0.43, 0.44, 0.44, 0.44, 0.44, 0.44, 0.44, 0.45, 0.45, 0.45 + ] + }, + { + name: 'Rainfall', + type: 'line', + xAxisIndex: 1, + yAxisIndex: 1, + symbolSize: 8, + // prettier-ignore + data: [ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.005, 0.017, 0.017, 0.017, 0.017, 0.011, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.021, 0.026, 0.03, 0.036, 0.036, 0.195, 0.221, 0.019, 0.013, 0.017, 0.03, 0.03, 0.03, 0.046, 0.045, 0.038, 0.084, 0.045, 0.045, 0.037, 0.034, 0.035, 0.036, 0.044, 0.052, 0.048, 0.109, 0.033, 0.029, 0.04, 0.042, 0.042, 0.042, 0.073, 0.076, 0.062, 0.066, 0.066, 0.075, 0.096, 0.128, 0.121, 0.128, 0.14, 0.226, 0.143, 0.097, 0.018, 0, 0, 0, 0, 0, 0.018, 0.047, 0.054, 0.054, 0.054, 0.036, 0.185, 0.009, 0.038, 0.061, 0.077, 0.091, 0.126, 0.69, 0.182, 0.349, 0.231, 0.146, 0.128, 0.167, 0.1, 0.075, 0.071, 0.071, 0.117, 0.01, 0.002, 0.002, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,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.024, 0.024, 0.024, 0.024, 0.006, 0.003, 0.046, 0.046, 0.046, 0.046, 0.043, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.204, 0.303, 1.028, 1.328, 1.524, 1.41, 1.362, 1.292, 1.191, 0.529, 0.501, 0.944, 1.81, 2.899, 0.859, 0.126, 0.087, 0.047, 0, 0, 0, 0, 0.011, 0.028, 0.028, 0.028, 0.028, 0.017, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.099, 0.159, 0.297, 0.309, 0.309, 0.614, 0.818, 1.436, 1.195, 0.553, 0.542, 0.955, 0.898, 0.466, 0.386, 0.556, 0.388, 0.221, 0.192, 0.192, 0.187, 0.166, 0.18, 0.302, 0.158, 0.009, 0.009, 0.009, 0.009, 0.009, 0.007, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.004, 0.032, 0.032, 0.032, 0.032, 0.082, 0.149, 0.204, 0.247, 0.262, 0.49, 0.51, 0.533, 0.746, 0.847, 2.393, 1.188, 1.114, 0.475, 0.043, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.017, 0.017, 0.021, 0.042, 0.079, 0.111, 0.126, 0.122, 0.133, 0.846, 0.102, 0.077, 0.067, 0.056, 0.005, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.011, 0.017, 0.017, 0.017, 0.017, 0.006, 0, 0, 0, 0, 0, 0.01, 0.03, 0.054, 0.067, 0.07, 0.25, 0.251, 0.494, 0.065, 0.054, 0.054, 0.064, 0.084, 0.077, 0.101, 0.132, 0.248, 0.069, 0.117, 0.115, 0.087, 0.326, 0.036, 0.009, 0.009, 0.009, 0.009, 0.009, 0.004, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.02, 0.039, 0.04, 0.04, 0.04, 0.229, 0.079, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.023, 0.069, 0.082, 0.082, 0.082, 0.503, 0.774, 0.038, 0.012, 0.012, 0.012, 0.016, 0.02, 0.028, 0.051, 0.06, 0.064, 0.19, 0.15, 0.164, 0.139, 0.13, 0.085, 0.031, 0.023, 0.022, 0.007, 0.005, 0.005, 0.001, 0, 0.02, 0.048, 0.048, 0.053, 0.056, 0.036, 0.008, 0.008, 0.004, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.013, 0.017, 0.036, 0.068, 0.095, 0.233, 0.272, 0.377, 0.722, 1.494, 3.756, 0.954, 0.439, 0.442, 0.462, 0.373, 0.249, 0.214, 0.1, 0.044, 0.037, 0.023, 0.002, 0, 0, 0, 0, 0, 0, 0.02, 0.024, 0.024, 0.024, 0.024, 0.004, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.008, 0.017, 0.017, 0.045, 0.186, 0.308, 0.241, 0.241, 0.893, 4.067, 4.494, 5.015, 3.494, 2.057, 1.411, 0.718, 0.407, 0.313, 0.339, 1.537, 1.105, 0.218, 0.136, 0.03, 0.005, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.037, 0.448, 1.2, 1.309, 1.309, 1.425, 1.223, 0.471, 0.767, 0.423, 0.273, 0.412, 0.646, 0.481, 0.239, 0.131, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.044, 0.15, 0.223, 0.388, 0.513, 0.883, 2.828, 4.786, 5.959, 4.95, 6.434, 6.319, 3.35, 2.806, 4.204, 1.395, 1.015, 1.015, 0.836, 0.74, 0.72, 0.615, 0.477, 0.192, 0.046, 0.007, 0.007, 0.007, 0.007, 0.007, 0.007, 0.007, 0.008, 0.005, 0.005, 0.005, 0.005, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.001, 0.012, 0.012, 0.012, 0.012, 0.011, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.002, 0.012, 0.028, 0.028, 0.028, 0.138, 0.092, 0.082, 0.082, 0.096, 0.719, 0.155, 0.042, 0.047, 0.129, 0.021, 0.021, 0.014, 0.009, 0.029, 0.067, 0.088, 0.095, 0.095, 0.138, 0.091, 0.032, 0.025, 0.025, 0.003, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.002, 0.045, 0.228, 0.297, 0.325, 0.339, 0.581, 1.244, 0.796, 0.517, 0.227, 0.053, 0.006, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.003, 0.005, 0.005, 0.005, 0.005, 0.081, 0.129, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.014, 0.041, 0.041, 0.041, 0.041, 0.027, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.009, 0.017, 0.017, 0.017, 0.017, 0.355, 0.174, 0.009, 0.009, 0.012, 0.136, 0.208, 0.208, 0.208, 0.215, 7.359, 1.858, 0.458, 0.053, 0.053, 0.047, 0.045, 0.045, 0.059, 0.136, 0.188, 0.206, 0.21, 0.588, 1.517, 6.02, 4.688, 4.42, 0.624, 0.326, 0.359, 0.553, 0.899, 0.94, 2.95, 9.415, 5.752, 1.092, 0.096, 0.035, 0.026, 0.018, 0.015, 0.011, 0.011, 0.011, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.056, 0.27, 0.314, 0.351, 0.354, 0.609, 0.796, 1.857, 0.848, 0.538, 0.214, 0.178, 0.178, 0.201, 0.231, 0.227, 0.272, 0.397, 0.45, 1.014, 2.917, 1.675, 0.081, 0.059, 0.059, 0.148, 0.075, 0.075, 0.078, 0.236, 0.784, 0.784, 0.784, 0.784, 0.741, 0.115, 0.058, 0.058, 0.058, 0.029, 0.015, 0.015, 0.015, 0.015, 0.012, 0.008, 0.604, 0.985, 1.305, 2.273, 2.528, 2.336, 2.496, 2.281, 1.397, 1.713, 3.259, 1.167, 0.745, 0.548, 1.058, 0.684, 0.728, 0.392, 0.179, 0.283, 0.283, 0.46, 0.08, 0.099, 0.099, 0.099, 0.1, 0.143, 0.137, 0.238, 0.317, 0.262, 0.225, 0.792, 0.426, 0.332, 0.261, 0.11, 0.093, 0.102, 0.171, 0.292, 0.504, 0.605, 1.745, 2.485, 1.964, 0.33, 0.171, 0.259, 0.242, 0.215, 0.366, 0.354, 0.205, 0.203, 0.262, 0.153, 0.13, 0.137, 0.362, 0.691, 0.295, 0.433, 0.154, 0.056, 0.053, 0.053, 0.053, 0.051, 0.047, 0.065, 0.078, 0.091, 0.206, 0.813, 0.102, 0.151, 0.05, 0.024, 0.004, 0.001, 0, 0, 0, 0.021, 0.021, 0.021, 0.021, 0.021, 0.013, 0.013, 0.013, 0.013, 0.013, 0.013, 0.013, 0.013, 0.01, 0.01, 0.01, 0.01, 0.01, 0.01, 0.01, 0.01, 0.01, 0.01, 0.008, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.018, 0.021, 0.021, 0.021, 0.021, 0.003, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.024, 0.173, 0.261, 0.267, 0.267, 0.534, 1.354, 1.772, 0.72, 0.218, 0.018, 0.018, 0.028, 0.036, 0.032, 0.194, 0.082, 0.035, 0.286, 0.027, 0.038, 0.038, 0.027, 0.021, 0.014, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.016, 0.017, 0.017, 0.031, 0.047, 0.043, 0.056, 0.104, 0.149, 0.179, 0.205, 0.328, 0.998, 0.522, 1.851, 3.727, 3.273, 2.204, 1.169, 1.006, 1.179, 0.74, 0.741, 1.065, 0.925, 0.671, 0.497, 0.431, 0.327, 0.277, 0.126, 0.581, 0.207, 0.359, 2.485, 0.038, 0.036, 0.003, 0.003, 0.003, 0.003, 0.004, 0.098, 0.023, 0.021, 0.021, 0.022, 0.041, 0.041, 0.043, 0.045, 0.043, 0.014, 0.014, 0.014, 0.014, 0.014, 0.014, 0.014, 0.031, 0.046, 0.063, 0.119, 0.107, 0.092, 0.085, 0.065, 0.06, 0.054, 0.042, 0.039, 0.046, 0.044, 0.028, 0.028, 0.02, 0.013, 0.013, 0.013, 0.013, 0.016, 0.032, 0.031, 0.031, 0.031, 0.028, 0.011, 0.011, 0.011, 0.011, 0.011, 0.023, 0.024, 0.024, 0.024, 0.019, 0.015, 0.015, 0.015, 0.015, 0.015, 0.015, 0.013, 0.01, 0.01, 0.01, 0.01, 0.01, 0.01, 0.01, 0.01, 0.01, 0.01, 0.001, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.011, 0.017, 0.024, 0.026, 0.061, 0.172, 0.206, 0.213, 0.267, 0.511, 0.668, 0.157, 0.017, 0.017, 0.017, 0.046, 0.054, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.001, 0.017, 0.017, 0.017, 0.017, 0.016, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.01, 0.017, 0.017, 0.017, 0.017, 0.012, 0.017, 0.017, 0.017, 0.017, 0.012, 0, 0, 0, 0, 0, 0.003, 0.031, 0.066, 0.093, 0.112, 0.122, 0.202, 0.068, 0.041, 0.022, 0.011, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.002, 0.005, 0.012, 0.021, 0.021, 0.019, 0.033, 0.03, 0.026, 0.026, 0.034, 0.095, 0.024, 0.024, 0.024, 0.023, 0.019, 0.018, 0.018, 0.018, 0.011, 0.03, 0.045, 0.044, 0.044, 0.044, 0.022, 0.009, 0.024, 0.033, 0.033, 0.033, 0.024, 0.009, 0, 0, 0, 0, 0, 0, 0.003, 0.017, 0.017, 0.017, 0.017, 0.014, 0, 0, 0, 0, 0, 0.032, 0.032, 0.032, 0.032, 0.032, 0.005, 0.008, 0.009, 0.014, 0.014, 0.009, 0.005, 0.004, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.007, 0.009, 0.009, 0.009, 0.009, 0.043, 0.063, 0.084, 0.098, 0.101, 0.213, 0.334, 0.383, 0.43, 0.448, 0.511, 0.801, 0.835, 1.642, 1.614, 1.496, 1.496, 1.476, 1.068, 0.481, 0.22, 0.119, 0.099, 0.07, 0.072, 0.063, 0.076, 0.14, 0.205, 0.28, 0.297, 0.3, 0.479, 0.877, 1.098, 1.611, 1.629, 1.686, 1.686, 1.631, 1.528, 1.862, 1.703, 1.531, 2.196, 0.395, 0.416, 0.453, 0.728, 0.917, 0.986, 1.17, 2.171, 3.011, 2.909, 3.301, 1.377, 0.778, 0.799, 0.947, 1.039, 0.879, 0.76, 1.372, 1.674, 1.674, 1.68, 1.823, 1.793, 1.162, 0.783, 0.216, 0.152, 0.152, 0.152, 0.049, 0, 0, 0, 0.117, 0.127, 0.127, 0.127, 0.127, 0.127, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.003, 0.005, 0.005, 0.005, 0.005, 0.003, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.309, 0.364, 0.364, 0.364, 0.364, 0.063, 0.01, 0.01, 0.01, 0.012, 0.015, 0.015, 0.11, 0.55, 0.824, 0.825, 0.829, 1.39, 1.429, 1.342, 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0.049, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.03, 0.039, 0.039, 0.039, 0.039, 0.098, 0.008, 0.007, 0.007, 0.007, 0.007, 0.007, 0.007, 0.007, 0.007, 0.007, 0.056, 0.062, 0.065, 0.065, 0.065, 0.047, 0.216, 0.256, 0.315, 0.4, 0.502, 0.449, 0.47, 0.571, 0.814, 1.153, 0.774, 0.202, 0.086, 0.075, 0.071, 0.032, 0.019, 0.003, 0.004, 0.004, 0.004, 0.004, 0.004, 0.004, 0.007, 0.072, 0.153, 0.256, 0.306, 0.404, 0.698, 0.733, 0.823, 0.715, 0.563, 0.404, 0.293, 0.217, 0.213, 0.202, 0.202, 0.294, 0.704, 0.797, 1.359, 1.101, 0.72, 0.514, 0.539, 0.434, 0.389, 0.387, 0.386, 0.375, 0.369, 0.319, 0.239, 0.183, 0.136, 0.062, 0.052, 0.096, 0.119, 0.119, 0.114, 0.127, 0.132, 0.139, 0.169, 0.191, 0.278, 0.254, 0.214, 0.237, 0.221, 0.143, 0.129, 0.125, 0.109, 0.1, 0.087, 0.06, 0.038, 0.029, 0.029, 0.028, 0.048, 0.053, 0.053, 0.111, 0.125, 0.102, 0.097, 0.097, 0.039, 0.02, 0.02, 0.02, 0.014, 0.004, 0.031, 0.043, 0.047, 0.052, 0.08, 0.144, 0.182, 0.176, 0.171, 0.149, 0.112, 0.025, 0, 0, 0, 0, 0, 0, 0, 0.016, 0.031, 0.031, 0.031, 0.031, 0.015, 0, 0, 0, 0, 0, 0.005, 0.005, 0.005, 0.005, 0.005, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.005, 0.005, 0.005, 0.005, 0.005, 0.001, 0, 0, 0 + ] + } + ] +}; +export {}; diff --git a/testdata/grid-multiple.js.svg b/testdata/grid-multiple.js.svg new file mode 100644 index 0000000..7473a3e --- /dev/null +++ b/testdata/grid-multiple.js.svg @@ -0,0 +1,180 @@ + + + + + + + + + + + + + + +Evaporation(m³/s) +Rainfall(mm) + + + + + + + + + + + + + + + + + + + + + + +0 +100 +200 +300 +400 +500 +0 +2 +4 +6 +8 +10 +7/23 10:00 +7/28 14:00 +8/2 18:00 +8/7 22:00 +8/13 2:00 +8/18 6:00 +8/23 10:00 +8/28 14:00 +9/2 18:00 +9/7 22:00 +7/23 10:00 +7/28 14:00 +8/2 18:00 +8/7 22:00 +8/13 2:00 +8/18 6:00 +8/23 10:00 +8/28 14:00 +9/2 18:00 +9/7 22:00 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Evaporation + + +Rainfall + + + + + + + + + + + + + +Rainfall vs Evaporation + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/heatmap-bmap.js b/testdata/heatmap-bmap.js new file mode 100644 index 0000000..bf31383 --- /dev/null +++ b/testdata/heatmap-bmap.js @@ -0,0 +1,46 @@ +"use strict"; +/* +title: Heatmap on Baidu Map Extension +category: heatmap +tags: bmap +titleCN: 热力图与百度地图扩展 +difficulty: 3 +*/ +$.get(ROOT_PATH + '/data/asset/data/hangzhou-tracks.json', function (data) { + var points = [].concat.apply([], data.map(function (track) { + return track.map(function (seg) { + return seg.coord.concat([1]); + }); + })); + myChart.setOption((option = { + animation: false, + bmap: { + center: [120.13066322374, 30.240018034923], + zoom: 14, + roam: true + }, + visualMap: { + show: false, + top: 'top', + min: 0, + max: 5, + seriesIndex: 0, + calculable: true, + inRange: { + color: ['blue', 'blue', 'green', 'yellow', 'red'] + } + }, + series: [ + { + type: 'heatmap', + coordinateSystem: 'bmap', + data: points, + pointSize: 5, + blurSize: 6 + } + ] + })); + // 添加百度地图插件 + var bmap = myChart.getModel().getComponent('bmap').getBMap(); + bmap.addControl(new BMap.MapTypeControl()); +}); diff --git a/testdata/heatmap-cartesian.js b/testdata/heatmap-cartesian.js new file mode 100644 index 0000000..a99fdd6 --- /dev/null +++ b/testdata/heatmap-cartesian.js @@ -0,0 +1,71 @@ +/* +title: Heatmap on Cartesian +category: heatmap +titleCN: 笛卡尔坐标系上的热力图 +difficulty: 0 +*/ +// prettier-ignore +const hours = [ + '12a', '1a', '2a', '3a', '4a', '5a', '6a', + '7a', '8a', '9a', '10a', '11a', + '12p', '1p', '2p', '3p', '4p', '5p', + '6p', '7p', '8p', '9p', '10p', '11p' +]; +// prettier-ignore +const days = [ + 'Saturday', 'Friday', 'Thursday', + 'Wednesday', 'Tuesday', 'Monday', 'Sunday' +]; +// prettier-ignore +const data = [[0, 0, 5], [0, 1, 1], [0, 2, 0], [0, 3, 0], [0, 4, 0], [0, 5, 0], [0, 6, 0], [0, 7, 0], [0, 8, 0], [0, 9, 0], [0, 10, 0], [0, 11, 2], [0, 12, 4], [0, 13, 1], [0, 14, 1], [0, 15, 3], [0, 16, 4], [0, 17, 6], [0, 18, 4], [0, 19, 4], [0, 20, 3], [0, 21, 3], [0, 22, 2], [0, 23, 5], [1, 0, 7], [1, 1, 0], [1, 2, 0], [1, 3, 0], [1, 4, 0], [1, 5, 0], [1, 6, 0], [1, 7, 0], [1, 8, 0], [1, 9, 0], [1, 10, 5], [1, 11, 2], [1, 12, 2], [1, 13, 6], [1, 14, 9], [1, 15, 11], [1, 16, 6], [1, 17, 7], [1, 18, 8], [1, 19, 12], [1, 20, 5], [1, 21, 5], [1, 22, 7], [1, 23, 2], [2, 0, 1], [2, 1, 1], [2, 2, 0], [2, 3, 0], [2, 4, 0], [2, 5, 0], [2, 6, 0], [2, 7, 0], [2, 8, 0], [2, 9, 0], [2, 10, 3], [2, 11, 2], [2, 12, 1], [2, 13, 9], [2, 14, 8], [2, 15, 10], [2, 16, 6], [2, 17, 5], [2, 18, 5], [2, 19, 5], [2, 20, 7], [2, 21, 4], [2, 22, 2], [2, 23, 4], [3, 0, 7], [3, 1, 3], [3, 2, 0], [3, 3, 0], [3, 4, 0], [3, 5, 0], [3, 6, 0], [3, 7, 0], [3, 8, 1], [3, 9, 0], [3, 10, 5], [3, 11, 4], [3, 12, 7], [3, 13, 14], [3, 14, 13], [3, 15, 12], [3, 16, 9], [3, 17, 5], [3, 18, 5], [3, 19, 10], [3, 20, 6], [3, 21, 4], [3, 22, 4], [3, 23, 1], [4, 0, 1], [4, 1, 3], [4, 2, 0], [4, 3, 0], [4, 4, 0], [4, 5, 1], [4, 6, 0], [4, 7, 0], [4, 8, 0], [4, 9, 2], [4, 10, 4], [4, 11, 4], [4, 12, 2], [4, 13, 4], [4, 14, 4], [4, 15, 14], [4, 16, 12], [4, 17, 1], [4, 18, 8], [4, 19, 5], [4, 20, 3], [4, 21, 7], [4, 22, 3], [4, 23, 0], [5, 0, 2], [5, 1, 1], [5, 2, 0], [5, 3, 3], [5, 4, 0], [5, 5, 0], [5, 6, 0], [5, 7, 0], [5, 8, 2], [5, 9, 0], [5, 10, 4], [5, 11, 1], [5, 12, 5], [5, 13, 10], [5, 14, 5], [5, 15, 7], [5, 16, 11], [5, 17, 6], [5, 18, 0], [5, 19, 5], [5, 20, 3], [5, 21, 4], [5, 22, 2], [5, 23, 0], [6, 0, 1], [6, 1, 0], [6, 2, 0], [6, 3, 0], [6, 4, 0], [6, 5, 0], [6, 6, 0], [6, 7, 0], [6, 8, 0], [6, 9, 0], [6, 10, 1], [6, 11, 0], [6, 12, 2], [6, 13, 1], [6, 14, 3], [6, 15, 4], [6, 16, 0], [6, 17, 0], [6, 18, 0], [6, 19, 0], [6, 20, 1], [6, 21, 2], [6, 22, 2], [6, 23, 6]] + .map(function (item) { + return [item[1], item[0], item[2] || '-']; +}); +option = { + tooltip: { + position: 'top' + }, + grid: { + height: '50%', + top: '10%' + }, + xAxis: { + type: 'category', + data: hours, + splitArea: { + show: true + } + }, + yAxis: { + type: 'category', + data: days, + splitArea: { + show: true + } + }, + visualMap: { + min: 0, + max: 10, + calculable: true, + orient: 'horizontal', + left: 'center', + bottom: '15%' + }, + series: [ + { + name: 'Punch Card', + type: 'heatmap', + data: data, + label: { + show: true + }, + emphasis: { + itemStyle: { + shadowBlur: 10, + shadowColor: 'rgba(0, 0, 0, 0.5)' + } + } + } + ] +}; +export {}; diff --git a/testdata/heatmap-cartesian.js.svg b/testdata/heatmap-cartesian.js.svg new file mode 100644 index 0000000..df9a1f5 --- /dev/null +++ b/testdata/heatmap-cartesian.js.svg @@ -0,0 +1,532 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Saturday +Friday +Thursday +Wednesday +Tuesday +Monday +Sunday +12a +1a +2a +3a +4a +5a +6a +7a +8a +9a +10a +11a +12p +1p +2p +3p +4p +5p +6p +7p +8p +9p +10p +11p + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +5 +1 +2 +4 +1 +1 +3 +4 +6 +4 +4 +3 +3 +2 +5 +7 +5 +2 +2 +6 +9 +11 +6 +7 +8 +12 +5 +5 +7 +2 +1 +1 +3 +2 +1 +9 +8 +10 +6 +5 +5 +5 +7 +4 +2 +4 +7 +3 +1 +5 +4 +7 +14 +13 +12 +9 +5 +5 +10 +6 +4 +4 +1 +1 +3 +1 +2 +4 +4 +2 +4 +4 +14 +12 +1 +8 +5 +3 +7 +3 +2 +1 +3 +2 +4 +1 +5 +10 +5 +7 +11 +6 +5 +3 +4 +2 +1 +1 +2 +1 +3 +4 +1 +2 +2 +6 + +0 +10 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/heatmap-large-piecewise.js b/testdata/heatmap-large-piecewise.js new file mode 100644 index 0000000..8889133 --- /dev/null +++ b/testdata/heatmap-large-piecewise.js @@ -0,0 +1,191 @@ +/* +title: Heatmap - Discrete Mapping of Color +category: heatmap +titleCN: 热力图 - 颜色的离散映射 +difficulty: 2 +*/ +let noise = getNoiseHelper(); +let xData = []; +let yData = []; +noise.seed(Math.random()); +function generateData(theta, min, max) { + let data = []; + for (let i = 0; i <= 200; i++) { + for (let j = 0; j <= 100; j++) { + // let x = (max - min) * i / 200 + min; + // let y = (max - min) * j / 100 + min; + data.push([i, j, noise.perlin2(i / 40, j / 20) + 0.5]); + // data.push([i, j, normalDist(theta, x) * normalDist(theta, y)]); + } + xData.push(i); + } + for (let j = 0; j < 100; j++) { + yData.push(j); + } + return data; +} +let data = generateData(2, -5, 5); +option = { + tooltip: {}, + grid: { + right: 140, + left: 40 + }, + xAxis: { + type: 'category', + data: xData + }, + yAxis: { + type: 'category', + data: yData + }, + visualMap: { + type: 'piecewise', + min: 0, + max: 1, + left: 'right', + top: 'center', + calculable: true, + realtime: false, + splitNumber: 8, + inRange: { + color: [ + '#313695', + '#4575b4', + '#74add1', + '#abd9e9', + '#e0f3f8', + '#ffffbf', + '#fee090', + '#fdae61', + '#f46d43', + '#d73027', + '#a50026' + ] + } + }, + series: [ + { + name: 'Gaussian', + type: 'heatmap', + data: data, + emphasis: { + itemStyle: { + borderColor: '#333', + borderWidth: 1 + } + }, + progressive: 1000, + animation: false + } + ] +}; +/////////////////////////////////////////////////////////////////////////// +// perlin noise helper from https://github.com/josephg/noisejs +/////////////////////////////////////////////////////////////////////////// +function getNoiseHelper() { + class Grad { + constructor(x, y, z) { + this.x = x; + this.y = y; + this.z = z; + } + dot2(x, y) { + return this.x * x + this.y * y; + } + dot3(x, y, z) { + return this.x * x + this.y * y + this.z * z; + } + } + const grad3 = [ + new Grad(1, 1, 0), + new Grad(-1, 1, 0), + new Grad(1, -1, 0), + new Grad(-1, -1, 0), + new Grad(1, 0, 1), + new Grad(-1, 0, 1), + new Grad(1, 0, -1), + new Grad(-1, 0, -1), + new Grad(0, 1, 1), + new Grad(0, -1, 1), + new Grad(0, 1, -1), + new Grad(0, -1, -1) + ]; + const p = [ + 151, 160, 137, 91, 90, 15, 131, 13, 201, 95, 96, 53, 194, 233, 7, 225, 140, + 36, 103, 30, 69, 142, 8, 99, 37, 240, 21, 10, 23, 190, 6, 148, 247, 120, + 234, 75, 0, 26, 197, 62, 94, 252, 219, 203, 117, 35, 11, 32, 57, 177, 33, + 88, 237, 149, 56, 87, 174, 20, 125, 136, 171, 168, 68, 175, 74, 165, 71, + 134, 139, 48, 27, 166, 77, 146, 158, 231, 83, 111, 229, 122, 60, 211, 133, + 230, 220, 105, 92, 41, 55, 46, 245, 40, 244, 102, 143, 54, 65, 25, 63, 161, + 1, 216, 80, 73, 209, 76, 132, 187, 208, 89, 18, 169, 200, 196, 135, 130, + 116, 188, 159, 86, 164, 100, 109, 198, 173, 186, 3, 64, 52, 217, 226, 250, + 124, 123, 5, 202, 38, 147, 118, 126, 255, 82, 85, 212, 207, 206, 59, 227, + 47, 16, 58, 17, 182, 189, 28, 42, 223, 183, 170, 213, 119, 248, 152, 2, 44, + 154, 163, 70, 221, 153, 101, 155, 167, 43, 172, 9, 129, 22, 39, 253, 19, 98, + 108, 110, 79, 113, 224, 232, 178, 185, 112, 104, 218, 246, 97, 228, 251, 34, + 242, 193, 238, 210, 144, 12, 191, 179, 162, 241, 81, 51, 145, 235, 249, 14, + 239, 107, 49, 192, 214, 31, 181, 199, 106, 157, 184, 84, 204, 176, 115, 121, + 50, 45, 127, 4, 150, 254, 138, 236, 205, 93, 222, 114, 67, 29, 24, 72, 243, + 141, 128, 195, 78, 66, 215, 61, 156, 180 + ]; + // To remove the need for index wrapping, double the permutation table length + let perm = new Array(512); + let gradP = new Array(512); + // This isn't a very good seeding function, but it works ok. It supports 2^16 + // different seed values. Write something better if you need more seeds. + function seed(seed) { + if (seed > 0 && seed < 1) { + // Scale the seed out + seed *= 65536; + } + seed = Math.floor(seed); + if (seed < 256) { + seed |= seed << 8; + } + for (let i = 0; i < 256; i++) { + let v; + if (i & 1) { + v = p[i] ^ (seed & 255); + } + else { + v = p[i] ^ ((seed >> 8) & 255); + } + perm[i] = perm[i + 256] = v; + gradP[i] = gradP[i + 256] = grad3[v % 12]; + } + } + seed(0); + // ##### Perlin noise stuff + function fade(t) { + return t * t * t * (t * (t * 6 - 15) + 10); + } + function lerp(a, b, t) { + return (1 - t) * a + t * b; + } + // 2D Perlin Noise + function perlin2(x, y) { + // Find unit grid cell containing point + let X = Math.floor(x), Y = Math.floor(y); + // Get relative xy coordinates of point within that cell + x = x - X; + y = y - Y; + // Wrap the integer cells at 255 (smaller integer period can be introduced here) + X = X & 255; + Y = Y & 255; + // Calculate noise contributions from each of the four corners + let n00 = gradP[X + perm[Y]].dot2(x, y); + let n01 = gradP[X + perm[Y + 1]].dot2(x, y - 1); + let n10 = gradP[X + 1 + perm[Y]].dot2(x - 1, y); + let n11 = gradP[X + 1 + perm[Y + 1]].dot2(x - 1, y - 1); + // Compute the fade curve value for x + let u = fade(x); + // Interpolate the four results + return lerp(lerp(n00, n10, u), lerp(n01, n11, u), fade(y)); + } + return { + seed, + perlin2 + }; +} +export {}; diff --git a/testdata/heatmap-large-piecewise.js.svg b/testdata/heatmap-large-piecewise.js.svg new file mode 100644 index 0000000..aef582a --- /dev/null +++ b/testdata/heatmap-large-piecewise.js.svg @@ -0,0 +1,1117 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +0 +4 +8 +12 +16 +20 +24 +28 +32 +36 +40 +44 +48 +52 +56 +60 +64 +68 +72 +76 +80 +84 +88 +92 +96 +0 +8 +16 +24 +32 +40 +48 +56 +64 +72 +80 +88 +96 +104 +112 +120 +128 +136 +144 +152 +160 +168 +176 +184 +192 +200 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +0.875 - 1.000 + +0.750 - 0.875 + +0.625 - 0.750 + +0.500 - 0.625 + +0.375 - 0.500 + +0.250 - 0.375 + +0.125 - 0.250 + +0.000 - 0.125 + \ No newline at end of file diff --git a/testdata/heatmap-large.js b/testdata/heatmap-large.js new file mode 100644 index 0000000..98757e8 --- /dev/null +++ b/testdata/heatmap-large.js @@ -0,0 +1,183 @@ +/* +title: Heatmap - 20K data +category: heatmap +titleCN: 热力图 - 2w 数据 +difficulty: 2 +*/ +let noise = getNoiseHelper(); +let xData = []; +let yData = []; +noise.seed(Math.random()); +function generateData(theta, min, max) { + let data = []; + for (let i = 0; i <= 200; i++) { + for (let j = 0; j <= 100; j++) { + // let x = (max - min) * i / 200 + min; + // let y = (max - min) * j / 100 + min; + data.push([i, j, noise.perlin2(i / 40, j / 20) + 0.5]); + // data.push([i, j, normalDist(theta, x) * normalDist(theta, y)]); + } + xData.push(i); + } + for (let j = 0; j < 100; j++) { + yData.push(j); + } + return data; +} +let data = generateData(2, -5, 5); +option = { + tooltip: {}, + xAxis: { + type: 'category', + data: xData + }, + yAxis: { + type: 'category', + data: yData + }, + visualMap: { + min: 0, + max: 1, + calculable: true, + realtime: false, + inRange: { + color: [ + '#313695', + '#4575b4', + '#74add1', + '#abd9e9', + '#e0f3f8', + '#ffffbf', + '#fee090', + '#fdae61', + '#f46d43', + '#d73027', + '#a50026' + ] + } + }, + series: [ + { + name: 'Gaussian', + type: 'heatmap', + data: data, + emphasis: { + itemStyle: { + borderColor: '#333', + borderWidth: 1 + } + }, + progressive: 1000, + animation: false + } + ] +}; +/////////////////////////////////////////////////////////////////////////// +// perlin noise helper from https://github.com/josephg/noisejs +/////////////////////////////////////////////////////////////////////////// +function getNoiseHelper() { + class Grad { + constructor(x, y, z) { + this.x = x; + this.y = y; + this.z = z; + } + dot2(x, y) { + return this.x * x + this.y * y; + } + dot3(x, y, z) { + return this.x * x + this.y * y + this.z * z; + } + } + const grad3 = [ + new Grad(1, 1, 0), + new Grad(-1, 1, 0), + new Grad(1, -1, 0), + new Grad(-1, -1, 0), + new Grad(1, 0, 1), + new Grad(-1, 0, 1), + new Grad(1, 0, -1), + new Grad(-1, 0, -1), + new Grad(0, 1, 1), + new Grad(0, -1, 1), + new Grad(0, 1, -1), + new Grad(0, -1, -1) + ]; + const p = [ + 151, 160, 137, 91, 90, 15, 131, 13, 201, 95, 96, 53, 194, 233, 7, 225, 140, + 36, 103, 30, 69, 142, 8, 99, 37, 240, 21, 10, 23, 190, 6, 148, 247, 120, + 234, 75, 0, 26, 197, 62, 94, 252, 219, 203, 117, 35, 11, 32, 57, 177, 33, + 88, 237, 149, 56, 87, 174, 20, 125, 136, 171, 168, 68, 175, 74, 165, 71, + 134, 139, 48, 27, 166, 77, 146, 158, 231, 83, 111, 229, 122, 60, 211, 133, + 230, 220, 105, 92, 41, 55, 46, 245, 40, 244, 102, 143, 54, 65, 25, 63, 161, + 1, 216, 80, 73, 209, 76, 132, 187, 208, 89, 18, 169, 200, 196, 135, 130, + 116, 188, 159, 86, 164, 100, 109, 198, 173, 186, 3, 64, 52, 217, 226, 250, + 124, 123, 5, 202, 38, 147, 118, 126, 255, 82, 85, 212, 207, 206, 59, 227, + 47, 16, 58, 17, 182, 189, 28, 42, 223, 183, 170, 213, 119, 248, 152, 2, 44, + 154, 163, 70, 221, 153, 101, 155, 167, 43, 172, 9, 129, 22, 39, 253, 19, 98, + 108, 110, 79, 113, 224, 232, 178, 185, 112, 104, 218, 246, 97, 228, 251, 34, + 242, 193, 238, 210, 144, 12, 191, 179, 162, 241, 81, 51, 145, 235, 249, 14, + 239, 107, 49, 192, 214, 31, 181, 199, 106, 157, 184, 84, 204, 176, 115, 121, + 50, 45, 127, 4, 150, 254, 138, 236, 205, 93, 222, 114, 67, 29, 24, 72, 243, + 141, 128, 195, 78, 66, 215, 61, 156, 180 + ]; + // To remove the need for index wrapping, double the permutation table length + let perm = new Array(512); + let gradP = new Array(512); + // This isn't a very good seeding function, but it works ok. It supports 2^16 + // different seed values. Write something better if you need more seeds. + function seed(seed) { + if (seed > 0 && seed < 1) { + // Scale the seed out + seed *= 65536; + } + seed = Math.floor(seed); + if (seed < 256) { + seed |= seed << 8; + } + for (let i = 0; i < 256; i++) { + let v; + if (i & 1) { + v = p[i] ^ (seed & 255); + } + else { + v = p[i] ^ ((seed >> 8) & 255); + } + perm[i] = perm[i + 256] = v; + gradP[i] = gradP[i + 256] = grad3[v % 12]; + } + } + seed(0); + // ##### Perlin noise stuff + function fade(t) { + return t * t * t * (t * (t * 6 - 15) + 10); + } + function lerp(a, b, t) { + return (1 - t) * a + t * b; + } + // 2D Perlin Noise + function perlin2(x, y) { + // Find unit grid cell containing point + let X = Math.floor(x), Y = Math.floor(y); + // Get relative xy coordinates of point within that cell + x = x - X; + y = y - Y; + // Wrap the integer cells at 255 (smaller integer period can be introduced here) + X = X & 255; + Y = Y & 255; + // Calculate noise contributions from each of the four corners + let n00 = gradP[X + perm[Y]].dot2(x, y); + let n01 = gradP[X + perm[Y + 1]].dot2(x, y - 1); + let n10 = gradP[X + 1 + perm[Y]].dot2(x - 1, y); + let n11 = gradP[X + 1 + perm[Y + 1]].dot2(x - 1, y - 1); + // Compute the fade curve value for x + let u = fade(x); + // Interpolate the four results + return lerp(lerp(n00, n10, u), lerp(n01, n11, u), fade(y)); + } + return { + seed, + perlin2 + }; +} +export {}; diff --git a/testdata/heatmap-large.js.svg b/testdata/heatmap-large.js.svg new file mode 100644 index 0000000..4fc9c7d --- /dev/null +++ b/testdata/heatmap-large.js.svg @@ -0,0 +1,1320 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +0 +4 +8 +12 +16 +20 +24 +28 +32 +36 +40 +44 +48 +52 +56 +60 +64 +68 +72 +76 +80 +84 +88 +92 +96 +0 +8 +16 +24 +32 +40 +48 +56 +64 +72 +80 +88 +96 +104 +112 +120 +128 +136 +144 +152 +160 +168 +176 +184 +192 +200 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +0 +1 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/heatmap-map.js b/testdata/heatmap-map.js new file mode 100644 index 0000000..11ba66f --- /dev/null +++ b/testdata/heatmap-map.js @@ -0,0 +1,447 @@ +"use strict"; +/* +title: Air Qulity +category: heatmap +titleCN: 全国主要城市空气质量 +difficulty: 3 +*/ +var geoCoordMap = { + 海门: [121.15, 31.89], + 鄂尔多斯: [109.781327, 39.608266], + 招远: [120.38, 37.35], + 舟山: [122.207216, 29.985295], + 齐齐哈尔: [123.97, 47.33], + 盐城: [120.13, 33.38], + 赤峰: [118.87, 42.28], + 青岛: [120.33, 36.07], + 乳山: [121.52, 36.89], + 金昌: [102.188043, 38.520089], + 泉州: [118.58, 24.93], + 莱西: [120.53, 36.86], + 日照: [119.46, 35.42], + 胶南: [119.97, 35.88], + 南通: [121.05, 32.08], + 拉萨: [91.11, 29.97], + 云浮: [112.02, 22.93], + 梅州: [116.1, 24.55], + 文登: [122.05, 37.2], + 上海: [121.48, 31.22], + 攀枝花: [101.718637, 26.582347], + 威海: [122.1, 37.5], + 承德: [117.93, 40.97], + 厦门: [118.1, 24.46], + 汕尾: [115.375279, 22.786211], + 潮州: [116.63, 23.68], + 丹东: [124.37, 40.13], + 太仓: [121.1, 31.45], + 曲靖: [103.79, 25.51], + 烟台: [121.39, 37.52], + 福州: [119.3, 26.08], + 瓦房店: [121.979603, 39.627114], + 即墨: [120.45, 36.38], + 抚顺: [123.97, 41.97], + 玉溪: [102.52, 24.35], + 张家口: [114.87, 40.82], + 阳泉: [113.57, 37.85], + 莱州: [119.942327, 37.177017], + 湖州: [120.1, 30.86], + 汕头: [116.69, 23.39], + 昆山: [120.95, 31.39], + 宁波: [121.56, 29.86], + 湛江: [110.359377, 21.270708], + 揭阳: [116.35, 23.55], + 荣成: [122.41, 37.16], + 连云港: [119.16, 34.59], + 葫芦岛: [120.836932, 40.711052], + 常熟: [120.74, 31.64], + 东莞: [113.75, 23.04], + 河源: [114.68, 23.73], + 淮安: [119.15, 33.5], + 泰州: [119.9, 32.49], + 南宁: [108.33, 22.84], + 营口: [122.18, 40.65], + 惠州: [114.4, 23.09], + 江阴: [120.26, 31.91], + 蓬莱: [120.75, 37.8], + 韶关: [113.62, 24.84], + 嘉峪关: [98.289152, 39.77313], + 广州: [113.23, 23.16], + 延安: [109.47, 36.6], + 太原: [112.53, 37.87], + 清远: [113.01, 23.7], + 中山: [113.38, 22.52], + 昆明: [102.73, 25.04], + 寿光: [118.73, 36.86], + 盘锦: [122.070714, 41.119997], + 长治: [113.08, 36.18], + 深圳: [114.07, 22.62], + 珠海: [113.52, 22.3], + 宿迁: [118.3, 33.96], + 咸阳: [108.72, 34.36], + 铜川: [109.11, 35.09], + 平度: [119.97, 36.77], + 佛山: [113.11, 23.05], + 海口: [110.35, 20.02], + 江门: [113.06, 22.61], + 章丘: [117.53, 36.72], + 肇庆: [112.44, 23.05], + 大连: [121.62, 38.92], + 临汾: [111.5, 36.08], + 吴江: [120.63, 31.16], + 石嘴山: [106.39, 39.04], + 沈阳: [123.38, 41.8], + 苏州: [120.62, 31.32], + 茂名: [110.88, 21.68], + 嘉兴: [120.76, 30.77], + 长春: [125.35, 43.88], + 胶州: [120.03336, 36.264622], + 银川: [106.27, 38.47], + 张家港: [120.555821, 31.875428], + 三门峡: [111.19, 34.76], + 锦州: [121.15, 41.13], + 南昌: [115.89, 28.68], + 柳州: [109.4, 24.33], + 三亚: [109.511909, 18.252847], + 自贡: [104.778442, 29.33903], + 吉林: [126.57, 43.87], + 阳江: [111.95, 21.85], + 泸州: [105.39, 28.91], + 西宁: [101.74, 36.56], + 宜宾: [104.56, 29.77], + 呼和浩特: [111.65, 40.82], + 成都: [104.06, 30.67], + 大同: [113.3, 40.12], + 镇江: [119.44, 32.2], + 桂林: [110.28, 25.29], + 张家界: [110.479191, 29.117096], + 宜兴: [119.82, 31.36], + 北海: [109.12, 21.49], + 西安: [108.95, 34.27], + 金坛: [119.56, 31.74], + 东营: [118.49, 37.46], + 牡丹江: [129.58, 44.6], + 遵义: [106.9, 27.7], + 绍兴: [120.58, 30.01], + 扬州: [119.42, 32.39], + 常州: [119.95, 31.79], + 潍坊: [119.1, 36.62], + 重庆: [106.54, 29.59], + 台州: [121.420757, 28.656386], + 南京: [118.78, 32.04], + 滨州: [118.03, 37.36], + 贵阳: [106.71, 26.57], + 无锡: [120.29, 31.59], + 本溪: [123.73, 41.3], + 克拉玛依: [84.77, 45.59], + 渭南: [109.5, 34.52], + 马鞍山: [118.48, 31.56], + 宝鸡: [107.15, 34.38], + 焦作: [113.21, 35.24], + 句容: [119.16, 31.95], + 北京: [116.46, 39.92], + 徐州: [117.2, 34.26], + 衡水: [115.72, 37.72], + 包头: [110, 40.58], + 绵阳: [104.73, 31.48], + 乌鲁木齐: [87.68, 43.77], + 枣庄: [117.57, 34.86], + 杭州: [120.19, 30.26], + 淄博: [118.05, 36.78], + 鞍山: [122.85, 41.12], + 溧阳: [119.48, 31.43], + 库尔勒: [86.06, 41.68], + 安阳: [114.35, 36.1], + 开封: [114.35, 34.79], + 济南: [117, 36.65], + 德阳: [104.37, 31.13], + 温州: [120.65, 28.01], + 九江: [115.97, 29.71], + 邯郸: [114.47, 36.6], + 临安: [119.72, 30.23], + 兰州: [103.73, 36.03], + 沧州: [116.83, 38.33], + 临沂: [118.35, 35.05], + 南充: [106.110698, 30.837793], + 天津: [117.2, 39.13], + 富阳: [119.95, 30.07], + 泰安: [117.13, 36.18], + 诸暨: [120.23, 29.71], + 郑州: [113.65, 34.76], + 哈尔滨: [126.63, 45.75], + 聊城: [115.97, 36.45], + 芜湖: [118.38, 31.33], + 唐山: [118.02, 39.63], + 平顶山: [113.29, 33.75], + 邢台: [114.48, 37.05], + 德州: [116.29, 37.45], + 济宁: [116.59, 35.38], + 荆州: [112.239741, 30.335165], + 宜昌: [111.3, 30.7], + 义乌: [120.06, 29.32], + 丽水: [119.92, 28.45], + 洛阳: [112.44, 34.7], + 秦皇岛: [119.57, 39.95], + 株洲: [113.16, 27.83], + 石家庄: [114.48, 38.03], + 莱芜: [117.67, 36.19], + 常德: [111.69, 29.05], + 保定: [115.48, 38.85], + 湘潭: [112.91, 27.87], + 金华: [119.64, 29.12], + 岳阳: [113.09, 29.37], + 长沙: [113, 28.21], + 衢州: [118.88, 28.97], + 廊坊: [116.7, 39.53], + 菏泽: [115.480656, 35.23375], + 合肥: [117.27, 31.86], + 武汉: [114.31, 30.52], + 大庆: [125.03, 46.58] +}; +var convertData = function (data) { + var res = []; + for (var i = 0; i < data.length; i++) { + var geoCoord = geoCoordMap[data[i].name]; + if (geoCoord) { + res.push(geoCoord.concat(data[i].value)); + } + } + return res; +}; +option = { + title: { + text: '全国主要城市空气质量', + subtext: 'data from PM25.in', + sublink: 'http://www.pm25.in', + left: 'center', + textStyle: { + color: '#fff' + } + }, + backgroundColor: '#404a59', + visualMap: { + min: 0, + max: 500, + splitNumber: 5, + inRange: { + color: ['#d94e5d', '#eac736', '#50a3ba'].reverse() + }, + textStyle: { + color: '#fff' + } + }, + geo: { + map: 'china', + roam: true, + itemStyle: { + areaColor: '#323c48', + borderColor: '#111' + }, + emphasis: { + label: { + show: false + }, + itemStyle: { + areaColor: '#2a333d' + } + } + }, + series: [ + { + name: 'AQI', + type: 'heatmap', + coordinateSystem: 'geo', + data: convertData([ + { name: '海门', value: 9 }, + { name: '鄂尔多斯', value: 12 }, + { name: '招远', value: 12 }, + { name: '舟山', value: 12 }, + { name: '齐齐哈尔', value: 14 }, + { name: '盐城', value: 15 }, + { name: '赤峰', value: 16 }, + { name: '青岛', value: 18 }, + { name: '乳山', value: 18 }, + { name: '金昌', value: 19 }, + { name: '泉州', value: 21 }, + { name: '莱西', value: 21 }, + { name: '日照', value: 21 }, + { name: '胶南', value: 22 }, + { name: '南通', value: 23 }, + { name: '拉萨', value: 24 }, + { name: '云浮', value: 24 }, + { name: '梅州', value: 25 }, + { name: '文登', value: 25 }, + { name: '上海', value: 25 }, + { name: '攀枝花', value: 25 }, + { name: '威海', value: 25 }, + { name: '承德', value: 25 }, + { name: '厦门', value: 26 }, + { name: '汕尾', value: 26 }, + { name: '潮州', value: 26 }, + { name: '丹东', value: 27 }, + { name: '太仓', value: 27 }, + { name: '曲靖', value: 27 }, + { name: '烟台', value: 28 }, + { name: '福州', value: 29 }, + { name: '瓦房店', value: 30 }, + { name: '即墨', value: 30 }, + { name: '抚顺', value: 31 }, + { name: '玉溪', value: 31 }, + { name: '张家口', value: 31 }, + { name: '阳泉', value: 31 }, + { name: '莱州', value: 32 }, + { name: '湖州', value: 32 }, + { name: '汕头', value: 32 }, + { name: '昆山', value: 33 }, + { name: '宁波', value: 33 }, + { name: '湛江', value: 33 }, + { name: '揭阳', value: 34 }, + { name: '荣成', value: 34 }, + { name: '连云港', value: 35 }, + { name: '葫芦岛', value: 35 }, + { name: '常熟', value: 36 }, + { name: '东莞', value: 36 }, + { name: '河源', value: 36 }, + { name: '淮安', value: 36 }, + { name: '泰州', value: 36 }, + { name: '南宁', value: 37 }, + { name: '营口', value: 37 }, + { name: '惠州', value: 37 }, + { name: '江阴', value: 37 }, + { name: '蓬莱', value: 37 }, + { name: '韶关', value: 38 }, + { name: '嘉峪关', value: 38 }, + { name: '广州', value: 38 }, + { name: '延安', value: 38 }, + { name: '太原', value: 39 }, + { name: '清远', value: 39 }, + { name: '中山', value: 39 }, + { name: '昆明', value: 39 }, + { name: '寿光', value: 40 }, + { name: '盘锦', value: 40 }, + { name: '长治', value: 41 }, + { name: '深圳', value: 41 }, + { name: '珠海', value: 42 }, + { name: '宿迁', value: 43 }, + { name: '咸阳', value: 43 }, + { name: '铜川', value: 44 }, + { name: '平度', value: 44 }, + { name: '佛山', value: 44 }, + { name: '海口', value: 44 }, + { name: '江门', value: 45 }, + { name: '章丘', value: 45 }, + { name: '肇庆', value: 46 }, + { name: '大连', value: 47 }, + { name: '临汾', value: 47 }, + { name: '吴江', value: 47 }, + { name: '石嘴山', value: 49 }, + { name: '沈阳', value: 50 }, + { name: '苏州', value: 50 }, + { name: '茂名', value: 50 }, + { name: '嘉兴', value: 51 }, + { name: '长春', value: 51 }, + { name: '胶州', value: 52 }, + { name: '银川', value: 52 }, + { name: '张家港', value: 52 }, + { name: '三门峡', value: 53 }, + { name: '锦州', value: 54 }, + { name: '南昌', value: 54 }, + { name: '柳州', value: 54 }, + { name: '三亚', value: 54 }, + { name: '自贡', value: 56 }, + { name: '吉林', value: 56 }, + { name: '阳江', value: 57 }, + { name: '泸州', value: 57 }, + { name: '西宁', value: 57 }, + { name: '宜宾', value: 58 }, + { name: '呼和浩特', value: 58 }, + { name: '成都', value: 58 }, + { name: '大同', value: 58 }, + { name: '镇江', value: 59 }, + { name: '桂林', value: 59 }, + { name: '张家界', value: 59 }, + { name: '宜兴', value: 59 }, + { name: '北海', value: 60 }, + { name: '西安', value: 61 }, + { name: '金坛', value: 62 }, + { name: '东营', value: 62 }, + { name: '牡丹江', value: 63 }, + { name: '遵义', value: 63 }, + { name: '绍兴', value: 63 }, + { name: '扬州', value: 64 }, + { name: '常州', value: 64 }, + { name: '潍坊', value: 65 }, + { name: '重庆', value: 66 }, + { name: '台州', value: 67 }, + { name: '南京', value: 67 }, + { name: '滨州', value: 70 }, + { name: '贵阳', value: 71 }, + { name: '无锡', value: 71 }, + { name: '本溪', value: 71 }, + { name: '克拉玛依', value: 72 }, + { name: '渭南', value: 72 }, + { name: '马鞍山', value: 72 }, + { name: '宝鸡', value: 72 }, + { name: '焦作', value: 75 }, + { name: '句容', value: 75 }, + { name: '北京', value: 79 }, + { name: '徐州', value: 79 }, + { name: '衡水', value: 80 }, + { name: '包头', value: 80 }, + { name: '绵阳', value: 80 }, + { name: '乌鲁木齐', value: 84 }, + { name: '枣庄', value: 84 }, + { name: '杭州', value: 84 }, + { name: '淄博', value: 85 }, + { name: '鞍山', value: 86 }, + { name: '溧阳', value: 86 }, + { name: '库尔勒', value: 86 }, + { name: '安阳', value: 90 }, + { name: '开封', value: 90 }, + { name: '济南', value: 92 }, + { name: '德阳', value: 93 }, + { name: '温州', value: 95 }, + { name: '九江', value: 96 }, + { name: '邯郸', value: 98 }, + { name: '临安', value: 99 }, + { name: '兰州', value: 99 }, + { name: '沧州', value: 100 }, + { name: '临沂', value: 103 }, + { name: '南充', value: 104 }, + { name: '天津', value: 105 }, + { name: '富阳', value: 106 }, + { name: '泰安', value: 112 }, + { name: '诸暨', value: 112 }, + { name: '郑州', value: 113 }, + { name: '哈尔滨', value: 114 }, + { name: '聊城', value: 116 }, + { name: '芜湖', value: 117 }, + { name: '唐山', value: 119 }, + { name: '平顶山', value: 119 }, + { name: '邢台', value: 119 }, + { name: '德州', value: 120 }, + { name: '济宁', value: 120 }, + { name: '荆州', value: 127 }, + { name: '宜昌', value: 130 }, + { name: '义乌', value: 132 }, + { name: '丽水', value: 133 }, + { name: '洛阳', value: 134 }, + { name: '秦皇岛', value: 136 }, + { name: '株洲', value: 143 }, + { name: '石家庄', value: 147 }, + { name: '莱芜', value: 148 }, + { name: '常德', value: 152 }, + { name: '保定', value: 153 }, + { name: '湘潭', value: 154 }, + { name: '金华', value: 157 }, + { name: '岳阳', value: 169 }, + { name: '长沙', value: 175 }, + { name: '衢州', value: 177 }, + { name: '廊坊', value: 193 }, + { name: '菏泽', value: 194 }, + { name: '合肥', value: 229 }, + { name: '武汉', value: 273 }, + { name: '大庆', value: 279 } + ]) + } + ] +}; diff --git a/testdata/line-aqi.js b/testdata/line-aqi.js new file mode 100644 index 0000000..169105f --- /dev/null +++ b/testdata/line-aqi.js @@ -0,0 +1,115 @@ +/* +title: Beijing AQI +category: line +titleCN: 北京 AQI 可视化 +difficulty: 4 +*/ +$.get(ROOT_PATH + '/data/asset/data/aqi-beijing.json', function (data) { + myChart.setOption((option = { + title: { + text: 'Beijing AQI', + left: '1%' + }, + tooltip: { + trigger: 'axis' + }, + grid: { + left: '5%', + right: '15%', + bottom: '10%' + }, + xAxis: { + data: data.map(function (item) { + return item[0]; + }) + }, + yAxis: {}, + toolbox: { + right: 10, + feature: { + dataZoom: { + yAxisIndex: 'none' + }, + restore: {}, + saveAsImage: {} + } + }, + dataZoom: [ + { + startValue: '2014-06-01' + }, + { + type: 'inside' + } + ], + visualMap: { + top: 50, + right: 10, + pieces: [ + { + gt: 0, + lte: 50, + color: '#93CE07' + }, + { + gt: 50, + lte: 100, + color: '#FBDB0F' + }, + { + gt: 100, + lte: 150, + color: '#FC7D02' + }, + { + gt: 150, + lte: 200, + color: '#FD0100' + }, + { + gt: 200, + lte: 300, + color: '#AA069F' + }, + { + gt: 300, + color: '#AC3B2A' + } + ], + outOfRange: { + color: '#999' + } + }, + series: { + name: 'Beijing AQI', + type: 'line', + data: data.map(function (item) { + return item[1]; + }), + markLine: { + silent: true, + lineStyle: { + color: '#333' + }, + data: [ + { + yAxis: 50 + }, + { + yAxis: 100 + }, + { + yAxis: 150 + }, + { + yAxis: 200 + }, + { + yAxis: 300 + } + ] + } + } + })); +}); +export {}; diff --git a/testdata/line-draggable.js b/testdata/line-draggable.js new file mode 100644 index 0000000..82dde22 --- /dev/null +++ b/testdata/line-draggable.js @@ -0,0 +1,140 @@ +/* +title: Draggable Points +category: 'line, graphic' +titleCN: 可拖拽点 +difficulty: 12 +*/ +const symbolSize = 20; +const data = [ + [40, -10], + [-30, -5], + [-76.5, 20], + [-63.5, 40], + [-22.1, 50] +]; +option = { + title: { + text: 'Try Dragging these Points', + left: 'center' + }, + tooltip: { + triggerOn: 'none', + formatter: function (params) { + return ('X: ' + + params.data[0].toFixed(2) + + '
Y: ' + + params.data[1].toFixed(2)); + } + }, + grid: { + top: '8%', + bottom: '12%' + }, + xAxis: { + min: -100, + max: 70, + type: 'value', + axisLine: { onZero: false } + }, + yAxis: { + min: -30, + max: 60, + type: 'value', + axisLine: { onZero: false } + }, + dataZoom: [ + { + type: 'slider', + xAxisIndex: 0, + filterMode: 'none' + }, + { + type: 'slider', + yAxisIndex: 0, + filterMode: 'none' + }, + { + type: 'inside', + xAxisIndex: 0, + filterMode: 'none' + }, + { + type: 'inside', + yAxisIndex: 0, + filterMode: 'none' + } + ], + series: [ + { + id: 'a', + type: 'line', + smooth: true, + symbolSize: symbolSize, + data: data + } + ] +}; +setTimeout(function () { + // Add shadow circles (which is not visible) to enable drag. + myChart.setOption({ + graphic: data.map(function (item, dataIndex) { + return { + type: 'circle', + position: myChart.convertToPixel('grid', item), + shape: { + cx: 0, + cy: 0, + r: symbolSize / 2 + }, + invisible: true, + draggable: true, + ondrag: function (dx, dy) { + onPointDragging(dataIndex, [this.x, this.y]); + }, + onmousemove: function () { + showTooltip(dataIndex); + }, + onmouseout: function () { + hideTooltip(dataIndex); + }, + z: 100 + }; + }) + }); +}, 0); +window.addEventListener('resize', updatePosition); +myChart.on('dataZoom', updatePosition); +function updatePosition() { + myChart.setOption({ + graphic: data.map(function (item, dataIndex) { + return { + position: myChart.convertToPixel('grid', item) + }; + }) + }); +} +function showTooltip(dataIndex) { + myChart.dispatchAction({ + type: 'showTip', + seriesIndex: 0, + dataIndex: dataIndex + }); +} +function hideTooltip(dataIndex) { + myChart.dispatchAction({ + type: 'hideTip' + }); +} +function onPointDragging(dataIndex, pos) { + data[dataIndex] = myChart.convertFromPixel('grid', pos); + // Update data + myChart.setOption({ + series: [ + { + id: 'a', + data: data + } + ] + }); +} +export {}; diff --git a/testdata/line-easing.js b/testdata/line-easing.js new file mode 100644 index 0000000..4781f8a --- /dev/null +++ b/testdata/line-easing.js @@ -0,0 +1,285 @@ +/* +title: Line Easing Visualizing +category: line +titleCN: 缓动函数可视化 +difficulty: 8 +*/ +const easingFuncs = { + linear: function (k) { + return k; + }, + quadraticIn: function (k) { + return k * k; + }, + quadraticOut: function (k) { + return k * (2 - k); + }, + quadraticInOut: function (k) { + if ((k *= 2) < 1) { + return 0.5 * k * k; + } + return -0.5 * (--k * (k - 2) - 1); + }, + cubicIn: function (k) { + return k * k * k; + }, + cubicOut: function (k) { + return --k * k * k + 1; + }, + cubicInOut: function (k) { + if ((k *= 2) < 1) { + return 0.5 * k * k * k; + } + return 0.5 * ((k -= 2) * k * k + 2); + }, + quarticIn: function (k) { + return k * k * k * k; + }, + quarticOut: function (k) { + return 1 - --k * k * k * k; + }, + quarticInOut: function (k) { + if ((k *= 2) < 1) { + return 0.5 * k * k * k * k; + } + return -0.5 * ((k -= 2) * k * k * k - 2); + }, + quinticIn: function (k) { + return k * k * k * k * k; + }, + quinticOut: function (k) { + return --k * k * k * k * k + 1; + }, + quinticInOut: function (k) { + if ((k *= 2) < 1) { + return 0.5 * k * k * k * k * k; + } + return 0.5 * ((k -= 2) * k * k * k * k + 2); + }, + sinusoidalIn: function (k) { + return 1 - Math.cos((k * Math.PI) / 2); + }, + sinusoidalOut: function (k) { + return Math.sin((k * Math.PI) / 2); + }, + sinusoidalInOut: function (k) { + return 0.5 * (1 - Math.cos(Math.PI * k)); + }, + exponentialIn: function (k) { + return k === 0 ? 0 : Math.pow(1024, k - 1); + }, + exponentialOut: function (k) { + return k === 1 ? 1 : 1 - Math.pow(2, -10 * k); + }, + exponentialInOut: function (k) { + if (k === 0) { + return 0; + } + if (k === 1) { + return 1; + } + if ((k *= 2) < 1) { + return 0.5 * Math.pow(1024, k - 1); + } + return 0.5 * (-Math.pow(2, -10 * (k - 1)) + 2); + }, + circularIn: function (k) { + return 1 - Math.sqrt(1 - k * k); + }, + circularOut: function (k) { + return Math.sqrt(1 - --k * k); + }, + circularInOut: function (k) { + if ((k *= 2) < 1) { + return -0.5 * (Math.sqrt(1 - k * k) - 1); + } + return 0.5 * (Math.sqrt(1 - (k -= 2) * k) + 1); + }, + elasticIn: function (k) { + var s; + var a = 0.1; + var p = 0.4; + if (k === 0) { + return 0; + } + if (k === 1) { + return 1; + } + if (!a || a < 1) { + a = 1; + s = p / 4; + } + else { + s = (p * Math.asin(1 / a)) / (2 * Math.PI); + } + return -(a * + Math.pow(2, 10 * (k -= 1)) * + Math.sin(((k - s) * (2 * Math.PI)) / p)); + }, + elasticOut: function (k) { + var s; + var a = 0.1; + var p = 0.4; + if (k === 0) { + return 0; + } + if (k === 1) { + return 1; + } + if (!a || a < 1) { + a = 1; + s = p / 4; + } + else { + s = (p * Math.asin(1 / a)) / (2 * Math.PI); + } + return (a * Math.pow(2, -10 * k) * Math.sin(((k - s) * (2 * Math.PI)) / p) + 1); + }, + elasticInOut: function (k) { + var s; + var a = 0.1; + var p = 0.4; + if (k === 0) { + return 0; + } + if (k === 1) { + return 1; + } + if (!a || a < 1) { + a = 1; + s = p / 4; + } + else { + s = (p * Math.asin(1 / a)) / (2 * Math.PI); + } + if ((k *= 2) < 1) { + return (-0.5 * + (a * + Math.pow(2, 10 * (k -= 1)) * + Math.sin(((k - s) * (2 * Math.PI)) / p))); + } + return (a * + Math.pow(2, -10 * (k -= 1)) * + Math.sin(((k - s) * (2 * Math.PI)) / p) * + 0.5 + + 1); + }, + // 在某一动画开始沿指示的路径进行动画处理前稍稍收回该动画的移动 + backIn: function (k) { + var s = 1.70158; + return k * k * ((s + 1) * k - s); + }, + backOut: function (k) { + var s = 1.70158; + return --k * k * ((s + 1) * k + s) + 1; + }, + backInOut: function (k) { + var s = 1.70158 * 1.525; + if ((k *= 2) < 1) { + return 0.5 * (k * k * ((s + 1) * k - s)); + } + return 0.5 * ((k -= 2) * k * ((s + 1) * k + s) + 2); + }, + // 创建弹跳效果 + bounceIn: function (k) { + return 1 - easingFuncs.bounceOut(1 - k); + }, + bounceOut: function (k) { + if (k < 1 / 2.75) { + return 7.5625 * k * k; + } + else if (k < 2 / 2.75) { + return 7.5625 * (k -= 1.5 / 2.75) * k + 0.75; + } + else if (k < 2.5 / 2.75) { + return 7.5625 * (k -= 2.25 / 2.75) * k + 0.9375; + } + else { + return 7.5625 * (k -= 2.625 / 2.75) * k + 0.984375; + } + }, + bounceInOut: function (k) { + if (k < 0.5) { + return easingFuncs.bounceIn(k * 2) * 0.5; + } + return easingFuncs.bounceOut(k * 2 - 1) * 0.5 + 0.5; + } +}; +const N_POINT = 30; +const grids = []; +const xAxes = []; +const yAxes = []; +const series = []; +const titles = []; +let count = 0; +Object.keys(easingFuncs).forEach(function (easingName) { + var easingFunc = easingFuncs[easingName]; + var data = []; + for (var i = 0; i <= N_POINT; i++) { + var x = i / N_POINT; + var y = easingFunc(x); + data.push([x, y]); + } + grids.push({ + show: true, + borderWidth: 0, + shadowColor: 'rgba(0, 0, 0, 0.3)', + shadowBlur: 2 + }); + xAxes.push({ + type: 'value', + show: false, + min: 0, + max: 1, + gridIndex: count + }); + yAxes.push({ + type: 'value', + show: false, + min: -0.4, + max: 1.4, + gridIndex: count + }); + series.push({ + name: easingName, + type: 'line', + xAxisIndex: count, + yAxisIndex: count, + data: data, + showSymbol: false, + animationEasing: easingName, + animationDuration: 1000 + }); + titles.push({ + textAlign: 'center', + text: easingName, + textStyle: { + fontSize: 12, + fontWeight: 'normal' + } + }); + count++; +}); +var rowNumber = Math.ceil(Math.sqrt(count)); +grids.forEach(function (grid, idx) { + grid.left = ((idx % rowNumber) / rowNumber) * 100 + 0.5 + '%'; + grid.top = (Math.floor(idx / rowNumber) / rowNumber) * 100 + 0.5 + '%'; + grid.width = (1 / rowNumber) * 100 - 1 + '%'; + grid.height = (1 / rowNumber) * 100 - 1 + '%'; + titles[idx].left = parseFloat(grid.left) + parseFloat(grid.width) / 2 + '%'; + titles[idx].top = parseFloat(grid.top) + '%'; +}); +option = { + title: titles.concat([ + { + text: 'Different Easing Functions', + top: 'bottom', + left: 'center' + } + ]), + grid: grids, + xAxis: xAxes, + yAxis: yAxes, + series: series +}; +export {}; diff --git a/testdata/line-easing.js.svg b/testdata/line-easing.js.svg new file mode 100644 index 0000000..7b84698 --- /dev/null +++ b/testdata/line-easing.js.svg @@ -0,0 +1,634 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +linear +quadraticIn +quadraticOut +quadraticInOut +cubicIn +cubicOut +cubicInOut +quarticIn +quarticOut +quarticInOut +quinticIn +quinticOut +quinticInOut +sinusoidalIn +sinusoidalOut +sinusoidalInOut +exponentialIn +exponentialOut +exponentialInOut +circularIn +circularOut +circularInOut +elasticIn +elasticOut +elasticInOut +backIn +backOut +backInOut +bounceIn +bounceOut +bounceInOut +Different Easing Functions + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/line-function.js b/testdata/line-function.js new file mode 100644 index 0000000..e4d0831 --- /dev/null +++ b/testdata/line-function.js @@ -0,0 +1,73 @@ +/* +title: Function Plot +category: line +titleCN: 函数绘图 +difficulty: 5 +*/ +function func(x) { + x /= 10; + return Math.sin(x) * Math.cos(x * 2 + 1) * Math.sin(x * 3 + 2) * 50; +} +function generateData() { + let data = []; + for (let i = -200; i <= 200; i += 0.1) { + data.push([i, func(i)]); + } + return data; +} +option = { + animation: false, + grid: { + top: 40, + left: 50, + right: 40, + bottom: 50 + }, + xAxis: { + name: 'x', + minorTick: { + show: true + }, + minorSplitLine: { + show: true + } + }, + yAxis: { + name: 'y', + min: -100, + max: 100, + minorTick: { + show: true + }, + minorSplitLine: { + show: true + } + }, + dataZoom: [ + { + show: true, + type: 'inside', + filterMode: 'none', + xAxisIndex: [0], + startValue: -20, + endValue: 20 + }, + { + show: true, + type: 'inside', + filterMode: 'none', + yAxisIndex: [0], + startValue: -20, + endValue: 20 + } + ], + series: [ + { + type: 'line', + showSymbol: false, + clip: true, + data: generateData() + } + ] +}; +export {}; diff --git a/testdata/line-function.js.svg b/testdata/line-function.js.svg new file mode 100644 index 0000000..5f00b17 --- /dev/null +++ b/testdata/line-function.js.svg @@ -0,0 +1,109 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +y + +x + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +-20 +-10 +0 +10 +20 +-20 +-10 +0 +10 +20 + + + + + + + + + \ No newline at end of file diff --git a/testdata/line-gradient.js b/testdata/line-gradient.js new file mode 100644 index 0000000..6ee262a --- /dev/null +++ b/testdata/line-gradient.js @@ -0,0 +1,86 @@ +/* +title: Line Gradient +category: line +titleCN: 折线图的渐变 +difficulty: 3 +*/ +// prettier-ignore +const data = [["2000-06-05", 116], ["2000-06-06", 129], ["2000-06-07", 135], ["2000-06-08", 86], ["2000-06-09", 73], ["2000-06-10", 85], ["2000-06-11", 73], ["2000-06-12", 68], ["2000-06-13", 92], ["2000-06-14", 130], ["2000-06-15", 245], ["2000-06-16", 139], ["2000-06-17", 115], ["2000-06-18", 111], ["2000-06-19", 309], ["2000-06-20", 206], ["2000-06-21", 137], ["2000-06-22", 128], ["2000-06-23", 85], ["2000-06-24", 94], ["2000-06-25", 71], ["2000-06-26", 106], ["2000-06-27", 84], ["2000-06-28", 93], ["2000-06-29", 85], ["2000-06-30", 73], ["2000-07-01", 83], ["2000-07-02", 125], ["2000-07-03", 107], ["2000-07-04", 82], ["2000-07-05", 44], ["2000-07-06", 72], ["2000-07-07", 106], ["2000-07-08", 107], ["2000-07-09", 66], ["2000-07-10", 91], ["2000-07-11", 92], ["2000-07-12", 113], ["2000-07-13", 107], ["2000-07-14", 131], ["2000-07-15", 111], ["2000-07-16", 64], ["2000-07-17", 69], ["2000-07-18", 88], ["2000-07-19", 77], ["2000-07-20", 83], ["2000-07-21", 111], ["2000-07-22", 57], ["2000-07-23", 55], ["2000-07-24", 60]]; +const dateList = data.map(function (item) { + return item[0]; +}); +const valueList = data.map(function (item) { + return item[1]; +}); +option = { + // Make gradient line here + visualMap: [ + { + show: false, + type: 'continuous', + seriesIndex: 0, + min: 0, + max: 400 + }, + { + show: false, + type: 'continuous', + seriesIndex: 1, + dimension: 0, + min: 0, + max: dateList.length - 1 + } + ], + title: [ + { + left: 'center', + text: 'Gradient along the y axis' + }, + { + top: '55%', + left: 'center', + text: 'Gradient along the x axis' + } + ], + tooltip: { + trigger: 'axis' + }, + xAxis: [ + { + data: dateList + }, + { + data: dateList, + gridIndex: 1 + } + ], + yAxis: [ + {}, + { + gridIndex: 1 + } + ], + grid: [ + { + bottom: '60%' + }, + { + top: '60%' + } + ], + series: [ + { + type: 'line', + showSymbol: false, + data: valueList + }, + { + type: 'line', + showSymbol: false, + data: valueList, + xAxisIndex: 1, + yAxisIndex: 1 + } + ] +}; +export {}; diff --git a/testdata/line-gradient.js.svg b/testdata/line-gradient.js.svg new file mode 100644 index 0000000..41202eb --- /dev/null +++ b/testdata/line-gradient.js.svg @@ -0,0 +1,530 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +0 +50 +100 +150 +200 +250 +300 +350 +0 +50 +100 +150 +200 +250 +300 +350 +2000-06-05 +2000-06-11 +2000-06-17 +2000-06-23 +2000-06-29 +2000-07-05 +2000-07-11 +2000-07-17 +2000-07-23 +2000-06-05 +2000-06-11 +2000-06-17 +2000-06-23 +2000-06-29 +2000-07-05 +2000-07-11 +2000-07-17 +2000-07-23 + + + + + + + + +Gradient along the y axis +Gradient along the x axis + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/line-graphic.js b/testdata/line-graphic.js new file mode 100644 index 0000000..d64b342 --- /dev/null +++ b/testdata/line-graphic.js @@ -0,0 +1,120 @@ +/* +title: Custom Graphic Component +titleCN: 自定义图形组件 +category: line, graphic +difficulty: 9 +*/ +option = { + legend: { + data: ['Altitude (km) vs Temperature (°C)'] + }, + tooltip: { + trigger: 'axis', + formatter: 'Temperature :
{b}km : {c}°C' + }, + grid: { + left: '3%', + right: '4%', + bottom: '3%', + containLabel: true + }, + xAxis: { + type: 'value', + axisLabel: { + formatter: '{value} °C' + } + }, + yAxis: { + type: 'category', + axisLine: { onZero: false }, + axisLabel: { + formatter: '{value} km' + }, + boundaryGap: true, + data: ['0', '10', '20', '30', '40', '50', '60', '70', '80'] + }, + graphic: [ + { + type: 'group', + rotation: Math.PI / 4, + bounding: 'raw', + right: 110, + bottom: 110, + z: 100, + children: [ + { + type: 'rect', + left: 'center', + top: 'center', + z: 100, + shape: { + width: 400, + height: 50 + }, + style: { + fill: 'rgba(0,0,0,0.3)' + } + }, + { + type: 'text', + left: 'center', + top: 'center', + z: 100, + style: { + fill: '#fff', + text: 'ECHARTS LINE CHART', + font: 'bold 26px sans-serif' + } + } + ] + }, + { + type: 'group', + left: '10%', + top: 'center', + children: [ + { + type: 'rect', + z: 100, + left: 'center', + top: 'middle', + shape: { + width: 240, + height: 90 + }, + style: { + fill: '#fff', + stroke: '#555', + lineWidth: 1, + shadowBlur: 8, + shadowOffsetX: 3, + shadowOffsetY: 3, + shadowColor: 'rgba(0,0,0,0.2)' + } + }, + { + type: 'text', + z: 100, + left: 'center', + top: 'middle', + style: { + fill: '#333', + width: 220, + overflow: 'break', + text: 'xAxis represents temperature in °C, yAxis represents altitude in km, An image watermark in the upper right, This text block can be placed in any place', + font: '14px Microsoft YaHei' + } + } + ] + } + ], + series: [ + { + name: '高度(km)与气温(°C)变化关系', + type: 'line', + smooth: true, + data: [15, -50, -56.5, -46.5, -22.1, -2.5, -27.7, -55.7, -76.5] + } + ] +}; +export {}; diff --git a/testdata/line-graphic.js.svg b/testdata/line-graphic.js.svg new file mode 100644 index 0000000..9882e21 --- /dev/null +++ b/testdata/line-graphic.js.svg @@ -0,0 +1,79 @@ + + + + + + + + + + + + + + + + + + + +0 km +10 km +20 km +30 km +40 km +50 km +60 km +70 km +80 km +-80 °C +-60 °C +-40 °C +-20 °C +0 °C +20 °C + + + + + + + + + + + + + + +ECHARTS LINE CHART + +xAxis represents temperature in +°C, yAxis represents altitude in +km, An image watermark in the +upper right, This text block can be +placed in any place + + + + + + + + + + \ No newline at end of file diff --git a/testdata/line-in-cartesian-coordinate-system.js b/testdata/line-in-cartesian-coordinate-system.js new file mode 100644 index 0000000..4969ca6 --- /dev/null +++ b/testdata/line-in-cartesian-coordinate-system.js @@ -0,0 +1,21 @@ +/* +title: Line Chart in Cartesian Coordinate System +category: line +titleCN: 双数值轴折线图 +difficulty: 7 +*/ +option = { + xAxis: {}, + yAxis: {}, + series: [ + { + data: [ + [10, 40], + [50, 100], + [40, 20] + ], + type: 'line' + } + ] +}; +export {}; diff --git a/testdata/line-in-cartesian-coordinate-system.js.svg b/testdata/line-in-cartesian-coordinate-system.js.svg new file mode 100644 index 0000000..cc9eed6 --- /dev/null +++ b/testdata/line-in-cartesian-coordinate-system.js.svg @@ -0,0 +1,67 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +0 +20 +40 +60 +80 +100 +0 +10 +20 +30 +40 +50 + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/line-log.js b/testdata/line-log.js new file mode 100644 index 0000000..204eb24 --- /dev/null +++ b/testdata/line-log.js @@ -0,0 +1,66 @@ +/* +title: Log Axis +category: line +titleCN: 对数轴示例 +difficulty: 7 +*/ +option = { + title: { + text: 'Log Axis', + left: 'center' + }, + tooltip: { + trigger: 'item', + formatter: '{a}
{b} : {c}' + }, + legend: { + left: 'left' + }, + xAxis: { + type: 'category', + name: 'x', + splitLine: { show: false }, + data: ['A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I'] + }, + grid: { + left: '3%', + right: '4%', + bottom: '3%', + containLabel: true + }, + yAxis: { + type: 'log', + name: 'y', + minorSplitLine: { + show: true + } + }, + series: [ + { + name: 'Log2', + type: 'line', + data: [1, 3, 9, 27, 81, 247, 741, 2223, 6669] + }, + { + name: 'Log3', + type: 'line', + data: [1, 2, 4, 8, 16, 32, 64, 128, 256] + }, + { + name: 'Log1/2', + type: 'line', + data: [ + 1 / 2, + 1 / 4, + 1 / 8, + 1 / 16, + 1 / 32, + 1 / 64, + 1 / 128, + 1 / 256, + 1 / 512 + ] + } + ] +}; +export {}; diff --git a/testdata/line-log.js.svg b/testdata/line-log.js.svg new file mode 100644 index 0000000..a76a9c3 --- /dev/null +++ b/testdata/line-log.js.svg @@ -0,0 +1,165 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +y + +x + + + + + + + + + + +0.001 +0.01 +0.1 +1 +10 +100 +1,000 +10,000 +A +B +C +D +E +F +G +H +I + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Log2 + + +Log3 + + +Log1/2 + +Log Axis + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/line-marker.js b/testdata/line-marker.js new file mode 100644 index 0000000..5a95722 --- /dev/null +++ b/testdata/line-marker.js @@ -0,0 +1,84 @@ +/* +title: Temperature Change in the Coming Week +category: line +titleCN: 未来一周气温变化 +difficulty: 2 +*/ +option = { + title: { + text: 'Temperature Change in the Coming Week' + }, + tooltip: { + trigger: 'axis' + }, + legend: {}, + toolbox: { + show: true, + feature: { + dataZoom: { + yAxisIndex: 'none' + }, + dataView: { readOnly: false }, + magicType: { type: ['line', 'bar'] }, + restore: {}, + saveAsImage: {} + } + }, + xAxis: { + type: 'category', + boundaryGap: false, + data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'] + }, + yAxis: { + type: 'value', + axisLabel: { + formatter: '{value} °C' + } + }, + series: [ + { + name: 'Highest', + type: 'line', + data: [10, 11, 13, 11, 12, 12, 9], + markPoint: { + data: [ + { type: 'max', name: 'Max' }, + { type: 'min', name: 'Min' } + ] + }, + markLine: { + data: [{ type: 'average', name: 'Avg' }] + } + }, + { + name: 'Lowest', + type: 'line', + data: [1, -2, 2, 5, 3, 2, 0], + markPoint: { + data: [{ name: '周最低', value: -2, xAxis: 1, yAxis: -1.5 }] + }, + markLine: { + data: [ + { type: 'average', name: 'Avg' }, + [ + { + symbol: 'none', + x: '90%', + yAxis: 'max' + }, + { + symbol: 'circle', + label: { + position: 'start', + formatter: 'Max' + }, + type: 'max', + name: '最高点' + } + ] + ] + } + } + ] +}; +export {}; diff --git a/testdata/line-marker.js.svg b/testdata/line-marker.js.svg new file mode 100644 index 0000000..0610ceb --- /dev/null +++ b/testdata/line-marker.js.svg @@ -0,0 +1,120 @@ + + + + + + + + + + + + + + + + + +-3 °C +0 °C +3 °C +6 °C +9 °C +12 °C +15 °C +Mon +Tue +Wed +Thu +Fri +Sat +Sun + + + + + + + + + + + + + + + + + + + + + + + +Highest + + +Lowest + + + + + + + + +11.14 +1.57 +Max + + + +13 +9 +-2 + + + + + + + + + +Temperature Change in the Coming Week + + + + + + + + + + \ No newline at end of file diff --git a/testdata/line-markline.js b/testdata/line-markline.js new file mode 100644 index 0000000..07f93c5 --- /dev/null +++ b/testdata/line-markline.js @@ -0,0 +1,86 @@ +/* +title: Line with Marklines +titleCN: 折线图的标记线 +category: line +difficulty: 6 +*/ +const markLine = []; +const positions = [ + 'start', + 'middle', + 'end', + 'insideStart', + 'insideStartTop', + 'insideStartBottom', + 'insideMiddle', + 'insideMiddleTop', + 'insideMiddleBottom', + 'insideEnd', + 'insideEndTop', + 'insideEndBottom' +]; +for (var i = 0; i < positions.length; ++i) { + markLine.push({ + name: positions[i], + yAxis: 1.8 - 0.2 * Math.floor(i / 3), + label: { + formatter: '{b}', + position: positions[i] + } + }); + if (positions[i] !== 'middle') { + const name = positions[i] === 'insideMiddle' ? 'insideMiddle / middle' : positions[i]; + markLine.push([ + { + name: 'start: ' + positions[i], + coord: [0, 0.3], + label: { + formatter: name, + position: positions[i] + } + }, + { + name: 'end: ' + positions[i], + coord: [3, 1] + } + ]); + } +} +option = { + animation: false, + textStyle: { + fontSize: 14 + }, + xAxis: { + data: ['A', 'B', 'C', 'D', 'E'], + boundaryGap: true, + splitArea: { + show: true + } + }, + yAxis: { + max: 2 + }, + series: [ + { + name: 'line', + type: 'line', + stack: 'all', + symbolSize: 6, + data: [0.3, 1.4, 1.2, 1, 0.6], + markLine: { + data: markLine, + label: { + distance: [20, 8] + } + } + } + ], + grid: { + top: 30, + left: 60, + right: 60, + bottom: 40 + } +}; +export {}; diff --git a/testdata/line-markline.js.svg b/testdata/line-markline.js.svg new file mode 100644 index 0000000..bac4e49 --- /dev/null +++ b/testdata/line-markline.js.svg @@ -0,0 +1,135 @@ + + + + + + + + + + + + + + + + + + + +0 +0.5 +1 +1.5 +2 +A +B +C +D +E + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +start +start +middle +end +end +insideStart +insideStart +insideStartTop +insideStartTop +insideStartBottom +insideStartBottom +insideMiddle +insideMiddle / middle +insideMiddleTop +insideMiddleTop +insideMiddleBottom +insideMiddleBottom +insideEnd +insideEnd +insideEndTop +insideEndTop +insideEndBottom +insideEndBottom + + + + + + \ No newline at end of file diff --git a/testdata/line-pen.js b/testdata/line-pen.js new file mode 100644 index 0000000..7427c2c --- /dev/null +++ b/testdata/line-pen.js @@ -0,0 +1,73 @@ +/* +title: Click to Add Points +category: line +titleCN: 点击添加折线图拐点 +difficulty: 9 +*/ +const symbolSize = 20; +const data = [ + [15, 0], + [-50, 10], + [-56.5, 20], + [-46.5, 30], + [-22.1, 40] +]; +option = { + title: { + text: 'Click to Add Points' + }, + tooltip: { + formatter: function (params) { + var data = params.data || [0, 0]; + return data[0].toFixed(2) + ', ' + data[1].toFixed(2); + } + }, + grid: { + left: '3%', + right: '4%', + bottom: '3%', + containLabel: true + }, + xAxis: { + min: -60, + max: 20, + type: 'value', + axisLine: { onZero: false } + }, + yAxis: { + min: 0, + max: 40, + type: 'value', + axisLine: { onZero: false } + }, + series: [ + { + id: 'a', + type: 'line', + smooth: true, + symbolSize: symbolSize, + data: data + } + ] +}; +var zr = myChart.getZr(); +zr.on('click', function (params) { + var pointInPixel = [params.offsetX, params.offsetY]; + var pointInGrid = myChart.convertFromPixel('grid', pointInPixel); + if (myChart.containPixel('grid', pointInPixel)) { + data.push(pointInGrid); + myChart.setOption({ + series: [ + { + id: 'a', + data: data + } + ] + }); + } +}); +zr.on('mousemove', function (params) { + var pointInPixel = [params.offsetX, params.offsetY]; + zr.setCursorStyle(myChart.containPixel('grid', pointInPixel) ? 'copy' : 'default'); +}); +export {}; diff --git a/testdata/line-polar.js b/testdata/line-polar.js new file mode 100644 index 0000000..c768872 --- /dev/null +++ b/testdata/line-polar.js @@ -0,0 +1,41 @@ +/* +title: Two Value-Axes in Polar +category: line +titleCN: 极坐标双数值轴 +difficulty: 10 +*/ +const data = []; +for (let i = 0; i <= 100; i++) { + let theta = (i / 100) * 360; + let r = 5 * (1 + Math.sin((theta / 180) * Math.PI)); + data.push([r, theta]); +} +option = { + title: { + text: 'Two Value-Axes in Polar' + }, + legend: { + data: ['line'] + }, + polar: {}, + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'cross' + } + }, + angleAxis: { + type: 'value', + startAngle: 0 + }, + radiusAxis: {}, + series: [ + { + coordinateSystem: 'polar', + name: 'line', + type: 'line', + data: data + } + ] +}; +export {}; diff --git a/testdata/line-polar.js.svg b/testdata/line-polar.js.svg new file mode 100644 index 0000000..0de8bec --- /dev/null +++ b/testdata/line-polar.js.svg @@ -0,0 +1,145 @@ + + + +0 +30 +60 +90 +120 +150 +180 +210 +240 +270 +300 +330 + + + + + + + + + + +0 +2 +4 +6 +8 +10 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +line + +Two Value-Axes in Polar + + + + + + \ No newline at end of file diff --git a/testdata/line-polar2.js b/testdata/line-polar2.js new file mode 100644 index 0000000..c0436fe --- /dev/null +++ b/testdata/line-polar2.js @@ -0,0 +1,47 @@ +/* +title: Two Value-Axes in Polar +category: line +titleCN: 极坐标双数值轴 +difficulty: 10 +*/ +const data = []; +for (let i = 0; i <= 360; i++) { + let t = (i / 180) * Math.PI; + let r = Math.sin(2 * t) * Math.cos(2 * t); + data.push([r, i]); +} +option = { + title: { + text: 'Two Value-Axes in Polar' + }, + legend: { + data: ['line'] + }, + polar: { + center: ['50%', '54%'] + }, + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'cross' + } + }, + angleAxis: { + type: 'value', + startAngle: 0 + }, + radiusAxis: { + min: 0 + }, + series: [ + { + coordinateSystem: 'polar', + name: 'line', + type: 'line', + showSymbol: false, + data: data + } + ], + animationDuration: 2000 +}; +export {}; diff --git a/testdata/line-polar2.js.svg b/testdata/line-polar2.js.svg new file mode 100644 index 0000000..2cb917e --- /dev/null +++ b/testdata/line-polar2.js.svg @@ -0,0 +1,46 @@ + + + +0 +30 +60 +90 +120 +150 +180 +210 +240 +270 +300 +330 + + + + + + + + + + +0 +0.1 +0.2 +0.3 +0.4 +0.5 + + + + + + +line + +Two Value-Axes in Polar + + + + + + \ No newline at end of file diff --git a/testdata/line-race.js b/testdata/line-race.js new file mode 100644 index 0000000..6fd8dc5 --- /dev/null +++ b/testdata/line-race.js @@ -0,0 +1,97 @@ +/* +title: Line Race +category: line +titleCN: 动态排序折线图 +difficulty: 5 +videoStart: 3000 +videoEnd: 8000 +*/ +$.get(ROOT_PATH + '/data/asset/data/life-expectancy-table.json', function (_rawData) { + run(_rawData); +}); +function run(_rawData) { + // var countries = ['Australia', 'Canada', 'China', 'Cuba', 'Finland', 'France', 'Germany', 'Iceland', 'India', 'Japan', 'North Korea', 'South Korea', 'New Zealand', 'Norway', 'Poland', 'Russia', 'Turkey', 'United Kingdom', 'United States']; + const countries = [ + 'Finland', + 'France', + 'Germany', + 'Iceland', + 'Norway', + 'Poland', + 'Russia', + 'United Kingdom' + ]; + const datasetWithFilters = []; + const seriesList = []; + echarts.util.each(countries, function (country) { + var datasetId = 'dataset_' + country; + datasetWithFilters.push({ + id: datasetId, + fromDatasetId: 'dataset_raw', + transform: { + type: 'filter', + config: { + and: [ + { dimension: 'Year', gte: 1950 }, + { dimension: 'Country', '=': country } + ] + } + } + }); + seriesList.push({ + type: 'line', + datasetId: datasetId, + showSymbol: false, + name: country, + endLabel: { + show: true, + formatter: function (params) { + return params.value[3] + ': ' + params.value[0]; + } + }, + labelLayout: { + moveOverlap: 'shiftY' + }, + emphasis: { + focus: 'series' + }, + encode: { + x: 'Year', + y: 'Income', + label: ['Country', 'Income'], + itemName: 'Year', + tooltip: ['Income'] + } + }); + }); + option = { + animationDuration: 10000, + dataset: [ + { + id: 'dataset_raw', + source: _rawData + }, + ...datasetWithFilters + ], + title: { + text: 'Income of Germany and France since 1950' + }, + tooltip: { + order: 'valueDesc', + trigger: 'axis' + }, + xAxis: { + type: 'category', + nameLocation: 'middle' + }, + yAxis: { + name: 'Income' + }, + grid: { + right: 140 + }, + series: seriesList + }; + myChart.setOption(option); +} +export {}; diff --git a/testdata/line-sections.js b/testdata/line-sections.js new file mode 100644 index 0000000..488ad0c --- /dev/null +++ b/testdata/line-sections.js @@ -0,0 +1,103 @@ +/* +title: Distribution of Electricity +category: line +titleCN: 一天用电量分布 +difficulty: 3 +*/ +option = { + title: { + text: 'Distribution of Electricity', + subtext: 'Fake Data' + }, + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'cross' + } + }, + toolbox: { + show: true, + feature: { + saveAsImage: {} + } + }, + xAxis: { + type: 'category', + boundaryGap: false, + // prettier-ignore + data: ['00:00', '01:15', '02:30', '03:45', '05:00', '06:15', '07:30', '08:45', '10:00', '11:15', '12:30', '13:45', '15:00', '16:15', '17:30', '18:45', '20:00', '21:15', '22:30', '23:45'] + }, + yAxis: { + type: 'value', + axisLabel: { + formatter: '{value} W' + }, + axisPointer: { + snap: true + } + }, + visualMap: { + show: false, + dimension: 0, + pieces: [ + { + lte: 6, + color: 'green' + }, + { + gt: 6, + lte: 8, + color: 'red' + }, + { + gt: 8, + lte: 14, + color: 'green' + }, + { + gt: 14, + lte: 17, + color: 'red' + }, + { + gt: 17, + color: 'green' + } + ] + }, + series: [ + { + name: 'Electricity', + type: 'line', + smooth: true, + // prettier-ignore + data: [300, 280, 250, 260, 270, 300, 550, 500, 400, 390, 380, 390, 400, 500, 600, 750, 800, 700, 600, 400], + markArea: { + itemStyle: { + color: 'rgba(255, 173, 177, 0.4)' + }, + data: [ + [ + { + name: 'Morning Peak', + xAxis: '07:30' + }, + { + xAxis: '10:00' + } + ], + [ + { + name: 'Evening Peak', + xAxis: '17:30' + }, + { + xAxis: '21:15' + } + ] + ] + } + } + ] +}; +export {}; diff --git a/testdata/line-sections.js.svg b/testdata/line-sections.js.svg new file mode 100644 index 0000000..25f9287 --- /dev/null +++ b/testdata/line-sections.js.svg @@ -0,0 +1,96 @@ + + + + + + + + + + + + + + + + + + +0 W +200 W +400 W +600 W +800 W +00:00 +02:30 +05:00 +07:30 +10:00 +12:30 +15:00 +17:30 +20:00 +22:30 + + +Morning Peak +Evening Peak + + + + + + + + + + + + + + + + + + + + + + + + + + +Distribution of Electricity +Fake Data + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/line-simple.js b/testdata/line-simple.js new file mode 100644 index 0000000..c8c1c4d --- /dev/null +++ b/testdata/line-simple.js @@ -0,0 +1,22 @@ +/* +title: Basic Line Chart +category: line +titleCN: 基础折线图 +difficulty: 0 +*/ +option = { + xAxis: { + type: 'category', + data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'] + }, + yAxis: { + type: 'value' + }, + series: [ + { + data: [150, 230, 224, 218, 135, 147, 260], + type: 'line' + } + ] +}; +export {}; diff --git a/testdata/line-simple.js.svg b/testdata/line-simple.js.svg new file mode 100644 index 0000000..a003d85 --- /dev/null +++ b/testdata/line-simple.js.svg @@ -0,0 +1,63 @@ + + + + + + + + + + + + + + + + + + +0 +50 +100 +150 +200 +250 +300 +Mon +Tue +Wed +Thu +Fri +Sat +Sun + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/line-smooth.js b/testdata/line-smooth.js new file mode 100644 index 0000000..05c9964 --- /dev/null +++ b/testdata/line-smooth.js @@ -0,0 +1,23 @@ +/* +title: Smoothed Line Chart +category: line +titleCN: 基础平滑折线图 +difficulty: 0 +*/ +option = { + xAxis: { + type: 'category', + data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'] + }, + yAxis: { + type: 'value' + }, + series: [ + { + data: [820, 932, 901, 934, 1290, 1330, 1320], + type: 'line', + smooth: true + } + ] +}; +export {}; diff --git a/testdata/line-smooth.js.svg b/testdata/line-smooth.js.svg new file mode 100644 index 0000000..2fecee3 --- /dev/null +++ b/testdata/line-smooth.js.svg @@ -0,0 +1,61 @@ + + + + + + + + + + + + + + + + + +0 +300 +600 +900 +1,200 +1,500 +Mon +Tue +Wed +Thu +Fri +Sat +Sun + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/line-stack.js b/testdata/line-stack.js new file mode 100644 index 0000000..0426b8c --- /dev/null +++ b/testdata/line-stack.js @@ -0,0 +1,69 @@ +/* +title: Stacked Line Chart +category: line +titleCN: 折线图堆叠 +difficulty: 1 +*/ +option = { + title: { + text: 'Stacked Line' + }, + tooltip: { + trigger: 'axis' + }, + legend: { + data: ['Email', 'Union Ads', 'Video Ads', 'Direct', 'Search Engine'] + }, + grid: { + left: '3%', + right: '4%', + bottom: '3%', + containLabel: true + }, + toolbox: { + feature: { + saveAsImage: {} + } + }, + xAxis: { + type: 'category', + boundaryGap: false, + data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'] + }, + yAxis: { + type: 'value' + }, + series: [ + { + name: 'Email', + type: 'line', + stack: 'Total', + data: [120, 132, 101, 134, 90, 230, 210] + }, + { + name: 'Union Ads', + type: 'line', + stack: 'Total', + data: [220, 182, 191, 234, 290, 330, 310] + }, + { + name: 'Video Ads', + type: 'line', + stack: 'Total', + data: [150, 232, 201, 154, 190, 330, 410] + }, + { + name: 'Direct', + type: 'line', + stack: 'Total', + data: [320, 332, 301, 334, 390, 330, 320] + }, + { + name: 'Search Engine', + type: 'line', + stack: 'Total', + data: [820, 932, 901, 934, 1290, 1330, 1320] + } + ] +}; +export {}; diff --git a/testdata/line-stack.js.svg b/testdata/line-stack.js.svg new file mode 100644 index 0000000..432cc78 --- /dev/null +++ b/testdata/line-stack.js.svg @@ -0,0 +1,178 @@ + + + + + + + + + + + + + + + + + +0 +500 +1,000 +1,500 +2,000 +2,500 +3,000 +Mon +Tue +Wed +Thu +Fri +Sat +Sun + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Email + + +Union Ads + + +Video Ads + + +Direct + + +Search Engine + + + +Stacked Line + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/line-step.js b/testdata/line-step.js new file mode 100644 index 0000000..972e1ac --- /dev/null +++ b/testdata/line-step.js @@ -0,0 +1,56 @@ +/* +title: Step Line +category: line +titleCN: 阶梯折线图 +difficulty: 7 +*/ +option = { + title: { + text: 'Step Line' + }, + tooltip: { + trigger: 'axis' + }, + legend: { + data: ['Step Start', 'Step Middle', 'Step End'] + }, + grid: { + left: '3%', + right: '4%', + bottom: '3%', + containLabel: true + }, + toolbox: { + feature: { + saveAsImage: {} + } + }, + xAxis: { + type: 'category', + data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'] + }, + yAxis: { + type: 'value' + }, + series: [ + { + name: 'Step Start', + type: 'line', + step: 'start', + data: [120, 132, 101, 134, 90, 230, 210] + }, + { + name: 'Step Middle', + type: 'line', + step: 'middle', + data: [220, 282, 201, 234, 290, 430, 410] + }, + { + name: 'Step End', + type: 'line', + step: 'end', + data: [450, 432, 401, 454, 590, 530, 510] + } + ] +}; +export {}; diff --git a/testdata/line-step.js.svg b/testdata/line-step.js.svg new file mode 100644 index 0000000..d1a9cc3 --- /dev/null +++ b/testdata/line-step.js.svg @@ -0,0 +1,125 @@ + + + + + + + + + + + + + + + + + + +0 +100 +200 +300 +400 +500 +600 +Mon +Tue +Wed +Thu +Fri +Sat +Sun + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Step Start + + +Step Middle + + +Step End + + + +Step Line + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/line-style.js b/testdata/line-style.js new file mode 100644 index 0000000..3498c43 --- /dev/null +++ b/testdata/line-style.js @@ -0,0 +1,34 @@ +/* +title: Line Style and Item Style +category: line +titleCN: 自定义折线图样式 +difficulty: 6 +*/ +option = { + xAxis: { + type: 'category', + data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'] + }, + yAxis: { + type: 'value' + }, + series: [ + { + data: [120, 200, 150, 80, 70, 110, 130], + type: 'line', + symbol: 'triangle', + symbolSize: 20, + lineStyle: { + color: '#5470C6', + width: 4, + type: 'dashed' + }, + itemStyle: { + borderWidth: 3, + borderColor: '#EE6666', + color: 'yellow' + } + } + ] +}; +export {}; diff --git a/testdata/line-style.js.svg b/testdata/line-style.js.svg new file mode 100644 index 0000000..e2360ec --- /dev/null +++ b/testdata/line-style.js.svg @@ -0,0 +1,59 @@ + + + + + + + + + + + + + + + + +0 +50 +100 +150 +200 +Mon +Tue +Wed +Thu +Fri +Sat +Sun + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/line-tooltip-touch.js b/testdata/line-tooltip-touch.js new file mode 100644 index 0000000..a3a4efb --- /dev/null +++ b/testdata/line-tooltip-touch.js @@ -0,0 +1,153 @@ +/* +title: Tooltip and DataZoom on Mobile +category: 'line, dataZoom' +titleCN: 移动端上的 dataZoom 和 tooltip +difficulty: 10 +*/ +let base = +new Date(2016, 9, 3); +let oneDay = 24 * 3600 * 1000; +let valueBase = Math.random() * 300; +let valueBase2 = Math.random() * 50; +let data = []; +let data2 = []; +for (var i = 1; i < 10; i++) { + var now = new Date((base += oneDay)); + var dayStr = [now.getFullYear(), now.getMonth() + 1, now.getDate()].join('-'); + valueBase = Math.round((Math.random() - 0.5) * 20 + valueBase); + valueBase <= 0 && (valueBase = Math.random() * 300); + data.push([dayStr, valueBase]); + valueBase2 = Math.round((Math.random() - 0.5) * 20 + valueBase2); + valueBase2 <= 0 && (valueBase2 = Math.random() * 50); + data2.push([dayStr, valueBase2]); +} +option = { + title: { + left: 'center', + text: 'Tootip and dataZoom on Mobile Device' + }, + legend: { + top: 'bottom', + data: ['Intention'] + }, + tooltip: { + triggerOn: 'none', + position: function (pt) { + return [pt[0], 130]; + } + }, + toolbox: { + left: 'center', + itemSize: 25, + top: 55, + feature: { + dataZoom: { + yAxisIndex: 'none' + }, + restore: {} + } + }, + xAxis: { + type: 'time', + axisPointer: { + value: '2016-10-7', + snap: true, + lineStyle: { + color: '#7581BD', + width: 2 + }, + label: { + show: true, + formatter: function (params) { + return echarts.format.formatTime('yyyy-MM-dd', params.value); + }, + backgroundColor: '#7581BD' + }, + handle: { + show: true, + color: '#7581BD' + } + }, + splitLine: { + show: false + } + }, + yAxis: { + type: 'value', + axisTick: { + inside: true + }, + splitLine: { + show: false + }, + axisLabel: { + inside: true, + formatter: '{value}\n' + }, + z: 10 + }, + grid: { + top: 110, + left: 15, + right: 15, + height: 160 + }, + dataZoom: [ + { + type: 'inside', + throttle: 50 + } + ], + series: [ + { + name: 'Fake Data', + type: 'line', + smooth: true, + symbol: 'circle', + symbolSize: 5, + sampling: 'average', + itemStyle: { + color: '#0770FF' + }, + stack: 'a', + areaStyle: { + color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [ + { + offset: 0, + color: 'rgba(58,77,233,0.8)' + }, + { + offset: 1, + color: 'rgba(58,77,233,0.3)' + } + ]) + }, + data: data + }, + { + name: 'Fake Data', + type: 'line', + smooth: true, + stack: 'a', + symbol: 'circle', + symbolSize: 5, + sampling: 'average', + itemStyle: { + color: '#F2597F' + }, + areaStyle: { + color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [ + { + offset: 0, + color: 'rgba(213,72,120,0.8)' + }, + { + offset: 1, + color: 'rgba(213,72,120,0.3)' + } + ]) + }, + data: data2 + } + ] +}; +export {}; diff --git a/testdata/line-tooltip-touch.js.svg b/testdata/line-tooltip-touch.js.svg new file mode 100644 index 0000000..eb15548 --- /dev/null +++ b/testdata/line-tooltip-touch.js.svg @@ -0,0 +1,112 @@ + + + + + + + + + + + +4 +5 +6 +7 +8 +9 +10 +11 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Tootip and dataZoom on Mobile Device +50 +100 +150 +200 +250 +300 + + + +2016-10-07 00:00:00 + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/line-y-category.js b/testdata/line-y-category.js new file mode 100644 index 0000000..13f28ea --- /dev/null +++ b/testdata/line-y-category.js @@ -0,0 +1,53 @@ +"use strict"; +/* +title: Line Y Category +category: line +titleCN: 垂直折线图(Y轴为类目轴) +difficulty: 8 +*/ +option = { + legend: { + data: ['Altitude (km) vs. temperature (°C)'] + }, + tooltip: { + trigger: 'axis', + formatter: 'Temperature :
{b}km : {c}°C' + }, + grid: { + left: '3%', + right: '4%', + bottom: '3%', + containLabel: true + }, + xAxis: { + type: 'value', + axisLabel: { + formatter: '{value} °C' + } + }, + yAxis: { + type: 'category', + axisLine: { onZero: false }, + axisLabel: { + formatter: '{value} km' + }, + boundaryGap: false, + data: ['0', '10', '20', '30', '40', '50', '60', '70', '80'] + }, + series: [ + { + name: 'Altitude (km) vs. temperature (°C)', + type: 'line', + symbolSize: 10, + symbol: 'circle', + smooth: true, + lineStyle: { + width: 3, + shadowColor: 'rgba(0,0,0,0.3)', + shadowBlur: 10, + shadowOffsetY: 8 + }, + data: [15, -50, -56.5, -46.5, -22.1, -2.5, -27.7, -55.7, -76.5] + } + ] +}; diff --git a/testdata/line-y-category.js.svg b/testdata/line-y-category.js.svg new file mode 100644 index 0000000..2efa2fa --- /dev/null +++ b/testdata/line-y-category.js.svg @@ -0,0 +1,73 @@ + + + + + + + + + + + + + + + + + + +0 km +10 km +20 km +30 km +40 km +50 km +60 km +70 km +80 km +-80 °C +-60 °C +-40 °C +-20 °C +0 °C +20 °C + + + + + + + + + + + + + + + +Altitude (km) vs. temperature (°C) + + + + + + + + + + \ No newline at end of file diff --git a/testdata/lines-airline.js b/testdata/lines-airline.js new file mode 100644 index 0000000..83e9884 --- /dev/null +++ b/testdata/lines-airline.js @@ -0,0 +1,58 @@ +/* +title: 65k+ Airline +category: 'map, lines' +titleCN: 65k+ 飞机航线 +*/ +myChart.showLoading(); +$.get(ROOT_PATH + '/data/asset/data/flights.json', function (data) { + myChart.hideLoading(); + function getAirportCoord(idx) { + return [data.airports[idx][3], data.airports[idx][4]]; + } + var routes = data.routes.map(function (airline) { + return [getAirportCoord(airline[1]), getAirportCoord(airline[2])]; + }); + myChart.setOption((option = { + title: { + text: 'World Flights', + left: 'center', + textStyle: { + color: '#eee' + } + }, + backgroundColor: '#003', + tooltip: { + formatter: function (param) { + var route = data.routes[param.dataIndex]; + return (data.airports[route[1]][1] + ' > ' + data.airports[route[2]][1]); + } + }, + geo: { + map: 'world', + left: 0, + right: 0, + silent: true, + roam: true, + itemStyle: { + borderColor: '#003', + color: '#005' + } + }, + series: [ + { + type: 'lines', + coordinateSystem: 'geo', + data: routes, + large: true, + largeThreshold: 100, + lineStyle: { + opacity: 0.05, + width: 0.5, + curveness: 0.3 + }, + blendMode: 'lighter' + } + ] + })); +}); +export {}; diff --git a/testdata/lines-bmap-bus.js b/testdata/lines-bmap-bus.js new file mode 100644 index 0000000..429f5cf --- /dev/null +++ b/testdata/lines-bmap-bus.js @@ -0,0 +1,163 @@ +/* +title: Bus Lines of Beijing - Baidu Map +category: 'map, lines' +tags: bmap +titleCN: 北京公交路线 - 百度地图 +*/ +$.get(ROOT_PATH + '/data/asset/data/lines-bus.json', function (data) { + let busLines = [].concat.apply([], data.map(function (busLine, idx) { + let prevPt = []; + let points = []; + for (let i = 0; i < busLine.length; i += 2) { + let pt = [busLine[i], busLine[i + 1]]; + if (i > 0) { + pt = [prevPt[0] + pt[0], prevPt[1] + pt[1]]; + } + prevPt = pt; + points.push([pt[0] / 1e4, pt[1] / 1e4]); + } + return { + coords: points + }; + })); + myChart.setOption((option = { + bmap: { + center: [116.46, 39.92], + zoom: 10, + roam: true, + mapStyle: { + styleJson: [ + { + featureType: 'water', + elementType: 'all', + stylers: { + color: '#d1d1d1' + } + }, + { + featureType: 'land', + elementType: 'all', + stylers: { + color: '#f3f3f3' + } + }, + { + featureType: 'railway', + elementType: 'all', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'highway', + elementType: 'all', + stylers: { + color: '#fdfdfd' + } + }, + { + featureType: 'highway', + elementType: 'labels', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'arterial', + elementType: 'geometry', + stylers: { + color: '#fefefe' + } + }, + { + featureType: 'arterial', + elementType: 'geometry.fill', + stylers: { + color: '#fefefe' + } + }, + { + featureType: 'poi', + elementType: 'all', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'green', + elementType: 'all', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'subway', + elementType: 'all', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'manmade', + elementType: 'all', + stylers: { + color: '#d1d1d1' + } + }, + { + featureType: 'local', + elementType: 'all', + stylers: { + color: '#d1d1d1' + } + }, + { + featureType: 'arterial', + elementType: 'labels', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'boundary', + elementType: 'all', + stylers: { + color: '#fefefe' + } + }, + { + featureType: 'building', + elementType: 'all', + stylers: { + color: '#d1d1d1' + } + }, + { + featureType: 'label', + elementType: 'labels.text.fill', + stylers: { + color: '#999999' + } + } + ] + } + }, + series: [ + { + type: 'lines', + coordinateSystem: 'bmap', + polyline: true, + data: busLines, + silent: true, + lineStyle: { + color: 'rgb(200, 35, 45)', + opacity: 0.2, + width: 1 + }, + progressiveThreshold: 500, + progressive: 200 + } + ] + })); +}); +export {}; diff --git a/testdata/lines-bmap-effect.js b/testdata/lines-bmap-effect.js new file mode 100644 index 0000000..bec10e2 --- /dev/null +++ b/testdata/lines-bmap-effect.js @@ -0,0 +1,194 @@ +/* +title: Bus Lines of Beijing - Line Effect +category: 'map, lines' +tags: bmap +titleCN: 北京公交路线 - 线特效 +shotDelay: 2000 +*/ +$.get(ROOT_PATH + '/data/asset/data/lines-bus.json', function (data) { + let hStep = 300 / (data.length - 1); + let busLines = [].concat.apply([], data.map(function (busLine, idx) { + let prevPt = []; + let points = []; + for (let i = 0; i < busLine.length; i += 2) { + let pt = [busLine[i], busLine[i + 1]]; + if (i > 0) { + pt = [prevPt[0] + pt[0], prevPt[1] + pt[1]]; + } + prevPt = pt; + points.push([pt[0] / 1e4, pt[1] / 1e4]); + } + return { + coords: points, + lineStyle: { + normal: { + color: echarts.color.modifyHSL('#5A94DF', Math.round(hStep * idx)) + } + } + }; + })); + myChart.setOption((option = { + bmap: { + center: [116.46, 39.92], + zoom: 10, + roam: true, + mapStyle: { + styleJson: [ + { + featureType: 'water', + elementType: 'all', + stylers: { + color: '#031628' + } + }, + { + featureType: 'land', + elementType: 'geometry', + stylers: { + color: '#000102' + } + }, + { + featureType: 'highway', + elementType: 'all', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'arterial', + elementType: 'geometry.fill', + stylers: { + color: '#000000' + } + }, + { + featureType: 'arterial', + elementType: 'geometry.stroke', + stylers: { + color: '#0b3d51' + } + }, + { + featureType: 'local', + elementType: 'geometry', + stylers: { + color: '#000000' + } + }, + { + featureType: 'railway', + elementType: 'geometry.fill', + stylers: { + color: '#000000' + } + }, + { + featureType: 'railway', + elementType: 'geometry.stroke', + stylers: { + color: '#08304b' + } + }, + { + featureType: 'subway', + elementType: 'geometry', + stylers: { + lightness: -70 + } + }, + { + featureType: 'building', + elementType: 'geometry.fill', + stylers: { + color: '#000000' + } + }, + { + featureType: 'all', + elementType: 'labels.text.fill', + stylers: { + color: '#857f7f' + } + }, + { + featureType: 'all', + elementType: 'labels.text.stroke', + stylers: { + color: '#000000' + } + }, + { + featureType: 'building', + elementType: 'geometry', + stylers: { + color: '#022338' + } + }, + { + featureType: 'green', + elementType: 'geometry', + stylers: { + color: '#062032' + } + }, + { + featureType: 'boundary', + elementType: 'all', + stylers: { + color: '#465b6c' + } + }, + { + featureType: 'manmade', + elementType: 'all', + stylers: { + color: '#022338' + } + }, + { + featureType: 'label', + elementType: 'all', + stylers: { + visibility: 'off' + } + } + ] + } + }, + series: [ + { + type: 'lines', + coordinateSystem: 'bmap', + polyline: true, + data: busLines, + silent: true, + lineStyle: { + // color: '#c23531', + // color: 'rgb(200, 35, 45)', + opacity: 0.2, + width: 1 + }, + progressiveThreshold: 500, + progressive: 200 + }, + { + type: 'lines', + coordinateSystem: 'bmap', + polyline: true, + data: busLines, + lineStyle: { + width: 0 + }, + effect: { + constantSpeed: 20, + show: true, + trailLength: 0.1, + symbolSize: 1.5 + }, + zlevel: 1 + } + ] + })); +}); +export {}; diff --git a/testdata/lines-bmap.js b/testdata/lines-bmap.js new file mode 100644 index 0000000..fd3c6cc --- /dev/null +++ b/testdata/lines-bmap.js @@ -0,0 +1,152 @@ +/* +title: A Hiking Trail in Hangzhou - Baidu Map +category: 'map, lines' +tags: bmap +titleCN: 杭州热门步行路线 - 百度地图 +*/ +$.get(ROOT_PATH + '/data/asset/data/hangzhou-tracks.json', function (data) { + const lines = data.map(function (track) { + return { + coords: track.map(function (seg, idx) { + return seg.coord; + }) + }; + }); + myChart.setOption((option = { + bmap: { + center: [120.13066322374, 30.240018034923], + zoom: 14, + roam: true, + mapStyle: { + styleJson: [ + { + featureType: 'water', + elementType: 'all', + stylers: { + color: '#d1d1d1' + } + }, + { + featureType: 'land', + elementType: 'all', + stylers: { + color: '#f3f3f3' + } + }, + { + featureType: 'railway', + elementType: 'all', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'highway', + elementType: 'all', + stylers: { + color: '#fdfdfd' + } + }, + { + featureType: 'highway', + elementType: 'labels', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'arterial', + elementType: 'geometry', + stylers: { + color: '#fefefe' + } + }, + { + featureType: 'arterial', + elementType: 'geometry.fill', + stylers: { + color: '#fefefe' + } + }, + { + featureType: 'poi', + elementType: 'all', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'green', + elementType: 'all', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'subway', + elementType: 'all', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'manmade', + elementType: 'all', + stylers: { + color: '#d1d1d1' + } + }, + { + featureType: 'local', + elementType: 'all', + stylers: { + color: '#d1d1d1' + } + }, + { + featureType: 'arterial', + elementType: 'labels', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'boundary', + elementType: 'all', + stylers: { + color: '#fefefe' + } + }, + { + featureType: 'building', + elementType: 'all', + stylers: { + color: '#d1d1d1' + } + }, + { + featureType: 'label', + elementType: 'labels.text.fill', + stylers: { + color: '#999999' + } + } + ] + } + }, + series: [ + { + type: 'lines', + coordinateSystem: 'bmap', + data: lines, + polyline: true, + lineStyle: { + color: 'purple', + opacity: 0.6, + width: 1 + } + } + ] + })); +}); +export {}; diff --git a/testdata/lines-ny.js b/testdata/lines-ny.js new file mode 100644 index 0000000..0b3c570 --- /dev/null +++ b/testdata/lines-ny.js @@ -0,0 +1,77 @@ +/* +title: Use lines to draw 1 million ny streets. +titleCN: 使用线图绘制近 100 万的纽约街道数据 +category: 'map, lines' +shotDelay: 1000 +*/ +var CHUNK_COUNT = 32; +var dataCount = 0; +function fetchData(idx) { + if (idx >= CHUNK_COUNT) { + return; + } + var dataURL = ROOT_PATH + '/data/asset/data/links-ny/links_ny_' + idx + '.bin'; + var xhr = new XMLHttpRequest(); + xhr.open('GET', dataURL, true); + xhr.responseType = 'arraybuffer'; + xhr.onload = function (e) { + var rawData = new Float32Array(this.response); + var data = new Float64Array(rawData.length - 2); + var offsetX = rawData[0]; + var offsetY = rawData[1]; + var off = 0; + var addedDataCount = 0; + for (var i = 2; i < rawData.length;) { + var count = rawData[i++]; + data[off++] = count; + for (var k = 0; k < count; k++) { + var x = rawData[i++] + offsetX; + var y = rawData[i++] + offsetY; + data[off++] = x; + data[off++] = y; + addedDataCount++; + } + } + myChart.appendData({ + seriesIndex: 0, + data: data + }); + dataCount += addedDataCount; + fetchData(idx + 1); + }; + xhr.send(); +} +option = { + progressive: 20000, + backgroundColor: '#111', + geo: { + center: [-74.04327099998152, 40.86737600240287], + zoom: 360, + map: 'world', + roam: true, + silent: true, + itemStyle: { + color: 'transparent', + borderColor: 'rgba(255,255,255,0.1)', + borderWidth: 1 + } + }, + series: [ + { + type: 'lines', + coordinateSystem: 'geo', + blendMode: 'lighter', + dimensions: ['value'], + data: new Float64Array(), + polyline: true, + large: true, + lineStyle: { + color: 'orange', + width: 0.5, + opacity: 0.3 + } + } + ] +}; +fetchData(0); +export {}; diff --git a/testdata/map-HK.js b/testdata/map-HK.js new file mode 100644 index 0000000..04a5154 --- /dev/null +++ b/testdata/map-HK.js @@ -0,0 +1,94 @@ +"use strict"; +/* +title: Population Density of HongKong (2011) +category: map +titleCN: 香港18区人口密度 (2011) +*/ +myChart.showLoading(); +$.get(ROOT_PATH + '/data/asset/geo/HK.json', function (geoJson) { + myChart.hideLoading(); + echarts.registerMap('HK', geoJson); + myChart.setOption((option = { + title: { + text: 'Population Density of Hong Kong (2011)', + subtext: 'Data from Wikipedia', + sublink: 'http://zh.wikipedia.org/wiki/%E9%A6%99%E6%B8%AF%E8%A1%8C%E6%94%BF%E5%8D%80%E5%8A%83#cite_note-12' + }, + tooltip: { + trigger: 'item', + formatter: '{b}
{c} (p / km2)' + }, + toolbox: { + show: true, + orient: 'vertical', + left: 'right', + top: 'center', + feature: { + dataView: { readOnly: false }, + restore: {}, + saveAsImage: {} + } + }, + visualMap: { + min: 800, + max: 50000, + text: ['High', 'Low'], + realtime: false, + calculable: true, + inRange: { + color: ['lightskyblue', 'yellow', 'orangered'] + } + }, + series: [ + { + name: '香港18区人口密度', + type: 'map', + map: 'HK', + label: { + show: true + }, + data: [ + { name: '中西区', value: 20057.34 }, + { name: '湾仔', value: 15477.48 }, + { name: '东区', value: 31686.1 }, + { name: '南区', value: 6992.6 }, + { name: '油尖旺', value: 44045.49 }, + { name: '深水埗', value: 40689.64 }, + { name: '九龙城', value: 37659.78 }, + { name: '黄大仙', value: 45180.97 }, + { name: '观塘', value: 55204.26 }, + { name: '葵青', value: 21900.9 }, + { name: '荃湾', value: 4918.26 }, + { name: '屯门', value: 5881.84 }, + { name: '元朗', value: 4178.01 }, + { name: '北区', value: 2227.92 }, + { name: '大埔', value: 2180.98 }, + { name: '沙田', value: 9172.94 }, + { name: '西贡', value: 3368 }, + { name: '离岛', value: 806.98 } + ], + // 自定义名称映射 + nameMap: { + 'Central and Western': '中西区', + Eastern: '东区', + Islands: '离岛', + 'Kowloon City': '九龙城', + 'Kwai Tsing': '葵青', + 'Kwun Tong': '观塘', + North: '北区', + 'Sai Kung': '西贡', + 'Sha Tin': '沙田', + 'Sham Shui Po': '深水埗', + Southern: '南区', + 'Tai Po': '大埔', + 'Tsuen Wan': '荃湾', + 'Tuen Mun': '屯门', + 'Wan Chai': '湾仔', + 'Wong Tai Sin': '黄大仙', + 'Yau Tsim Mong': '油尖旺', + 'Yuen Long': '元朗' + } + } + ] + })); +}); diff --git a/testdata/map-bar-morph.js b/testdata/map-bar-morph.js new file mode 100644 index 0000000..f503174 --- /dev/null +++ b/testdata/map-bar-morph.js @@ -0,0 +1,141 @@ +/* +title: Morphing between Map and Bar +category: map, animation +titleCN: 地图柱状图变形动画 +videoStart: 2000 +videoEnd: 6000 +*/ +myChart.showLoading(); +$.get(ROOT_PATH + '/data/asset/geo/USA.json', function (usaJson) { + myChart.hideLoading(); + echarts.registerMap('USA', usaJson, { + Alaska: { + // 把阿拉斯加移到美国主大陆左下方 + left: -131, + top: 25, + width: 15 + }, + Hawaii: { + left: -110, + top: 28, + width: 5 + }, + 'Puerto Rico': { + // 波多黎各 + left: -76, + top: 26, + width: 2 + } + }); + var data = [ + { name: 'Alabama', value: 4822023 }, + { name: 'Alaska', value: 731449 }, + { name: 'Arizona', value: 6553255 }, + { name: 'Arkansas', value: 2949131 }, + { name: 'California', value: 38041430 }, + { name: 'Colorado', value: 5187582 }, + { name: 'Connecticut', value: 3590347 }, + { name: 'Delaware', value: 917092 }, + { name: 'District of Columbia', value: 632323 }, + { name: 'Florida', value: 19317568 }, + { name: 'Georgia', value: 9919945 }, + { name: 'Hawaii', value: 1392313 }, + { name: 'Idaho', value: 1595728 }, + { name: 'Illinois', value: 12875255 }, + { name: 'Indiana', value: 6537334 }, + { name: 'Iowa', value: 3074186 }, + { name: 'Kansas', value: 2885905 }, + { name: 'Kentucky', value: 4380415 }, + { name: 'Louisiana', value: 4601893 }, + { name: 'Maine', value: 1329192 }, + { name: 'Maryland', value: 5884563 }, + { name: 'Massachusetts', value: 6646144 }, + { name: 'Michigan', value: 9883360 }, + { name: 'Minnesota', value: 5379139 }, + { name: 'Mississippi', value: 2984926 }, + { name: 'Missouri', value: 6021988 }, + { name: 'Montana', value: 1005141 }, + { name: 'Nebraska', value: 1855525 }, + { name: 'Nevada', value: 2758931 }, + { name: 'New Hampshire', value: 1320718 }, + { name: 'New Jersey', value: 8864590 }, + { name: 'New Mexico', value: 2085538 }, + { name: 'New York', value: 19570261 }, + { name: 'North Carolina', value: 9752073 }, + { name: 'North Dakota', value: 699628 }, + { name: 'Ohio', value: 11544225 }, + { name: 'Oklahoma', value: 3814820 }, + { name: 'Oregon', value: 3899353 }, + { name: 'Pennsylvania', value: 12763536 }, + { name: 'Rhode Island', value: 1050292 }, + { name: 'South Carolina', value: 4723723 }, + { name: 'South Dakota', value: 833354 }, + { name: 'Tennessee', value: 6456243 }, + { name: 'Texas', value: 26059203 }, + { name: 'Utah', value: 2855287 }, + { name: 'Vermont', value: 626011 }, + { name: 'Virginia', value: 8185867 }, + { name: 'Washington', value: 6897012 }, + { name: 'West Virginia', value: 1855413 }, + { name: 'Wisconsin', value: 5726398 }, + { name: 'Wyoming', value: 576412 }, + { name: 'Puerto Rico', value: 3667084 } + ]; + data.sort(function (a, b) { + return a.value - b.value; + }); + const mapOption = { + visualMap: { + left: 'right', + min: 500000, + max: 38000000, + inRange: { + // prettier-ignore + color: ['#313695', '#4575b4', '#74add1', '#abd9e9', '#e0f3f8', '#ffffbf', '#fee090', '#fdae61', '#f46d43', '#d73027', '#a50026'] + }, + text: ['High', 'Low'], + calculable: true + }, + series: [ + { + id: 'population', + type: 'map', + roam: true, + map: 'USA', + animationDurationUpdate: 1000, + universalTransition: true, + data: data + } + ] + }; + const barOption = { + xAxis: { + type: 'value' + }, + yAxis: { + type: 'category', + axisLabel: { + rotate: 30 + }, + data: data.map(function (item) { + return item.name; + }) + }, + animationDurationUpdate: 1000, + series: { + type: 'bar', + id: 'population', + data: data.map(function (item) { + return item.value; + }), + universalTransition: true + } + }; + let currentOption = mapOption; + myChart.setOption(mapOption); + setInterval(function () { + currentOption = currentOption === mapOption ? barOption : mapOption; + myChart.setOption(currentOption, true); + }, 2000); +}); +export {}; diff --git a/testdata/map-bin.js b/testdata/map-bin.js new file mode 100644 index 0000000..8ba773a --- /dev/null +++ b/testdata/map-bin.js @@ -0,0 +1,234 @@ +"use strict"; +/* +title: Binning on Map +category: map +tags: bmap +titleCN: Binning on Map +*/ +var COLORS = ['#070093', '#1c3fbf', '#1482e5', '#70b4eb', '#b4e0f3', '#ffffff']; +var lngExtent = [39.5, 40.6]; +var latExtent = [115.9, 116.8]; +var cellCount = [50, 50]; +var cellSizeCoord = [ + (lngExtent[1] - lngExtent[0]) / cellCount[0], + (latExtent[1] - latExtent[0]) / cellCount[1] +]; +var gapSize = 0; +// prettier-ignore +var data = [[0, 0, 5], [1, 0, 5], [2, 0, 5], [3, 0, 5], [4, 0, 5], [5, 0, 5], [6, 0, 5], [7, 0, 5], [8, 0, 5], [9, 0, 5], [10, 0, 5], [11, 0, 5], [12, 0, 5], [13, 0, 5], [14, 0, 5], [15, 0, 5], [16, 0, 5], [17, 0, 5], [18, 0, 5], [19, 0, 5], [20, 0, 5], [21, 0, 5], [22, 0, 5], [23, 0, 5], [24, 0, 5], [25, 0, 5], [26, 0, 5], [27, 0, 5], [28, 0, 5], [29, 0, 5], [30, 0, 5], [31, 0, 5], [32, 0, 5], [33, 0, 5], [34, 0, 5], [35, 0, 5], [36, 0, 5], [37, 0, 5], [38, 0, 5], [39, 0, 5], [40, 0, 5], [41, 0, 5], [42, 0, 5], [43, 0, 5], [44, 0, 5], [45, 0, 5], [46, 0, 5], [47, 0, 5], [48, 0, 5], [49, 0, 5], [0, 1, 5], [1, 1, 5], [2, 1, 5], [3, 1, 5], [4, 1, 5], [5, 1, 5], [6, 1, 5], [7, 1, 5], [8, 1, 5], [9, 1, 5], [10, 1, 5], [11, 1, 5], [12, 1, 5], [13, 1, 5], [14, 1, 5], [15, 1, 5], [16, 1, 5], [17, 1, 5], [18, 1, 5], [19, 1, 5], [20, 1, 5], [21, 1, 5], [22, 1, 5], [23, 1, 5], [24, 1, 5], [25, 1, 5], [26, 1, 5], [27, 1, 5], [28, 1, 5], [29, 1, 5], [30, 1, 5], [31, 1, 5], [32, 1, 5], [33, 1, 5], [34, 1, 5], [35, 1, 5], [36, 1, 5], [37, 1, 5], [38, 1, 5], [39, 1, 5], [40, 1, 5], [41, 1, 5], [42, 1, 5], [43, 1, 5], [44, 1, 5], [45, 1, 5], [46, 1, 5], [47, 1, 5], [48, 1, 5], [49, 1, 5], [0, 2, 5], [1, 2, 5], [2, 2, 5], [3, 2, 5], [4, 2, 5], [5, 2, 5], [6, 2, 5], [7, 2, 5], [8, 2, 5], [9, 2, 5], [10, 2, 5], [11, 2, 5], [12, 2, 5], [13, 2, 5], [14, 2, 5], [15, 2, 5], [16, 2, 5], [17, 2, 5], [18, 2, 5], [19, 2, 5], [20, 2, 5], [21, 2, 5], [22, 2, 5], [23, 2, 5], [24, 2, 4], [25, 2, 5], [26, 2, 5], [27, 2, 5], [28, 2, 5], [29, 2, 5], [30, 2, 5], [31, 2, 5], [32, 2, 5], [33, 2, 5], [34, 2, 4], [35, 2, 5], [36, 2, 5], [37, 2, 5], [38, 2, 5], [39, 2, 5], [40, 2, 5], [41, 2, 5], [42, 2, 5], [43, 2, 5], [44, 2, 5], [45, 2, 5], [46, 2, 5], [47, 2, 5], [48, 2, 5], [49, 2, 5], [0, 3, 5], [1, 3, 5], [2, 3, 5], [3, 3, 5], [4, 3, 5], [5, 3, 5], [6, 3, 5], [7, 3, 5], [8, 3, 5], [9, 3, 5], [10, 3, 5], [11, 3, 5], [12, 3, 5], [13, 3, 5], [14, 3, 5], [15, 3, 5], [16, 3, 5], [17, 3, 5], [18, 3, 5], [19, 3, 5], [20, 3, 5], [21, 3, 5], [22, 3, 5], [23, 3, 5], [24, 3, 5], [25, 3, 5], [26, 3, 5], [27, 3, 5], [28, 3, 5], [29, 3, 5], [30, 3, 5], [31, 3, 5], [32, 3, 5], [33, 3, 4], [34, 3, 5], [35, 3, 5], [36, 3, 5], [37, 3, 5], [38, 3, 5], [39, 3, 5], [40, 3, 5], [41, 3, 5], [42, 3, 5], [43, 3, 5], [44, 3, 5], [45, 3, 5], [46, 3, 5], [47, 3, 5], [48, 3, 5], [49, 3, 5], [0, 4, 5], [1, 4, 5], [2, 4, 5], [3, 4, 5], [4, 4, 5], [5, 4, 5], [6, 4, 5], [7, 4, 5], [8, 4, 5], [9, 4, 5], [10, 4, 5], [11, 4, 5], [12, 4, 5], [13, 4, 5], [14, 4, 5], [15, 4, 5], [16, 4, 5], [17, 4, 4], [18, 4, 5], [19, 4, 5], [20, 4, 5], [21, 4, 5], [22, 4, 5], [23, 4, 5], [24, 4, 5], [25, 4, 5], [26, 4, 5], [27, 4, 5], [28, 4, 5], [29, 4, 5], [30, 4, 5], [31, 4, 5], [32, 4, 5], [33, 4, 4], [34, 4, 5], [35, 4, 5], [36, 4, 5], [37, 4, 5], [38, 4, 5], [39, 4, 5], [40, 4, 5], [41, 4, 5], [42, 4, 5], [43, 4, 5], [44, 4, 5], [45, 4, 5], [46, 4, 5], [47, 4, 5], [48, 4, 5], [49, 4, 5], [0, 5, 5], [1, 5, 5], [2, 5, 5], [3, 5, 5], [4, 5, 5], [5, 5, 5], [6, 5, 5], [7, 5, 5], [8, 5, 5], [9, 5, 5], [10, 5, 5], [11, 5, 5], [12, 5, 5], [13, 5, 5], [14, 5, 5], [15, 5, 5], [16, 5, 5], [17, 5, 5], [18, 5, 5], [19, 5, 5], [20, 5, 5], [21, 5, 5], [22, 5, 5], [23, 5, 5], [24, 5, 5], [25, 5, 5], [26, 5, 5], [27, 5, 5], [28, 5, 5], [29, 5, 5], [30, 5, 5], [31, 5, 5], [32, 5, 5], [33, 5, 5], [34, 5, 5], [35, 5, 5], [36, 5, 5], [37, 5, 5], [38, 5, 5], [39, 5, 5], [40, 5, 5], [41, 5, 5], [42, 5, 5], [43, 5, 5], [44, 5, 5], [45, 5, 5], [46, 5, 5], [47, 5, 5], [48, 5, 5], [49, 5, 5], [0, 6, 5], [1, 6, 5], [2, 6, 5], [3, 6, 5], [4, 6, 5], [5, 6, 5], [6, 6, 5], [7, 6, 5], [8, 6, 5], [9, 6, 5], [10, 6, 5], [11, 6, 5], [12, 6, 5], [13, 6, 5], [14, 6, 5], [15, 6, 5], [16, 6, 5], [17, 6, 5], [18, 6, 5], [19, 6, 5], [20, 6, 5], [21, 6, 5], [22, 6, 5], [23, 6, 5], [24, 6, 5], [25, 6, 5], [26, 6, 4], [27, 6, 5], [28, 6, 5], [29, 6, 4], [30, 6, 5], [31, 6, 5], [32, 6, 5], [33, 6, 5], [34, 6, 5], [35, 6, 5], [36, 6, 5], [37, 6, 5], [38, 6, 5], [39, 6, 5], [40, 6, 5], [41, 6, 5], [42, 6, 5], [43, 6, 5], [44, 6, 5], [45, 6, 5], [46, 6, 5], [47, 6, 5], [48, 6, 5], [49, 6, 5], [0, 7, 5], [1, 7, 5], [2, 7, 5], [3, 7, 5], [4, 7, 5], [5, 7, 5], [6, 7, 5], [7, 7, 5], [8, 7, 5], [9, 7, 5], [10, 7, 5], [11, 7, 5], [12, 7, 5], [13, 7, 5], [14, 7, 5], [15, 7, 5], [16, 7, 5], [17, 7, 4], [18, 7, 5], [19, 7, 4], [20, 7, 4], [21, 7, 5], [22, 7, 5], [23, 7, 5], [24, 7, 5], [25, 7, 5], [26, 7, 5], [27, 7, 5], [28, 7, 5], [29, 7, 5], [30, 7, 5], [31, 7, 5], [32, 7, 5], [33, 7, 5], [34, 7, 5], [35, 7, 5], [36, 7, 5], [37, 7, 5], [38, 7, 5], [39, 7, 5], [40, 7, 5], [41, 7, 5], [42, 7, 5], [43, 7, 5], [44, 7, 5], [45, 7, 5], [46, 7, 5], [47, 7, 5], [48, 7, 5], [49, 7, 5], [0, 8, 5], [1, 8, 5], [2, 8, 5], [3, 8, 5], [4, 8, 5], [5, 8, 4], [6, 8, 5], [7, 8, 4], [8, 8, 5], [9, 8, 5], [10, 8, 5], [11, 8, 5], [12, 8, 5], [13, 8, 5], [14, 8, 5], [15, 8, 4], [16, 8, 5], [17, 8, 5], [18, 8, 5], [19, 8, 5], [20, 8, 5], [21, 8, 5], [22, 8, 4], [23, 8, 4], [24, 8, 4], [25, 8, 5], [26, 8, 5], [27, 8, 5], [28, 8, 4], [29, 8, 4], [30, 8, 5], [31, 8, 5], [32, 8, 4], [33, 8, 4], [34, 8, 5], [35, 8, 5], [36, 8, 5], [37, 8, 5], [38, 8, 5], [39, 8, 5], [40, 8, 5], [41, 8, 5], [42, 8, 5], [43, 8, 5], [44, 8, 5], [45, 8, 5], [46, 8, 5], [47, 8, 5], [48, 8, 5], [49, 8, 5], [0, 9, 5], [1, 9, 5], [2, 9, 5], [3, 9, 5], [4, 9, 5], [5, 9, 5], [6, 9, 5], [7, 9, 5], [8, 9, 4], [9, 9, 5], [10, 9, 5], [11, 9, 4], [12, 9, 5], [13, 9, 4], [14, 9, 5], [15, 9, 4], [16, 9, 4], [17, 9, 5], [18, 9, 5], [19, 9, 5], [20, 9, 5], [21, 9, 5], [22, 9, 5], [23, 9, 5], [24, 9, 4], [25, 9, 5], [26, 9, 4], [27, 9, 4], [28, 9, 4], [29, 9, 5], [30, 9, 5], [31, 9, 5], [32, 9, 5], [33, 9, 5], [34, 9, 4], [35, 9, 5], [36, 9, 5], [37, 9, 5], [38, 9, 5], [39, 9, 5], [40, 9, 5], [41, 9, 5], [42, 9, 5], [43, 9, 5], [44, 9, 5], [45, 9, 5], [46, 9, 5], [47, 9, 5], [48, 9, 5], [49, 9, 5], [0, 10, 5], [1, 10, 5], [2, 10, 5], [3, 10, 5], [4, 10, 5], [5, 10, 5], [6, 10, 5], [7, 10, 5], [8, 10, 5], [9, 10, 5], [10, 10, 5], [11, 10, 5], [12, 10, 5], [13, 10, 5], [14, 10, 5], [15, 10, 4], [16, 10, 5], [17, 10, 5], [18, 10, 5], [19, 10, 4], [20, 10, 5], [21, 10, 4], [22, 10, 4], [23, 10, 4], [24, 10, 4], [25, 10, 4], [26, 10, 4], [27, 10, 5], [28, 10, 5], [29, 10, 4], [30, 10, 5], [31, 10, 4], [32, 10, 5], [33, 10, 5], [34, 10, 5], [35, 10, 4], [36, 10, 5], [37, 10, 5], [38, 10, 5], [39, 10, 5], [40, 10, 5], [41, 10, 5], [42, 10, 5], [43, 10, 5], [44, 10, 5], [45, 10, 5], [46, 10, 5], [47, 10, 5], [48, 10, 5], [49, 10, 5], [0, 11, 5], [1, 11, 5], [2, 11, 5], [3, 11, 5], [4, 11, 5], [5, 11, 5], [6, 11, 5], [7, 11, 5], [8, 11, 5], [9, 11, 5], [10, 11, 4], [11, 11, 4], [12, 11, 4], [13, 11, 2], [14, 11, 2], [15, 11, 2], [16, 11, 5], [17, 11, 4], [18, 11, 4], [19, 11, 1], [20, 11, 1], [21, 11, 4], [22, 11, 4], [23, 11, 5], [24, 11, 4], [25, 11, 4], [26, 11, 4], [27, 11, 4], [28, 11, 4], [29, 11, 4], [30, 11, 4], [31, 11, 4], [32, 11, 5], [33, 11, 5], [34, 11, 5], [35, 11, 4], [36, 11, 4], [37, 11, 4], [38, 11, 5], [39, 11, 5], [40, 11, 5], [41, 11, 5], [42, 11, 5], [43, 11, 5], [44, 11, 5], [45, 11, 5], [46, 11, 5], [47, 11, 5], [48, 11, 5], [49, 11, 5], [0, 12, 5], [1, 12, 5], [2, 12, 5], [3, 12, 5], [4, 12, 5], [5, 12, 5], [6, 12, 5], [7, 12, 5], [8, 12, 4], [9, 12, 4], [10, 12, 4], [11, 12, 2], [12, 12, 2], [13, 12, 2], [14, 12, 2], [15, 12, 5], [16, 12, 4], [17, 12, 4], [18, 12, 4], [19, 12, 4], [20, 12, 1], [21, 12, 4], [22, 12, 4], [23, 12, 4], [24, 12, 5], [25, 12, 4], [26, 12, 4], [27, 12, 4], [28, 12, 4], [29, 12, 4], [30, 12, 4], [31, 12, 4], [32, 12, 4], [33, 12, 4], [34, 12, 4], [35, 12, 4], [36, 12, 4], [37, 12, 4], [38, 12, 5], [39, 12, 5], [40, 12, 5], [41, 12, 5], [42, 12, 5], [43, 12, 5], [44, 12, 5], [45, 12, 5], [46, 12, 5], [47, 12, 5], [48, 12, 5], [49, 12, 5], [0, 13, 5], [1, 13, 5], [2, 13, 5], [3, 13, 5], [4, 13, 5], [5, 13, 5], [6, 13, 5], [7, 13, 5], [8, 13, 4], [9, 13, 4], [10, 13, 4], [11, 13, 4], [12, 13, 1], [13, 13, 4], [14, 13, 2], [15, 13, 4], [16, 13, 4], [17, 13, 4], [18, 13, 4], [19, 13, 4], [20, 13, 4], [21, 13, 4], [22, 13, 4], [23, 13, 4], [24, 13, 4], [25, 13, 4], [26, 13, 4], [27, 13, 4], [28, 13, 5], [29, 13, 4], [30, 13, 4], [31, 13, 4], [32, 13, 5], [33, 13, 4], [34, 13, 4], [35, 13, 5], [36, 13, 4], [37, 13, 4], [38, 13, 5], [39, 13, 4], [40, 13, 4], [41, 13, 5], [42, 13, 5], [43, 13, 4], [44, 13, 5], [45, 13, 5], [46, 13, 5], [47, 13, 5], [48, 13, 5], [49, 13, 5], [0, 14, 5], [1, 14, 5], [2, 14, 5], [3, 14, 5], [4, 14, 5], [5, 14, 5], [6, 14, 5], [7, 14, 5], [8, 14, 4], [9, 14, 4], [10, 14, 4], [11, 14, 2], [12, 14, 2], [13, 14, 4], [14, 14, 1], [15, 14, 4], [16, 14, 4], [17, 14, 4], [18, 14, 4], [19, 14, 4], [20, 14, 4], [21, 14, 4], [22, 14, 2], [23, 14, 4], [24, 14, 2], [25, 14, 3], [26, 14, 3], [27, 14, 3], [28, 14, 4], [29, 14, 3], [30, 14, 4], [31, 14, 5], [32, 14, 3], [33, 14, 3], [34, 14, 4], [35, 14, 4], [36, 14, 4], [37, 14, 4], [38, 14, 5], [39, 14, 5], [40, 14, 5], [41, 14, 5], [42, 14, 5], [43, 14, 5], [44, 14, 5], [45, 14, 5], [46, 14, 5], [47, 14, 5], [48, 14, 5], [49, 14, 5], [0, 15, 5], [1, 15, 5], [2, 15, 5], [3, 15, 5], [4, 15, 5], [5, 15, 5], [6, 15, 5], [7, 15, 5], [8, 15, 5], [9, 15, 4], [10, 15, 4], [11, 15, 4], [12, 15, 4], [13, 15, 1], [14, 15, 1], [15, 15, 1], [16, 15, 4], [17, 15, 2], [18, 15, 2], [19, 15, 4], [20, 15, 3], [21, 15, 3], [22, 15, 2], [23, 15, 2], [24, 15, 1], [25, 15, 1], [26, 15, 3], [27, 15, 3], [28, 15, 3], [29, 15, 3], [30, 15, 5], [31, 15, 5], [32, 15, 4], [33, 15, 4], [34, 15, 4], [35, 15, 4], [36, 15, 4], [37, 15, 5], [38, 15, 5], [39, 15, 2], [40, 15, 5], [41, 15, 5], [42, 15, 5], [43, 15, 5], [44, 15, 5], [45, 15, 5], [46, 15, 5], [47, 15, 5], [48, 15, 5], [49, 15, 5], [0, 16, 5], [1, 16, 5], [2, 16, 5], [3, 16, 5], [4, 16, 5], [5, 16, 5], [6, 16, 5], [7, 16, 5], [8, 16, 5], [9, 16, 4], [10, 16, 3], [11, 16, 4], [12, 16, 4], [13, 16, 1], [14, 16, 4], [15, 16, 4], [16, 16, 4], [17, 16, 4], [18, 16, 3], [19, 16, 2], [20, 16, 4], [21, 16, 2], [22, 16, 2], [23, 16, 1], [24, 16, 0], [25, 16, 0], [26, 16, 0], [27, 16, 0], [28, 16, 3], [29, 16, 4], [30, 16, 4], [31, 16, 4], [32, 16, 4], [33, 16, 4], [34, 16, 3], [35, 16, 4], [36, 16, 4], [37, 16, 4], [38, 16, 5], [39, 16, 5], [40, 16, 5], [41, 16, 5], [42, 16, 5], [43, 16, 5], [44, 16, 4], [45, 16, 5], [46, 16, 5], [47, 16, 5], [48, 16, 5], [49, 16, 5], [0, 17, 5], [1, 17, 5], [2, 17, 5], [3, 17, 5], [4, 17, 4], [5, 17, 5], [6, 17, 4], [7, 17, 5], [8, 17, 4], [9, 17, 4], [10, 17, 3], [11, 17, 4], [12, 17, 4], [13, 17, 4], [14, 17, 4], [15, 17, 4], [16, 17, 4], [17, 17, 4], [18, 17, 3], [19, 17, 2], [20, 17, 3], [21, 17, 2], [22, 17, 1], [23, 17, 1], [24, 17, 1], [25, 17, 0], [26, 17, 1], [27, 17, 1], [28, 17, 3], [29, 17, 4], [30, 17, 4], [31, 17, 3], [32, 17, 3], [33, 17, 4], [34, 17, 4], [35, 17, 4], [36, 17, 4], [37, 17, 4], [38, 17, 4], [39, 17, 4], [40, 17, 5], [41, 17, 4], [42, 17, 5], [43, 17, 5], [44, 17, 5], [45, 17, 5], [46, 17, 5], [47, 17, 5], [48, 17, 5], [49, 17, 5], [0, 18, 5], [1, 18, 5], [2, 18, 5], [3, 18, 5], [4, 18, 5], [5, 18, 5], [6, 18, 5], [7, 18, 4], [8, 18, 4], [9, 18, 3], [10, 18, 3], [11, 18, 4], [12, 18, 4], [13, 18, 4], [14, 18, 4], [15, 18, 2], [16, 18, 4], [17, 18, 2], [18, 18, 3], [19, 18, 2], [20, 18, 4], [21, 18, 1], [22, 18, 0], [23, 18, 0], [24, 18, 0], [25, 18, 3], [26, 18, 1], [27, 18, 4], [28, 18, 1], [29, 18, 1], [30, 18, 1], [31, 18, 4], [32, 18, 3], [33, 18, 4], [34, 18, 3], [35, 18, 3], [36, 18, 4], [37, 18, 4], [38, 18, 4], [39, 18, 5], [40, 18, 4], [41, 18, 4], [42, 18, 5], [43, 18, 4], [44, 18, 4], [45, 18, 5], [46, 18, 5], [47, 18, 5], [48, 18, 5], [49, 18, 5], [0, 19, 5], [1, 19, 5], [2, 19, 5], [3, 19, 5], [4, 19, 5], [5, 19, 5], [6, 19, 4], [7, 19, 4], [8, 19, 3], [9, 19, 4], [10, 19, 3], [11, 19, 4], [12, 19, 3], [13, 19, 4], [14, 19, 2], [15, 19, 2], [16, 19, 1], [17, 19, 3], [18, 19, 1], [19, 19, 0], [20, 19, 0], [21, 19, 1], [22, 19, 0], [23, 19, 1], [24, 19, 0], [25, 19, 0], [26, 19, 1], [27, 19, 0], [28, 19, 0], [29, 19, 1], [30, 19, 4], [31, 19, 4], [32, 19, 3], [33, 19, 3], [34, 19, 4], [35, 19, 4], [36, 19, 4], [37, 19, 4], [38, 19, 4], [39, 19, 4], [40, 19, 4], [41, 19, 5], [42, 19, 5], [43, 19, 4], [44, 19, 5], [45, 19, 5], [46, 19, 5], [47, 19, 5], [48, 19, 5], [49, 19, 5], [0, 20, 5], [1, 20, 5], [2, 20, 5], [3, 20, 5], [4, 20, 5], [5, 20, 4], [6, 20, 4], [7, 20, 4], [8, 20, 4], [9, 20, 4], [10, 20, 3], [11, 20, 4], [12, 20, 3], [13, 20, 4], [14, 20, 2], [15, 20, 1], [16, 20, 1], [17, 20, 1], [18, 20, 1], [19, 20, 0], [20, 20, 0], [21, 20, 1], [22, 20, 1], [23, 20, 1], [24, 20, 1], [25, 20, 1], [26, 20, 0], [27, 20, 0], [28, 20, 0], [29, 20, 1], [30, 20, 1], [31, 20, 0], [32, 20, 4], [33, 20, 3], [34, 20, 4], [35, 20, 2], [36, 20, 4], [37, 20, 4], [38, 20, 4], [39, 20, 4], [40, 20, 4], [41, 20, 5], [42, 20, 4], [43, 20, 5], [44, 20, 5], [45, 20, 5], [46, 20, 5], [47, 20, 5], [48, 20, 5], [49, 20, 5], [0, 21, 5], [1, 21, 5], [2, 21, 5], [3, 21, 5], [4, 21, 5], [5, 21, 4], [6, 21, 5], [7, 21, 4], [8, 21, 3], [9, 21, 4], [10, 21, 4], [11, 21, 4], [12, 21, 4], [13, 21, 3], [14, 21, 2], [15, 21, 3], [16, 21, 4], [17, 21, 1], [18, 21, 1], [19, 21, 0], [20, 21, 0], [21, 21, 0], [22, 21, 1], [23, 21, 0], [24, 21, 0], [25, 21, 1], [26, 21, 2], [27, 21, 0], [28, 21, 1], [29, 21, 1], [30, 21, 1], [31, 21, 4], [32, 21, 4], [33, 21, 4], [34, 21, 3], [35, 21, 2], [36, 21, 4], [37, 21, 1], [38, 21, 4], [39, 21, 4], [40, 21, 4], [41, 21, 4], [42, 21, 5], [43, 21, 4], [44, 21, 5], [45, 21, 5], [46, 21, 5], [47, 21, 5], [48, 21, 5], [49, 21, 5], [0, 22, 5], [1, 22, 5], [2, 22, 5], [3, 22, 5], [4, 22, 5], [5, 22, 4], [6, 22, 4], [7, 22, 4], [8, 22, 4], [9, 22, 3], [10, 22, 4], [11, 22, 3], [12, 22, 2], [13, 22, 2], [14, 22, 2], [15, 22, 0], [16, 22, 0], [17, 22, 0], [18, 22, 1], [19, 22, 0], [20, 22, 0], [21, 22, 0], [22, 22, 0], [23, 22, 0], [24, 22, 0], [25, 22, 0], [26, 22, 0], [27, 22, 0], [28, 22, 1], [29, 22, 1], [30, 22, 1], [31, 22, 0], [32, 22, 1], [33, 22, 3], [34, 22, 4], [35, 22, 2], [36, 22, 4], [37, 22, 1], [38, 22, 4], [39, 22, 2], [40, 22, 4], [41, 22, 1], [42, 22, 5], [43, 22, 1], [44, 22, 5], [45, 22, 5], [46, 22, 5], [47, 22, 5], [48, 22, 5], [49, 22, 5], [0, 23, 5], [1, 23, 5], [2, 23, 5], [3, 23, 5], [4, 23, 5], [5, 23, 5], [6, 23, 4], [7, 23, 4], [8, 23, 4], [9, 23, 3], [10, 23, 3], [11, 23, 1], [12, 23, 1], [13, 23, 1], [14, 23, 2], [15, 23, 0], [16, 23, 0], [17, 23, 0], [18, 23, 0], [19, 23, 0], [20, 23, 0], [21, 23, 0], [22, 23, 0], [23, 23, 1], [24, 23, 0], [25, 23, 1], [26, 23, 1], [27, 23, 2], [28, 23, 0], [29, 23, 0], [30, 23, 0], [31, 23, 0], [32, 23, 4], [33, 23, 1], [34, 23, 1], [35, 23, 2], [36, 23, 2], [37, 23, 2], [38, 23, 0], [39, 23, 2], [40, 23, 0], [41, 23, 1], [42, 23, 1], [43, 23, 1], [44, 23, 5], [45, 23, 5], [46, 23, 5], [47, 23, 5], [48, 23, 5], [49, 23, 5], [0, 24, 5], [1, 24, 5], [2, 24, 5], [3, 24, 5], [4, 24, 5], [5, 24, 5], [6, 24, 5], [7, 24, 4], [8, 24, 4], [9, 24, 4], [10, 24, 4], [11, 24, 4], [12, 24, 1], [13, 24, 1], [14, 24, 1], [15, 24, 1], [16, 24, 1], [17, 24, 0], [18, 24, 1], [19, 24, 1], [20, 24, 0], [21, 24, 0], [22, 24, 1], [23, 24, 2], [24, 24, 0], [25, 24, 0], [26, 24, 0], [27, 24, 0], [28, 24, 0], [29, 24, 0], [30, 24, 1], [31, 24, 1], [32, 24, 1], [33, 24, 4], [34, 24, 4], [35, 24, 1], [36, 24, 1], [37, 24, 2], [38, 24, 2], [39, 24, 2], [40, 24, 2], [41, 24, 4], [42, 24, 0], [43, 24, 5], [44, 24, 5], [45, 24, 4], [46, 24, 5], [47, 24, 5], [48, 24, 5], [49, 24, 5], [0, 25, 5], [1, 25, 5], [2, 25, 5], [3, 25, 5], [4, 25, 5], [5, 25, 5], [6, 25, 5], [7, 25, 4], [8, 25, 4], [9, 25, 4], [10, 25, 4], [11, 25, 4], [12, 25, 1], [13, 25, 1], [14, 25, 3], [15, 25, 1], [16, 25, 0], [17, 25, 0], [18, 25, 0], [19, 25, 0], [20, 25, 0], [21, 25, 0], [22, 25, 0], [23, 25, 1], [24, 25, 1], [25, 25, 0], [26, 25, 0], [27, 25, 0], [28, 25, 1], [29, 25, 0], [30, 25, 1], [31, 25, 1], [32, 25, 1], [33, 25, 3], [34, 25, 4], [35, 25, 4], [36, 25, 4], [37, 25, 2], [38, 25, 2], [39, 25, 4], [40, 25, 4], [41, 25, 4], [42, 25, 5], [43, 25, 5], [44, 25, 5], [45, 25, 5], [46, 25, 5], [47, 25, 5], [48, 25, 5], [49, 25, 5], [0, 26, 5], [1, 26, 5], [2, 26, 5], [3, 26, 5], [4, 26, 5], [5, 26, 5], [6, 26, 5], [7, 26, 5], [8, 26, 4], [9, 26, 4], [10, 26, 1], [11, 26, 1], [12, 26, 1], [13, 26, 1], [14, 26, 1], [15, 26, 0], [16, 26, 0], [17, 26, 2], [18, 26, 1], [19, 26, 0], [20, 26, 0], [21, 26, 1], [22, 26, 0], [23, 26, 0], [24, 26, 1], [25, 26, 0], [26, 26, 0], [27, 26, 0], [28, 26, 0], [29, 26, 1], [30, 26, 1], [31, 26, 0], [32, 26, 4], [33, 26, 2], [34, 26, 2], [35, 26, 2], [36, 26, 2], [37, 26, 4], [38, 26, 2], [39, 26, 4], [40, 26, 1], [41, 26, 4], [42, 26, 4], [43, 26, 4], [44, 26, 4], [45, 26, 5], [46, 26, 5], [47, 26, 5], [48, 26, 5], [49, 26, 5], [0, 27, 5], [1, 27, 5], [2, 27, 5], [3, 27, 5], [4, 27, 5], [5, 27, 5], [6, 27, 5], [7, 27, 5], [8, 27, 5], [9, 27, 2], [10, 27, 4], [11, 27, 4], [12, 27, 4], [13, 27, 1], [14, 27, 1], [15, 27, 0], [16, 27, 1], [17, 27, 0], [18, 27, 0], [19, 27, 0], [20, 27, 1], [21, 27, 1], [22, 27, 0], [23, 27, 1], [24, 27, 0], [25, 27, 0], [26, 27, 0], [27, 27, 0], [28, 27, 0], [29, 27, 1], [30, 27, 1], [31, 27, 0], [32, 27, 1], [33, 27, 1], [34, 27, 3], [35, 27, 4], [36, 27, 4], [37, 27, 4], [38, 27, 4], [39, 27, 4], [40, 27, 2], [41, 27, 5], [42, 27, 5], [43, 27, 5], [44, 27, 5], [45, 27, 4], [46, 27, 5], [47, 27, 5], [48, 27, 5], [49, 27, 5], [0, 28, 5], [1, 28, 5], [2, 28, 5], [3, 28, 5], [4, 28, 5], [5, 28, 5], [6, 28, 5], [7, 28, 5], [8, 28, 2], [9, 28, 4], [10, 28, 2], [11, 28, 2], [12, 28, 4], [13, 28, 2], [14, 28, 3], [15, 28, 0], [16, 28, 1], [17, 28, 0], [18, 28, 0], [19, 28, 0], [20, 28, 1], [21, 28, 0], [22, 28, 0], [23, 28, 0], [24, 28, 0], [25, 28, 0], [26, 28, 0], [27, 28, 0], [28, 28, 0], [29, 28, 0], [30, 28, 1], [31, 28, 0], [32, 28, 0], [33, 28, 1], [34, 28, 1], [35, 28, 4], [36, 28, 4], [37, 28, 4], [38, 28, 4], [39, 28, 4], [40, 28, 4], [41, 28, 5], [42, 28, 5], [43, 28, 5], [44, 28, 5], [45, 28, 5], [46, 28, 5], [47, 28, 5], [48, 28, 5], [49, 28, 5], [0, 29, 5], [1, 29, 5], [2, 29, 5], [3, 29, 5], [4, 29, 5], [5, 29, 5], [6, 29, 5], [7, 29, 5], [8, 29, 5], [9, 29, 5], [10, 29, 4], [11, 29, 4], [12, 29, 4], [13, 29, 2], [14, 29, 2], [15, 29, 0], [16, 29, 0], [17, 29, 0], [18, 29, 0], [19, 29, 1], [20, 29, 0], [21, 29, 0], [22, 29, 0], [23, 29, 0], [24, 29, 1], [25, 29, 2], [26, 29, 0], [27, 29, 0], [28, 29, 0], [29, 29, 1], [30, 29, 0], [31, 29, 0], [32, 29, 0], [33, 29, 3], [34, 29, 4], [35, 29, 4], [36, 29, 3], [37, 29, 3], [38, 29, 3], [39, 29, 4], [40, 29, 4], [41, 29, 5], [42, 29, 5], [43, 29, 5], [44, 29, 4], [45, 29, 5], [46, 29, 5], [47, 29, 5], [48, 29, 5], [49, 29, 5], [0, 30, 5], [1, 30, 5], [2, 30, 5], [3, 30, 5], [4, 30, 5], [5, 30, 4], [6, 30, 4], [7, 30, 4], [8, 30, 5], [9, 30, 4], [10, 30, 3], [11, 30, 4], [12, 30, 4], [13, 30, 4], [14, 30, 4], [15, 30, 1], [16, 30, 1], [17, 30, 1], [18, 30, 0], [19, 30, 1], [20, 30, 0], [21, 30, 1], [22, 30, 0], [23, 30, 0], [24, 30, 1], [25, 30, 0], [26, 30, 0], [27, 30, 0], [28, 30, 0], [29, 30, 1], [30, 30, 1], [31, 30, 4], [32, 30, 4], [33, 30, 4], [34, 30, 4], [35, 30, 4], [36, 30, 3], [37, 30, 3], [38, 30, 3], [39, 30, 5], [40, 30, 5], [41, 30, 4], [42, 30, 5], [43, 30, 5], [44, 30, 5], [45, 30, 5], [46, 30, 5], [47, 30, 5], [48, 30, 5], [49, 30, 5], [0, 31, 5], [1, 31, 5], [2, 31, 5], [3, 31, 5], [4, 31, 5], [5, 31, 5], [6, 31, 5], [7, 31, 5], [8, 31, 5], [9, 31, 4], [10, 31, 3], [11, 31, 4], [12, 31, 2], [13, 31, 3], [14, 31, 3], [15, 31, 3], [16, 31, 0], [17, 31, 0], [18, 31, 0], [19, 31, 1], [20, 31, 2], [21, 31, 2], [22, 31, 1], [23, 31, 0], [24, 31, 0], [25, 31, 3], [26, 31, 1], [27, 31, 1], [28, 31, 4], [29, 31, 2], [30, 31, 1], [31, 31, 4], [32, 31, 3], [33, 31, 2], [34, 31, 2], [35, 31, 4], [36, 31, 3], [37, 31, 4], [38, 31, 4], [39, 31, 4], [40, 31, 4], [41, 31, 5], [42, 31, 5], [43, 31, 5], [44, 31, 5], [45, 31, 5], [46, 31, 5], [47, 31, 5], [48, 31, 5], [49, 31, 5], [0, 32, 5], [1, 32, 5], [2, 32, 5], [3, 32, 5], [4, 32, 5], [5, 32, 5], [6, 32, 5], [7, 32, 5], [8, 32, 5], [9, 32, 4], [10, 32, 3], [11, 32, 2], [12, 32, 2], [13, 32, 2], [14, 32, 1], [15, 32, 3], [16, 32, 4], [17, 32, 3], [18, 32, 0], [19, 32, 2], [20, 32, 2], [21, 32, 1], [22, 32, 0], [23, 32, 1], [24, 32, 0], [25, 32, 0], [26, 32, 0], [27, 32, 0], [28, 32, 1], [29, 32, 1], [30, 32, 4], [31, 32, 3], [32, 32, 3], [33, 32, 4], [34, 32, 3], [35, 32, 4], [36, 32, 3], [37, 32, 3], [38, 32, 4], [39, 32, 5], [40, 32, 4], [41, 32, 5], [42, 32, 5], [43, 32, 5], [44, 32, 5], [45, 32, 5], [46, 32, 5], [47, 32, 5], [48, 32, 5], [49, 32, 5], [0, 33, 5], [1, 33, 5], [2, 33, 5], [3, 33, 5], [4, 33, 5], [5, 33, 4], [6, 33, 4], [7, 33, 5], [8, 33, 4], [9, 33, 5], [10, 33, 2], [11, 33, 4], [12, 33, 2], [13, 33, 4], [14, 33, 4], [15, 33, 4], [16, 33, 2], [17, 33, 3], [18, 33, 2], [19, 33, 0], [20, 33, 4], [21, 33, 0], [22, 33, 1], [23, 33, 1], [24, 33, 1], [25, 33, 0], [26, 33, 1], [27, 33, 0], [28, 33, 4], [29, 33, 1], [30, 33, 1], [31, 33, 3], [32, 33, 3], [33, 33, 4], [34, 33, 4], [35, 33, 3], [36, 33, 4], [37, 33, 3], [38, 33, 5], [39, 33, 4], [40, 33, 4], [41, 33, 5], [42, 33, 5], [43, 33, 5], [44, 33, 5], [45, 33, 4], [46, 33, 5], [47, 33, 5], [48, 33, 5], [49, 33, 5], [0, 34, 5], [1, 34, 5], [2, 34, 5], [3, 34, 5], [4, 34, 5], [5, 34, 5], [6, 34, 5], [7, 34, 5], [8, 34, 5], [9, 34, 4], [10, 34, 4], [11, 34, 4], [12, 34, 4], [13, 34, 4], [14, 34, 3], [15, 34, 4], [16, 34, 3], [17, 34, 3], [18, 34, 1], [19, 34, 2], [20, 34, 1], [21, 34, 2], [22, 34, 1], [23, 34, 2], [24, 34, 1], [25, 34, 2], [26, 34, 1], [27, 34, 1], [28, 34, 0], [29, 34, 0], [30, 34, 3], [31, 34, 3], [32, 34, 4], [33, 34, 4], [34, 34, 4], [35, 34, 4], [36, 34, 4], [37, 34, 5], [38, 34, 5], [39, 34, 5], [40, 34, 5], [41, 34, 5], [42, 34, 5], [43, 34, 5], [44, 34, 5], [45, 34, 5], [46, 34, 5], [47, 34, 5], [48, 34, 5], [49, 34, 5], [0, 35, 4], [1, 35, 4], [2, 35, 5], [3, 35, 5], [4, 35, 4], [5, 35, 4], [6, 35, 4], [7, 35, 4], [8, 35, 4], [9, 35, 5], [10, 35, 4], [11, 35, 4], [12, 35, 4], [13, 35, 3], [14, 35, 3], [15, 35, 4], [16, 35, 1], [17, 35, 3], [18, 35, 4], [19, 35, 4], [20, 35, 4], [21, 35, 4], [22, 35, 3], [23, 35, 2], [24, 35, 2], [25, 35, 3], [26, 35, 2], [27, 35, 3], [28, 35, 2], [29, 35, 2], [30, 35, 2], [31, 35, 3], [32, 35, 3], [33, 35, 4], [34, 35, 4], [35, 35, 5], [36, 35, 5], [37, 35, 5], [38, 35, 5], [39, 35, 5], [40, 35, 5], [41, 35, 5], [42, 35, 5], [43, 35, 5], [44, 35, 5], [45, 35, 5], [46, 35, 5], [47, 35, 5], [48, 35, 5], [49, 35, 5], [0, 36, 5], [1, 36, 5], [2, 36, 5], [3, 36, 5], [4, 36, 5], [5, 36, 5], [6, 36, 5], [7, 36, 5], [8, 36, 5], [9, 36, 5], [10, 36, 5], [11, 36, 4], [12, 36, 2], [13, 36, 1], [14, 36, 4], [15, 36, 1], [16, 36, 2], [17, 36, 1], [18, 36, 1], [19, 36, 1], [20, 36, 4], [21, 36, 4], [22, 36, 4], [23, 36, 1], [24, 36, 2], [25, 36, 1], [26, 36, 3], [27, 36, 3], [28, 36, 3], [29, 36, 3], [30, 36, 5], [31, 36, 4], [32, 36, 4], [33, 36, 4], [34, 36, 4], [35, 36, 4], [36, 36, 5], [37, 36, 5], [38, 36, 5], [39, 36, 5], [40, 36, 5], [41, 36, 5], [42, 36, 4], [43, 36, 5], [44, 36, 5], [45, 36, 5], [46, 36, 2], [47, 36, 5], [48, 36, 5], [49, 36, 5], [0, 37, 5], [1, 37, 5], [2, 37, 5], [3, 37, 5], [4, 37, 5], [5, 37, 5], [6, 37, 5], [7, 37, 5], [8, 37, 5], [9, 37, 4], [10, 37, 5], [11, 37, 5], [12, 37, 5], [13, 37, 4], [14, 37, 1], [15, 37, 1], [16, 37, 4], [17, 37, 2], [18, 37, 2], [19, 37, 2], [20, 37, 5], [21, 37, 5], [22, 37, 5], [23, 37, 5], [24, 37, 1], [25, 37, 2], [26, 37, 2], [27, 37, 4], [28, 37, 3], [29, 37, 5], [30, 37, 5], [31, 37, 2], [32, 37, 4], [33, 37, 4], [34, 37, 4], [35, 37, 5], [36, 37, 5], [37, 37, 5], [38, 37, 5], [39, 37, 5], [40, 37, 5], [41, 37, 5], [42, 37, 5], [43, 37, 2], [44, 37, 5], [45, 37, 5], [46, 37, 5], [47, 37, 5], [48, 37, 5], [49, 37, 5], [0, 38, 5], [1, 38, 5], [2, 38, 5], [3, 38, 5], [4, 38, 5], [5, 38, 5], [6, 38, 5], [7, 38, 5], [8, 38, 5], [9, 38, 4], [10, 38, 5], [11, 38, 5], [12, 38, 2], [13, 38, 2], [14, 38, 1], [15, 38, 2], [16, 38, 1], [17, 38, 4], [18, 38, 4], [19, 38, 5], [20, 38, 4], [21, 38, 5], [22, 38, 4], [23, 38, 2], [24, 38, 2], [25, 38, 5], [26, 38, 5], [27, 38, 4], [28, 38, 4], [29, 38, 5], [30, 38, 4], [31, 38, 5], [32, 38, 5], [33, 38, 5], [34, 38, 5], [35, 38, 5], [36, 38, 5], [37, 38, 5], [38, 38, 5], [39, 38, 5], [40, 38, 5], [41, 38, 5], [42, 38, 5], [43, 38, 5], [44, 38, 5], [45, 38, 5], [46, 38, 5], [47, 38, 5], [48, 38, 5], [49, 38, 5], [0, 39, 5], [1, 39, 5], [2, 39, 5], [3, 39, 5], [4, 39, 5], [5, 39, 5], [6, 39, 5], [7, 39, 5], [8, 39, 5], [9, 39, 4], [10, 39, 5], [11, 39, 5], [12, 39, 4], [13, 39, 2], [14, 39, 4], [15, 39, 2], [16, 39, 2], [17, 39, 4], [18, 39, 4], [19, 39, 5], [20, 39, 4], [21, 39, 5], [22, 39, 5], [23, 39, 5], [24, 39, 5], [25, 39, 5], [26, 39, 5], [27, 39, 5], [28, 39, 4], [29, 39, 4], [30, 39, 4], [31, 39, 4], [32, 39, 4], [33, 39, 5], [34, 39, 5], [35, 39, 5], [36, 39, 5], [37, 39, 5], [38, 39, 5], [39, 39, 5], [40, 39, 5], [41, 39, 5], [42, 39, 5], [43, 39, 5], [44, 39, 5], [45, 39, 5], [46, 39, 5], [47, 39, 5], [48, 39, 5], [49, 39, 5], [0, 40, 5], [1, 40, 5], [2, 40, 5], [3, 40, 5], [4, 40, 5], [5, 40, 4], [6, 40, 5], [7, 40, 5], [8, 40, 5], [9, 40, 5], [10, 40, 5], [11, 40, 4], [12, 40, 4], [13, 40, 4], [14, 40, 2], [15, 40, 2], [16, 40, 4], [17, 40, 2], [18, 40, 5], [19, 40, 5], [20, 40, 5], [21, 40, 5], [22, 40, 5], [23, 40, 4], [24, 40, 4], [25, 40, 5], [26, 40, 5], [27, 40, 4], [28, 40, 5], [29, 40, 5], [30, 40, 4], [31, 40, 4], [32, 40, 5], [33, 40, 4], [34, 40, 5], [35, 40, 5], [36, 40, 5], [37, 40, 5], [38, 40, 5], [39, 40, 5], [40, 40, 5], [41, 40, 5], [42, 40, 5], [43, 40, 5], [44, 40, 5], [45, 40, 5], [46, 40, 5], [47, 40, 5], [48, 40, 5], [49, 40, 5], [0, 41, 5], [1, 41, 5], [2, 41, 5], [3, 41, 5], [4, 41, 5], [5, 41, 5], [6, 41, 5], [7, 41, 5], [8, 41, 5], [9, 41, 5], [10, 41, 5], [11, 41, 5], [12, 41, 5], [13, 41, 4], [14, 41, 4], [15, 41, 4], [16, 41, 4], [17, 41, 4], [18, 41, 5], [19, 41, 5], [20, 41, 5], [21, 41, 5], [22, 41, 5], [23, 41, 5], [24, 41, 5], [25, 41, 5], [26, 41, 4], [27, 41, 5], [28, 41, 5], [29, 41, 2], [30, 41, 5], [31, 41, 4], [32, 41, 5], [33, 41, 5], [34, 41, 5], [35, 41, 5], [36, 41, 5], [37, 41, 5], [38, 41, 5], [39, 41, 5], [40, 41, 5], [41, 41, 5], [42, 41, 5], [43, 41, 5], [44, 41, 5], [45, 41, 5], [46, 41, 5], [47, 41, 5], [48, 41, 5], [49, 41, 5], [0, 42, 5], [1, 42, 5], [2, 42, 5], [3, 42, 5], [4, 42, 5], [5, 42, 5], [6, 42, 5], [7, 42, 5], [8, 42, 5], [9, 42, 5], [10, 42, 5], [11, 42, 4], [12, 42, 4], [13, 42, 5], [14, 42, 5], [15, 42, 4], [16, 42, 4], [17, 42, 5], [18, 42, 5], [19, 42, 5], [20, 42, 5], [21, 42, 5], [22, 42, 5], [23, 42, 5], [24, 42, 5], [25, 42, 5], [26, 42, 5], [27, 42, 5], [28, 42, 5], [29, 42, 2], [30, 42, 5], [31, 42, 5], [32, 42, 5], [33, 42, 5], [34, 42, 5], [35, 42, 5], [36, 42, 5], [37, 42, 5], [38, 42, 5], [39, 42, 5], [40, 42, 5], [41, 42, 5], [42, 42, 5], [43, 42, 5], [44, 42, 5], [45, 42, 5], [46, 42, 5], [47, 42, 5], [48, 42, 5], [49, 42, 5], [0, 43, 5], [1, 43, 5], [2, 43, 5], [3, 43, 5], [4, 43, 5], [5, 43, 5], [6, 43, 5], [7, 43, 5], [8, 43, 5], [9, 43, 5], [10, 43, 5], [11, 43, 5], [12, 43, 5], [13, 43, 2], [14, 43, 5], [15, 43, 5], [16, 43, 5], [17, 43, 5], [18, 43, 5], [19, 43, 5], [20, 43, 5], [21, 43, 5], [22, 43, 5], [23, 43, 5], [24, 43, 5], [25, 43, 5], [26, 43, 5], [27, 43, 5], [28, 43, 5], [29, 43, 5], [30, 43, 4], [31, 43, 4], [32, 43, 4], [33, 43, 4], [34, 43, 5], [35, 43, 5], [36, 43, 5], [37, 43, 5], [38, 43, 4], [39, 43, 4], [40, 43, 4], [41, 43, 5], [42, 43, 5], [43, 43, 5], [44, 43, 5], [45, 43, 5], [46, 43, 5], [47, 43, 5], [48, 43, 5], [49, 43, 5], [0, 44, 5], [1, 44, 5], [2, 44, 5], [3, 44, 5], [4, 44, 5], [5, 44, 5], [6, 44, 5], [7, 44, 5], [8, 44, 5], [9, 44, 5], [10, 44, 5], [11, 44, 5], [12, 44, 5], [13, 44, 2], [14, 44, 5], [15, 44, 5], [16, 44, 5], [17, 44, 5], [18, 44, 5], [19, 44, 5], [20, 44, 4], [21, 44, 5], [22, 44, 5], [23, 44, 5], [24, 44, 5], [25, 44, 5], [26, 44, 5], [27, 44, 5], [28, 44, 5], [29, 44, 5], [30, 44, 2], [31, 44, 4], [32, 44, 2], [33, 44, 2], [34, 44, 2], [35, 44, 4], [36, 44, 4], [37, 44, 5], [38, 44, 5], [39, 44, 4], [40, 44, 5], [41, 44, 4], [42, 44, 5], [43, 44, 5], [44, 44, 5], [45, 44, 5], [46, 44, 5], [47, 44, 5], [48, 44, 5], [49, 44, 5], [0, 45, 5], [1, 45, 5], [2, 45, 5], [3, 45, 5], [4, 45, 5], [5, 45, 5], [6, 45, 5], [7, 45, 5], [8, 45, 5], [9, 45, 5], [10, 45, 5], [11, 45, 5], [12, 45, 5], [13, 45, 5], [14, 45, 5], [15, 45, 5], [16, 45, 5], [17, 45, 5], [18, 45, 5], [19, 45, 4], [20, 45, 5], [21, 45, 5], [22, 45, 5], [23, 45, 5], [24, 45, 5], [25, 45, 5], [26, 45, 5], [27, 45, 5], [28, 45, 5], [29, 45, 5], [30, 45, 4], [31, 45, 2], [32, 45, 2], [33, 45, 2], [34, 45, 2], [35, 45, 4], [36, 45, 4], [37, 45, 4], [38, 45, 4], [39, 45, 4], [40, 45, 5], [41, 45, 4], [42, 45, 4], [43, 45, 5], [44, 45, 5], [45, 45, 5], [46, 45, 5], [47, 45, 5], [48, 45, 5], [49, 45, 5], [0, 46, 5], [1, 46, 5], [2, 46, 5], [3, 46, 5], [4, 46, 5], [5, 46, 5], [6, 46, 5], [7, 46, 5], [8, 46, 5], [9, 46, 5], [10, 46, 5], [11, 46, 5], [12, 46, 5], [13, 46, 5], [14, 46, 5], [15, 46, 5], [16, 46, 5], [17, 46, 5], [18, 46, 5], [19, 46, 5], [20, 46, 5], [21, 46, 5], [22, 46, 5], [23, 46, 5], [24, 46, 5], [25, 46, 5], [26, 46, 5], [27, 46, 5], [28, 46, 5], [29, 46, 4], [30, 46, 4], [31, 46, 4], [32, 46, 4], [33, 46, 2], [34, 46, 2], [35, 46, 4], [36, 46, 2], [37, 46, 4], [38, 46, 5], [39, 46, 4], [40, 46, 5], [41, 46, 5], [42, 46, 5], [43, 46, 5], [44, 46, 5], [45, 46, 5], [46, 46, 5], [47, 46, 5], [48, 46, 5], [49, 46, 5], [0, 47, 5], [1, 47, 5], [2, 47, 5], [3, 47, 5], [4, 47, 5], [5, 47, 5], [6, 47, 5], [7, 47, 5], [8, 47, 5], [9, 47, 5], [10, 47, 5], [11, 47, 5], [12, 47, 5], [13, 47, 5], [14, 47, 5], [15, 47, 5], [16, 47, 5], [17, 47, 5], [18, 47, 5], [19, 47, 5], [20, 47, 5], [21, 47, 5], [22, 47, 5], [23, 47, 5], [24, 47, 5], [25, 47, 5], [26, 47, 5], [27, 47, 5], [28, 47, 5], [29, 47, 5], [30, 47, 5], [31, 47, 5], [32, 47, 4], [33, 47, 5], [34, 47, 4], [35, 47, 5], [36, 47, 5], [37, 47, 5], [38, 47, 5], [39, 47, 5], [40, 47, 4], [41, 47, 4], [42, 47, 5], [43, 47, 5], [44, 47, 5], [45, 47, 5], [46, 47, 5], [47, 47, 5], [48, 47, 5], [49, 47, 5], [0, 48, 5], [1, 48, 5], [2, 48, 5], [3, 48, 5], [4, 48, 5], [5, 48, 5], [6, 48, 5], [7, 48, 5], [8, 48, 5], [9, 48, 5], [10, 48, 5], [11, 48, 5], [12, 48, 5], [13, 48, 4], [14, 48, 5], [15, 48, 4], [16, 48, 5], [17, 48, 5], [18, 48, 5], [19, 48, 5], [20, 48, 5], [21, 48, 5], [22, 48, 5], [23, 48, 5], [24, 48, 5], [25, 48, 5], [26, 48, 5], [27, 48, 5], [28, 48, 5], [29, 48, 5], [30, 48, 5], [31, 48, 5], [32, 48, 5], [33, 48, 5], [34, 48, 5], [35, 48, 5], [36, 48, 5], [37, 48, 5], [38, 48, 5], [39, 48, 5], [40, 48, 5], [41, 48, 4], [42, 48, 4], [43, 48, 5], [44, 48, 5], [45, 48, 5], [46, 48, 5], [47, 48, 5], [48, 48, 5], [49, 48, 5], [0, 49, 5], [1, 49, 5], [2, 49, 5], [3, 49, 5], [4, 49, 5], [5, 49, 5], [6, 49, 5], [7, 49, 5], [8, 49, 5], [9, 49, 5], [10, 49, 5], [11, 49, 5], [12, 49, 5], [13, 49, 5], [14, 49, 5], [15, 49, 5], [16, 49, 5], [17, 49, 5], [18, 49, 5], [19, 49, 5], [20, 49, 5], [21, 49, 5], [22, 49, 5], [23, 49, 5], [24, 49, 5], [25, 49, 5], [26, 49, 5], [27, 49, 5], [28, 49, 5], [29, 49, 5], [30, 49, 5], [31, 49, 5], [32, 49, 5], [33, 49, 5], [34, 49, 5], [35, 49, 5], [36, 49, 5], [37, 49, 5], [38, 49, 5], [39, 49, 5], [40, 49, 5], [41, 49, 4], [42, 49, 5], [43, 49, 5], [44, 49, 5], [45, 49, 5], [46, 49, 5], [47, 49, 5], [48, 49, 5], [49, 49, 5]]; +function renderItem(params, api) { + var context = params.context; + var lngIndex = api.value(0); + var latIndex = api.value(1); + var coordLeftTop = [ + +(latExtent[0] + lngIndex * cellSizeCoord[0]).toFixed(6), + +(lngExtent[0] + latIndex * cellSizeCoord[1]).toFixed(6) + ]; + var pointLeftTop = getCoord(params, api, lngIndex, latIndex); + var pointRightBottom = getCoord(params, api, lngIndex + 1, latIndex + 1); + return { + type: 'rect', + shape: { + x: pointLeftTop[0], + y: pointLeftTop[1], + width: pointRightBottom[0] - pointLeftTop[0], + height: pointRightBottom[1] - pointLeftTop[1] + }, + style: api.style({ + stroke: 'rgba(0,0,0,0.1)' + }), + styleEmphasis: api.styleEmphasis() + }; +} +function getCoord(params, api, lngIndex, latIndex) { + var coords = params.context.coords || (params.context.coords = []); + var key = lngIndex + '-' + latIndex; + // bmap returns point in integer, which makes cell width unstable. + // So we have to use right bottom point. + return (coords[key] || + (coords[key] = api.coord([ + +(latExtent[0] + lngIndex * cellSizeCoord[0]).toFixed(6), + +(lngExtent[0] + latIndex * cellSizeCoord[1]).toFixed(6) + ]))); +} +option = { + tooltip: {}, + visualMap: { + type: 'piecewise', + inverse: true, + top: 10, + left: 10, + pieces: [ + { + value: 0, + color: COLORS[0] + }, + { + value: 1, + color: COLORS[1] + }, + { + value: 2, + color: COLORS[2] + }, + { + value: 3, + color: COLORS[3] + }, + { + value: 4, + color: COLORS[4] + }, + { + value: 5, + color: COLORS[5] + } + ], + borderColor: '#ccc', + borderWidth: 2, + backgroundColor: '#eee', + dimension: 2, + inRange: { + color: COLORS, + opacity: 0.7 + } + }, + series: [ + { + type: 'custom', + coordinateSystem: 'bmap', + renderItem: renderItem, + animation: false, + emphasis: { + itemStyle: { + color: 'yellow' + } + }, + encode: { + tooltip: 2 + }, + data: data + } + ], + bmap: { + center: [116.46, 39.92], + zoom: 11.8, + roam: true, + mapStyle: { + styleJson: [ + { + featureType: 'water', + elementType: 'all', + stylers: { + color: '#d1d1d1' + } + }, + { + featureType: 'land', + elementType: 'all', + stylers: { + color: '#f3f3f3' + } + }, + { + featureType: 'railway', + elementType: 'all', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'highway', + elementType: 'all', + stylers: { + color: '#999999' + } + }, + { + featureType: 'highway', + elementType: 'labels', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'arterial', + elementType: 'geometry', + stylers: { + color: '#fefefe' + } + }, + { + featureType: 'arterial', + elementType: 'geometry.fill', + stylers: { + color: '#fefefe' + } + }, + { + featureType: 'poi', + elementType: 'all', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'green', + elementType: 'all', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'subway', + elementType: 'all', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'manmade', + elementType: 'all', + stylers: { + color: '#d1d1d1' + } + }, + { + featureType: 'local', + elementType: 'all', + stylers: { + color: '#d1d1d1' + } + }, + { + featureType: 'arterial', + elementType: 'labels', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'boundary', + elementType: 'all', + stylers: { + color: '#fefefe' + } + }, + { + featureType: 'building', + elementType: 'all', + stylers: { + color: '#d1d1d1' + } + }, + { + featureType: 'label', + elementType: 'labels.text.fill', + stylers: { + color: 'rgba(0,0,0,0)' + } + } + ] + } + } +}; diff --git a/testdata/map-bin.js.svg b/testdata/map-bin.js.svg new file mode 100644 index 0000000..fcaa7af --- /dev/null +++ b/testdata/map-bin.js.svg @@ -0,0 +1,16 @@ + + + + +0 + +1 + +2 + +3 + +4 + +5 + \ No newline at end of file diff --git a/testdata/map-polygon.js b/testdata/map-polygon.js new file mode 100644 index 0000000..b3e6164 --- /dev/null +++ b/testdata/map-polygon.js @@ -0,0 +1,655 @@ +"use strict"; +/* +title: Draw Polygon on Map +category: map +tags: bmap +titleCN: 在地图上绘制多边形 +*/ +var data = [ + { name: '海门', value: 9 }, + { name: '鄂尔多斯', value: 12 }, + { name: '招远', value: 12 }, + { name: '舟山', value: 12 }, + { name: '齐齐哈尔', value: 14 }, + { name: '盐城', value: 15 }, + { name: '赤峰', value: 16 }, + { name: '青岛', value: 18 }, + { name: '乳山', value: 18 }, + { name: '金昌', value: 19 }, + { name: '泉州', value: 21 }, + { name: '莱西', value: 21 }, + { name: '日照', value: 21 }, + { name: '胶南', value: 22 }, + { name: '南通', value: 23 }, + { name: '拉萨', value: 24 }, + { name: '云浮', value: 24 }, + { name: '梅州', value: 25 }, + { name: '文登', value: 25 }, + { name: '上海', value: 25 }, + { name: '攀枝花', value: 25 }, + { name: '威海', value: 25 }, + { name: '承德', value: 25 }, + { name: '厦门', value: 26 }, + { name: '汕尾', value: 26 }, + { name: '潮州', value: 26 }, + { name: '丹东', value: 27 }, + { name: '太仓', value: 27 }, + { name: '曲靖', value: 27 }, + { name: '烟台', value: 28 }, + { name: '福州', value: 29 }, + { name: '瓦房店', value: 30 }, + { name: '即墨', value: 30 }, + { name: '抚顺', value: 31 }, + { name: '玉溪', value: 31 }, + { name: '张家口', value: 31 }, + { name: '阳泉', value: 31 }, + { name: '莱州', value: 32 }, + { name: '湖州', value: 32 }, + { name: '汕头', value: 32 }, + { name: '昆山', value: 33 }, + { name: '宁波', value: 33 }, + { name: '湛江', value: 33 }, + { name: '揭阳', value: 34 }, + { name: '荣成', value: 34 }, + { name: '连云港', value: 35 }, + { name: '葫芦岛', value: 35 }, + { name: '常熟', value: 36 }, + { name: '东莞', value: 36 }, + { name: '河源', value: 36 }, + { name: '淮安', value: 36 }, + { name: '泰州', value: 36 }, + { name: '南宁', value: 37 }, + { name: '营口', value: 37 }, + { name: '惠州', value: 37 }, + { name: '江阴', value: 37 }, + { name: '蓬莱', value: 37 }, + { name: '韶关', value: 38 }, + { name: '嘉峪关', value: 38 }, + { name: '广州', value: 38 }, + { name: '延安', value: 38 }, + { name: '太原', value: 39 }, + { name: '清远', value: 39 }, + { name: '中山', value: 39 }, + { name: '昆明', value: 39 }, + { name: '寿光', value: 40 }, + { name: '盘锦', value: 40 }, + { name: '长治', value: 41 }, + { name: '深圳', value: 41 }, + { name: '珠海', value: 42 }, + { name: '宿迁', value: 43 }, + { name: '咸阳', value: 43 }, + { name: '铜川', value: 44 }, + { name: '平度', value: 44 }, + { name: '佛山', value: 44 }, + { name: '海口', value: 44 }, + { name: '江门', value: 45 }, + { name: '章丘', value: 45 }, + { name: '肇庆', value: 46 }, + { name: '大连', value: 47 }, + { name: '临汾', value: 47 }, + { name: '吴江', value: 47 }, + { name: '石嘴山', value: 49 }, + { name: '沈阳', value: 50 }, + { name: '苏州', value: 50 }, + { name: '茂名', value: 50 }, + { name: '嘉兴', value: 51 }, + { name: '长春', value: 51 }, + { name: '胶州', value: 52 }, + { name: '银川', value: 52 }, + { name: '张家港', value: 52 }, + { name: '三门峡', value: 53 }, + { name: '锦州', value: 54 }, + { name: '南昌', value: 54 }, + { name: '柳州', value: 54 }, + { name: '三亚', value: 54 }, + { name: '自贡', value: 56 }, + { name: '吉林', value: 56 }, + { name: '阳江', value: 57 }, + { name: '泸州', value: 57 }, + { name: '西宁', value: 57 }, + { name: '宜宾', value: 58 }, + { name: '呼和浩特', value: 58 }, + { name: '成都', value: 58 }, + { name: '大同', value: 58 }, + { name: '镇江', value: 59 }, + { name: '桂林', value: 59 }, + { name: '张家界', value: 59 }, + { name: '宜兴', value: 59 }, + { name: '北海', value: 60 }, + { name: '西安', value: 61 }, + { name: '金坛', value: 62 }, + { name: '东营', value: 62 }, + { name: '牡丹江', value: 63 }, + { name: '遵义', value: 63 }, + { name: '绍兴', value: 63 }, + { name: '扬州', value: 64 }, + { name: '常州', value: 64 }, + { name: '潍坊', value: 65 }, + { name: '重庆', value: 66 }, + { name: '台州', value: 67 }, + { name: '南京', value: 67 }, + { name: '滨州', value: 70 }, + { name: '贵阳', value: 71 }, + { name: '无锡', value: 71 }, + { name: '本溪', value: 71 }, + { name: '克拉玛依', value: 72 }, + { name: '渭南', value: 72 }, + { name: '马鞍山', value: 72 }, + { name: '宝鸡', value: 72 }, + { name: '焦作', value: 75 }, + { name: '句容', value: 75 }, + { name: '北京', value: 79 }, + { name: '徐州', value: 79 }, + { name: '衡水', value: 80 }, + { name: '包头', value: 80 }, + { name: '绵阳', value: 80 }, + { name: '乌鲁木齐', value: 84 }, + { name: '枣庄', value: 84 }, + { name: '杭州', value: 84 }, + { name: '淄博', value: 85 }, + { name: '鞍山', value: 86 }, + { name: '溧阳', value: 86 }, + { name: '库尔勒', value: 86 }, + { name: '安阳', value: 90 }, + { name: '开封', value: 90 }, + { name: '济南', value: 92 }, + { name: '德阳', value: 93 }, + { name: '温州', value: 95 }, + { name: '九江', value: 96 }, + { name: '邯郸', value: 98 }, + { name: '临安', value: 99 }, + { name: '兰州', value: 99 }, + { name: '沧州', value: 100 }, + { name: '临沂', value: 103 }, + { name: '南充', value: 104 }, + { name: '天津', value: 105 }, + { name: '富阳', value: 106 }, + { name: '泰安', value: 112 }, + { name: '诸暨', value: 112 }, + { name: '郑州', value: 113 }, + { name: '哈尔滨', value: 114 }, + { name: '聊城', value: 116 }, + { name: '芜湖', value: 117 }, + { name: '唐山', value: 119 }, + { name: '平顶山', value: 119 }, + { name: '邢台', value: 119 }, + { name: '德州', value: 120 }, + { name: '济宁', value: 120 }, + { name: '荆州', value: 127 }, + { name: '宜昌', value: 130 }, + { name: '义乌', value: 132 }, + { name: '丽水', value: 133 }, + { name: '洛阳', value: 134 }, + { name: '秦皇岛', value: 136 }, + { name: '株洲', value: 143 }, + { name: '石家庄', value: 147 }, + { name: '莱芜', value: 148 }, + { name: '常德', value: 152 }, + { name: '保定', value: 153 }, + { name: '湘潭', value: 154 }, + { name: '金华', value: 157 }, + { name: '岳阳', value: 169 }, + { name: '长沙', value: 175 }, + { name: '衢州', value: 177 }, + { name: '廊坊', value: 193 }, + { name: '菏泽', value: 194 }, + { name: '合肥', value: 229 }, + { name: '武汉', value: 273 }, + { name: '大庆', value: 279 } +]; +var geoCoordMap = { + 海门: [121.15, 31.89], + 鄂尔多斯: [109.781327, 39.608266], + 招远: [120.38, 37.35], + 舟山: [122.207216, 29.985295], + 齐齐哈尔: [123.97, 47.33], + 盐城: [120.13, 33.38], + 赤峰: [118.87, 42.28], + 青岛: [120.33, 36.07], + 乳山: [121.52, 36.89], + 金昌: [102.188043, 38.520089], + 泉州: [118.58, 24.93], + 莱西: [120.53, 36.86], + 日照: [119.46, 35.42], + 胶南: [119.97, 35.88], + 南通: [121.05, 32.08], + 拉萨: [91.11, 29.97], + 云浮: [112.02, 22.93], + 梅州: [116.1, 24.55], + 文登: [122.05, 37.2], + 上海: [121.48, 31.22], + 攀枝花: [101.718637, 26.582347], + 威海: [122.1, 37.5], + 承德: [117.93, 40.97], + 厦门: [118.1, 24.46], + 汕尾: [115.375279, 22.786211], + 潮州: [116.63, 23.68], + 丹东: [124.37, 40.13], + 太仓: [121.1, 31.45], + 曲靖: [103.79, 25.51], + 烟台: [121.39, 37.52], + 福州: [119.3, 26.08], + 瓦房店: [121.979603, 39.627114], + 即墨: [120.45, 36.38], + 抚顺: [123.97, 41.97], + 玉溪: [102.52, 24.35], + 张家口: [114.87, 40.82], + 阳泉: [113.57, 37.85], + 莱州: [119.942327, 37.177017], + 湖州: [120.1, 30.86], + 汕头: [116.69, 23.39], + 昆山: [120.95, 31.39], + 宁波: [121.56, 29.86], + 湛江: [110.359377, 21.270708], + 揭阳: [116.35, 23.55], + 荣成: [122.41, 37.16], + 连云港: [119.16, 34.59], + 葫芦岛: [120.836932, 40.711052], + 常熟: [120.74, 31.64], + 东莞: [113.75, 23.04], + 河源: [114.68, 23.73], + 淮安: [119.15, 33.5], + 泰州: [119.9, 32.49], + 南宁: [108.33, 22.84], + 营口: [122.18, 40.65], + 惠州: [114.4, 23.09], + 江阴: [120.26, 31.91], + 蓬莱: [120.75, 37.8], + 韶关: [113.62, 24.84], + 嘉峪关: [98.289152, 39.77313], + 广州: [113.23, 23.16], + 延安: [109.47, 36.6], + 太原: [112.53, 37.87], + 清远: [113.01, 23.7], + 中山: [113.38, 22.52], + 昆明: [102.73, 25.04], + 寿光: [118.73, 36.86], + 盘锦: [122.070714, 41.119997], + 长治: [113.08, 36.18], + 深圳: [114.07, 22.62], + 珠海: [113.52, 22.3], + 宿迁: [118.3, 33.96], + 咸阳: [108.72, 34.36], + 铜川: [109.11, 35.09], + 平度: [119.97, 36.77], + 佛山: [113.11, 23.05], + 海口: [110.35, 20.02], + 江门: [113.06, 22.61], + 章丘: [117.53, 36.72], + 肇庆: [112.44, 23.05], + 大连: [121.62, 38.92], + 临汾: [111.5, 36.08], + 吴江: [120.63, 31.16], + 石嘴山: [106.39, 39.04], + 沈阳: [123.38, 41.8], + 苏州: [120.62, 31.32], + 茂名: [110.88, 21.68], + 嘉兴: [120.76, 30.77], + 长春: [125.35, 43.88], + 胶州: [120.03336, 36.264622], + 银川: [106.27, 38.47], + 张家港: [120.555821, 31.875428], + 三门峡: [111.19, 34.76], + 锦州: [121.15, 41.13], + 南昌: [115.89, 28.68], + 柳州: [109.4, 24.33], + 三亚: [109.511909, 18.252847], + 自贡: [104.778442, 29.33903], + 吉林: [126.57, 43.87], + 阳江: [111.95, 21.85], + 泸州: [105.39, 28.91], + 西宁: [101.74, 36.56], + 宜宾: [104.56, 29.77], + 呼和浩特: [111.65, 40.82], + 成都: [104.06, 30.67], + 大同: [113.3, 40.12], + 镇江: [119.44, 32.2], + 桂林: [110.28, 25.29], + 张家界: [110.479191, 29.117096], + 宜兴: [119.82, 31.36], + 北海: [109.12, 21.49], + 西安: [108.95, 34.27], + 金坛: [119.56, 31.74], + 东营: [118.49, 37.46], + 牡丹江: [129.58, 44.6], + 遵义: [106.9, 27.7], + 绍兴: [120.58, 30.01], + 扬州: [119.42, 32.39], + 常州: [119.95, 31.79], + 潍坊: [119.1, 36.62], + 重庆: [106.54, 29.59], + 台州: [121.420757, 28.656386], + 南京: [118.78, 32.04], + 滨州: [118.03, 37.36], + 贵阳: [106.71, 26.57], + 无锡: [120.29, 31.59], + 本溪: [123.73, 41.3], + 克拉玛依: [84.77, 45.59], + 渭南: [109.5, 34.52], + 马鞍山: [118.48, 31.56], + 宝鸡: [107.15, 34.38], + 焦作: [113.21, 35.24], + 句容: [119.16, 31.95], + 北京: [116.46, 39.92], + 徐州: [117.2, 34.26], + 衡水: [115.72, 37.72], + 包头: [110, 40.58], + 绵阳: [104.73, 31.48], + 乌鲁木齐: [87.68, 43.77], + 枣庄: [117.57, 34.86], + 杭州: [120.19, 30.26], + 淄博: [118.05, 36.78], + 鞍山: [122.85, 41.12], + 溧阳: [119.48, 31.43], + 库尔勒: [86.06, 41.68], + 安阳: [114.35, 36.1], + 开封: [114.35, 34.79], + 济南: [117, 36.65], + 德阳: [104.37, 31.13], + 温州: [120.65, 28.01], + 九江: [115.97, 29.71], + 邯郸: [114.47, 36.6], + 临安: [119.72, 30.23], + 兰州: [103.73, 36.03], + 沧州: [116.83, 38.33], + 临沂: [118.35, 35.05], + 南充: [106.110698, 30.837793], + 天津: [117.2, 39.13], + 富阳: [119.95, 30.07], + 泰安: [117.13, 36.18], + 诸暨: [120.23, 29.71], + 郑州: [113.65, 34.76], + 哈尔滨: [126.63, 45.75], + 聊城: [115.97, 36.45], + 芜湖: [118.38, 31.33], + 唐山: [118.02, 39.63], + 平顶山: [113.29, 33.75], + 邢台: [114.48, 37.05], + 德州: [116.29, 37.45], + 济宁: [116.59, 35.38], + 荆州: [112.239741, 30.335165], + 宜昌: [111.3, 30.7], + 义乌: [120.06, 29.32], + 丽水: [119.92, 28.45], + 洛阳: [112.44, 34.7], + 秦皇岛: [119.57, 39.95], + 株洲: [113.16, 27.83], + 石家庄: [114.48, 38.03], + 莱芜: [117.67, 36.19], + 常德: [111.69, 29.05], + 保定: [115.48, 38.85], + 湘潭: [112.91, 27.87], + 金华: [119.64, 29.12], + 岳阳: [113.09, 29.37], + 长沙: [113, 28.21], + 衢州: [118.88, 28.97], + 廊坊: [116.7, 39.53], + 菏泽: [115.480656, 35.23375], + 合肥: [117.27, 31.86], + 武汉: [114.31, 30.52], + 大庆: [125.03, 46.58] +}; +var convertData = function (data) { + var res = []; + for (var i = 0; i < data.length; i++) { + var geoCoord = geoCoordMap[data[i].name]; + if (geoCoord) { + res.push({ + name: data[i].name, + value: geoCoord.concat(data[i].value) + }); + } + } + return res; +}; +function renderItem(params, api) { + var coords = [ + [116.7, 39.53], + [103.73, 36.03], + [112.91, 27.87], + [120.65, 28.01], + [119.57, 39.95] + ]; + var points = []; + for (var i = 0; i < coords.length; i++) { + points.push(api.coord(coords[i])); + } + var color = api.visual('color'); + return { + type: 'polygon', + shape: { + points: echarts.graphic.clipPointsByRect(points, { + x: params.coordSys.x, + y: params.coordSys.y, + width: params.coordSys.width, + height: params.coordSys.height + }) + }, + style: api.style({ + fill: color, + stroke: echarts.color.lift(color) + }) + }; +} +option = { + backgroundColor: 'transparent', + title: { + text: '全国主要城市空气质量', + subtext: 'data from PM25.in', + sublink: 'http://www.pm25.in', + left: 'center', + textStyle: { + color: '#fff' + } + }, + tooltip: { + trigger: 'item' + }, + bmap: { + center: [104.114129, 37.550339], + zoom: 5, + roam: true, + mapStyle: { + styleJson: [ + { + featureType: 'water', + elementType: 'all', + stylers: { + color: '#044161' + } + }, + { + featureType: 'land', + elementType: 'all', + stylers: { + color: '#004981' + } + }, + { + featureType: 'boundary', + elementType: 'geometry', + stylers: { + color: '#064f85' + } + }, + { + featureType: 'railway', + elementType: 'all', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'highway', + elementType: 'geometry', + stylers: { + color: '#004981' + } + }, + { + featureType: 'highway', + elementType: 'geometry.fill', + stylers: { + color: '#005b96', + lightness: 1 + } + }, + { + featureType: 'highway', + elementType: 'labels', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'arterial', + elementType: 'geometry', + stylers: { + color: '#004981' + } + }, + { + featureType: 'arterial', + elementType: 'geometry.fill', + stylers: { + color: '#00508b' + } + }, + { + featureType: 'poi', + elementType: 'all', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'green', + elementType: 'all', + stylers: { + color: '#056197', + visibility: 'off' + } + }, + { + featureType: 'subway', + elementType: 'all', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'manmade', + elementType: 'all', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'local', + elementType: 'all', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'arterial', + elementType: 'labels', + stylers: { + visibility: 'off' + } + }, + { + featureType: 'boundary', + elementType: 'geometry.fill', + stylers: { + color: '#029fd4' + } + }, + { + featureType: 'building', + elementType: 'all', + stylers: { + color: '#1a5787' + } + }, + { + featureType: 'label', + elementType: 'all', + stylers: { + visibility: 'off' + } + } + ] + } + }, + series: [ + { + name: 'pm2.5', + type: 'scatter', + coordinateSystem: 'bmap', + data: convertData(data), + encode: { + value: 2 + }, + symbolSize: function (val) { + return val[2] / 10; + }, + label: { + formatter: '{b}', + position: 'right' + }, + itemStyle: { + color: '#ddb926' + }, + emphasis: { + label: { + show: true + } + } + }, + { + name: 'Top 5', + type: 'effectScatter', + coordinateSystem: 'bmap', + data: convertData(data + .sort(function (a, b) { + return b.value - a.value; + }) + .slice(0, 6)), + encode: { + value: 2 + }, + symbolSize: function (val) { + return val[2] / 10; + }, + showEffectOn: 'emphasis', + rippleEffect: { + brushType: 'stroke' + }, + hoverAnimation: true, + label: { + formatter: '{b}', + position: 'right', + show: true + }, + itemStyle: { + color: '#f4e925', + shadowBlur: 10, + shadowColor: '#333' + }, + zlevel: 1 + }, + { + type: 'custom', + coordinateSystem: 'bmap', + renderItem: renderItem, + itemStyle: { + opacity: 0.5 + }, + animation: false, + silent: true, + data: [0], + z: -10 + } + ] +}; diff --git a/testdata/map-polygon.js.svg b/testdata/map-polygon.js.svg new file mode 100644 index 0000000..fdb819b --- /dev/null +++ b/testdata/map-polygon.js.svg @@ -0,0 +1,6 @@ + + + +全国主要城市空气质量 +data from PM25.in + \ No newline at end of file diff --git a/testdata/map-usa-pie.js b/testdata/map-usa-pie.js new file mode 100644 index 0000000..cf42ca6 --- /dev/null +++ b/testdata/map-usa-pie.js @@ -0,0 +1,76 @@ +/* +title: Pie Charts on GEO Map +category: map, pie +titleCN: 在地图上显示饼图 +*/ +// This example requires ECharts v5.4.0 or later +myChart.showLoading(); +$.get(ROOT_PATH + '/data/asset/geo/USA.json', function (usaJson) { + echarts.registerMap('USA', usaJson, { + Alaska: { + left: -131, + top: 25, + width: 15 + }, + Hawaii: { + left: -110, + top: 28, + width: 5 + }, + 'Puerto Rico': { + left: -76, + top: 26, + width: 2 + } + }); + function randomPieSeries(center, radius) { + const data = ['A', 'B', 'C', 'D'].map((t) => { + return { + value: Math.round(Math.random() * 100), + name: 'Category ' + t + }; + }); + return { + type: 'pie', + coordinateSystem: 'geo', + tooltip: { + formatter: '{b}: {c} ({d}%)' + }, + label: { + show: false + }, + labelLine: { + show: false + }, + animationDuration: 0, + radius, + center, + data + }; + } + option = { + geo: { + map: 'USA', + roam: true, + itemStyle: { + areaColor: '#e7e8ea' + } + }, + tooltip: {}, + legend: {}, + series: [ + randomPieSeries([-86.753504, 33.01077], 15), + randomPieSeries([-116.853504, 39.8], 25), + randomPieSeries([-99, 31.5], 30), + randomPieSeries( + // it's also supported to use geo region name as center since v5.4.1 + +echarts.version.split('.').slice(0, 3).join('') > 540 + ? 'Maine' + : // or you can only use the LngLat array + [-69, 45.5], 12) + ] + }; + myChart.hideLoading(); + myChart.setOption(option); +}); +export {}; diff --git a/testdata/map-usa-projection.js b/testdata/map-usa-projection.js new file mode 100644 index 0000000..798e8ad --- /dev/null +++ b/testdata/map-usa-projection.js @@ -0,0 +1,134 @@ +/* +title: USA Choropleth Map with Projection +category: map +titleCN: 自定义地图投影 +*/ +myChart.showLoading(); +$.when($.get(ROOT_PATH + '/data/asset/geo/USA.json'), $.getScript('https://fastly.jsdelivr.net/npm/d3-array'), $.getScript('https://fastly.jsdelivr.net/npm/d3-geo')).done(function (res) { + const usaJson = res[0]; + const projection = d3.geoAlbersUsa(); + myChart.hideLoading(); + echarts.registerMap('USA', usaJson); + option = { + title: { + text: 'USA Population Estimates (2012)', + subtext: 'Data from www.census.gov', + sublink: 'http://www.census.gov/popest/data/datasets.html', + left: 'right' + }, + tooltip: { + trigger: 'item', + showDelay: 0, + transitionDuration: 0.2 + }, + visualMap: { + left: 'right', + min: 500000, + max: 38000000, + inRange: { + color: [ + '#313695', + '#4575b4', + '#74add1', + '#abd9e9', + '#e0f3f8', + '#ffffbf', + '#fee090', + '#fdae61', + '#f46d43', + '#d73027', + '#a50026' + ] + }, + text: ['High', 'Low'], + calculable: true + }, + toolbox: { + show: true, + //orient: 'vertical', + left: 'left', + top: 'top', + feature: { + dataView: { readOnly: false }, + restore: {}, + saveAsImage: {} + } + }, + series: [ + { + name: 'USA PopEstimates', + type: 'map', + map: 'USA', + projection: { + project: function (point) { + return projection(point); + }, + unproject: function (point) { + return projection.invert(point); + } + }, + emphasis: { + label: { + show: true + } + }, + data: [ + { name: 'Alabama', value: 4822023 }, + { name: 'Alaska', value: 731449 }, + { name: 'Arizona', value: 6553255 }, + { name: 'Arkansas', value: 2949131 }, + { name: 'California', value: 38041430 }, + { name: 'Colorado', value: 5187582 }, + { name: 'Connecticut', value: 3590347 }, + { name: 'Delaware', value: 917092 }, + { name: 'District of Columbia', value: 632323 }, + { name: 'Florida', value: 19317568 }, + { name: 'Georgia', value: 9919945 }, + { name: 'Hawaii', value: 1392313 }, + { name: 'Idaho', value: 1595728 }, + { name: 'Illinois', value: 12875255 }, + { name: 'Indiana', value: 6537334 }, + { name: 'Iowa', value: 3074186 }, + { name: 'Kansas', value: 2885905 }, + { name: 'Kentucky', value: 4380415 }, + { name: 'Louisiana', value: 4601893 }, + { name: 'Maine', value: 1329192 }, + { name: 'Maryland', value: 5884563 }, + { name: 'Massachusetts', value: 6646144 }, + { name: 'Michigan', value: 9883360 }, + { name: 'Minnesota', value: 5379139 }, + { name: 'Mississippi', value: 2984926 }, + { name: 'Missouri', value: 6021988 }, + { name: 'Montana', value: 1005141 }, + { name: 'Nebraska', value: 1855525 }, + { name: 'Nevada', value: 2758931 }, + { name: 'New Hampshire', value: 1320718 }, + { name: 'New Jersey', value: 8864590 }, + { name: 'New Mexico', value: 2085538 }, + { name: 'New York', value: 19570261 }, + { name: 'North Carolina', value: 9752073 }, + { name: 'North Dakota', value: 699628 }, + { name: 'Ohio', value: 11544225 }, + { name: 'Oklahoma', value: 3814820 }, + { name: 'Oregon', value: 3899353 }, + { name: 'Pennsylvania', value: 12763536 }, + { name: 'Rhode Island', value: 1050292 }, + { name: 'South Carolina', value: 4723723 }, + { name: 'South Dakota', value: 833354 }, + { name: 'Tennessee', value: 6456243 }, + { name: 'Texas', value: 26059203 }, + { name: 'Utah', value: 2855287 }, + { name: 'Vermont', value: 626011 }, + { name: 'Virginia', value: 8185867 }, + { name: 'Washington', value: 6897012 }, + { name: 'West Virginia', value: 1855413 }, + { name: 'Wisconsin', value: 5726398 }, + { name: 'Wyoming', value: 576412 }, + { name: 'Puerto Rico', value: 3667084 } + ] + } + ] + }; + myChart.setOption(option); +}); +export {}; diff --git a/testdata/map-usa.js b/testdata/map-usa.js new file mode 100644 index 0000000..b50b090 --- /dev/null +++ b/testdata/map-usa.js @@ -0,0 +1,141 @@ +/* +title: USA Population Estimates (2012) +category: map +titleCN: 2012 年美国人口统计 +*/ +myChart.showLoading(); +$.get(ROOT_PATH + '/data/asset/geo/USA.json', function (usaJson) { + myChart.hideLoading(); + echarts.registerMap('USA', usaJson, { + Alaska: { + left: -131, + top: 25, + width: 15 + }, + Hawaii: { + left: -110, + top: 28, + width: 5 + }, + 'Puerto Rico': { + left: -76, + top: 26, + width: 2 + } + }); + option = { + title: { + text: 'USA Population Estimates (2012)', + subtext: 'Data from www.census.gov', + sublink: 'http://www.census.gov/popest/data/datasets.html', + left: 'right' + }, + tooltip: { + trigger: 'item', + showDelay: 0, + transitionDuration: 0.2 + }, + visualMap: { + left: 'right', + min: 500000, + max: 38000000, + inRange: { + color: [ + '#313695', + '#4575b4', + '#74add1', + '#abd9e9', + '#e0f3f8', + '#ffffbf', + '#fee090', + '#fdae61', + '#f46d43', + '#d73027', + '#a50026' + ] + }, + text: ['High', 'Low'], + calculable: true + }, + toolbox: { + show: true, + //orient: 'vertical', + left: 'left', + top: 'top', + feature: { + dataView: { readOnly: false }, + restore: {}, + saveAsImage: {} + } + }, + series: [ + { + name: 'USA PopEstimates', + type: 'map', + roam: true, + map: 'USA', + emphasis: { + label: { + show: true + } + }, + data: [ + { name: 'Alabama', value: 4822023 }, + { name: 'Alaska', value: 731449 }, + { name: 'Arizona', value: 6553255 }, + { name: 'Arkansas', value: 2949131 }, + { name: 'California', value: 38041430 }, + { name: 'Colorado', value: 5187582 }, + { name: 'Connecticut', value: 3590347 }, + { name: 'Delaware', value: 917092 }, + { name: 'District of Columbia', value: 632323 }, + { name: 'Florida', value: 19317568 }, + { name: 'Georgia', value: 9919945 }, + { name: 'Hawaii', value: 1392313 }, + { name: 'Idaho', value: 1595728 }, + { name: 'Illinois', value: 12875255 }, + { name: 'Indiana', value: 6537334 }, + { name: 'Iowa', value: 3074186 }, + { name: 'Kansas', value: 2885905 }, + { name: 'Kentucky', value: 4380415 }, + { name: 'Louisiana', value: 4601893 }, + { name: 'Maine', value: 1329192 }, + { name: 'Maryland', value: 5884563 }, + { name: 'Massachusetts', value: 6646144 }, + { name: 'Michigan', value: 9883360 }, + { name: 'Minnesota', value: 5379139 }, + { name: 'Mississippi', value: 2984926 }, + { name: 'Missouri', value: 6021988 }, + { name: 'Montana', value: 1005141 }, + { name: 'Nebraska', value: 1855525 }, + { name: 'Nevada', value: 2758931 }, + { name: 'New Hampshire', value: 1320718 }, + { name: 'New Jersey', value: 8864590 }, + { name: 'New Mexico', value: 2085538 }, + { name: 'New York', value: 19570261 }, + { name: 'North Carolina', value: 9752073 }, + { name: 'North Dakota', value: 699628 }, + { name: 'Ohio', value: 11544225 }, + { name: 'Oklahoma', value: 3814820 }, + { name: 'Oregon', value: 3899353 }, + { name: 'Pennsylvania', value: 12763536 }, + { name: 'Rhode Island', value: 1050292 }, + { name: 'South Carolina', value: 4723723 }, + { name: 'South Dakota', value: 833354 }, + { name: 'Tennessee', value: 6456243 }, + { name: 'Texas', value: 26059203 }, + { name: 'Utah', value: 2855287 }, + { name: 'Vermont', value: 626011 }, + { name: 'Virginia', value: 8185867 }, + { name: 'Washington', value: 6897012 }, + { name: 'West Virginia', value: 1855413 }, + { name: 'Wisconsin', value: 5726398 }, + { name: 'Wyoming', value: 576412 }, + { name: 'Puerto Rico', value: 3667084 } + ] + } + ] + }; + myChart.setOption(option); +}); +export {}; diff --git a/testdata/mix-line-bar.js b/testdata/mix-line-bar.js new file mode 100644 index 0000000..1fa2ef7 --- /dev/null +++ b/testdata/mix-line-bar.js @@ -0,0 +1,97 @@ +/* +title: Mixed Line and Bar +category: bar +titleCN: 折柱混合 +difficulty: 4 +*/ +option = { + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'cross', + crossStyle: { + color: '#999' + } + } + }, + toolbox: { + feature: { + dataView: { show: true, readOnly: false }, + magicType: { show: true, type: ['line', 'bar'] }, + restore: { show: true }, + saveAsImage: { show: true } + } + }, + legend: { + data: ['Evaporation', 'Precipitation', 'Temperature'] + }, + xAxis: [ + { + type: 'category', + data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'], + axisPointer: { + type: 'shadow' + } + } + ], + yAxis: [ + { + type: 'value', + name: 'Precipitation', + min: 0, + max: 250, + interval: 50, + axisLabel: { + formatter: '{value} ml' + } + }, + { + type: 'value', + name: 'Temperature', + min: 0, + max: 25, + interval: 5, + axisLabel: { + formatter: '{value} °C' + } + } + ], + series: [ + { + name: 'Evaporation', + type: 'bar', + tooltip: { + valueFormatter: function (value) { + return value + ' ml'; + } + }, + data: [ + 2.0, 4.9, 7.0, 23.2, 25.6, 76.7, 135.6, 162.2, 32.6, 20.0, 6.4, 3.3 + ] + }, + { + name: 'Precipitation', + type: 'bar', + tooltip: { + valueFormatter: function (value) { + return value + ' ml'; + } + }, + data: [ + 2.6, 5.9, 9.0, 26.4, 28.7, 70.7, 175.6, 182.2, 48.7, 18.8, 6.0, 2.3 + ] + }, + { + name: 'Temperature', + type: 'line', + yAxisIndex: 1, + tooltip: { + valueFormatter: function (value) { + return value + ' °C'; + } + }, + data: [2.0, 2.2, 3.3, 4.5, 6.3, 10.2, 20.3, 23.4, 23.0, 16.5, 12.0, 6.2] + } + ] +}; +export {}; diff --git a/testdata/mix-line-bar.js.svg b/testdata/mix-line-bar.js.svg new file mode 100644 index 0000000..36149a1 --- /dev/null +++ b/testdata/mix-line-bar.js.svg @@ -0,0 +1,257 @@ + + + + + + + + + + + + + + +Precipitation +Temperature + + + + + + + + + +0 ml +50 ml +100 ml +150 ml +200 ml +250 ml +0 °C +5 °C +10 °C +15 °C +20 °C +25 °C +Mon +Tue +Wed +Thu +Fri +Sat +Sun + + + + + + + + + + + + + + + + + + + + + + + + + + +Evaporation + +Precipitation + + +Temperature + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/mix-timeline-finance.js b/testdata/mix-timeline-finance.js new file mode 100644 index 0000000..e9ff0db --- /dev/null +++ b/testdata/mix-timeline-finance.js @@ -0,0 +1,434 @@ +"use strict"; +/* +title: Finance Indices 2002 +category: bar +titleCN: 2002全国宏观经济指标 +difficulty: 6 +*/ +var dataMap = {}; +function dataFormatter(obj) { + // prettier-ignore + var pList = ['北京', '天津', '河北', '山西', '内蒙古', '辽宁', '吉林', '黑龙江', '上海', '江苏', '浙江', '安徽', '福建', '江西', '山东', '河南', '湖北', '湖南', '广东', '广西', '海南', '重庆', '四川', '贵州', '云南', '西藏', '陕西', '甘肃', '青海', '宁夏', '新疆']; + var temp; + for (var year = 2002; year <= 2011; year++) { + var max = 0; + var sum = 0; + temp = obj[year]; + for (var i = 0, l = temp.length; i < l; i++) { + max = Math.max(max, temp[i]); + sum += temp[i]; + obj[year][i] = { + name: pList[i], + value: temp[i] + }; + } + obj[year + 'max'] = Math.floor(max / 100) * 100; + obj[year + 'sum'] = sum; + } + return obj; +} +// prettier-ignore +dataMap.dataGDP = dataFormatter({ + //max : 60000, + 2011: [16251.93, 11307.28, 24515.76, 11237.55, 14359.88, 22226.7, 10568.83, 12582, 19195.69, 49110.27, 32318.85, 15300.65, 17560.18, 11702.82, 45361.85, 26931.03, 19632.26, 19669.56, 53210.28, 11720.87, 2522.66, 10011.37, 21026.68, 5701.84, 8893.12, 605.83, 12512.3, 5020.37, 1670.44, 2102.21, 6610.05], + 2010: [14113.58, 9224.46, 20394.26, 9200.86, 11672, 18457.27, 8667.58, 10368.6, 17165.98, 41425.48, 27722.31, 12359.33, 14737.12, 9451.26, 39169.92, 23092.36, 15967.61, 16037.96, 46013.06, 9569.85, 2064.5, 7925.58, 17185.48, 4602.16, 7224.18, 507.46, 10123.48, 4120.75, 1350.43, 1689.65, 5437.47], + 2009: [12153.03, 7521.85, 17235.48, 7358.31, 9740.25, 15212.49, 7278.75, 8587, 15046.45, 34457.3, 22990.35, 10062.82, 12236.53, 7655.18, 33896.65, 19480.46, 12961.1, 13059.69, 39482.56, 7759.16, 1654.21, 6530.01, 14151.28, 3912.68, 6169.75, 441.36, 8169.8, 3387.56, 1081.27, 1353.31, 4277.05], + 2008: [11115, 6719.01, 16011.97, 7315.4, 8496.2, 13668.58, 6426.1, 8314.37, 14069.87, 30981.98, 21462.69, 8851.66, 10823.01, 6971.05, 30933.28, 18018.53, 11328.92, 11555, 36796.71, 7021, 1503.06, 5793.66, 12601.23, 3561.56, 5692.12, 394.85, 7314.58, 3166.82, 1018.62, 1203.92, 4183.21], + 2007: [9846.81, 5252.76, 13607.32, 6024.45, 6423.18, 11164.3, 5284.69, 7104, 12494.01, 26018.48, 18753.73, 7360.92, 9248.53, 5800.25, 25776.91, 15012.46, 9333.4, 9439.6, 31777.01, 5823.41, 1254.17, 4676.13, 10562.39, 2884.11, 4772.52, 341.43, 5757.29, 2703.98, 797.35, 919.11, 3523.16], + 2006: [8117.78, 4462.74, 11467.6, 4878.61, 4944.25, 9304.52, 4275.12, 6211.8, 10572.24, 21742.05, 15718.47, 6112.5, 7583.85, 4820.53, 21900.19, 12362.79, 7617.47, 7688.67, 26587.76, 4746.16, 1065.67, 3907.23, 8690.24, 2338.98, 3988.14, 290.76, 4743.61, 2277.35, 648.5, 725.9, 3045.26], + 2005: [6969.52, 3905.64, 10012.11, 4230.53, 3905.03, 8047.26, 3620.27, 5513.7, 9247.66, 18598.69, 13417.68, 5350.17, 6554.69, 4056.76, 18366.87, 10587.42, 6590.19, 6596.1, 22557.37, 3984.1, 918.75, 3467.72, 7385.1, 2005.42, 3462.73, 248.8, 3933.72, 1933.98, 543.32, 612.61, 2604.19], + 2004: [6033.21, 3110.97, 8477.63, 3571.37, 3041.07, 6672, 3122.01, 4750.6, 8072.83, 15003.6, 11648.7, 4759.3, 5763.35, 3456.7, 15021.84, 8553.79, 5633.24, 5641.94, 18864.62, 3433.5, 819.66, 3034.58, 6379.63, 1677.8, 3081.91, 220.34, 3175.58, 1688.49, 466.1, 537.11, 2209.09], + 2003: [5007.21, 2578.03, 6921.29, 2855.23, 2388.38, 6002.54, 2662.08, 4057.4, 6694.23, 12442.87, 9705.02, 3923.11, 4983.67, 2807.41, 12078.15, 6867.7, 4757.45, 4659.99, 15844.64, 2821.11, 713.96, 2555.72, 5333.09, 1426.34, 2556.02, 185.09, 2587.72, 1399.83, 390.2, 445.36, 1886.35], + 2002: [4315, 2150.76, 6018.28, 2324.8, 1940.94, 5458.22, 2348.54, 3637.2, 5741.03, 10606.85, 8003.67, 3519.72, 4467.55, 2450.48, 10275.5, 6035.48, 4212.82, 4151.54, 13502.42, 2523.73, 642.73, 2232.86, 4725.01, 1243.43, 2312.82, 162.04, 2253.39, 1232.03, 340.65, 377.16, 1612.6] +}); +// prettier-ignore +dataMap.dataPI = dataFormatter({ + //max : 4000, + 2011: [136.27, 159.72, 2905.73, 641.42, 1306.3, 1915.57, 1277.44, 1701.5, 124.94, 3064.78, 1583.04, 2015.31, 1612.24, 1391.07, 3973.85, 3512.24, 2569.3, 2768.03, 2665.2, 2047.23, 659.23, 844.52, 2983.51, 726.22, 1411.01, 74.47, 1220.9, 678.75, 155.08, 184.14, 1139.03], + 2010: [124.36, 145.58, 2562.81, 554.48, 1095.28, 1631.08, 1050.15, 1302.9, 114.15, 2540.1, 1360.56, 1729.02, 1363.67, 1206.98, 3588.28, 3258.09, 2147, 2325.5, 2286.98, 1675.06, 539.83, 685.38, 2482.89, 625.03, 1108.38, 68.72, 988.45, 599.28, 134.92, 159.29, 1078.63], + 2009: [118.29, 128.85, 2207.34, 477.59, 929.6, 1414.9, 980.57, 1154.33, 113.82, 2261.86, 1163.08, 1495.45, 1182.74, 1098.66, 3226.64, 2769.05, 1795.9, 1969.69, 2010.27, 1458.49, 462.19, 606.8, 2240.61, 550.27, 1067.6, 63.88, 789.64, 497.05, 107.4, 127.25, 759.74], + 2008: [112.83, 122.58, 2034.59, 313.58, 907.95, 1302.02, 916.72, 1088.94, 111.8, 2100.11, 1095.96, 1418.09, 1158.17, 1060.38, 3002.65, 2658.78, 1780, 1892.4, 1973.05, 1453.75, 436.04, 575.4, 2216.15, 539.19, 1020.56, 60.62, 753.72, 462.27, 105.57, 118.94, 691.07], + 2007: [101.26, 110.19, 1804.72, 311.97, 762.1, 1133.42, 783.8, 915.38, 101.84, 1816.31, 986.02, 1200.18, 1002.11, 905.77, 2509.14, 2217.66, 1378, 1626.48, 1695.57, 1241.35, 361.07, 482.39, 2032, 446.38, 837.35, 54.89, 592.63, 387.55, 83.41, 97.89, 628.72], + 2006: [88.8, 103.35, 1461.81, 276.77, 634.94, 939.43, 672.76, 750.14, 93.81, 1545.05, 925.1, 1011.03, 865.98, 786.14, 2138.9, 1916.74, 1140.41, 1272.2, 1532.17, 1032.47, 323.48, 386.38, 1595.48, 382.06, 724.4, 50.9, 484.81, 334, 67.55, 79.54, 527.8], + 2005: [88.68, 112.38, 1400, 262.42, 589.56, 882.41, 625.61, 684.6, 90.26, 1461.51, 892.83, 966.5, 827.36, 727.37, 1963.51, 1892.01, 1082.13, 1100.65, 1428.27, 912.5, 300.75, 463.4, 1481.14, 368.94, 661.69, 48.04, 435.77, 308.06, 65.34, 72.07, 509.99], + 2004: [87.36, 105.28, 1370.43, 276.3, 522.8, 798.43, 568.69, 605.79, 83.45, 1367.58, 814.1, 950.5, 786.84, 664.5, 1778.45, 1649.29, 1020.09, 1022.45, 1248.59, 817.88, 278.76, 428.05, 1379.93, 334.5, 607.75, 44.3, 387.88, 286.78, 60.7, 65.33, 461.26], + 2003: [84.11, 89.91, 1064.05, 215.19, 420.1, 615.8, 488.23, 504.8, 81.02, 1162.45, 717.85, 749.4, 692.94, 560, 1480.67, 1198.7, 798.35, 886.47, 1072.91, 658.78, 244.29, 339.06, 1128.61, 298.69, 494.6, 40.7, 302.66, 237.91, 48.47, 55.63, 412.9], + 2002: [82.44, 84.21, 956.84, 197.8, 374.69, 590.2, 446.17, 474.2, 79.68, 1110.44, 685.2, 783.66, 664.78, 535.98, 1390, 1288.36, 707, 847.25, 1015.08, 601.99, 222.89, 317.87, 1047.95, 281.1, 463.44, 39.75, 282.21, 215.51, 47.31, 52.95, 305] +}); +// prettier-ignore +dataMap.dataSI = dataFormatter({ + //max : 26600, + 2011: [3752.48, 5928.32, 13126.86, 6635.26, 8037.69, 12152.15, 5611.48, 5962.41, 7927.89, 25203.28, 16555.58, 8309.38, 9069.2, 6390.55, 24017.11, 15427.08, 9815.94, 9361.99, 26447.38, 5675.32, 714.5, 5543.04, 11029.13, 2194.33, 3780.32, 208.79, 6935.59, 2377.83, 975.18, 1056.15, 3225.9], + 2010: [3388.38, 4840.23, 10707.68, 5234, 6367.69, 9976.82, 4506.31, 5025.15, 7218.32, 21753.93, 14297.93, 6436.62, 7522.83, 5122.88, 21238.49, 13226.38, 7767.24, 7343.19, 23014.53, 4511.68, 571, 4359.12, 8672.18, 1800.06, 3223.49, 163.92, 5446.1, 1984.97, 744.63, 827.91, 2592.15], + 2009: [2855.55, 3987.84, 8959.83, 3993.8, 5114, 7906.34, 3541.92, 4060.72, 6001.78, 18566.37, 11908.49, 4905.22, 6005.3, 3919.45, 18901.83, 11010.5, 6038.08, 5687.19, 19419.7, 3381.54, 443.43, 3448.77, 6711.87, 1476.62, 2582.53, 136.63, 4236.42, 1527.24, 575.33, 662.32, 1929.59], + 2008: [2626.41, 3709.78, 8701.34, 4242.36, 4376.19, 7158.84, 3097.12, 4319.75, 6085.84, 16993.34, 11567.42, 4198.93, 5318.44, 3554.81, 17571.98, 10259.99, 5082.07, 5028.93, 18502.2, 3037.74, 423.55, 3057.78, 5823.39, 1370.03, 2452.75, 115.56, 3861.12, 1470.34, 557.12, 609.98, 2070.76], + 2007: [2509.4, 2892.53, 7201.88, 3454.49, 3193.67, 5544.14, 2475.45, 3695.58, 5571.06, 14471.26, 10154.25, 3370.96, 4476.42, 2975.53, 14647.53, 8282.83, 4143.06, 3977.72, 16004.61, 2425.29, 364.26, 2368.53, 4648.79, 1124.79, 2038.39, 98.48, 2986.46, 1279.32, 419.03, 455.04, 1647.55], + 2006: [2191.43, 2457.08, 6110.43, 2755.66, 2374.96, 4566.83, 1915.29, 3365.31, 4969.95, 12282.89, 8511.51, 2711.18, 3695.04, 2419.74, 12574.03, 6724.61, 3365.08, 3187.05, 13469.77, 1878.56, 308.62, 1871.65, 3775.14, 967.54, 1705.83, 80.1, 2452.44, 1043.19, 331.91, 351.58, 1459.3], + 2005: [2026.51, 2135.07, 5271.57, 2357.04, 1773.21, 3869.4, 1580.83, 2971.68, 4381.2, 10524.96, 7164.75, 2245.9, 3175.92, 1917.47, 10478.62, 5514.14, 2852.12, 2612.57, 11356.6, 1510.68, 240.83, 1564, 3067.23, 821.16, 1426.42, 63.52, 1951.36, 838.56, 264.61, 281.05, 1164.79], + 2004: [1853.58, 1685.93, 4301.73, 1919.4, 1248.27, 3061.62, 1329.68, 2487.04, 3892.12, 8437.99, 6250.38, 1844.9, 2770.49, 1566.4, 8478.69, 4182.1, 2320.6, 2190.54, 9280.73, 1253.7, 205.6, 1376.91, 2489.4, 681.5, 1281.63, 52.74, 1553.1, 713.3, 211.7, 244.05, 914.47], + 2003: [1487.15, 1337.31, 3417.56, 1463.38, 967.49, 2898.89, 1098.37, 2084.7, 3209.02, 6787.11, 5096.38, 1535.29, 2340.82, 1204.33, 6485.05, 3310.14, 1956.02, 1777.74, 7592.78, 984.08, 175.82, 1135.31, 2014.8, 569.37, 1047.66, 47.64, 1221.17, 572.02, 171.92, 194.27, 719.54], + 2002: [1249.99, 1069.08, 2911.69, 1134.31, 754.78, 2609.85, 943.49, 1843.6, 2622.45, 5604.49, 4090.48, 1337.04, 2036.97, 941.77, 5184.98, 2768.75, 1709.89, 1523.5, 6143.4, 846.89, 148.88, 958.87, 1733.38, 481.96, 934.88, 32.72, 1007.56, 501.69, 144.51, 153.06, 603.15] +}); +// prettier-ignore +dataMap.dataTI = dataFormatter({ + //max : 25000, + 2011: [12363.18, 5219.24, 8483.17, 3960.87, 5015.89, 8158.98, 3679.91, 4918.09, 11142.86, 20842.21, 14180.23, 4975.96, 6878.74, 3921.2, 17370.89, 7991.72, 7247.02, 7539.54, 24097.7, 3998.33, 1148.93, 3623.81, 7014.04, 2781.29, 3701.79, 322.57, 4355.81, 1963.79, 540.18, 861.92, 2245.12], + 2010: [10600.84, 4238.65, 7123.77, 3412.38, 4209.03, 6849.37, 3111.12, 4040.55, 9833.51, 17131.45, 12063.82, 4193.69, 5850.62, 3121.4, 14343.14, 6607.89, 6053.37, 6369.27, 20711.55, 3383.11, 953.67, 2881.08, 6030.41, 2177.07, 2892.31, 274.82, 3688.93, 1536.5, 470.88, 702.45, 1766.69], + 2009: [9179.19, 3405.16, 6068.31, 2886.92, 3696.65, 5891.25, 2756.26, 3371.95, 8930.85, 13629.07, 9918.78, 3662.15, 5048.49, 2637.07, 11768.18, 5700.91, 5127.12, 5402.81, 18052.59, 2919.13, 748.59, 2474.44, 5198.8, 1885.79, 2519.62, 240.85, 3143.74, 1363.27, 398.54, 563.74, 1587.72], + 2008: [8375.76, 2886.65, 5276.04, 2759.46, 3212.06, 5207.72, 2412.26, 2905.68, 7872.23, 11888.53, 8799.31, 3234.64, 4346.4, 2355.86, 10358.64, 5099.76, 4466.85, 4633.67, 16321.46, 2529.51, 643.47, 2160.48, 4561.69, 1652.34, 2218.81, 218.67, 2699.74, 1234.21, 355.93, 475, 1421.38], + 2007: [7236.15, 2250.04, 4600.72, 2257.99, 2467.41, 4486.74, 2025.44, 2493.04, 6821.11, 9730.91, 7613.46, 2789.78, 3770, 1918.95, 8620.24, 4511.97, 3812.34, 3835.4, 14076.83, 2156.76, 528.84, 1825.21, 3881.6, 1312.94, 1896.78, 188.06, 2178.2, 1037.11, 294.91, 366.18, 1246.89], + 2006: [5837.55, 1902.31, 3895.36, 1846.18, 1934.35, 3798.26, 1687.07, 2096.35, 5508.48, 7914.11, 6281.86, 2390.29, 3022.83, 1614.65, 7187.26, 3721.44, 3111.98, 3229.42, 11585.82, 1835.12, 433.57, 1649.2, 3319.62, 989.38, 1557.91, 159.76, 1806.36, 900.16, 249.04, 294.78, 1058.16], + 2005: [4854.33, 1658.19, 3340.54, 1611.07, 1542.26, 3295.45, 1413.83, 1857.42, 4776.2, 6612.22, 5360.1, 2137.77, 2551.41, 1411.92, 5924.74, 3181.27, 2655.94, 2882.88, 9772.5, 1560.92, 377.17, 1440.32, 2836.73, 815.32, 1374.62, 137.24, 1546.59, 787.36, 213.37, 259.49, 929.41], + 2004: [4092.27, 1319.76, 2805.47, 1375.67, 1270, 2811.95, 1223.64, 1657.77, 4097.26, 5198.03, 4584.22, 1963.9, 2206.02, 1225.8, 4764.7, 2722.4, 2292.55, 2428.95, 8335.3, 1361.92, 335.3, 1229.62, 2510.3, 661.8, 1192.53, 123.3, 1234.6, 688.41, 193.7, 227.73, 833.36], + 2003: [3435.95, 1150.81, 2439.68, 1176.65, 1000.79, 2487.85, 1075.48, 1467.9, 3404.19, 4493.31, 3890.79, 1638.42, 1949.91, 1043.08, 4112.43, 2358.86, 2003.08, 1995.78, 7178.94, 1178.25, 293.85, 1081.35, 2189.68, 558.28, 1013.76, 96.76, 1063.89, 589.91, 169.81, 195.46, 753.91], + 2002: [2982.57, 997.47, 2149.75, 992.69, 811.47, 2258.17, 958.88, 1319.4, 3038.9, 3891.92, 3227.99, 1399.02, 1765.8, 972.73, 3700.52, 1978.37, 1795.93, 1780.79, 6343.94, 1074.85, 270.96, 956.12, 1943.68, 480.37, 914.5, 89.56, 963.62, 514.83, 148.83, 171.14, 704.5] +}); +// prettier-ignore +dataMap.dataEstate = dataFormatter({ + //max : 3600, + 2011: [1074.93, 411.46, 918.02, 224.91, 384.76, 876.12, 238.61, 492.1, 1019.68, 2747.89, 1677.13, 634.92, 911.16, 402.51, 1838.14, 987, 634.67, 518.04, 3321.31, 465.68, 208.71, 396.28, 620.62, 160.3, 222.31, 17.44, 398.03, 134.25, 29.05, 79.01, 176.22], + 2010: [1006.52, 377.59, 697.79, 192, 309.25, 733.37, 212.32, 391.89, 1002.5, 2600.95, 1618.17, 532.17, 679.03, 340.56, 1622.15, 773.23, 564.41, 464.21, 2813.95, 405.79, 188.33, 266.38, 558.56, 139.64, 223.45, 14.54, 315.95, 110.02, 25.41, 60.53, 143.44], + 2009: [1062.47, 308.73, 612.4, 173.31, 286.65, 605.27, 200.14, 301.18, 1237.56, 2025.39, 1316.84, 497.94, 656.61, 305.9, 1329.59, 622.98, 546.11, 400.11, 2470.63, 348.98, 121.76, 229.09, 548.14, 136.15, 205.14, 13.28, 239.92, 101.37, 23.05, 47.56, 115.23], + 2008: [844.59, 227.88, 513.81, 166.04, 273.3, 500.81, 182.7, 244.47, 939.34, 1626.13, 1052.03, 431.27, 506.98, 281.96, 1104.95, 512.42, 526.88, 340.07, 2057.45, 282.96, 95.6, 191.21, 453.63, 104.81, 195.48, 15.08, 193.27, 93.8, 19.96, 38.85, 89.79], + 2007: [821.5, 183.44, 467.97, 134.12, 191.01, 410.43, 153.03, 225.81, 958.06, 1365.71, 981.42, 366.57, 511.5, 225.96, 953.69, 447.44, 409.65, 301.8, 2029.77, 239.45, 67.19, 196.06, 376.84, 93.19, 193.59, 13.24, 153.98, 83.52, 16.98, 29.49, 91.28], + 2006: [658.3, 156.64, 397.14, 117.01, 136.5, 318.54, 131.01, 194.7, 773.61, 1017.91, 794.41, 281.98, 435.22, 184.67, 786.51, 348.7, 294.73, 254.81, 1722.07, 192.2, 44.45, 158.2, 336.2, 80.24, 165.92, 11.92, 125.2, 73.21, 15.17, 25.53, 68.9], + 2005: [493.73, 122.67, 330.87, 106, 98.75, 256.77, 112.29, 163.34, 715.97, 799.73, 688.86, 231.66, 331.8, 171.88, 664.9, 298.19, 217.17, 215.63, 1430.37, 165.05, 38.2, 143.88, 286.23, 76.38, 148.69, 10.02, 108.62, 63.78, 14.1, 22.97, 55.79], + 2004: [436.11, 106.14, 231.08, 95.1, 73.81, 203.1, 97.93, 137.74, 666.3, 534.17, 587.83, 188.28, 248.44, 167.2, 473.27, 236.44, 204.8, 191.5, 1103.75, 122.52, 30.64, 129.12, 264.3, 68.3, 116.54, 5.8, 95.9, 56.84, 13, 20.78, 53.55], + 2003: [341.88, 92.31, 185.19, 78.73, 61.05, 188.49, 91.99, 127.2, 487.82, 447.47, 473.16, 162.63, 215.84, 138.02, 418.21, 217.58, 176.8, 186.49, 955.66, 100.93, 25.14, 113.69, 231.72, 59.86, 103.79, 4.35, 83.9, 48.09, 11.41, 16.85, 47.84], + 2002: [298.02, 73.04, 140.89, 65.83, 51.48, 130.94, 76.11, 118.7, 384.86, 371.09, 360.63, 139.18, 188.09, 125.27, 371.13, 199.31, 145.17, 165.29, 808.16, 82.83, 21.45, 90.48, 210.82, 53.49, 95.68, 3.42, 77.68, 41.52, 9.74, 13.46, 43.04] +}); +// prettier-ignore +dataMap.dataFinancial = dataFormatter({ + //max : 3200, + 2011: [2215.41, 756.5, 746.01, 519.32, 447.46, 755.57, 207.65, 370.78, 2277.4, 2600.11, 2730.29, 503.85, 862.41, 357.44, 1640.41, 868.2, 674.57, 501.09, 2916.13, 445.37, 105.24, 704.66, 868.15, 297.27, 456.23, 31.7, 432.11, 145.05, 62.56, 134.18, 288.77], + 2010: [1863.61, 572.99, 615.42, 448.3, 346.44, 639.27, 190.12, 304.59, 1950.96, 2105.92, 2326.58, 396.17, 767.58, 241.49, 1361.45, 697.68, 561.27, 463.16, 2658.76, 384.53, 78.12, 496.56, 654.7, 231.51, 375.08, 27.08, 384.75, 100.54, 54.53, 97.87, 225.2], + 2009: [1603.63, 461.2, 525.67, 361.64, 291.1, 560.2, 180.83, 227.54, 1804.28, 1596.98, 1899.33, 359.6, 612.2, 165.1, 1044.9, 499.92, 479.11, 402.57, 2283.29, 336.82, 65.73, 389.97, 524.63, 194.44, 351.74, 23.17, 336.21, 88.27, 45.63, 75.54, 198.87], + 2008: [1519.19, 368.1, 420.74, 290.91, 219.09, 455.07, 147.24, 177.43, 1414.21, 1298.48, 1653.45, 313.81, 497.65, 130.57, 880.28, 413.83, 393.05, 334.32, 1972.4, 249.01, 47.33, 303.01, 411.14, 151.55, 277.66, 22.42, 287.16, 72.49, 36.54, 64.8, 171.97], + 2007: [1302.77, 288.17, 347.65, 218.73, 148.3, 386.34, 126.03, 155.48, 1209.08, 1054.25, 1251.43, 223.85, 385.84, 101.34, 734.9, 302.31, 337.27, 260.14, 1705.08, 190.73, 34.43, 247.46, 359.11, 122.25, 168.55, 11.51, 231.03, 61.6, 27.67, 51.05, 149.22], + 2006: [982.37, 186.87, 284.04, 169.63, 108.21, 303.41, 100.75, 74.17, 825.2, 653.25, 906.37, 166.01, 243.9, 79.75, 524.94, 219.72, 174.99, 204.72, 899.91, 129.14, 16.37, 213.7, 299.5, 89.43, 143.62, 6.44, 152.25, 50.51, 23.69, 36.99, 99.25], + 2005: [840.2, 147.4, 213.47, 135.07, 72.52, 232.85, 83.63, 35.03, 675.12, 492.4, 686.32, 127.05, 186.12, 69.55, 448.36, 181.74, 127.32, 162.37, 661.81, 91.93, 13.16, 185.18, 262.26, 73.67, 130.5, 7.57, 127.58, 44.73, 20.36, 32.25, 80.34], + 2004: [713.79, 136.97, 209.1, 110.29, 55.89, 188.04, 77.17, 32.2, 612.45, 440.5, 523.49, 94.1, 171, 65.1, 343.37, 170.82, 118.85, 118.64, 602.68, 74, 11.56, 162.38, 236.5, 60.3, 118.4, 5.4, 90.1, 42.99, 19, 27.92, 70.3], + 2003: [635.56, 112.79, 199.87, 118.48, 55.89, 145.38, 73.15, 32.2, 517.97, 392.11, 451.54, 87.45, 150.09, 64.31, 329.71, 165.11, 107.31, 99.35, 534.28, 61.59, 10.68, 147.04, 206.24, 48.01, 105.48, 4.74, 77.87, 42.31, 17.98, 24.8, 64.92], + 2002: [561.91, 76.86, 179.6, 124.1, 48.39, 137.18, 75.45, 31.6, 485.25, 368.86, 347.53, 81.85, 138.28, 76.51, 310.07, 158.77, 96.95, 92.43, 454.65, 35.86, 10.08, 134.52, 183.13, 41.45, 102.39, 2.81, 67.3, 42.08, 16.75, 21.45, 52.18] +}); +option = { + baseOption: { + timeline: { + axisType: 'category', + // realtime: false, + // loop: false, + autoPlay: true, + // currentIndex: 2, + playInterval: 1000, + // controlStyle: { + // position: 'left' + // }, + data: [ + '2002-01-01', + '2003-01-01', + '2004-01-01', + { + value: '2005-01-01', + tooltip: { + formatter: '{b} GDP达到一个高度' + }, + symbol: 'diamond', + symbolSize: 16 + }, + '2006-01-01', + '2007-01-01', + '2008-01-01', + '2009-01-01', + '2010-01-01', + { + value: '2011-01-01', + tooltip: { + formatter: function (params) { + return params.name + 'GDP达到又一个高度'; + } + }, + symbol: 'diamond', + symbolSize: 18 + } + ], + label: { + formatter: function (s) { + return new Date(s).getFullYear(); + } + } + }, + title: { + subtext: '数据来自国家统计局' + }, + tooltip: {}, + legend: { + left: 'right', + data: ['第一产业', '第二产业', '第三产业', 'GDP', '金融', '房地产'], + selected: { + GDP: false, + 金融: false, + 房地产: false + } + }, + calculable: true, + grid: { + top: 80, + bottom: 100, + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'shadow', + label: { + show: true, + formatter: function (params) { + return params.value.replace('\n', ''); + } + } + } + } + }, + xAxis: [ + { + type: 'category', + axisLabel: { interval: 0 }, + data: [ + '北京', + '\n天津', + '河北', + '\n山西', + '内蒙古', + '\n辽宁', + '吉林', + '\n黑龙江', + '上海', + '\n江苏', + '浙江', + '\n安徽', + '福建', + '\n江西', + '山东', + '\n河南', + '湖北', + '\n湖南', + '广东', + '\n广西', + '海南', + '\n重庆', + '四川', + '\n贵州', + '云南', + '\n西藏', + '陕西', + '\n甘肃', + '青海', + '\n宁夏', + '新疆' + ], + splitLine: { show: false } + } + ], + yAxis: [ + { + type: 'value', + name: 'GDP(亿元)' + } + ], + series: [ + { name: 'GDP', type: 'bar' }, + { name: '金融', type: 'bar' }, + { name: '房地产', type: 'bar' }, + { name: '第一产业', type: 'bar' }, + { name: '第二产业', type: 'bar' }, + { name: '第三产业', type: 'bar' }, + { + name: 'GDP占比', + type: 'pie', + center: ['75%', '35%'], + radius: '28%', + z: 100 + } + ] + }, + options: [ + { + title: { text: '2002全国宏观经济指标' }, + series: [ + { data: dataMap.dataGDP['2002'] }, + { data: dataMap.dataFinancial['2002'] }, + { data: dataMap.dataEstate['2002'] }, + { data: dataMap.dataPI['2002'] }, + { data: dataMap.dataSI['2002'] }, + { data: dataMap.dataTI['2002'] }, + { + data: [ + { name: '第一产业', value: dataMap.dataPI['2002sum'] }, + { name: '第二产业', value: dataMap.dataSI['2002sum'] }, + { name: '第三产业', value: dataMap.dataTI['2002sum'] } + ] + } + ] + }, + { + title: { text: '2003全国宏观经济指标' }, + series: [ + { data: dataMap.dataGDP['2003'] }, + { data: dataMap.dataFinancial['2003'] }, + { data: dataMap.dataEstate['2003'] }, + { data: dataMap.dataPI['2003'] }, + { data: dataMap.dataSI['2003'] }, + { data: dataMap.dataTI['2003'] }, + { + data: [ + { name: '第一产业', value: dataMap.dataPI['2003sum'] }, + { name: '第二产业', value: dataMap.dataSI['2003sum'] }, + { name: '第三产业', value: dataMap.dataTI['2003sum'] } + ] + } + ] + }, + { + title: { text: '2004全国宏观经济指标' }, + series: [ + { data: dataMap.dataGDP['2004'] }, + { data: dataMap.dataFinancial['2004'] }, + { data: dataMap.dataEstate['2004'] }, + { data: dataMap.dataPI['2004'] }, + { data: dataMap.dataSI['2004'] }, + { data: dataMap.dataTI['2004'] }, + { + data: [ + { name: '第一产业', value: dataMap.dataPI['2004sum'] }, + { name: '第二产业', value: dataMap.dataSI['2004sum'] }, + { name: '第三产业', value: dataMap.dataTI['2004sum'] } + ] + } + ] + }, + { + title: { text: '2005全国宏观经济指标' }, + series: [ + { data: dataMap.dataGDP['2005'] }, + { data: dataMap.dataFinancial['2005'] }, + { data: dataMap.dataEstate['2005'] }, + { data: dataMap.dataPI['2005'] }, + { data: dataMap.dataSI['2005'] }, + { data: dataMap.dataTI['2005'] }, + { + data: [ + { name: '第一产业', value: dataMap.dataPI['2005sum'] }, + { name: '第二产业', value: dataMap.dataSI['2005sum'] }, + { name: '第三产业', value: dataMap.dataTI['2005sum'] } + ] + } + ] + }, + { + title: { text: '2006全国宏观经济指标' }, + series: [ + { data: dataMap.dataGDP['2006'] }, + { data: dataMap.dataFinancial['2006'] }, + { data: dataMap.dataEstate['2006'] }, + { data: dataMap.dataPI['2006'] }, + { data: dataMap.dataSI['2006'] }, + { data: dataMap.dataTI['2006'] }, + { + data: [ + { name: '第一产业', value: dataMap.dataPI['2006sum'] }, + { name: '第二产业', value: dataMap.dataSI['2006sum'] }, + { name: '第三产业', value: dataMap.dataTI['2006sum'] } + ] + } + ] + }, + { + title: { text: '2007全国宏观经济指标' }, + series: [ + { data: dataMap.dataGDP['2007'] }, + { data: dataMap.dataFinancial['2007'] }, + { data: dataMap.dataEstate['2007'] }, + { data: dataMap.dataPI['2007'] }, + { data: dataMap.dataSI['2007'] }, + { data: dataMap.dataTI['2007'] }, + { + data: [ + { name: '第一产业', value: dataMap.dataPI['2007sum'] }, + { name: '第二产业', value: dataMap.dataSI['2007sum'] }, + { name: '第三产业', value: dataMap.dataTI['2007sum'] } + ] + } + ] + }, + { + title: { text: '2008全国宏观经济指标' }, + series: [ + { data: dataMap.dataGDP['2008'] }, + { data: dataMap.dataFinancial['2008'] }, + { data: dataMap.dataEstate['2008'] }, + { data: dataMap.dataPI['2008'] }, + { data: dataMap.dataSI['2008'] }, + { data: dataMap.dataTI['2008'] }, + { + data: [ + { name: '第一产业', value: dataMap.dataPI['2008sum'] }, + { name: '第二产业', value: dataMap.dataSI['2008sum'] }, + { name: '第三产业', value: dataMap.dataTI['2008sum'] } + ] + } + ] + }, + { + title: { text: '2009全国宏观经济指标' }, + series: [ + { data: dataMap.dataGDP['2009'] }, + { data: dataMap.dataFinancial['2009'] }, + { data: dataMap.dataEstate['2009'] }, + { data: dataMap.dataPI['2009'] }, + { data: dataMap.dataSI['2009'] }, + { data: dataMap.dataTI['2009'] }, + { + data: [ + { name: '第一产业', value: dataMap.dataPI['2009sum'] }, + { name: '第二产业', value: dataMap.dataSI['2009sum'] }, + { name: '第三产业', value: dataMap.dataTI['2009sum'] } + ] + } + ] + }, + { + title: { text: '2010全国宏观经济指标' }, + series: [ + { data: dataMap.dataGDP['2010'] }, + { data: dataMap.dataFinancial['2010'] }, + { data: dataMap.dataEstate['2010'] }, + { data: dataMap.dataPI['2010'] }, + { data: dataMap.dataSI['2010'] }, + { data: dataMap.dataTI['2010'] }, + { + data: [ + { name: '第一产业', value: dataMap.dataPI['2010sum'] }, + { name: '第二产业', value: dataMap.dataSI['2010sum'] }, + { name: '第三产业', value: dataMap.dataTI['2010sum'] } + ] + } + ] + }, + { + title: { text: '2011全国宏观经济指标' }, + series: [ + { data: dataMap.dataGDP['2011'] }, + { data: dataMap.dataFinancial['2011'] }, + { data: dataMap.dataEstate['2011'] }, + { data: dataMap.dataPI['2011'] }, + { data: dataMap.dataSI['2011'] }, + { data: dataMap.dataTI['2011'] }, + { + data: [ + { name: '第一产业', value: dataMap.dataPI['2011sum'] }, + { name: '第二产业', value: dataMap.dataSI['2011sum'] }, + { name: '第三产业', value: dataMap.dataTI['2011sum'] } + ] + } + ] + } + ] +}; diff --git a/testdata/mix-timeline-finance.js.svg b/testdata/mix-timeline-finance.js.svg new file mode 100644 index 0000000..3a9bbfc --- /dev/null +++ b/testdata/mix-timeline-finance.js.svg @@ -0,0 +1,1288 @@ + + + + + + + + + + +GDP(亿元) + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +0 +1,000 +2,000 +3,000 +4,000 +5,000 +6,000 +7,000 +北京 +天津 +河北 +山西 +内蒙古 +辽宁 +吉林 +黑龙江 +上海 +江苏 +浙江 +安徽 +福建 +江西 +山东 +河南 +湖北 +湖南 +广东 +广西 +海南 +重庆 +四川 +贵州 +云南 +西藏 +陕西 +甘肃 +青海 +宁夏 +新疆 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +2002-01-01 +2004-01-01 +2006-01-01 +2008-01-01 +2010-01-01 + +第一产业 + +第二产业 + +第三产业 + +GDP + +金融 + +房地产 + + + + + + + + + + + + + + +2002全国宏观经济指标 +数据来自国家统计局 + + + + + + +第一产业 +第二产业 +第三产业 + + + + + + + \ No newline at end of file diff --git a/testdata/mix-zoom-on-value.js b/testdata/mix-zoom-on-value.js new file mode 100644 index 0000000..310ed9b --- /dev/null +++ b/testdata/mix-zoom-on-value.js @@ -0,0 +1,95 @@ +/* +title: Mix Zoom On Value +category: bar +titleCN: 多数值轴轴缩放 +difficulty: 4 +*/ +myChart.showLoading(); +$.get(ROOT_PATH + '/data/asset/data/obama_budget_proposal_2012.list.json', function (obama_budget_2012) { + myChart.hideLoading(); + option = { + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'shadow', + label: { + show: true + } + } + }, + toolbox: { + show: true, + feature: { + mark: { show: true }, + dataView: { show: true, readOnly: false }, + magicType: { show: true, type: ['line', 'bar'] }, + restore: { show: true }, + saveAsImage: { show: true } + } + }, + calculable: true, + legend: { + data: ['Growth', 'Budget 2011', 'Budget 2012'], + itemGap: 5 + }, + grid: { + top: '12%', + left: '1%', + right: '10%', + containLabel: true + }, + xAxis: [ + { + type: 'category', + data: obama_budget_2012.names + } + ], + yAxis: [ + { + type: 'value', + name: 'Budget (million USD)', + axisLabel: { + formatter: function (a) { + a = +a; + return isFinite(a) ? echarts.format.addCommas(+a / 1000) : ''; + } + } + } + ], + dataZoom: [ + { + show: true, + start: 94, + end: 100 + }, + { + type: 'inside', + start: 94, + end: 100 + }, + { + show: true, + yAxisIndex: 0, + filterMode: 'empty', + width: 30, + height: '80%', + showDataShadow: false, + left: '93%' + } + ], + series: [ + { + name: 'Budget 2011', + type: 'bar', + data: obama_budget_2012.budget2011List + }, + { + name: 'Budget 2012', + type: 'bar', + data: obama_budget_2012.budget2012List + } + ] + }; + myChart.setOption(option); +}); +export {}; diff --git a/testdata/multiple-x-axis.js b/testdata/multiple-x-axis.js new file mode 100644 index 0000000..7550f4f --- /dev/null +++ b/testdata/multiple-x-axis.js @@ -0,0 +1,100 @@ +/* +title: Multiple X Axes +category: line +titleCN: 多 X 轴 +difficulty: 4 +*/ +const colors = ['#5470C6', '#EE6666']; +option = { + color: colors, + tooltip: { + trigger: 'none', + axisPointer: { + type: 'cross' + } + }, + legend: {}, + grid: { + top: 70, + bottom: 50 + }, + xAxis: [ + { + type: 'category', + axisTick: { + alignWithLabel: true + }, + axisLine: { + onZero: false, + lineStyle: { + color: colors[1] + } + }, + axisPointer: { + label: { + formatter: function (params) { + return ('Precipitation ' + + params.value + + (params.seriesData.length ? ':' + params.seriesData[0].data : '')); + } + } + }, + // prettier-ignore + data: ['2016-1', '2016-2', '2016-3', '2016-4', '2016-5', '2016-6', '2016-7', '2016-8', '2016-9', '2016-10', '2016-11', '2016-12'] + }, + { + type: 'category', + axisTick: { + alignWithLabel: true + }, + axisLine: { + onZero: false, + lineStyle: { + color: colors[0] + } + }, + axisPointer: { + label: { + formatter: function (params) { + return ('Precipitation ' + + params.value + + (params.seriesData.length ? ':' + params.seriesData[0].data : '')); + } + } + }, + // prettier-ignore + data: ['2015-1', '2015-2', '2015-3', '2015-4', '2015-5', '2015-6', '2015-7', '2015-8', '2015-9', '2015-10', '2015-11', '2015-12'] + } + ], + yAxis: [ + { + type: 'value' + } + ], + series: [ + { + name: 'Precipitation(2015)', + type: 'line', + xAxisIndex: 1, + smooth: true, + emphasis: { + focus: 'series' + }, + data: [ + 2.6, 5.9, 9.0, 26.4, 28.7, 70.7, 175.6, 182.2, 48.7, 18.8, 6.0, 2.3 + ] + }, + { + name: 'Precipitation(2016)', + type: 'line', + smooth: true, + emphasis: { + focus: 'series' + }, + data: [ + 3.9, 5.9, 11.1, 18.7, 48.3, 69.2, 231.6, 46.6, 55.4, 18.4, 10.3, 0.7 + ] + } + ] +}; +export {}; diff --git a/testdata/multiple-x-axis.js.svg b/testdata/multiple-x-axis.js.svg new file mode 100644 index 0000000..ffd140f --- /dev/null +++ b/testdata/multiple-x-axis.js.svg @@ -0,0 +1,112 @@ + + + + + + + + + + + + + + + + + + + + + + +0 +50 +100 +150 +200 +250 +2016-1 +2016-3 +2016-5 +2016-7 +2016-9 +2016-11 +2015-1 +2015-3 +2015-5 +2015-7 +2015-9 +2015-11 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Precipitation(2015) + + +Precipitation(2016) + + + + + + + + + + \ No newline at end of file diff --git a/testdata/multiple-y-axis.js b/testdata/multiple-y-axis.js new file mode 100644 index 0000000..5b83ebf --- /dev/null +++ b/testdata/multiple-y-axis.js @@ -0,0 +1,111 @@ +"use strict"; +/* +title: Multiple Y Axes +category: bar +titleCN: 多 Y 轴示例 +difficulty: 4 +*/ +const colors = ['#5470C6', '#91CC75', '#EE6666']; +option = { + color: colors, + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'cross' + } + }, + grid: { + right: '20%' + }, + toolbox: { + feature: { + dataView: { show: true, readOnly: false }, + restore: { show: true }, + saveAsImage: { show: true } + } + }, + legend: { + data: ['Evaporation', 'Precipitation', 'Temperature'] + }, + xAxis: [ + { + type: 'category', + axisTick: { + alignWithLabel: true + }, + // prettier-ignore + data: ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'] + } + ], + yAxis: [ + { + type: 'value', + name: 'Evaporation', + position: 'right', + alignTicks: true, + axisLine: { + show: true, + lineStyle: { + color: colors[0] + } + }, + axisLabel: { + formatter: '{value} ml' + } + }, + { + type: 'value', + name: 'Precipitation', + position: 'right', + alignTicks: true, + offset: 80, + axisLine: { + show: true, + lineStyle: { + color: colors[1] + } + }, + axisLabel: { + formatter: '{value} ml' + } + }, + { + type: 'value', + name: '温度', + position: 'left', + alignTicks: true, + axisLine: { + show: true, + lineStyle: { + color: colors[2] + } + }, + axisLabel: { + formatter: '{value} °C' + } + } + ], + series: [ + { + name: 'Evaporation', + type: 'bar', + data: [ + 2.0, 4.9, 7.0, 23.2, 25.6, 76.7, 135.6, 162.2, 32.6, 20.0, 6.4, 3.3 + ] + }, + { + name: 'Precipitation', + type: 'bar', + yAxisIndex: 1, + data: [ + 2.6, 5.9, 9.0, 26.4, 28.7, 70.7, 175.6, 182.2, 48.7, 18.8, 6.0, 2.3 + ] + }, + { + name: 'Temperature', + type: 'line', + yAxisIndex: 2, + data: [2.0, 2.2, 3.3, 4.5, 6.3, 10.2, 20.3, 23.4, 23.0, 16.5, 12.0, 6.2] + } + ] +}; diff --git a/testdata/multiple-y-axis.js.svg b/testdata/multiple-y-axis.js.svg new file mode 100644 index 0000000..edf5400 --- /dev/null +++ b/testdata/multiple-y-axis.js.svg @@ -0,0 +1,411 @@ + + + + + + + + + + + + + + + + + + + + + + + + +Evaporation + +Precipitation + +温度 + + + + + + + + + + + + + +0 ml +30 ml +60 ml +90 ml +120 ml +150 ml +180 ml +0 ml +50 ml +100 ml +150 ml +200 ml +250 ml +300 ml +0 °C +5 °C +10 °C +15 °C +20 °C +25 °C +30 °C +Jan +Feb +Mar +Apr +May +Jun +Jul +Aug +Sep +Oct +Nov +Dec + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Evaporation + +Precipitation + + +Temperature + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/parallel-aqi.js b/testdata/parallel-aqi.js new file mode 100644 index 0000000..ffa8455 --- /dev/null +++ b/testdata/parallel-aqi.js @@ -0,0 +1,222 @@ +/* +title: Parallel Aqi +category: parallel +titleCN: AQI 分布(平行坐标) +difficulty: 2 +*/ +// Schema: +// date,AQIindex,PM2.5,PM10,CO,NO2,SO2 +const dataBJ = [ + [1, 55, 9, 56, 0.46, 18, 6, '良'], + [2, 25, 11, 21, 0.65, 34, 9, '优'], + [3, 56, 7, 63, 0.3, 14, 5, '良'], + [4, 33, 7, 29, 0.33, 16, 6, '优'], + [5, 42, 24, 44, 0.76, 40, 16, '优'], + [6, 82, 58, 90, 1.77, 68, 33, '良'], + [7, 74, 49, 77, 1.46, 48, 27, '良'], + [8, 78, 55, 80, 1.29, 59, 29, '良'], + [9, 267, 216, 280, 4.8, 108, 64, '重度污染'], + [10, 185, 127, 216, 2.52, 61, 27, '中度污染'], + [11, 39, 19, 38, 0.57, 31, 15, '优'], + [12, 41, 11, 40, 0.43, 21, 7, '优'], + [13, 64, 38, 74, 1.04, 46, 22, '良'], + [14, 108, 79, 120, 1.7, 75, 41, '轻度污染'], + [15, 108, 63, 116, 1.48, 44, 26, '轻度污染'], + [16, 33, 6, 29, 0.34, 13, 5, '优'], + [17, 94, 66, 110, 1.54, 62, 31, '良'], + [18, 186, 142, 192, 3.88, 93, 79, '中度污染'], + [19, 57, 31, 54, 0.96, 32, 14, '良'], + [20, 22, 8, 17, 0.48, 23, 10, '优'], + [21, 39, 15, 36, 0.61, 29, 13, '优'], + [22, 94, 69, 114, 2.08, 73, 39, '良'], + [23, 99, 73, 110, 2.43, 76, 48, '良'], + [24, 31, 12, 30, 0.5, 32, 16, '优'], + [25, 42, 27, 43, 1, 53, 22, '优'], + [26, 154, 117, 157, 3.05, 92, 58, '中度污染'], + [27, 234, 185, 230, 4.09, 123, 69, '重度污染'], + [28, 160, 120, 186, 2.77, 91, 50, '中度污染'], + [29, 134, 96, 165, 2.76, 83, 41, '轻度污染'], + [30, 52, 24, 60, 1.03, 50, 21, '良'], + [31, 46, 5, 49, 0.28, 10, 6, '优'] +]; +var dataGZ = [ + [1, 26, 37, 27, 1.163, 27, 13, '优'], + [2, 85, 62, 71, 1.195, 60, 8, '良'], + [3, 78, 38, 74, 1.363, 37, 7, '良'], + [4, 21, 21, 36, 0.634, 40, 9, '优'], + [5, 41, 42, 46, 0.915, 81, 13, '优'], + [6, 56, 52, 69, 1.067, 92, 16, '良'], + [7, 64, 30, 28, 0.924, 51, 2, '良'], + [8, 55, 48, 74, 1.236, 75, 26, '良'], + [9, 76, 85, 113, 1.237, 114, 27, '良'], + [10, 91, 81, 104, 1.041, 56, 40, '良'], + [11, 84, 39, 60, 0.964, 25, 11, '良'], + [12, 64, 51, 101, 0.862, 58, 23, '良'], + [13, 70, 69, 120, 1.198, 65, 36, '良'], + [14, 77, 105, 178, 2.549, 64, 16, '良'], + [15, 109, 68, 87, 0.996, 74, 29, '轻度污染'], + [16, 73, 68, 97, 0.905, 51, 34, '良'], + [17, 54, 27, 47, 0.592, 53, 12, '良'], + [18, 51, 61, 97, 0.811, 65, 19, '良'], + [19, 91, 71, 121, 1.374, 43, 18, '良'], + [20, 73, 102, 182, 2.787, 44, 19, '良'], + [21, 73, 50, 76, 0.717, 31, 20, '良'], + [22, 84, 94, 140, 2.238, 68, 18, '良'], + [23, 93, 77, 104, 1.165, 53, 7, '良'], + [24, 99, 130, 227, 3.97, 55, 15, '良'], + [25, 146, 84, 139, 1.094, 40, 17, '轻度污染'], + [26, 113, 108, 137, 1.481, 48, 15, '轻度污染'], + [27, 81, 48, 62, 1.619, 26, 3, '良'], + [28, 56, 48, 68, 1.336, 37, 9, '良'], + [29, 82, 92, 174, 3.29, 0, 13, '良'], + [30, 106, 116, 188, 3.628, 101, 16, '轻度污染'], + [31, 118, 50, 0, 1.383, 76, 11, '轻度污染'] +]; +var dataSH = [ + [1, 91, 45, 125, 0.82, 34, 23, '良'], + [2, 65, 27, 78, 0.86, 45, 29, '良'], + [3, 83, 60, 84, 1.09, 73, 27, '良'], + [4, 109, 81, 121, 1.28, 68, 51, '轻度污染'], + [5, 106, 77, 114, 1.07, 55, 51, '轻度污染'], + [6, 109, 81, 121, 1.28, 68, 51, '轻度污染'], + [7, 106, 77, 114, 1.07, 55, 51, '轻度污染'], + [8, 89, 65, 78, 0.86, 51, 26, '良'], + [9, 53, 33, 47, 0.64, 50, 17, '良'], + [10, 80, 55, 80, 1.01, 75, 24, '良'], + [11, 117, 81, 124, 1.03, 45, 24, '轻度污染'], + [12, 99, 71, 142, 1.1, 62, 42, '良'], + [13, 95, 69, 130, 1.28, 74, 50, '良'], + [14, 116, 87, 131, 1.47, 84, 40, '轻度污染'], + [15, 108, 80, 121, 1.3, 85, 37, '轻度污染'], + [16, 134, 83, 167, 1.16, 57, 43, '轻度污染'], + [17, 79, 43, 107, 1.05, 59, 37, '良'], + [18, 71, 46, 89, 0.86, 64, 25, '良'], + [19, 97, 71, 113, 1.17, 88, 31, '良'], + [20, 84, 57, 91, 0.85, 55, 31, '良'], + [21, 87, 63, 101, 0.9, 56, 41, '良'], + [22, 104, 77, 119, 1.09, 73, 48, '轻度污染'], + [23, 87, 62, 100, 1, 72, 28, '良'], + [24, 168, 128, 172, 1.49, 97, 56, '中度污染'], + [25, 65, 45, 51, 0.74, 39, 17, '良'], + [26, 39, 24, 38, 0.61, 47, 17, '优'], + [27, 39, 24, 39, 0.59, 50, 19, '优'], + [28, 93, 68, 96, 1.05, 79, 29, '良'], + [29, 188, 143, 197, 1.66, 99, 51, '中度污染'], + [30, 174, 131, 174, 1.55, 108, 50, '中度污染'], + [31, 187, 143, 201, 1.39, 89, 53, '中度污染'] +]; +var schema = [ + { name: 'date', index: 0, text: '日期' }, + { name: 'AQIindex', index: 1, text: 'AQI' }, + { name: 'PM25', index: 2, text: 'PM2.5' }, + { name: 'PM10', index: 3, text: 'PM10' }, + { name: 'CO', index: 4, text: ' CO' }, + { name: 'NO2', index: 5, text: 'NO2' }, + { name: 'SO2', index: 6, text: 'SO2' }, + { name: '等级', index: 7, text: '等级' } +]; +var lineStyle = { + width: 1, + opacity: 0.5 +}; +option = { + backgroundColor: '#333', + legend: { + bottom: 30, + data: ['Beijing', 'Shanghai', 'Guangzhou'], + itemGap: 20, + textStyle: { + color: '#fff', + fontSize: 14 + } + }, + tooltip: { + padding: 10, + backgroundColor: '#222', + borderColor: '#777', + borderWidth: 1 + }, + parallelAxis: [ + { + dim: 0, + name: schema[0].text, + inverse: true, + max: 31, + nameLocation: 'start' + }, + { dim: 1, name: schema[1].text }, + { dim: 2, name: schema[2].text }, + { dim: 3, name: schema[3].text }, + { dim: 4, name: schema[4].text }, + { dim: 5, name: schema[5].text }, + { dim: 6, name: schema[6].text }, + { + dim: 7, + name: schema[7].text, + type: 'category', + data: ['优', '良', '轻度污染', '中度污染', '重度污染', '严重污染'] + } + ], + visualMap: { + show: true, + min: 0, + max: 150, + dimension: 2, + inRange: { + color: ['#d94e5d', '#eac736', '#50a3ba'].reverse() + // colorAlpha: [0, 1] + } + }, + parallel: { + left: '5%', + right: '18%', + bottom: 100, + parallelAxisDefault: { + type: 'value', + name: 'AQI指数', + nameLocation: 'end', + nameGap: 20, + nameTextStyle: { + color: '#fff', + fontSize: 12 + }, + axisLine: { + lineStyle: { + color: '#aaa' + } + }, + axisTick: { + lineStyle: { + color: '#777' + } + }, + splitLine: { + show: false + }, + axisLabel: { + color: '#fff' + } + } + }, + series: [ + { + name: 'Beijing', + type: 'parallel', + lineStyle: lineStyle, + data: dataBJ + }, + { + name: 'Shanghai', + type: 'parallel', + lineStyle: lineStyle, + data: dataSH + }, + { + name: 'Guangzhou', + type: 'parallel', + lineStyle: lineStyle, + data: dataGZ + } + ] +}; +export {}; diff --git a/testdata/parallel-aqi.js.svg b/testdata/parallel-aqi.js.svg new file mode 100644 index 0000000..f791932 --- /dev/null +++ b/testdata/parallel-aqi.js.svg @@ -0,0 +1,494 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Beijing + +Shanghai + +Guangzhou + +日期 + +AQI + +PM2.5 + +PM10 + + CO + +NO2 + +SO2 + +等级 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +0 +5 +10 +15 +20 +25 +30 +31 +0 +50 +100 +150 +200 +250 +300 +0 +50 +100 +150 +200 +250 +0 +50 +100 +150 +200 +250 +300 +0 +1 +2 +3 +4 +5 +0 +20 +40 +60 +80 +100 +120 +140 +0 +20 +40 +60 +80 + + +轻度污染 +中度污染 +重度污染 +严重污染 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/parallel-nutrients.js b/testdata/parallel-nutrients.js new file mode 100644 index 0000000..338bd25 --- /dev/null +++ b/testdata/parallel-nutrients.js @@ -0,0 +1,172 @@ +/* +title: Parallel Nutrients +category: parallel +titleCN: 营养结构(平行坐标) +difficulty: 4 +*/ +const indices = { + name: 0, + group: 1, + id: 16 +}; +const schema = [ + { name: 'name', index: 0 }, + { name: 'group', index: 1 }, + { name: 'protein', index: 2 }, + { name: 'calcium', index: 3 }, + { name: 'sodium', index: 4 }, + { name: 'fiber', index: 5 }, + { name: 'vitaminc', index: 6 }, + { name: 'potassium', index: 7 }, + { name: 'carbohydrate', index: 8 }, + { name: 'sugars', index: 9 }, + { name: 'fat', index: 10 }, + { name: 'water', index: 11 }, + { name: 'calories', index: 12 }, + { name: 'saturated', index: 13 }, + { name: 'monounsat', index: 14 }, + { name: 'polyunsat', index: 15 }, + { name: 'id', index: 16 } +]; +const groupCategories = []; +const groupColors = []; +$.get(ROOT_PATH + '/data/asset/data/nutrients.json', function (data) { + normalizeData(data); + myChart.setOption((option = getOption(data))); +}); +function normalizeData(originData) { + const groupMap = {}; + originData.forEach(function (row) { + const groupName = row[indices.group]; + if (!groupMap.hasOwnProperty(groupName)) { + groupMap[groupName] = 1; + } + }); + originData.forEach(function (row) { + row.forEach(function (item, index) { + if (index !== indices.name && + index !== indices.group && + index !== indices.id) { + // Convert null to zero, as all of them under unit "g". + row[index] = parseFloat(item) || 0; + } + }); + }); + for (const groupName in groupMap) { + if (groupMap.hasOwnProperty(groupName)) { + groupCategories.push(groupName); + } + } + const hStep = Math.round(300 / (groupCategories.length - 1)); + for (var i = 0; i < groupCategories.length; i++) { + groupColors.push(echarts.color.modifyHSL('#5A94DF', hStep * i)); + } +} +function getOption(data) { + const lineStyle = { + width: 0.5, + opacity: 0.05 + }; + return { + backgroundColor: '#333', + tooltip: { + padding: 10, + backgroundColor: '#222', + borderColor: '#777', + borderWidth: 1 + }, + title: [ + { + text: 'Groups', + top: 0, + left: 0, + textStyle: { + color: '#fff' + } + } + ], + visualMap: { + show: true, + type: 'piecewise', + categories: groupCategories, + dimension: indices.group, + inRange: { + color: groupColors //['#d94e5d','#eac736','#50a3ba'] + }, + outOfRange: { + color: ['#ccc'] //['#d94e5d','#eac736','#50a3ba'] + }, + top: 20, + textStyle: { + color: '#fff' + }, + realtime: false + }, + parallelAxis: [ + { dim: 16, name: schema[16].name, scale: true, nameLocation: 'end' }, + { dim: 2, name: schema[2].name, nameLocation: 'end' }, + { dim: 4, name: schema[4].name, nameLocation: 'end' }, + { dim: 3, name: schema[3].name, nameLocation: 'end' }, + { dim: 5, name: schema[5].name, nameLocation: 'end' }, + { dim: 6, name: schema[6].name, nameLocation: 'end' }, + { dim: 7, name: schema[7].name, nameLocation: 'end' }, + { dim: 8, name: schema[8].name, nameLocation: 'end' }, + { dim: 9, name: schema[9].name, nameLocation: 'end' }, + { dim: 10, name: schema[10].name, nameLocation: 'end' }, + { dim: 11, name: schema[11].name, nameLocation: 'end' }, + { dim: 12, name: schema[12].name, nameLocation: 'end' }, + { dim: 13, name: schema[13].name, nameLocation: 'end' }, + { dim: 14, name: schema[14].name, nameLocation: 'end' }, + { dim: 15, name: schema[15].name, nameLocation: 'end' } + ], + parallel: { + left: 280, + top: 20, + // top: 150, + // height: 300, + width: 400, + layout: 'vertical', + parallelAxisDefault: { + type: 'value', + name: 'nutrients', + nameLocation: 'end', + nameGap: 20, + nameTextStyle: { + color: '#fff', + fontSize: 14 + }, + axisLine: { + lineStyle: { + color: '#aaa' + } + }, + axisTick: { + lineStyle: { + color: '#777' + } + }, + splitLine: { + show: false + }, + axisLabel: { + color: '#fff' + }, + realtime: false + } + }, + animation: false, + series: [ + { + name: 'nutrients', + type: 'parallel', + lineStyle: lineStyle, + inactiveOpacity: 0, + activeOpacity: 0.01, + progressive: 500, + smooth: true, + data: data + } + ] + }; +} +export {}; diff --git a/testdata/parallel-simple.js b/testdata/parallel-simple.js new file mode 100644 index 0000000..544a090 --- /dev/null +++ b/testdata/parallel-simple.js @@ -0,0 +1,31 @@ +/* +title: Basic Parallel +category: parallel +titleCN: 基础平行坐标 +difficulty: 1 +*/ +option = { + parallelAxis: [ + { dim: 0, name: 'Price' }, + { dim: 1, name: 'Net Weight' }, + { dim: 2, name: 'Amount' }, + { + dim: 3, + name: 'Score', + type: 'category', + data: ['Excellent', 'Good', 'OK', 'Bad'] + } + ], + series: { + type: 'parallel', + lineStyle: { + width: 4 + }, + data: [ + [12.99, 100, 82, 'Good'], + [9.99, 80, 77, 'OK'], + [20, 120, 60, 'Excellent'] + ] + } +}; +export {}; diff --git a/testdata/parallel-simple.js.svg b/testdata/parallel-simple.js.svg new file mode 100644 index 0000000..df1690d --- /dev/null +++ b/testdata/parallel-simple.js.svg @@ -0,0 +1,81 @@ + + + + + + + + +Price + +Net Weight + +Amount + +Score + + + + + + + + + + + + + + + + + + + + + + + +0 +5 +10 +15 +20 +0 +20 +40 +60 +80 +100 +120 +0 +20 +40 +60 +80 +100 +Excellent +Good +OK +Bad + + + + + + + \ No newline at end of file diff --git a/testdata/pictorialBar-bar-transition.js b/testdata/pictorialBar-bar-transition.js new file mode 100644 index 0000000..16ec504 --- /dev/null +++ b/testdata/pictorialBar-bar-transition.js @@ -0,0 +1,152 @@ +/* +title: Transition between pictorialBar and bar +category: pictorialBar, animation +titleCN: 象形主图变形为柱状图 +difficulty: 4 +videoStart: 2500 +videoEnd: 10000 +*/ +const pathSymbols = { + reindeer: 'path://M-22.788,24.521c2.08-0.986,3.611-3.905,4.984-5.892 c-2.686,2.782-5.047,5.884-9.102,7.312c-0.992,0.005-0.25-2.016,0.34-2.362l1.852-0.41c0.564-0.218,0.785-0.842,0.902-1.347 c2.133-0.727,4.91-4.129,6.031-6.194c1.748-0.7,4.443-0.679,5.734-2.293c1.176-1.468,0.393-3.992,1.215-6.557 c0.24-0.754,0.574-1.581,1.008-2.293c-0.611,0.011-1.348-0.061-1.959-0.608c-1.391-1.245-0.785-2.086-1.297-3.313 c1.684,0.744,2.5,2.584,4.426,2.586C-8.46,3.012-8.255,2.901-8.04,2.824c6.031-1.952,15.182-0.165,19.498-3.937 c1.15-3.933-1.24-9.846-1.229-9.938c0.008-0.062-1.314-0.004-1.803-0.258c-1.119-0.771-6.531-3.75-0.17-3.33 c0.314-0.045,0.943,0.259,1.439,0.435c-0.289-1.694-0.92-0.144-3.311-1.946c0,0-1.1-0.855-1.764-1.98 c-0.836-1.09-2.01-2.825-2.992-4.031c-1.523-2.476,1.367,0.709,1.816,1.108c1.768,1.704,1.844,3.281,3.232,3.983 c0.195,0.203,1.453,0.164,0.926-0.468c-0.525-0.632-1.367-1.278-1.775-2.341c-0.293-0.703-1.311-2.326-1.566-2.711 c-0.256-0.384-0.959-1.718-1.67-2.351c-1.047-1.187-0.268-0.902,0.521-0.07c0.789,0.834,1.537,1.821,1.672,2.023 c0.135,0.203,1.584,2.521,1.725,2.387c0.102-0.259-0.035-0.428-0.158-0.852c-0.125-0.423-0.912-2.032-0.961-2.083 c-0.357-0.852-0.566-1.908-0.598-3.333c0.4-2.375,0.648-2.486,0.549-0.705c0.014,1.143,0.031,2.215,0.602,3.247 c0.807,1.496,1.764,4.064,1.836,4.474c0.561,3.176,2.904,1.749,2.281-0.126c-0.068-0.446-0.109-2.014-0.287-2.862 c-0.18-0.849-0.219-1.688-0.113-3.056c0.066-1.389,0.232-2.055,0.277-2.299c0.285-1.023,0.4-1.088,0.408,0.135 c-0.059,0.399-0.131,1.687-0.125,2.655c0.064,0.642-0.043,1.768,0.172,2.486c0.654,1.928-0.027,3.496,1,3.514 c1.805-0.424,2.428-1.218,2.428-2.346c-0.086-0.704-0.121-0.843-0.031-1.193c0.221-0.568,0.359-0.67,0.312-0.076 c-0.055,0.287,0.031,0.533,0.082,0.794c0.264,1.197,0.912,0.114,1.283-0.782c0.15-0.238,0.539-2.154,0.545-2.522 c-0.023-0.617,0.285-0.645,0.309,0.01c0.064,0.422-0.248,2.646-0.205,2.334c-0.338,1.24-1.105,3.402-3.379,4.712 c-0.389,0.12-1.186,1.286-3.328,2.178c0,0,1.729,0.321,3.156,0.246c1.102-0.19,3.707-0.027,4.654,0.269 c1.752,0.494,1.531-0.053,4.084,0.164c2.26-0.4,2.154,2.391-1.496,3.68c-2.549,1.405-3.107,1.475-2.293,2.984 c3.484,7.906,2.865,13.183,2.193,16.466c2.41,0.271,5.732-0.62,7.301,0.725c0.506,0.333,0.648,1.866-0.457,2.86 c-4.105,2.745-9.283,7.022-13.904,7.662c-0.977-0.194,0.156-2.025,0.803-2.247l1.898-0.03c0.596-0.101,0.936-0.669,1.152-1.139 c3.16-0.404,5.045-3.775,8.246-4.818c-4.035-0.718-9.588,3.981-12.162,1.051c-5.043,1.423-11.449,1.84-15.895,1.111 c-3.105,2.687-7.934,4.021-12.115,5.866c-3.271,3.511-5.188,8.086-9.967,10.414c-0.986,0.119-0.48-1.974,0.066-2.385l1.795-0.618 C-22.995,25.682-22.849,25.035-22.788,24.521z', + plane: 'path://M1.112,32.559l2.998,1.205l-2.882,2.268l-2.215-0.012L1.112,32.559z M37.803,23.96 c0.158-0.838,0.5-1.509,0.961-1.904c-0.096-0.037-0.205-0.071-0.344-0.071c-0.777-0.005-2.068-0.009-3.047-0.009 c-0.633,0-1.217,0.066-1.754,0.18l2.199,1.804H37.803z M39.738,23.036c-0.111,0-0.377,0.325-0.537,0.924h1.076 C40.115,23.361,39.854,23.036,39.738,23.036z M39.934,39.867c-0.166,0-0.674,0.705-0.674,1.986s0.506,1.986,0.674,1.986 s0.672-0.705,0.672-1.986S40.102,39.867,39.934,39.867z M38.963,38.889c-0.098-0.038-0.209-0.07-0.348-0.073 c-0.082,0-0.174,0-0.268-0.001l-7.127,4.671c0.879,0.821,2.42,1.417,4.348,1.417c0.979,0,2.27-0.006,3.047-0.01 c0.139,0,0.25-0.034,0.348-0.072c-0.646-0.555-1.07-1.643-1.07-2.967C37.891,40.529,38.316,39.441,38.963,38.889z M32.713,23.96 l-12.37-10.116l-4.693-0.004c0,0,4,8.222,4.827,10.121H32.713z M59.311,32.374c-0.248,2.104-5.305,3.172-8.018,3.172H39.629 l-25.325,16.61L9.607,52.16c0,0,6.687-8.479,7.95-10.207c1.17-1.6,3.019-3.699,3.027-6.407h-2.138 c-5.839,0-13.816-3.789-18.472-5.583c-2.818-1.085-2.396-4.04-0.031-4.04h0.039l-3.299-11.371h3.617c0,0,4.352,5.696,5.846,7.5 c2,2.416,4.503,3.678,8.228,3.87h30.727c2.17,0,4.311,0.417,6.252,1.046c3.49,1.175,5.863,2.7,7.199,4.027 C59.145,31.584,59.352,32.025,59.311,32.374z M22.069,30.408c0-0.815-0.661-1.475-1.469-1.475c-0.812,0-1.471,0.66-1.471,1.475 s0.658,1.475,1.471,1.475C21.408,31.883,22.069,31.224,22.069,30.408z M27.06,30.408c0-0.815-0.656-1.478-1.466-1.478 c-0.812,0-1.471,0.662-1.471,1.478s0.658,1.477,1.471,1.477C26.404,31.885,27.06,31.224,27.06,30.408z M32.055,30.408 c0-0.815-0.66-1.475-1.469-1.475c-0.808,0-1.466,0.66-1.466,1.475s0.658,1.475,1.466,1.475 C31.398,31.883,32.055,31.224,32.055,30.408z M37.049,30.408c0-0.815-0.658-1.478-1.467-1.478c-0.812,0-1.469,0.662-1.469,1.478 s0.656,1.477,1.469,1.477C36.389,31.885,37.049,31.224,37.049,30.408z M42.039,30.408c0-0.815-0.656-1.478-1.465-1.478 c-0.811,0-1.469,0.662-1.469,1.478s0.658,1.477,1.469,1.477C41.383,31.885,42.039,31.224,42.039,30.408z M55.479,30.565 c-0.701-0.436-1.568-0.896-2.627-1.347c-0.613,0.289-1.551,0.476-2.73,0.476c-1.527,0-1.639,2.263,0.164,2.316 C52.389,32.074,54.627,31.373,55.479,30.565z', + train: 'path://M67.335,33.596L67.335,33.596c-0.002-1.39-1.153-3.183-3.328-4.218h-9.096v-2.07h5.371 c-4.939-2.07-11.199-4.141-14.89-4.141H19.72v12.421v5.176h38.373c4.033,0,8.457-1.035,9.142-5.176h-0.027 c0.076-0.367,0.129-0.751,0.129-1.165L67.335,33.596L67.335,33.596z M27.999,30.413h-3.105v-4.141h3.105V30.413z M35.245,30.413 h-3.104v-4.141h3.104V30.413z M42.491,30.413h-3.104v-4.141h3.104V30.413z M49.736,30.413h-3.104v-4.141h3.104V30.413z M14.544,40.764c1.143,0,2.07-0.927,2.07-2.07V35.59V25.237c0-1.145-0.928-2.07-2.07-2.07H-9.265c-1.143,0-2.068,0.926-2.068,2.07 v10.351v3.105c0,1.144,0.926,2.07,2.068,2.07H14.544L14.544,40.764z M8.333,26.272h3.105v4.141H8.333V26.272z M1.087,26.272h3.105 v4.141H1.087V26.272z M-6.159,26.272h3.105v4.141h-3.105V26.272z M-9.265,41.798h69.352v1.035H-9.265V41.798z', + ship: 'path://M16.678,17.086h9.854l-2.703,5.912c5.596,2.428,11.155,5.575,16.711,8.607c3.387,1.847,6.967,3.75,10.541,5.375 v-6.16l-4.197-2.763v-5.318L33.064,12.197h-11.48L20.43,15.24h-4.533l-1.266,3.286l0.781,0.345L16.678,17.086z M49.6,31.84 l0.047,1.273L27.438,20.998l0.799-1.734L49.6,31.84z M33.031,15.1l12.889,8.82l0.027,0.769L32.551,16.1L33.031,15.1z M22.377,14.045 h9.846l-1.539,3.365l-2.287-1.498h1.371l0.721-1.352h-2.023l-0.553,1.037l-0.541-0.357h-0.34l0.359-0.684h-2.025l-0.361,0.684 h-3.473L22.377,14.045z M23.695,20.678l-0.004,0.004h0.004V20.678z M24.828,18.199h-2.031l-0.719,1.358h2.029L24.828,18.199z M40.385,34.227c-12.85-7.009-25.729-14.667-38.971-12.527c1.26,8.809,9.08,16.201,8.213,24.328 c-0.553,4.062-3.111,0.828-3.303,7.137c15.799,0,32.379,0,48.166,0l0.066-4.195l1.477-7.23 C50.842,39.812,45.393,36.961,40.385,34.227z M13.99,35.954c-1.213,0-2.195-1.353-2.195-3.035c0-1.665,0.98-3.017,2.195-3.017 c1.219,0,2.195,1.352,2.195,3.017C16.186,34.604,15.213,35.954,13.99,35.954z M23.691,20.682h-2.02l-0.588,1.351h2.023 L23.691,20.682z M19.697,18.199l-0.721,1.358h2.025l0.727-1.358H19.697z', + car: 'path://M49.592,40.883c-0.053,0.354-0.139,0.697-0.268,0.963c-0.232,0.475-0.455,0.519-1.334,0.475 c-1.135-0.053-2.764,0-4.484,0.068c0,0.476,0.018,0.697,0.018,0.697c0.111,1.299,0.697,1.342,0.931,1.342h3.7 c0.326,0,0.628,0,0.861-0.154c0.301-0.196,0.43-0.772,0.543-1.78c0.017-0.146,0.025-0.336,0.033-0.56v-0.01 c0-0.068,0.008-0.154,0.008-0.25V41.58l0,0C49.6,41.348,49.6,41.09,49.592,40.883L49.592,40.883z M6.057,40.883 c0.053,0.354,0.137,0.697,0.268,0.963c0.23,0.475,0.455,0.519,1.334,0.475c1.137-0.053,2.762,0,4.484,0.068 c0,0.476-0.018,0.697-0.018,0.697c-0.111,1.299-0.697,1.342-0.93,1.342h-3.7c-0.328,0-0.602,0-0.861-0.154 c-0.309-0.18-0.43-0.772-0.541-1.78c-0.018-0.146-0.027-0.336-0.035-0.56v-0.01c0-0.068-0.008-0.154-0.008-0.25V41.58l0,0 C6.057,41.348,6.057,41.09,6.057,40.883L6.057,40.883z M49.867,32.766c0-2.642-0.344-5.224-0.482-5.507 c-0.104-0.207-0.766-0.749-2.271-1.773c-1.522-1.042-1.487-0.887-1.766-1.566c0.25-0.078,0.492-0.224,0.639-0.241 c0.326-0.034,0.345,0.274,1.023,0.274c0.68,0,2.152-0.18,2.453-0.48c0.301-0.303,0.396-0.405,0.396-0.672 c0-0.268-0.156-0.818-0.447-1.146c-0.293-0.327-1.541-0.49-2.273-0.585c-0.729-0.095-0.834,0-1.022,0.121 c-0.304,0.189-0.32,1.919-0.32,1.919l-0.713,0.018c-0.465-1.146-1.11-3.452-2.117-5.269c-1.103-1.979-2.256-2.599-2.737-2.754 c-0.474-0.146-0.904-0.249-4.131-0.576c-3.298-0.344-5.922-0.388-8.262-0.388c-2.342,0-4.967,0.052-8.264,0.388 c-3.229,0.336-3.66,0.43-4.133,0.576s-1.633,0.775-2.736,2.754c-1.006,1.816-1.652,4.123-2.117,5.269L9.87,23.109 c0,0-0.008-1.729-0.318-1.919c-0.189-0.121-0.293-0.225-1.023-0.121c-0.732,0.104-1.98,0.258-2.273,0.585 c-0.293,0.327-0.447,0.878-0.447,1.146c0,0.267,0.094,0.379,0.396,0.672c0.301,0.301,1.773,0.48,2.453,0.48 c0.68,0,0.697-0.309,1.023-0.274c0.146,0.018,0.396,0.163,0.637,0.241c-0.283,0.68-0.24,0.524-1.764,1.566 c-1.506,1.033-2.178,1.566-2.271,1.773c-0.139,0.283-0.482,2.865-0.482,5.508s0.189,5.02,0.189,5.86c0,0.354,0,0.976,0.076,1.565 c0.053,0.354,0.129,0.697,0.268,0.966c0.232,0.473,0.447,0.516,1.334,0.473c1.137-0.051,2.779,0,4.477,0.07 c1.135,0.043,2.297,0.086,3.33,0.11c2.582,0.051,1.826-0.379,2.928-0.36c1.102,0.016,5.447,0.196,9.424,0.196 c3.976,0,8.332-0.182,9.423-0.196c1.102-0.019,0.346,0.411,2.926,0.36c1.033-0.018,2.195-0.067,3.332-0.11 c1.695-0.062,3.348-0.121,4.477-0.07c0.886,0.043,1.103,0,1.332-0.473c0.132-0.269,0.218-0.611,0.269-0.966 c0.086-0.592,0.078-1.213,0.078-1.565C49.678,37.793,49.867,35.408,49.867,32.766L49.867,32.766z M13.219,19.735 c0.412-0.964,1.652-2.9,2.256-3.244c0.145-0.087,1.426-0.491,4.637-0.706c2.953-0.198,6.217-0.276,7.73-0.276 c1.513,0,4.777,0.078,7.729,0.276c3.201,0.215,4.502,0.611,4.639,0.706c0.775,0.533,1.842,2.28,2.256,3.244 c0.412,0.965,0.965,2.858,0.861,3.116c-0.104,0.258,0.104,0.388-1.291,0.275c-1.387-0.103-10.088-0.216-14.185-0.216 c-4.088,0-12.789,0.113-14.184,0.216c-1.395,0.104-1.188-0.018-1.291-0.275C12.254,22.593,12.805,20.708,13.219,19.735 L13.219,19.735z M16.385,30.511c-0.619,0.155-0.988,0.491-1.764,0.482c-0.775,0-2.867-0.353-3.314-0.371 c-0.447-0.017-0.842,0.302-1.076,0.362c-0.23,0.06-0.688-0.104-1.377-0.318c-0.688-0.216-1.092-0.155-1.316-1.094 c-0.232-0.93,0-2.264,0-2.264c1.488-0.068,2.928,0.069,5.621,0.826c2.693,0.758,4.191,2.213,4.191,2.213 S17.004,30.357,16.385,30.511L16.385,30.511z M36.629,37.293c-1.23,0.164-6.386,0.207-8.794,0.207c-2.412,0-7.566-0.051-8.799-0.207 c-1.256-0.164-2.891-1.67-1.764-2.865c1.523-1.627,1.24-1.576,4.701-2.023C24.967,32.018,27.239,32,27.834,32 c0.584,0,2.865,0.025,5.859,0.404c3.461,0.447,3.178,0.396,4.699,2.022C39.521,35.623,37.887,37.129,36.629,37.293L36.629,37.293z M48.129,29.582c-0.232,0.93-0.629,0.878-1.318,1.093c-0.688,0.216-1.145,0.371-1.377,0.319c-0.231-0.053-0.627-0.371-1.074-0.361 c-0.448,0.018-2.539,0.37-3.313,0.37c-0.772,0-1.146-0.328-1.764-0.481c-0.621-0.154-0.966-0.154-0.966-0.154 s1.49-1.464,4.191-2.213c2.693-0.758,4.131-0.895,5.621-0.826C48.129,27.309,48.361,28.643,48.129,29.582L48.129,29.582z' +}; +const labelSetting = { + show: true, + position: 'right', + offset: [10, 0], + fontSize: 16 +}; +function makeOption(type, symbol) { + return { + title: { + text: 'Vehicles in X City' + }, + legend: { + data: ['2015', '2016'] + }, + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'shadow' + } + }, + grid: { + containLabel: true, + left: 20 + }, + yAxis: { + data: ['reindeer', 'ship', 'plane', 'train', 'car'], + inverse: true, + axisLine: { show: false }, + axisTick: { show: false }, + axisLabel: { + margin: 30, + fontSize: 14 + }, + axisPointer: { + label: { + show: true, + margin: 30 + } + } + }, + xAxis: { + splitLine: { show: false }, + axisLabel: { show: false }, + axisTick: { show: false }, + axisLine: { show: false } + }, + animationDurationUpdate: 500, + series: [ + { + name: '2015', + id: 'bar1', + type: type, + label: labelSetting, + symbolRepeat: true, + symbolSize: ['80%', '60%'], + barCategoryGap: '40%', + universalTransition: { + enabled: true, + delay: function (idx, total) { + return (idx / total) * 1000; + } + }, + data: [ + { + value: 157, + symbol: symbol || pathSymbols.reindeer + }, + { + value: 21, + symbol: symbol || pathSymbols.ship + }, + { + value: 66, + symbol: symbol || pathSymbols.plane + }, + { + value: 78, + symbol: symbol || pathSymbols.train + }, + { + value: 123, + symbol: symbol || pathSymbols.car + } + ] + }, + { + name: '2016', + id: 'bar2', + type: type, + barGap: '10%', + label: labelSetting, + symbolRepeat: true, + symbolSize: ['80%', '60%'], + universalTransition: { + enabled: true, + delay: function (idx, total) { + return (idx / total) * 1000; + } + }, + data: [ + { + value: 184, + symbol: symbol || pathSymbols.reindeer + }, + { + value: 29, + symbol: symbol || pathSymbols.ship + }, + { + value: 73, + symbol: symbol || pathSymbols.plane + }, + { + value: 91, + symbol: symbol || pathSymbols.train + }, + { + value: 95, + symbol: symbol || pathSymbols.car + } + ] + } + ] + }; +} +const options = [ + makeOption('pictorialBar'), + makeOption('bar'), + makeOption('pictorialBar', 'diamond') +]; +var optionIndex = 0; +option = options[optionIndex]; +setInterval(function () { + optionIndex = (optionIndex + 1) % options.length; + myChart.setOption(options[optionIndex]); +}, 2500); +export {}; diff --git a/testdata/pictorialBar-bar-transition.js.svg b/testdata/pictorialBar-bar-transition.js.svg new file mode 100644 index 0000000..c67160e --- /dev/null +++ b/testdata/pictorialBar-bar-transition.js.svg @@ -0,0 +1,1335 @@ + + +reindeer +ship +plane +train +car + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +157 +21 +66 +78 +123 +184 +29 +73 +91 +95 + + +2015 + +2016 + +Vehicles in X City + + \ No newline at end of file diff --git a/testdata/pictorialBar-body-fill.js b/testdata/pictorialBar-body-fill.js new file mode 100644 index 0000000..f2d9a21 --- /dev/null +++ b/testdata/pictorialBar-body-fill.js @@ -0,0 +1,164 @@ +/* +title: Water Content +category: pictorialBar +titleCN: 人体含水量 +*/ +const symbols = [ + 'path://M36.7,102.84c-1.17,2.54-2.99,4.98-3.39,7.63c-1.51,9.89-3.31,19.58-1.93,29.95 c0.95,7.15-2.91,14.82-3.57,22.35c-0.64,7.36-0.2,14.86,0.35,22.25c0.12,1.68,2.66,3.17,4.67,5.4c-0.6,0.82-1.5,2.22-2.58,3.48 c-0.96,1.12-1.96,2.35-3.21,3.04c-1.71,0.95-3.71,2.03-5.51,1.9c-1.18-0.08-3.04-2.13-3.16-3.43c-0.44-4.72,0-9.52-0.41-14.25 c-0.94-10.88-2.32-21.72-3.24-32.61c-0.49-5.84-1.63-12.01-0.35-17.54c3.39-14.56,2.8-28.84,0.36-43.4 c-2.71-16.16-1.06-32.4,0.54-48.59c0.91-9.22,4.62-17.36,8.53-25.57c1.32-2.77,1.88-6.84,0.87-9.62C21.89-3.77,18.09-11,14.7-18.38 c-0.56,0.1-1.13,0.21-1.69,0.31C10.17-11.52,6.29-5.2,4.71,1.65C2.05,13.21-4.42,22.3-11.43,31.28c-1.32,1.69-2.51,3.5-3.98,5.04 c-4.85,5.08-3.25,10.98-2.32,16.82c0.25,1.53,0.52,3.06,0.77,4.59c-0.53,0.22-1.07,0.43-1.6,0.65c-1.07-2.09-2.14-4.19-3.28-6.44 c-6.39,2.91-2.67,9.6-5.23,15.16c-1.61-3.31-2.77-5.68-3.93-8.06c0-0.33,0-0.67,0-1c6.96-16.08,14.63-31.9,20.68-48.31 C-5.24-4.07-2.03-18.55,2-32.73c0.36-1.27,0.75-2.53,0.98-3.82c1.36-7.75,4.19-10.23,11.88-10.38c1.76-0.04,3.52-0.21,5.76-0.35 c-0.55-3.95-1.21-7.3-1.45-10.68c-0.61-8.67,0.77-16.69,7.39-23.19c2.18-2.14,4.27-4.82,5.25-7.65c2.39-6.88,11.66-9,16.94-8.12 c5.92,0.99,12.15,7.93,12.16,14.12c0.01,9.89-5.19,17.26-12.24,23.68c-2.17,1.97-5.35,4.77-5.17,6.94c0.31,3.78,4.15,5.66,8.08,6.04 c1.82,0.18,3.7,0.37,5.49,0.1c5.62-0.85,8.8,2.17,10.85,6.73C73.38-27.19,78.46-14.9,84.2-2.91c1.52,3.17,4.52,5.91,7.41,8.09 c7.64,5.77,15.57,11.16,23.45,16.61c2.28,1.58,4.64,3.23,7.21,4.14c5.18,1.84,8.09,5.63,9.82,10.46c0.45,1.24,0.19,3.71-0.6,4.18 c-1.06,0.63-3.15,0.27-4.44-0.38c-7.05-3.54-12.84-8.88-19.14-13.5c-3.5-2.57-7.9-4-12.03-5.6c-9.44-3.66-17.73-8.42-22.5-18.09 c-2.43-4.94-6.09-9.27-9.69-14.61c-1.2,10.98-4.46,20.65,1.14,31.19c6.62,12.47,5.89,26.25,1.21,39.49 c-2.52,7.11-6.5,13.74-8.67,20.94c-1.91,6.33-2.2,13.15-3.23,19.75c-0.72,4.63-0.84,9.48-2.36,13.84 c-2.49,7.16-6.67,13.83-5.84,21.82c0.42,4.02,1.29,7.99,2.1,12.8c-3.74-0.49-7.47-0.4-10.67-1.66c-1.33-0.53-2.43-4.11-2.07-6.01 c1.86-9.94,3.89-19.69,0.07-29.74C34.55,108.63,36.19,105.52,36.7,102.84c1.25-8.45,2.51-16.89,3.71-24.9 c-0.83-0.58-0.85-0.59-0.87-0.61c-0.03,0.16-0.07,0.32-0.09,0.48C38.53,86.15,37.62,94.5,36.7,102.84z', + 'path://M40.02-99c2.07,1.21,4.26,2.25,6.19,3.66c5.94,4.34,8.23,12.57,4.95,19.79 c-3.21,7.08-6.82,14.03-10.86,20.67c-2.17,3.56-1.25,5.38,1.99,6.36c2.94,0.89,6.36,1.91,9.15,1.21c5.51-1.4,8.33,1.23,10.66,5.29 c4.71,8.22,9.72,16.29,13.84,24.8C81.06-6.65,89,0.4,99.56,5.17C109.82,9.8,120,14.7,129.85,20.15c4.72,2.61,9.09,6.37,10.24,12.97 c-2.89-1.93-5.2-3.75-7.78-5.04c-0.99-0.5-2.6,0.22-4.83,0.5c-5.36-9.35-16.8-9.4-26.74-12.62C91.68,13.04,81.82,11.37,75.66,3 c-5.98-8.13-11.61-16.52-17.4-24.79c-0.46-0.66-0.98-1.27-1.66-2.16c-3.21,7.75-6.78,15-9.12,22.63c-1.15,3.76-0.64,8.37,0.26,12.33 c0.81,3.59,3.01,6.92,4.87,10.22c6.73,11.95,2.41,22.89-2.91,33.75c-0.35,0.72-0.86,1.43-1.46,1.97 c-7.11,6.38-14.48,12.5-21.24,19.22c-2.08,2.07-3.1,5.7-3.62,8.77c-1.92,11.44-3.81,22.92-4.93,34.46 c-0.5,5.16,1.06,10.49,1.28,15.75c0.23,5.7,0.39,11.47-0.15,17.13c-1.15,12.11-2.83,24.17-4.11,36.27c-0.18,1.72,0.8,3.53,1.13,5.33 c0.88,4.76-0.22,6.23-4.71,5.17c-4.53-1.06-8.86-2.94-14.27-4.8c1.98-1.62,2.84-2.83,3.94-3.12c5.42-1.44,7-5.2,6.39-10.23 c-1.39-11.39-3.15-22.73-4.24-34.14c-0.53-5.56,0.16-11.23,0.24-16.85c0.06-4.49,0.01-8.97,0.01-14.72 c-2.79,1.53-5.2,2.27-6.79,3.83c-4.26,4.19-8.39,8.56-12.11,13.22c-1.55,1.95-2.19,4.76-2.79,7.29c-0.47,1.99,0.6,5.02-0.48,6.05 c-2.17,2.08-5.2,3.79-8.13,4.38c-3.61,0.73-7.49,0.18-12.26,0.18c6.34-8.69,11.91-16.11,17.22-23.71c3.29-4.71,6.23-9.67,9.24-14.58 c2.15-3.5,3.76-7.4,6.3-10.57c5.38-6.73,6.74-14.28,6.72-22.64C0.88,68.3,1.36,57.91,2.26,47.58c0.69-7.85,2.15-15.67,3.7-23.41 c0.77-3.83,2.89-7.39,3.72-11.22c1.83-8.4-1.9-16-4.38-23.95C2.96-5.34-0.31,0.12-1.5,6c-1.96,9.72-7.34,17.44-12.26,25.57 c-4.39,7.25-8.79,14.52-12.75,22.01c-2.64,5-4.5,10.41-6.83,15.92c-4.82-5.28-4.65-10.59-0.94-16.97 C-21.4,30.4-12.08,6.78-6.17-18.12c1.4-5.88,1.24-12.11,2.23-18.12c1.2-7.27,4.15-9.56,11.39-9.69c8.65-0.14,13.86-4.77,14.48-13.51 c0.35-5.01,0.16-10.11-0.28-15.12c-0.82-9.3,2.49-16.57,10.17-21.69c2.08-1.39,4.78-1.87,7.2-2.76C39.35-99,39.69-99,40.02-99z', + 'path://M-39,33.03c3.72-9.74,12.97-12.87,20.96-17.43c9.51-5.43,19.2-10.54,28.69-16 c1.77-1.02,3.35-2.85,4.33-4.67C21.44-17,27.82-28.95,33.95-41.04c2.13-4.2,4.95-6.01,9.7-6.09c3.68-0.06,7.52-0.92,10.97-2.25 c5.09-1.95,4.85-5.2,1.1-9.01c-5.12-5.21-10.89-10.1-13.23-17.54c-1.71-5.44,0.78-15.62,4.87-18.74 c4.12-3.15,12.55-3.84,16.69-0.12c3.39,3.04,6.44,7.27,7.8,11.56c1.96,6.16,3.31,12.9,2.99,19.29 c-0.45,9.21,6.35,16.71,15.73,16.97c7.94,0.21,9.27,0.78,10.69,8.61c5.23,28.73,19.4,53.73,32.21,79.33 c1.95,3.9,4.32,7.71,5.51,11.84c1.03,3.61,0.66,7.61,0.91,11.45c-0.73,0.14-1.45,0.28-2.18,0.42c-0.49-1.57-0.98-3.15-1.47-4.72 c-0.22,0.09-0.44,0.19-0.66,0.28c-0.85-2.62-1.7-5.24-2.74-8.45c-0.9,2.53-1.55,4.4-2.21,6.26c-0.41-0.03-0.83-0.06-1.24-0.08 c-0.19-2.78-0.35-5.56-0.56-8.34c-0.67-9.04-7.05-14.8-12.04-21.47c-5.2-6.95-10.31-14.09-14.36-21.73 c-3.56-6.7-5.59-14.21-9-21.29c-3.02,9.7-8.69,18.66-6.3,29.2c0.63,2.78,2.68,5.21,3.87,7.9c4.73,10.64,5.56,22.14,6.92,33.46 c1.21,10.13,1.88,20.38,1.96,30.59c0.06,7.02-1.67,14.04-1.85,21.08c-0.12,4.66,0.83,9.41,1.73,14.03 c1.21,6.22,2.81,12.36,4.28,18.52c0.3,1.26,0.69,2.51,1.23,3.69c3.92,8.54,7.79,17.1,11.88,25.55c1.3,2.67,3.24,5.04,5.07,7.83 c-2.19,0.86-3.64,1.76-5.17,1.97c-3.53,0.47-6.9,0.64-8.13-4.11c-1.71-6.58-3.78-13.07-5.87-19.54c-0.44-1.35-1.6-2.47-3.21-3.33 c0,16.17-7.35,32.86,6.17,48.11c-3.55,0-5.95,0.01-8.36,0c-7.59-0.03-7.66-0.54-7.72-7.64c-0.11-13.74-0.69-27.4-5.27-40.71 c-1.72-5.01-0.38-11.01-1.01-16.49c-0.67-5.79-2.11-11.48-3.08-17.24c-2.52-14.91-12.01-26.06-20.01-38.12 c-5.34-8.06-10.18-16.56-14.25-25.32c-5.18-11.16-5.52-22.61,1.24-33.57c3.68-5.96,3.12-12.27,1.17-18.55 c-2.5-8.03-5.22-16-8.05-24.61c-0.91,1.44-1.76,2.86-2.68,4.24C32.9-10.29,28.04-2.46,22.63,4.96c-5.34,7.34-14.22,8.45-22.08,10.9 c-8.48,2.65-17.2,4.46-23.03,12.01c-1.84,2.39-3.61,4.84-5.41,7.26c-0.39-0.17-0.78-0.34-1.16-0.51c0.81-2.38,1.62-4.76,2.43-7.14 c-0.2-0.22-0.39-0.44-0.59-0.66c-1.24,1.3-2.31,2.88-3.77,3.83c-2.54,1.66-5.33,2.94-8.02,4.37C-39,34.36-39,33.7-39,33.03z', + 'path://M80,100.49c0,5.23,0.13,10.46-0.03,15.69c-0.2,6.3-0.57,12.6-0.99,18.9 c-0.94,14.08-2.08,28.14-2.87,42.22c-0.41,7.29,4.95,14.31,12.03,16.62c1.22,0.4,2.43,0.84,3.65,2.16c-1.8,0.35-3.59,0.91-5.4,1 c-5.4,0.3-10.83,0.7-16.22,0.42c-1.44-0.07-3.7-2.25-3.95-3.74c-0.56-3.4,0.14-6.98-0.13-10.45c-0.77-9.67-0.8-19.56-3-28.92 c-1.97-8.39-2.18-16.07-0.02-24.35c1.28-4.91,1.34-10.48,0.5-15.52c-2.09-12.71-4.95-25.31-7.65-37.92 c-0.34-1.57-1.3-3.33-2.52-4.33c-3.71-3.01-7.37-6.38-11.62-8.38c-13.61-6.41-19.23-28.93-9.14-42.66 c5.41-7.36,5.32-13.85,0.74-21.4c-4.33-7.14-7.8-14.79-11.71-22.32C16.35-14.03,11.08-4.82,4.94,3.76 C1.8,8.13-2.43,12.19-7.04,14.93c-5.3,3.15-11.39,5.39-17.43,6.76c-9.05,2.05-14.31,7.59-17.67,15.68 c-0.43,1.05-1.13,1.99-1.76,2.95c-0.15,0.22-0.52,0.29-1.8,0.94c0.32-2.2,0.61-3.74,0.74-5.3c0.09-1.14-0.04-2.3-0.07-3.46 c-1.38,0.26-3.21,0.05-4.06,0.86c-2,1.91-3.5,4.33-5.27,6.49c-0.5,0.61-1.22,1.03-1.95,1.61c-1.02-5.19,1.42-10.27,7.11-13.9 C-36.09,19.24-22.82,11.2-9.77,2.82c2.12-1.36,3.99-3.6,5.17-5.85C1.52-14.72,7.44-26.52,13.29-38.35 c2.21-4.48,5.11-7.27,10.48-7.83c3.23-0.34,6.27-2.47,9.89-4.01c-4.23-4.83-8.31-8.74-11.49-13.28c-6.34-9.03-7.03-22.38,3.14-29.92 c6.9-5.12,13.79-4.47,20.85,0.69c6.15,4.5,6.15,11.2,7.55,17.13c1.32,5.6,0.82,11.84,0.1,17.67c-0.73,5.9-0.29,7.53,5.3,8.73 c0.96,0.21,1.99,0.17,2.98,0.19C72.51-48.76,74.44-47.06,76-36.52c1.83,12.35,2.1,25.03,6.99,36.77 c3.28,7.88,6.57,15.79,10.47,23.38c3.66,7.12,8.05,13.87,12.25,20.7c2.97,4.84,3.11,12.13-0.65,17c-1.8-2.05-3.45-3.92-5.01-5.7 c0.04-0.04-0.45,0.53-1.46,1.71C94.83,37.86,80.48,24.72,71.82,8.18c0.46,3.43,0.09,7.26,1.54,10.2c3.95,8.01,1.92,16.67,3.56,24.91 c1.63,8.22,1.87,16.74,3.79,24.88c0.88,3.73,4.32,6.84,6.58,10.25c1.09,1.65,2.2,3.29,3.17,5.01c4.84,8.58,9.09,17.55,14.58,25.69 c7.27,10.79,15.21,21.16,23.39,31.28c6.19,7.67,13.08,14.8,19.92,21.92c2.93,3.04,6.54,5.42,9.96,8.2 c-6.92,4.09-12.67,3.33-19.87-2.17c-1.82-1.39-3.76-2.79-5.87-3.62c-4.12-1.63-4.47-4.54-3.73-8.3c0.26-1.33,0.17-3.42-0.66-4.18 c-7.53-6.87-14.85-14.07-23.04-20.07c-7.75-5.68-12.26-13.2-16.11-21.54c-1.44-3.12-3.31-6.06-5.14-8.98 c-0.5-0.8-1.57-1.24-2.38-1.85C81.01,100.03,80.5,100.26,80,100.49z', + 'path://M-57,41.03c3.65-4.15,7.17-8.43,10.98-12.42c6.53-6.83,13.31-13.41,19.84-20.23 c1.76-1.84,3.51-3.98,4.4-6.31c3.8-9.99,6.99-20.23,10.99-30.14c2.74-6.79,5.65-13.62,12.37-17.95c4.17-2.68,5.12-7.31,4.29-11.96 c-0.3-1.67-2.02-3.08-3.35-4.97c-2.57,5.59-4.62,10.03-7.21,15.66c-4.79-6.43-9.76-10.83-11.68-16.31 c-1.77-5.04-1.18-11.44,0.04-16.86c1.27-5.62,5.24-9.71,12.03-9.7c1.55,0,3.1-1.68,4.66-2.55c9.3-5.22,20.47-1.53,25.73,7.59 c4.06,7.04,4.84,14.6,5.57,22.26c0.65,6.82-0.32,7.59-8.26,8.11c0,1.97,0,3.96,0,5.95c8.01-0.17,8.01,0.43,12.02,7.52 c2.09,3.69,6.34,6.1,9.41,9.29c2.48,2.58,7.04,3.14,7.24,8c0.29,6.79,0.46,6.78-6.43,11.08c0,15.78-0.02,31.49,0.03,47.2 c0,1.23,0.29,2.51,0.71,3.67c1.64,4.59,3.27,9.19,5.13,13.7c0.79,1.92,1.88,3.83,3.26,5.36c7.54,8.36,15.45,16.41,22.75,24.96 c5.09,5.97,9.05,12.9,14.18,18.84c9.73,11.26,19.47,22.59,30.08,33c8.84,8.67,18.88,16.13,28.51,23.98 c2.52,2.06,5.48,3.58,8.27,5.36c-4.02,3.54-10.94,4.01-16.34,1.62c-4.76-2.11-9.63-4.03-14.6-5.56c-5.6-1.72-6.59-3.72-4.42-9.32 c0.47-1.22-0.12-3.8-1.11-4.5c-7.36-5.15-14.66-10.53-22.55-14.78c-8.49-4.57-15.35-10.3-19.59-19.04 c-4.29-8.84-11.6-14.85-19.48-20.29c-3.2-2.21-6.43-4.4-9.64-6.6c-0.53,0.17-1.05,0.33-1.58,0.5c-0.11,11.17,0.12,22.36-0.45,33.51 c-0.29,5.72-2.33,11.33-3,17.05c-1.68,14.31-3.04,28.65-4.51,42.98c-0.34,3.34,0.94,5.76,4.12,7.18c6.09,2.73,12.14,5.56,18.61,9.26 c-3.96,0.36-7.93,0.72-11.89,1.08c-4.92,0.45-9.91,0.53-14.76,1.42c-6.96,1.28-9.68-0.99-8.69-8.02c1.73-12.28,0.67-24.36-1.4-36.56 c-1.08-6.36-2.02-14.02,0.49-19.47c5.62-12.19,2.4-23.48,0.01-35.2c-2.05-10.04-3.8-20.14-5.9-30.17c-0.32-1.52-1.72-2.91-2.87-4.13 c-3.6-3.83-8.03-7.09-10.85-11.41c-6.61-10.14-2.6-19.6,3.74-28.13c5.27-7.1,6.85-14.1,2.15-21.95c-3.79-6.34-7.53-12.7-11.38-19 c-0.46-0.75-1.41-1.2-2.77-2.3c-3.27,7.28-6.98,13.9-9.24,20.98c-3.58,11.2-12.11,17.05-21.53,22.3c-1.86,1.04-3.57,2.44-5.53,3.21 c-4.29,1.67-6.09,3.88-4.9,9.01c0.69,2.96-1.31,6.55-2.1,9.86c-0.5,0.03-0.99,0.06-1.49,0.08c-0.18-2.57-0.36-5.14-0.66-9.41 c-3.45,4.38-6.11,7.75-9.33,11.84c-1.07-2.08-1.61-3.13-2.15-4.18C-57,43.7-57,42.36-57,41.03z' +]; +const bodyMax = 150; +const labelSetting = { + show: true, + position: 'top', + offset: [0, -20], + formatter: function (param) { + return ((param.value / bodyMax) * 100).toFixed(0) + '%'; + }, + fontSize: 18, + fontFamily: 'Arial' +}; +const markLineSetting = { + symbol: 'none', + lineStyle: { + opacity: 0.3 + }, + data: [ + { + type: 'max', + label: { + formatter: 'max: {c}' + } + }, + { + type: 'min', + label: { + formatter: 'min: {c}' + } + } + ] +}; +option = { + tooltip: {}, + legend: { + data: ['typeA', 'typeB'], + selectedMode: 'single' + }, + xAxis: { + data: ['a', 'b', 'c', 'd', 'e'], + axisTick: { show: false }, + axisLine: { show: false }, + axisLabel: { show: false } + }, + yAxis: { + max: bodyMax, + offset: 20, + splitLine: { show: false } + }, + grid: { + top: 'center', + height: 230 + }, + markLine: { + z: -100 + }, + series: [ + { + name: 'typeA', + type: 'pictorialBar', + symbolClip: true, + symbolBoundingData: bodyMax, + label: labelSetting, + data: [ + { + value: 123, + symbol: symbols[0] + }, + { + value: 34, + symbol: symbols[1] + }, + { + value: 101, + symbol: symbols[2] + }, + { + value: 89, + symbol: symbols[3] + }, + { + value: 72, + symbol: symbols[4] + } + ], + markLine: markLineSetting, + z: 10 + }, + { + name: 'typeB', + type: 'pictorialBar', + symbolClip: true, + symbolBoundingData: bodyMax, + label: labelSetting, + data: [ + { + value: 12, + symbol: symbols[0] + }, + { + value: 44, + symbol: symbols[1] + }, + { + value: 131, + symbol: symbols[2] + }, + { + value: 33, + symbol: symbols[3] + }, + { + value: 142, + symbol: symbols[4] + } + ], + markLine: markLineSetting, + z: 10 + }, + { + name: 'full', + type: 'pictorialBar', + symbolBoundingData: bodyMax, + animationDuration: 0, + itemStyle: { + color: '#ccc' + }, + data: [ + { + value: 1, + symbol: symbols[0] + }, + { + value: 1, + symbol: symbols[1] + }, + { + value: 1, + symbol: symbols[2] + }, + { + value: 1, + symbol: symbols[3] + }, + { + value: 1, + symbol: symbols[4] + } + ] + } + ] +}; +export {}; diff --git a/testdata/pictorialBar-body-fill.js.svg b/testdata/pictorialBar-body-fill.js.svg new file mode 100644 index 0000000..09cffb8 --- /dev/null +++ b/testdata/pictorialBar-body-fill.js.svg @@ -0,0 +1,129 @@ + + + + +max: 123 +min: 34 +0 +30 +60 +90 +120 +150 + + + + + + + + + + + + +typeA + +typeB + + + + + + + + + + + + + + + + + + + + +123 +34 +101 +89 +72 + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/pictorialBar-dotted.js b/testdata/pictorialBar-dotted.js new file mode 100644 index 0000000..e7bee97 --- /dev/null +++ b/testdata/pictorialBar-dotted.js @@ -0,0 +1,103 @@ +/* +title: Dotted bar +category: pictorialBar +titleCN: 虚线柱状图效果 +*/ +// Generate data +let category = []; +let dottedBase = +new Date(); +let lineData = []; +let barData = []; +for (let i = 0; i < 20; i++) { + let date = new Date((dottedBase += 3600 * 24 * 1000)); + category.push([date.getFullYear(), date.getMonth() + 1, date.getDate()].join('-')); + let b = Math.random() * 200; + let d = Math.random() * 200; + barData.push(b); + lineData.push(d + b); +} +// option +option = { + backgroundColor: '#0f375f', + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'shadow' + } + }, + legend: { + data: ['line', 'bar'], + textStyle: { + color: '#ccc' + } + }, + xAxis: { + data: category, + axisLine: { + lineStyle: { + color: '#ccc' + } + } + }, + yAxis: { + splitLine: { show: false }, + axisLine: { + lineStyle: { + color: '#ccc' + } + } + }, + series: [ + { + name: 'line', + type: 'line', + smooth: true, + showAllSymbol: true, + symbol: 'emptyCircle', + symbolSize: 15, + data: lineData + }, + { + name: 'bar', + type: 'bar', + barWidth: 10, + itemStyle: { + borderRadius: 5, + color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [ + { offset: 0, color: '#14c8d4' }, + { offset: 1, color: '#43eec6' } + ]) + }, + data: barData + }, + { + name: 'line', + type: 'bar', + barGap: '-100%', + barWidth: 10, + itemStyle: { + color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [ + { offset: 0, color: 'rgba(20,200,212,0.5)' }, + { offset: 0.2, color: 'rgba(20,200,212,0.2)' }, + { offset: 1, color: 'rgba(20,200,212,0)' } + ]) + }, + z: -12, + data: lineData + }, + { + name: 'dotted', + type: 'pictorialBar', + symbol: 'rect', + itemStyle: { + color: '#0f375f' + }, + symbolRepeat: true, + symbolSize: [12, 4], + symbolMargin: 1, + z: -10, + data: lineData + } + ] +}; +export {}; diff --git a/testdata/pictorialBar-dotted.js.svg b/testdata/pictorialBar-dotted.js.svg new file mode 100644 index 0000000..62c8125 --- /dev/null +++ b/testdata/pictorialBar-dotted.js.svg @@ -0,0 +1,10838 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +0 +100 +200 +300 +400 +2024-1-21 +2024-1-24 +2024-1-27 +2024-1-30 +2024-2-2 +2024-2-5 +2024-2-8 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +line + +bar + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/pictorialBar-forest.js b/testdata/pictorialBar-forest.js new file mode 100644 index 0000000..a62aa0c --- /dev/null +++ b/testdata/pictorialBar-forest.js @@ -0,0 +1,107 @@ +/* +title: Expansion of forest +category: pictorialBar +titleCN: 森林的增长 +videoStart: 4000 +videoEnd: 10000 +*/ +const treeDataURI = 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABwAAAA2CAYAAADUOvnEAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAA5tJREFUeNrcWE1oE0EUnp0kbWyUpCiNYEpCFSpIMdpLRTD15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vfmJHXLaEvZUTseu/TeLc+xgAPhEAb/PbjO6PBaOTf6LQRh/dERde23zxLtOXbaKNhfq2L/1fAOPHDUhOpIf5485h7l+GNHHiSYPKE3Myz9sFxoJuAyazvwIMAItferha5LTqAAAAAElFTkSuQmCC'; +const beginYear = 2016; +const endYear = 2050; +const lineCount = 10; +// Basic option: +option = { + color: ['#e54035'], + xAxis: { + axisLine: { show: false }, + axisLabel: { show: false }, + axisTick: { show: false }, + splitLine: { show: false }, + name: beginYear + '', + nameLocation: 'middle', + nameGap: 40, + nameTextStyle: { + color: 'green', + fontSize: 30, + fontFamily: 'Arial' + }, + min: -2800, + max: 2800 + }, + yAxis: { + data: makeCategoryData(), + show: false + }, + grid: { + top: 'center', + height: 280 + }, + series: [ + { + name: 'all', + type: 'pictorialBar', + symbol: 'image://' + treeDataURI, + symbolSize: [30, 55], + symbolRepeat: true, + data: makeSeriesData(beginYear), + animationEasing: 'elasticOut' + }, + { + name: 'all', + type: 'pictorialBar', + symbol: 'image://' + treeDataURI, + symbolSize: [30, 55], + symbolRepeat: true, + data: makeSeriesData(beginYear, true), + animationEasing: 'elasticOut' + } + ] +}; +// Make fake data. +function makeCategoryData() { + var categoryData = []; + for (var i = 0; i < lineCount; i++) { + categoryData.push(i + 'a'); + } + return categoryData; +} +function makeSeriesData(year, negative) { + // make a fake value just for demo. + const r = (year - beginYear + 1) * 10; + const seriesData = []; + for (let i = 0; i < lineCount; i++) { + let sign = negative ? -1 * (i % 3 ? 0.9 : 1) : 1 * ((i + 1) % 3 ? 0.9 : 1); + seriesData.push({ + value: sign * + (year <= beginYear + 1 + ? Math.abs(i - lineCount / 2 + 0.5) < lineCount / 5 + ? 5 + : 0 + : (lineCount - Math.abs(i - lineCount / 2 + 0.5)) * r), + symbolOffset: i % 2 ? ['50%', 0] : undefined + }); + } + return seriesData; +} +// Set dynamic data. +var currentYear = beginYear; +setInterval(function () { + currentYear++; + if (currentYear > endYear) { + currentYear = beginYear; + } + myChart.setOption({ + xAxis: { + name: currentYear + }, + series: [ + { + data: makeSeriesData(currentYear) + }, + { + data: makeSeriesData(currentYear, true) + } + ] + }); +}, 800); +export {}; diff --git a/testdata/pictorialBar-forest.js.svg b/testdata/pictorialBar-forest.js.svg new file mode 100644 index 0000000..53e5740 --- /dev/null +++ b/testdata/pictorialBar-forest.js.svg @@ -0,0 +1,124 @@ + + +2016 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/pictorialBar-hill.js b/testdata/pictorialBar-hill.js new file mode 100644 index 0000000..69cc2d4 --- /dev/null +++ b/testdata/pictorialBar-hill.js @@ -0,0 +1,128 @@ +/* +title: Wish List and Mountain Height +category: pictorialBar +titleCN: 圣诞愿望清单和山峰高度 +videoStart: 0 +videoEnd: 2000 +*/ +var paperDataURI = 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAJgAAAAyCAYAAACgRRKpAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAB6FJREFUeNrsnE9y2zYYxUmRkig7spVdpx3Hdqb7ZNeFO2PdoD1Cj9DeoEdKbmDPeNFNW7lu0y7tRZvsYqfjWhL/qPgggoIggABIQKQkwsOhE5sQCfzw3uNHJu5sNnOaZq29RttolwfAbxgwChO9nad//4C2C7S9Sfe3uzQobqNghdoJBdIw3R8qHnvNANcA1sBUGCaV9pYC7rYBbLvbgAFpaBgmWbujlO1NA9h2wQTbcdHOoih2ZujLa7WcFtoMtUsKuFEDWL3bkAHq2GTnT+OJkyTzsXRd1/G8FoYN9vBnQ+pGZ7f7BrDqYSLbq6IdxXGM96BKIlBgDP97mgj7aLXcDLa8fgqoGwFu1ABmvzwwLAuTTJmw/SFIfG/ZBmEMIwRiHCVOnCTSPkk/BDoD7YHJbvcNYOVgYmtNWo1cs0xJ8pQJDgXIfM9bscE4TrDyAWwETuEEpP0QSzWU365T0CpXtzoDdsJY3bmpjqfT0AlRK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', + tooltip: {}, + legend: { + textStyle: { color: '#ddd' } + }, + xAxis: [ + { + data: ['Christmas Wish List', '', 'Qomolangma', 'Kilimanjaro'], + axisTick: { show: false }, + axisLine: { show: false }, + axisLabel: { + margin: 20, + color: '#ddd', + fontSize: 14 + } + } + ], + yAxis: { + splitLine: { show: false }, + axisTick: { show: false }, + axisLine: { show: false }, + axisLabel: { show: false } + }, + markLine: { + z: -1 + }, + animationEasing: 'elasticOut', + series: [ + { + type: 'pictorialBar', + name: 'All', + emphasis: { + scale: true + }, + label: { + show: true, + position: 'top', + formatter: '{c} m', + fontSize: 16, + color: '#e54035' + }, + data: [ + { + value: 13000, + symbol: 'image://' + paperDataURI, + symbolRepeat: true, + symbolSize: ['130%', '20%'], + symbolOffset: [0, 10], + symbolMargin: '-30%', + animationDelay: function (dataIndex, params) { + return params.index * 30; + } + }, + { + value: '-', + symbol: 'none' + }, + { + value: 8844, + symbol: 'image://' + ROOT_PATH + '/data/asset/img/hill-Qomolangma.png', + symbolSize: ['200%', '105%'], + symbolPosition: 'end', + z: 10 + }, + { + value: 5895, + symbol: 'image://' + ROOT_PATH + '/data/asset/img/hill-Kilimanjaro.png', + symbolSize: ['200%', '105%'], + symbolPosition: 'end' + } + ], + markLine: { + symbol: ['none', 'none'], + label: { + show: false + }, + lineStyle: { + color: '#e54035', + width: 2 + }, + data: [ + { + yAxis: 8844 + } + ] + } + }, + { + name: 'All', + type: 'pictorialBar', + barGap: '-100%', + symbol: 'circle', + itemStyle: { + color: '#185491' + }, + silent: true, + symbolOffset: [0, '50%'], + z: -10, + data: [ + { + value: 1, + symbolSize: ['150%', 50] + }, + { + value: '-' + }, + { + value: 1, + symbolSize: ['200%', 50] + }, + { + value: 1, + symbolSize: ['200%', 50] + } + ] + } + ] +}; +export {}; diff --git a/testdata/pictorialBar-spirit.js b/testdata/pictorialBar-spirit.js new file mode 100644 index 0000000..07495c4 --- /dev/null +++ b/testdata/pictorialBar-spirit.js @@ -0,0 +1,115 @@ +/* +title: Spirits +category: pictorialBar +titleCN: 精灵 +*/ +const spirit = 'image://data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAHUAAACUCAYAAACtHGabAAAACXBIWXMAABcSAAAXEgFnn9JSAAAKTWlDQ1BQaG90b3Nob3AgSUNDIHByb2ZpbGUAAHjanVN3WJP3Fj7f92UPVkLY8LGXbIEAIiOsCMgQWaIQkgBhhBASQMWFiApWFBURnEhVxILVCkidiOKgKLhnQYqIWotVXDjuH9yntX167+3t+9f7vOec5/zOec8PgBESJpHmomoAOVKFPDrYH49PSMTJvYACFUjgBCAQ5svCZwXFAADwA3l4fnSwP/wBr28AAgBw1S4kEsfh/4O6UCZXACCRAOAiEucLAZBSAMguVMgUAMgYALBTs2QKAJQAAGx5fEIiAKoNAOz0ST4FANipk9wXANiiHKkIAI0BAJkoRyQCQLsAYFWBUiwCwMIAoKxAIi4EwK4BgFm2MkcCgL0FAHaOWJAPQGAAgJlCLMwAIDgCAEMeE80DIEwDoDDSv+CpX3CFuEgBAMDLlc2XS9IzFLiV0Bp38vDg4iHiwmyxQmEXKRBmCeQinJebIxNI5wNMzgwAABr50cH+OD+Q5+bk4eZm52zv9MWi/mvwbyI+IfHf/ryMAgQAEE7P79pf5eXWA3DHAbB1v2upWwDaVgBo3/ldM9sJoFoK0Hr5i3k4/EAenqFQyDwdHAoLC+0lYqG9MOOLPv8z4W/gi372/EAe/tt68ABxmkCZrcCjg/1xYW52rlKO58sEQjFu9+cj/seFf/2OKdHiNLFcLBWK8ViJuFAiTcd5uVKRRCHJleIS6X8y8R+W/QmTdw0ArIZPwE62B7XLbMB+7gECiw5Y0nYAQH7zLYwaC5EAEGc0Mnn3AACTv/mPQCsBAM2XpOMAALzoGFyolBdMxggAAESggSqwQQcMwRSswA6cwR28wBcCYQZEQAwkwDwQQgbkgBwKoRiWQRlUwDrYBLWwAxqgEZrhELTBMTgN5+ASXIHrcBcGYBiewhi8hgkEQcgIE2EhOogRYo7YIs4IF5mOBCJhSDSSgKQg6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AWg9nQOlGmo5gKrpIYrvQD60oWZLai9Qgg2FdhFqbJfUOWQ2gfPeEVJGKd2Cy/TDFdkP4B+Ndb25hSqDHAngNDLNAPUaBVAWtW8ViavoMoAW4TQbEGC+dVp0o6Cn/y3Zhti3kCNA9ksZM2teQzwEPjn4w0BGMp0OJ22UOOALhdAm0U/m7IEDoLy7ALA4Vwq8IaAmkQCFhoylacxfAoBAwB7JrLRbLf/HwBxI17fueoAtgAAAABJRU5ErkJggg=='; +var maxData = 2000; +option = { + tooltip: {}, + xAxis: { + max: maxData, + splitLine: { show: false }, + offset: 10, + axisLine: { + lineStyle: { + color: '#999' + } + }, + axisLabel: { + margin: 10 + } + }, + yAxis: { + data: ['2013', '2014', '2015', '2016'], + inverse: true, + axisTick: { show: false }, + axisLine: { show: false }, + axisLabel: { + margin: 10, + color: '#999', + fontSize: 16 + } + }, + grid: { + top: 'center', + height: 200, + left: 70, + right: 100 + }, + series: [ + { + // current data + type: 'pictorialBar', + symbol: spirit, + symbolRepeat: 'fixed', + symbolMargin: '5%', + symbolClip: true, + symbolSize: 30, + symbolBoundingData: maxData, + data: [891, 1220, 660, 1670], + markLine: { + symbol: 'none', + label: { + formatter: 'max: {c}', + position: 'start' + }, + lineStyle: { + color: 'green', + type: 'dotted', + opacity: 0.2, + width: 2 + }, + data: [ + { + type: 'max' + } + ] + }, + z: 10 + }, + { + // full data + type: 'pictorialBar', + itemStyle: { + opacity: 0.2 + }, + label: { + show: true, + formatter: function (params) { + return ((params.value / maxData) * 100).toFixed(1) + ' %'; + }, + position: 'right', + offset: [10, 0], + color: 'green', + fontSize: 18 + }, + animationDuration: 0, + symbolRepeat: 'fixed', + symbolMargin: '5%', + symbol: spirit, + symbolSize: 30, + symbolBoundingData: maxData, + data: [891, 1220, 660, 1670], + z: 5 + } + ] +}; +// Make dynamic data. +function random() { + return +(Math.random() * (maxData - 10)).toFixed(1); +} +setInterval(function () { + const dynamicData = [random(), random(), random(), random()]; + myChart.setOption({ + series: [ + { + data: dynamicData.slice() + }, + { + data: dynamicData.slice() + } + ] + }); +}, 3000); +export {}; diff --git a/testdata/pictorialBar-spirit.js.svg b/testdata/pictorialBar-spirit.js.svg new file mode 100644 index 0000000..b246fab --- /dev/null +++ b/testdata/pictorialBar-spirit.js.svg @@ -0,0 +1,264 @@ + + +2013 +2014 +2015 +2016 +0 +500 +1,000 +1,500 +2,000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +max: 1670 + + + + +891 +1220 +660 +1670 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/pictorialBar-vehicle.js b/testdata/pictorialBar-vehicle.js new file mode 100644 index 0000000..3aab8e5 --- /dev/null +++ b/testdata/pictorialBar-vehicle.js @@ -0,0 +1,121 @@ +/* +title: Vehicles +category: pictorialBar +titleCN: 交通工具 +*/ +const pathSymbols = { + reindeer: 'path://M-22.788,24.521c2.08-0.986,3.611-3.905,4.984-5.892 c-2.686,2.782-5.047,5.884-9.102,7.312c-0.992,0.005-0.25-2.016,0.34-2.362l1.852-0.41c0.564-0.218,0.785-0.842,0.902-1.347 c2.133-0.727,4.91-4.129,6.031-6.194c1.748-0.7,4.443-0.679,5.734-2.293c1.176-1.468,0.393-3.992,1.215-6.557 c0.24-0.754,0.574-1.581,1.008-2.293c-0.611,0.011-1.348-0.061-1.959-0.608c-1.391-1.245-0.785-2.086-1.297-3.313 c1.684,0.744,2.5,2.584,4.426,2.586C-8.46,3.012-8.255,2.901-8.04,2.824c6.031-1.952,15.182-0.165,19.498-3.937 c1.15-3.933-1.24-9.846-1.229-9.938c0.008-0.062-1.314-0.004-1.803-0.258c-1.119-0.771-6.531-3.75-0.17-3.33 c0.314-0.045,0.943,0.259,1.439,0.435c-0.289-1.694-0.92-0.144-3.311-1.946c0,0-1.1-0.855-1.764-1.98 c-0.836-1.09-2.01-2.825-2.992-4.031c-1.523-2.476,1.367,0.709,1.816,1.108c1.768,1.704,1.844,3.281,3.232,3.983 c0.195,0.203,1.453,0.164,0.926-0.468c-0.525-0.632-1.367-1.278-1.775-2.341c-0.293-0.703-1.311-2.326-1.566-2.711 c-0.256-0.384-0.959-1.718-1.67-2.351c-1.047-1.187-0.268-0.902,0.521-0.07c0.789,0.834,1.537,1.821,1.672,2.023 c0.135,0.203,1.584,2.521,1.725,2.387c0.102-0.259-0.035-0.428-0.158-0.852c-0.125-0.423-0.912-2.032-0.961-2.083 c-0.357-0.852-0.566-1.908-0.598-3.333c0.4-2.375,0.648-2.486,0.549-0.705c0.014,1.143,0.031,2.215,0.602,3.247 c0.807,1.496,1.764,4.064,1.836,4.474c0.561,3.176,2.904,1.749,2.281-0.126c-0.068-0.446-0.109-2.014-0.287-2.862 c-0.18-0.849-0.219-1.688-0.113-3.056c0.066-1.389,0.232-2.055,0.277-2.299c0.285-1.023,0.4-1.088,0.408,0.135 c-0.059,0.399-0.131,1.687-0.125,2.655c0.064,0.642-0.043,1.768,0.172,2.486c0.654,1.928-0.027,3.496,1,3.514 c1.805-0.424,2.428-1.218,2.428-2.346c-0.086-0.704-0.121-0.843-0.031-1.193c0.221-0.568,0.359-0.67,0.312-0.076 c-0.055,0.287,0.031,0.533,0.082,0.794c0.264,1.197,0.912,0.114,1.283-0.782c0.15-0.238,0.539-2.154,0.545-2.522 c-0.023-0.617,0.285-0.645,0.309,0.01c0.064,0.422-0.248,2.646-0.205,2.334c-0.338,1.24-1.105,3.402-3.379,4.712 c-0.389,0.12-1.186,1.286-3.328,2.178c0,0,1.729,0.321,3.156,0.246c1.102-0.19,3.707-0.027,4.654,0.269 c1.752,0.494,1.531-0.053,4.084,0.164c2.26-0.4,2.154,2.391-1.496,3.68c-2.549,1.405-3.107,1.475-2.293,2.984 c3.484,7.906,2.865,13.183,2.193,16.466c2.41,0.271,5.732-0.62,7.301,0.725c0.506,0.333,0.648,1.866-0.457,2.86 c-4.105,2.745-9.283,7.022-13.904,7.662c-0.977-0.194,0.156-2.025,0.803-2.247l1.898-0.03c0.596-0.101,0.936-0.669,1.152-1.139 c3.16-0.404,5.045-3.775,8.246-4.818c-4.035-0.718-9.588,3.981-12.162,1.051c-5.043,1.423-11.449,1.84-15.895,1.111 c-3.105,2.687-7.934,4.021-12.115,5.866c-3.271,3.511-5.188,8.086-9.967,10.414c-0.986,0.119-0.48-1.974,0.066-2.385l1.795-0.618 C-22.995,25.682-22.849,25.035-22.788,24.521z', + plane: 'path://M1.112,32.559l2.998,1.205l-2.882,2.268l-2.215-0.012L1.112,32.559z M37.803,23.96 c0.158-0.838,0.5-1.509,0.961-1.904c-0.096-0.037-0.205-0.071-0.344-0.071c-0.777-0.005-2.068-0.009-3.047-0.009 c-0.633,0-1.217,0.066-1.754,0.18l2.199,1.804H37.803z M39.738,23.036c-0.111,0-0.377,0.325-0.537,0.924h1.076 C40.115,23.361,39.854,23.036,39.738,23.036z M39.934,39.867c-0.166,0-0.674,0.705-0.674,1.986s0.506,1.986,0.674,1.986 s0.672-0.705,0.672-1.986S40.102,39.867,39.934,39.867z M38.963,38.889c-0.098-0.038-0.209-0.07-0.348-0.073 c-0.082,0-0.174,0-0.268-0.001l-7.127,4.671c0.879,0.821,2.42,1.417,4.348,1.417c0.979,0,2.27-0.006,3.047-0.01 c0.139,0,0.25-0.034,0.348-0.072c-0.646-0.555-1.07-1.643-1.07-2.967C37.891,40.529,38.316,39.441,38.963,38.889z M32.713,23.96 l-12.37-10.116l-4.693-0.004c0,0,4,8.222,4.827,10.121H32.713z M59.311,32.374c-0.248,2.104-5.305,3.172-8.018,3.172H39.629 l-25.325,16.61L9.607,52.16c0,0,6.687-8.479,7.95-10.207c1.17-1.6,3.019-3.699,3.027-6.407h-2.138 c-5.839,0-13.816-3.789-18.472-5.583c-2.818-1.085-2.396-4.04-0.031-4.04h0.039l-3.299-11.371h3.617c0,0,4.352,5.696,5.846,7.5 c2,2.416,4.503,3.678,8.228,3.87h30.727c2.17,0,4.311,0.417,6.252,1.046c3.49,1.175,5.863,2.7,7.199,4.027 C59.145,31.584,59.352,32.025,59.311,32.374z M22.069,30.408c0-0.815-0.661-1.475-1.469-1.475c-0.812,0-1.471,0.66-1.471,1.475 s0.658,1.475,1.471,1.475C21.408,31.883,22.069,31.224,22.069,30.408z M27.06,30.408c0-0.815-0.656-1.478-1.466-1.478 c-0.812,0-1.471,0.662-1.471,1.478s0.658,1.477,1.471,1.477C26.404,31.885,27.06,31.224,27.06,30.408z M32.055,30.408 c0-0.815-0.66-1.475-1.469-1.475c-0.808,0-1.466,0.66-1.466,1.475s0.658,1.475,1.466,1.475 C31.398,31.883,32.055,31.224,32.055,30.408z M37.049,30.408c0-0.815-0.658-1.478-1.467-1.478c-0.812,0-1.469,0.662-1.469,1.478 s0.656,1.477,1.469,1.477C36.389,31.885,37.049,31.224,37.049,30.408z M42.039,30.408c0-0.815-0.656-1.478-1.465-1.478 c-0.811,0-1.469,0.662-1.469,1.478s0.658,1.477,1.469,1.477C41.383,31.885,42.039,31.224,42.039,30.408z M55.479,30.565 c-0.701-0.436-1.568-0.896-2.627-1.347c-0.613,0.289-1.551,0.476-2.73,0.476c-1.527,0-1.639,2.263,0.164,2.316 C52.389,32.074,54.627,31.373,55.479,30.565z', + train: 'path://M67.335,33.596L67.335,33.596c-0.002-1.39-1.153-3.183-3.328-4.218h-9.096v-2.07h5.371 c-4.939-2.07-11.199-4.141-14.89-4.141H19.72v12.421v5.176h38.373c4.033,0,8.457-1.035,9.142-5.176h-0.027 c0.076-0.367,0.129-0.751,0.129-1.165L67.335,33.596L67.335,33.596z M27.999,30.413h-3.105v-4.141h3.105V30.413z M35.245,30.413 h-3.104v-4.141h3.104V30.413z M42.491,30.413h-3.104v-4.141h3.104V30.413z M49.736,30.413h-3.104v-4.141h3.104V30.413z M14.544,40.764c1.143,0,2.07-0.927,2.07-2.07V35.59V25.237c0-1.145-0.928-2.07-2.07-2.07H-9.265c-1.143,0-2.068,0.926-2.068,2.07 v10.351v3.105c0,1.144,0.926,2.07,2.068,2.07H14.544L14.544,40.764z M8.333,26.272h3.105v4.141H8.333V26.272z M1.087,26.272h3.105 v4.141H1.087V26.272z M-6.159,26.272h3.105v4.141h-3.105V26.272z M-9.265,41.798h69.352v1.035H-9.265V41.798z', + ship: 'path://M16.678,17.086h9.854l-2.703,5.912c5.596,2.428,11.155,5.575,16.711,8.607c3.387,1.847,6.967,3.75,10.541,5.375 v-6.16l-4.197-2.763v-5.318L33.064,12.197h-11.48L20.43,15.24h-4.533l-1.266,3.286l0.781,0.345L16.678,17.086z M49.6,31.84 l0.047,1.273L27.438,20.998l0.799-1.734L49.6,31.84z M33.031,15.1l12.889,8.82l0.027,0.769L32.551,16.1L33.031,15.1z M22.377,14.045 h9.846l-1.539,3.365l-2.287-1.498h1.371l0.721-1.352h-2.023l-0.553,1.037l-0.541-0.357h-0.34l0.359-0.684h-2.025l-0.361,0.684 h-3.473L22.377,14.045z M23.695,20.678l-0.004,0.004h0.004V20.678z M24.828,18.199h-2.031l-0.719,1.358h2.029L24.828,18.199z M40.385,34.227c-12.85-7.009-25.729-14.667-38.971-12.527c1.26,8.809,9.08,16.201,8.213,24.328 c-0.553,4.062-3.111,0.828-3.303,7.137c15.799,0,32.379,0,48.166,0l0.066-4.195l1.477-7.23 C50.842,39.812,45.393,36.961,40.385,34.227z M13.99,35.954c-1.213,0-2.195-1.353-2.195-3.035c0-1.665,0.98-3.017,2.195-3.017 c1.219,0,2.195,1.352,2.195,3.017C16.186,34.604,15.213,35.954,13.99,35.954z M23.691,20.682h-2.02l-0.588,1.351h2.023 L23.691,20.682z M19.697,18.199l-0.721,1.358h2.025l0.727-1.358H19.697z', + car: 'path://M49.592,40.883c-0.053,0.354-0.139,0.697-0.268,0.963c-0.232,0.475-0.455,0.519-1.334,0.475 c-1.135-0.053-2.764,0-4.484,0.068c0,0.476,0.018,0.697,0.018,0.697c0.111,1.299,0.697,1.342,0.931,1.342h3.7 c0.326,0,0.628,0,0.861-0.154c0.301-0.196,0.43-0.772,0.543-1.78c0.017-0.146,0.025-0.336,0.033-0.56v-0.01 c0-0.068,0.008-0.154,0.008-0.25V41.58l0,0C49.6,41.348,49.6,41.09,49.592,40.883L49.592,40.883z M6.057,40.883 c0.053,0.354,0.137,0.697,0.268,0.963c0.23,0.475,0.455,0.519,1.334,0.475c1.137-0.053,2.762,0,4.484,0.068 c0,0.476-0.018,0.697-0.018,0.697c-0.111,1.299-0.697,1.342-0.93,1.342h-3.7c-0.328,0-0.602,0-0.861-0.154 c-0.309-0.18-0.43-0.772-0.541-1.78c-0.018-0.146-0.027-0.336-0.035-0.56v-0.01c0-0.068-0.008-0.154-0.008-0.25V41.58l0,0 C6.057,41.348,6.057,41.09,6.057,40.883L6.057,40.883z M49.867,32.766c0-2.642-0.344-5.224-0.482-5.507 c-0.104-0.207-0.766-0.749-2.271-1.773c-1.522-1.042-1.487-0.887-1.766-1.566c0.25-0.078,0.492-0.224,0.639-0.241 c0.326-0.034,0.345,0.274,1.023,0.274c0.68,0,2.152-0.18,2.453-0.48c0.301-0.303,0.396-0.405,0.396-0.672 c0-0.268-0.156-0.818-0.447-1.146c-0.293-0.327-1.541-0.49-2.273-0.585c-0.729-0.095-0.834,0-1.022,0.121 c-0.304,0.189-0.32,1.919-0.32,1.919l-0.713,0.018c-0.465-1.146-1.11-3.452-2.117-5.269c-1.103-1.979-2.256-2.599-2.737-2.754 c-0.474-0.146-0.904-0.249-4.131-0.576c-3.298-0.344-5.922-0.388-8.262-0.388c-2.342,0-4.967,0.052-8.264,0.388 c-3.229,0.336-3.66,0.43-4.133,0.576s-1.633,0.775-2.736,2.754c-1.006,1.816-1.652,4.123-2.117,5.269L9.87,23.109 c0,0-0.008-1.729-0.318-1.919c-0.189-0.121-0.293-0.225-1.023-0.121c-0.732,0.104-1.98,0.258-2.273,0.585 c-0.293,0.327-0.447,0.878-0.447,1.146c0,0.267,0.094,0.379,0.396,0.672c0.301,0.301,1.773,0.48,2.453,0.48 c0.68,0,0.697-0.309,1.023-0.274c0.146,0.018,0.396,0.163,0.637,0.241c-0.283,0.68-0.24,0.524-1.764,1.566 c-1.506,1.033-2.178,1.566-2.271,1.773c-0.139,0.283-0.482,2.865-0.482,5.508s0.189,5.02,0.189,5.86c0,0.354,0,0.976,0.076,1.565 c0.053,0.354,0.129,0.697,0.268,0.966c0.232,0.473,0.447,0.516,1.334,0.473c1.137-0.051,2.779,0,4.477,0.07 c1.135,0.043,2.297,0.086,3.33,0.11c2.582,0.051,1.826-0.379,2.928-0.36c1.102,0.016,5.447,0.196,9.424,0.196 c3.976,0,8.332-0.182,9.423-0.196c1.102-0.019,0.346,0.411,2.926,0.36c1.033-0.018,2.195-0.067,3.332-0.11 c1.695-0.062,3.348-0.121,4.477-0.07c0.886,0.043,1.103,0,1.332-0.473c0.132-0.269,0.218-0.611,0.269-0.966 c0.086-0.592,0.078-1.213,0.078-1.565C49.678,37.793,49.867,35.408,49.867,32.766L49.867,32.766z M13.219,19.735 c0.412-0.964,1.652-2.9,2.256-3.244c0.145-0.087,1.426-0.491,4.637-0.706c2.953-0.198,6.217-0.276,7.73-0.276 c1.513,0,4.777,0.078,7.729,0.276c3.201,0.215,4.502,0.611,4.639,0.706c0.775,0.533,1.842,2.28,2.256,3.244 c0.412,0.965,0.965,2.858,0.861,3.116c-0.104,0.258,0.104,0.388-1.291,0.275c-1.387-0.103-10.088-0.216-14.185-0.216 c-4.088,0-12.789,0.113-14.184,0.216c-1.395,0.104-1.188-0.018-1.291-0.275C12.254,22.593,12.805,20.708,13.219,19.735 L13.219,19.735z M16.385,30.511c-0.619,0.155-0.988,0.491-1.764,0.482c-0.775,0-2.867-0.353-3.314-0.371 c-0.447-0.017-0.842,0.302-1.076,0.362c-0.23,0.06-0.688-0.104-1.377-0.318c-0.688-0.216-1.092-0.155-1.316-1.094 c-0.232-0.93,0-2.264,0-2.264c1.488-0.068,2.928,0.069,5.621,0.826c2.693,0.758,4.191,2.213,4.191,2.213 S17.004,30.357,16.385,30.511L16.385,30.511z M36.629,37.293c-1.23,0.164-6.386,0.207-8.794,0.207c-2.412,0-7.566-0.051-8.799-0.207 c-1.256-0.164-2.891-1.67-1.764-2.865c1.523-1.627,1.24-1.576,4.701-2.023C24.967,32.018,27.239,32,27.834,32 c0.584,0,2.865,0.025,5.859,0.404c3.461,0.447,3.178,0.396,4.699,2.022C39.521,35.623,37.887,37.129,36.629,37.293L36.629,37.293z M48.129,29.582c-0.232,0.93-0.629,0.878-1.318,1.093c-0.688,0.216-1.145,0.371-1.377,0.319c-0.231-0.053-0.627-0.371-1.074-0.361 c-0.448,0.018-2.539,0.37-3.313,0.37c-0.772,0-1.146-0.328-1.764-0.481c-0.621-0.154-0.966-0.154-0.966-0.154 s1.49-1.464,4.191-2.213c2.693-0.758,4.131-0.895,5.621-0.826C48.129,27.309,48.361,28.643,48.129,29.582L48.129,29.582z' +}; +const labelSetting = { + show: true, + position: 'right', + offset: [10, 0], + fontSize: 16 +}; +option = { + title: { + text: 'Vehicles in X City' + }, + legend: { + data: ['2015', '2016'] + }, + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'shadow' + } + }, + grid: { + containLabel: true, + left: 20 + }, + yAxis: { + data: ['reindeer', 'ship', 'plane', 'train', 'car'], + inverse: true, + axisLine: { show: false }, + axisTick: { show: false }, + axisLabel: { + margin: 30, + fontSize: 14 + }, + axisPointer: { + label: { + show: true, + margin: 30 + } + } + }, + xAxis: { + splitLine: { show: false }, + axisLabel: { show: false }, + axisTick: { show: false }, + axisLine: { show: false } + }, + series: [ + { + name: '2015', + type: 'pictorialBar', + label: labelSetting, + symbolRepeat: true, + symbolSize: ['80%', '60%'], + barCategoryGap: '40%', + data: [ + { + value: 157, + symbol: pathSymbols.reindeer + }, + { + value: 21, + symbol: pathSymbols.ship + }, + { + value: 66, + symbol: pathSymbols.plane + }, + { + value: 78, + symbol: pathSymbols.train + }, + { + value: 123, + symbol: pathSymbols.car + } + ] + }, + { + name: '2016', + type: 'pictorialBar', + barGap: '10%', + label: labelSetting, + symbolRepeat: true, + symbolSize: ['80%', '60%'], + data: [ + { + value: 184, + symbol: pathSymbols.reindeer + }, + { + value: 29, + symbol: pathSymbols.ship + }, + { + value: 73, + symbol: pathSymbols.plane + }, + { + value: 91, + symbol: pathSymbols.train + }, + { + value: 95, + symbol: pathSymbols.car + } + ] + } + ] +}; +export {}; diff --git a/testdata/pictorialBar-vehicle.js.svg b/testdata/pictorialBar-vehicle.js.svg new file mode 100644 index 0000000..c67160e --- /dev/null +++ b/testdata/pictorialBar-vehicle.js.svg @@ -0,0 +1,1335 @@ + + +reindeer +ship +plane +train +car + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +157 +21 +66 +78 +123 +184 +29 +73 +91 +95 + + +2015 + +2016 + +Vehicles in X City + + \ No newline at end of file diff --git a/testdata/pictorialBar-velocity.js b/testdata/pictorialBar-velocity.js new file mode 100644 index 0000000..c0e47a3 --- /dev/null +++ b/testdata/pictorialBar-velocity.js @@ -0,0 +1,111 @@ +/* +title: Velocity of Christmas Reindeers +category: pictorialBar +titleCN: 驯鹿的速度 +*/ +const pathSymbols = { + reindeer: 'path://M-22.788,24.521c2.08-0.986,3.611-3.905,4.984-5.892 c-2.686,2.782-5.047,5.884-9.102,7.312c-0.992,0.005-0.25-2.016,0.34-2.362l1.852-0.41c0.564-0.218,0.785-0.842,0.902-1.347 c2.133-0.727,4.91-4.129,6.031-6.194c1.748-0.7,4.443-0.679,5.734-2.293c1.176-1.468,0.393-3.992,1.215-6.557 c0.24-0.754,0.574-1.581,1.008-2.293c-0.611,0.011-1.348-0.061-1.959-0.608c-1.391-1.245-0.785-2.086-1.297-3.313 c1.684,0.744,2.5,2.584,4.426,2.586C-8.46,3.012-8.255,2.901-8.04,2.824c6.031-1.952,15.182-0.165,19.498-3.937 c1.15-3.933-1.24-9.846-1.229-9.938c0.008-0.062-1.314-0.004-1.803-0.258c-1.119-0.771-6.531-3.75-0.17-3.33 c0.314-0.045,0.943,0.259,1.439,0.435c-0.289-1.694-0.92-0.144-3.311-1.946c0,0-1.1-0.855-1.764-1.98 c-0.836-1.09-2.01-2.825-2.992-4.031c-1.523-2.476,1.367,0.709,1.816,1.108c1.768,1.704,1.844,3.281,3.232,3.983 c0.195,0.203,1.453,0.164,0.926-0.468c-0.525-0.632-1.367-1.278-1.775-2.341c-0.293-0.703-1.311-2.326-1.566-2.711 c-0.256-0.384-0.959-1.718-1.67-2.351c-1.047-1.187-0.268-0.902,0.521-0.07c0.789,0.834,1.537,1.821,1.672,2.023 c0.135,0.203,1.584,2.521,1.725,2.387c0.102-0.259-0.035-0.428-0.158-0.852c-0.125-0.423-0.912-2.032-0.961-2.083 c-0.357-0.852-0.566-1.908-0.598-3.333c0.4-2.375,0.648-2.486,0.549-0.705c0.014,1.143,0.031,2.215,0.602,3.247 c0.807,1.496,1.764,4.064,1.836,4.474c0.561,3.176,2.904,1.749,2.281-0.126c-0.068-0.446-0.109-2.014-0.287-2.862 c-0.18-0.849-0.219-1.688-0.113-3.056c0.066-1.389,0.232-2.055,0.277-2.299c0.285-1.023,0.4-1.088,0.408,0.135 c-0.059,0.399-0.131,1.687-0.125,2.655c0.064,0.642-0.043,1.768,0.172,2.486c0.654,1.928-0.027,3.496,1,3.514 c1.805-0.424,2.428-1.218,2.428-2.346c-0.086-0.704-0.121-0.843-0.031-1.193c0.221-0.568,0.359-0.67,0.312-0.076 c-0.055,0.287,0.031,0.533,0.082,0.794c0.264,1.197,0.912,0.114,1.283-0.782c0.15-0.238,0.539-2.154,0.545-2.522 c-0.023-0.617,0.285-0.645,0.309,0.01c0.064,0.422-0.248,2.646-0.205,2.334c-0.338,1.24-1.105,3.402-3.379,4.712 c-0.389,0.12-1.186,1.286-3.328,2.178c0,0,1.729,0.321,3.156,0.246c1.102-0.19,3.707-0.027,4.654,0.269 c1.752,0.494,1.531-0.053,4.084,0.164c2.26-0.4,2.154,2.391-1.496,3.68c-2.549,1.405-3.107,1.475-2.293,2.984 c3.484,7.906,2.865,13.183,2.193,16.466c2.41,0.271,5.732-0.62,7.301,0.725c0.506,0.333,0.648,1.866-0.457,2.86 c-4.105,2.745-9.283,7.022-13.904,7.662c-0.977-0.194,0.156-2.025,0.803-2.247l1.898-0.03c0.596-0.101,0.936-0.669,1.152-1.139 c3.16-0.404,5.045-3.775,8.246-4.818c-4.035-0.718-9.588,3.981-12.162,1.051c-5.043,1.423-11.449,1.84-15.895,1.111 c-3.105,2.687-7.934,4.021-12.115,5.866c-3.271,3.511-5.188,8.086-9.967,10.414c-0.986,0.119-0.48-1.974,0.066-2.385l1.795-0.618 C-22.995,25.682-22.849,25.035-22.788,24.521z', + plane: 'path://M1.112,32.559l2.998,1.205l-2.882,2.268l-2.215-0.012L1.112,32.559z M37.803,23.96 c0.158-0.838,0.5-1.509,0.961-1.904c-0.096-0.037-0.205-0.071-0.344-0.071c-0.777-0.005-2.068-0.009-3.047-0.009 c-0.633,0-1.217,0.066-1.754,0.18l2.199,1.804H37.803z M39.738,23.036c-0.111,0-0.377,0.325-0.537,0.924h1.076 C40.115,23.361,39.854,23.036,39.738,23.036z M39.934,39.867c-0.166,0-0.674,0.705-0.674,1.986s0.506,1.986,0.674,1.986 s0.672-0.705,0.672-1.986S40.102,39.867,39.934,39.867z M38.963,38.889c-0.098-0.038-0.209-0.07-0.348-0.073 c-0.082,0-0.174,0-0.268-0.001l-7.127,4.671c0.879,0.821,2.42,1.417,4.348,1.417c0.979,0,2.27-0.006,3.047-0.01 c0.139,0,0.25-0.034,0.348-0.072c-0.646-0.555-1.07-1.643-1.07-2.967C37.891,40.529,38.316,39.441,38.963,38.889z M32.713,23.96 l-12.37-10.116l-4.693-0.004c0,0,4,8.222,4.827,10.121H32.713z M59.311,32.374c-0.248,2.104-5.305,3.172-8.018,3.172H39.629 l-25.325,16.61L9.607,52.16c0,0,6.687-8.479,7.95-10.207c1.17-1.6,3.019-3.699,3.027-6.407h-2.138 c-5.839,0-13.816-3.789-18.472-5.583c-2.818-1.085-2.396-4.04-0.031-4.04h0.039l-3.299-11.371h3.617c0,0,4.352,5.696,5.846,7.5 c2,2.416,4.503,3.678,8.228,3.87h30.727c2.17,0,4.311,0.417,6.252,1.046c3.49,1.175,5.863,2.7,7.199,4.027 C59.145,31.584,59.352,32.025,59.311,32.374z M22.069,30.408c0-0.815-0.661-1.475-1.469-1.475c-0.812,0-1.471,0.66-1.471,1.475 s0.658,1.475,1.471,1.475C21.408,31.883,22.069,31.224,22.069,30.408z M27.06,30.408c0-0.815-0.656-1.478-1.466-1.478 c-0.812,0-1.471,0.662-1.471,1.478s0.658,1.477,1.471,1.477C26.404,31.885,27.06,31.224,27.06,30.408z M32.055,30.408 c0-0.815-0.66-1.475-1.469-1.475c-0.808,0-1.466,0.66-1.466,1.475s0.658,1.475,1.466,1.475 C31.398,31.883,32.055,31.224,32.055,30.408z M37.049,30.408c0-0.815-0.658-1.478-1.467-1.478c-0.812,0-1.469,0.662-1.469,1.478 s0.656,1.477,1.469,1.477C36.389,31.885,37.049,31.224,37.049,30.408z M42.039,30.408c0-0.815-0.656-1.478-1.465-1.478 c-0.811,0-1.469,0.662-1.469,1.478s0.658,1.477,1.469,1.477C41.383,31.885,42.039,31.224,42.039,30.408z M55.479,30.565 c-0.701-0.436-1.568-0.896-2.627-1.347c-0.613,0.289-1.551,0.476-2.73,0.476c-1.527,0-1.639,2.263,0.164,2.316 C52.389,32.074,54.627,31.373,55.479,30.565z', + rocket: 'path://M-244.396,44.399c0,0,0.47-2.931-2.427-6.512c2.819-8.221,3.21-15.709,3.21-15.709s5.795,1.383,5.795,7.325C-237.818,39.679-244.396,44.399-244.396,44.399z M-260.371,40.827c0,0-3.881-12.946-3.881-18.319c0-2.416,0.262-4.566,0.669-6.517h17.684c0.411,1.952,0.675,4.104,0.675,6.519c0,5.291-3.87,18.317-3.87,18.317H-260.371z M-254.745,18.951c-1.99,0-3.603,1.676-3.603,3.744c0,2.068,1.612,3.744,3.603,3.744c1.988,0,3.602-1.676,3.602-3.744S-252.757,18.951-254.745,18.951z M-255.521,2.228v-5.098h1.402v4.969c1.603,1.213,5.941,5.069,7.901,12.5h-17.05C-261.373,7.373-257.245,3.558-255.521,2.228zM-265.07,44.399c0,0-6.577-4.721-6.577-14.896c0-5.942,5.794-7.325,5.794-7.325s0.393,7.488,3.211,15.708C-265.539,41.469-265.07,44.399-265.07,44.399z M-252.36,45.15l-1.176-1.22L-254.789,48l-1.487-4.069l-1.019,2.116l-1.488-3.826h8.067L-252.36,45.15z', + train: 'path://M67.335,33.596L67.335,33.596c-0.002-1.39-1.153-3.183-3.328-4.218h-9.096v-2.07h5.371 c-4.939-2.07-11.199-4.141-14.89-4.141H19.72v12.421v5.176h38.373c4.033,0,8.457-1.035,9.142-5.176h-0.027 c0.076-0.367,0.129-0.751,0.129-1.165L67.335,33.596L67.335,33.596z M27.999,30.413h-3.105v-4.141h3.105V30.413z M35.245,30.413 h-3.104v-4.141h3.104V30.413z M42.491,30.413h-3.104v-4.141h3.104V30.413z M49.736,30.413h-3.104v-4.141h3.104V30.413z M14.544,40.764c1.143,0,2.07-0.927,2.07-2.07V35.59V25.237c0-1.145-0.928-2.07-2.07-2.07H-9.265c-1.143,0-2.068,0.926-2.068,2.07 v10.351v3.105c0,1.144,0.926,2.07,2.068,2.07H14.544L14.544,40.764z M8.333,26.272h3.105v4.141H8.333V26.272z M1.087,26.272h3.105 v4.141H1.087V26.272z M-6.159,26.272h3.105v4.141h-3.105V26.272z M-9.265,41.798h69.352v1.035H-9.265V41.798z', + ship: 'path://M16.678,17.086h9.854l-2.703,5.912c5.596,2.428,11.155,5.575,16.711,8.607c3.387,1.847,6.967,3.75,10.541,5.375 v-6.16l-4.197-2.763v-5.318L33.064,12.197h-11.48L20.43,15.24h-4.533l-1.266,3.286l0.781,0.345L16.678,17.086z M49.6,31.84 l0.047,1.273L27.438,20.998l0.799-1.734L49.6,31.84z M33.031,15.1l12.889,8.82l0.027,0.769L32.551,16.1L33.031,15.1z M22.377,14.045 h9.846l-1.539,3.365l-2.287-1.498h1.371l0.721-1.352h-2.023l-0.553,1.037l-0.541-0.357h-0.34l0.359-0.684h-2.025l-0.361,0.684 h-3.473L22.377,14.045z M23.695,20.678l-0.004,0.004h0.004V20.678z M24.828,18.199h-2.031l-0.719,1.358h2.029L24.828,18.199z M40.385,34.227c-12.85-7.009-25.729-14.667-38.971-12.527c1.26,8.809,9.08,16.201,8.213,24.328 c-0.553,4.062-3.111,0.828-3.303,7.137c15.799,0,32.379,0,48.166,0l0.066-4.195l1.477-7.23 C50.842,39.812,45.393,36.961,40.385,34.227z M13.99,35.954c-1.213,0-2.195-1.353-2.195-3.035c0-1.665,0.98-3.017,2.195-3.017 c1.219,0,2.195,1.352,2.195,3.017C16.186,34.604,15.213,35.954,13.99,35.954z M23.691,20.682h-2.02l-0.588,1.351h2.023 L23.691,20.682z M19.697,18.199l-0.721,1.358h2.025l0.727-1.358H19.697z', + car: 'path://M49.592,40.883c-0.053,0.354-0.139,0.697-0.268,0.963c-0.232,0.475-0.455,0.519-1.334,0.475 c-1.135-0.053-2.764,0-4.484,0.068c0,0.476,0.018,0.697,0.018,0.697c0.111,1.299,0.697,1.342,0.931,1.342h3.7 c0.326,0,0.628,0,0.861-0.154c0.301-0.196,0.43-0.772,0.543-1.78c0.017-0.146,0.025-0.336,0.033-0.56v-0.01 c0-0.068,0.008-0.154,0.008-0.25V41.58l0,0C49.6,41.348,49.6,41.09,49.592,40.883L49.592,40.883z M6.057,40.883 c0.053,0.354,0.137,0.697,0.268,0.963c0.23,0.475,0.455,0.519,1.334,0.475c1.137-0.053,2.762,0,4.484,0.068 c0,0.476-0.018,0.697-0.018,0.697c-0.111,1.299-0.697,1.342-0.93,1.342h-3.7c-0.328,0-0.602,0-0.861-0.154 c-0.309-0.18-0.43-0.772-0.541-1.78c-0.018-0.146-0.027-0.336-0.035-0.56v-0.01c0-0.068-0.008-0.154-0.008-0.25V41.58l0,0 C6.057,41.348,6.057,41.09,6.057,40.883L6.057,40.883z M49.867,32.766c0-2.642-0.344-5.224-0.482-5.507 c-0.104-0.207-0.766-0.749-2.271-1.773c-1.522-1.042-1.487-0.887-1.766-1.566c0.25-0.078,0.492-0.224,0.639-0.241 c0.326-0.034,0.345,0.274,1.023,0.274c0.68,0,2.152-0.18,2.453-0.48c0.301-0.303,0.396-0.405,0.396-0.672 c0-0.268-0.156-0.818-0.447-1.146c-0.293-0.327-1.541-0.49-2.273-0.585c-0.729-0.095-0.834,0-1.022,0.121 c-0.304,0.189-0.32,1.919-0.32,1.919l-0.713,0.018c-0.465-1.146-1.11-3.452-2.117-5.269c-1.103-1.979-2.256-2.599-2.737-2.754 c-0.474-0.146-0.904-0.249-4.131-0.576c-3.298-0.344-5.922-0.388-8.262-0.388c-2.342,0-4.967,0.052-8.264,0.388 c-3.229,0.336-3.66,0.43-4.133,0.576s-1.633,0.775-2.736,2.754c-1.006,1.816-1.652,4.123-2.117,5.269L9.87,23.109 c0,0-0.008-1.729-0.318-1.919c-0.189-0.121-0.293-0.225-1.023-0.121c-0.732,0.104-1.98,0.258-2.273,0.585 c-0.293,0.327-0.447,0.878-0.447,1.146c0,0.267,0.094,0.379,0.396,0.672c0.301,0.301,1.773,0.48,2.453,0.48 c0.68,0,0.697-0.309,1.023-0.274c0.146,0.018,0.396,0.163,0.637,0.241c-0.283,0.68-0.24,0.524-1.764,1.566 c-1.506,1.033-2.178,1.566-2.271,1.773c-0.139,0.283-0.482,2.865-0.482,5.508s0.189,5.02,0.189,5.86c0,0.354,0,0.976,0.076,1.565 c0.053,0.354,0.129,0.697,0.268,0.966c0.232,0.473,0.447,0.516,1.334,0.473c1.137-0.051,2.779,0,4.477,0.07 c1.135,0.043,2.297,0.086,3.33,0.11c2.582,0.051,1.826-0.379,2.928-0.36c1.102,0.016,5.447,0.196,9.424,0.196 c3.976,0,8.332-0.182,9.423-0.196c1.102-0.019,0.346,0.411,2.926,0.36c1.033-0.018,2.195-0.067,3.332-0.11 c1.695-0.062,3.348-0.121,4.477-0.07c0.886,0.043,1.103,0,1.332-0.473c0.132-0.269,0.218-0.611,0.269-0.966 c0.086-0.592,0.078-1.213,0.078-1.565C49.678,37.793,49.867,35.408,49.867,32.766L49.867,32.766z M13.219,19.735 c0.412-0.964,1.652-2.9,2.256-3.244c0.145-0.087,1.426-0.491,4.637-0.706c2.953-0.198,6.217-0.276,7.73-0.276 c1.513,0,4.777,0.078,7.729,0.276c3.201,0.215,4.502,0.611,4.639,0.706c0.775,0.533,1.842,2.28,2.256,3.244 c0.412,0.965,0.965,2.858,0.861,3.116c-0.104,0.258,0.104,0.388-1.291,0.275c-1.387-0.103-10.088-0.216-14.185-0.216 c-4.088,0-12.789,0.113-14.184,0.216c-1.395,0.104-1.188-0.018-1.291-0.275C12.254,22.593,12.805,20.708,13.219,19.735 L13.219,19.735z M16.385,30.511c-0.619,0.155-0.988,0.491-1.764,0.482c-0.775,0-2.867-0.353-3.314-0.371 c-0.447-0.017-0.842,0.302-1.076,0.362c-0.23,0.06-0.688-0.104-1.377-0.318c-0.688-0.216-1.092-0.155-1.316-1.094 c-0.232-0.93,0-2.264,0-2.264c1.488-0.068,2.928,0.069,5.621,0.826c2.693,0.758,4.191,2.213,4.191,2.213 S17.004,30.357,16.385,30.511L16.385,30.511z M36.629,37.293c-1.23,0.164-6.386,0.207-8.794,0.207c-2.412,0-7.566-0.051-8.799-0.207 c-1.256-0.164-2.891-1.67-1.764-2.865c1.523-1.627,1.24-1.576,4.701-2.023C24.967,32.018,27.239,32,27.834,32 c0.584,0,2.865,0.025,5.859,0.404c3.461,0.447,3.178,0.396,4.699,2.022C39.521,35.623,37.887,37.129,36.629,37.293L36.629,37.293z M48.129,29.582c-0.232,0.93-0.629,0.878-1.318,1.093c-0.688,0.216-1.145,0.371-1.377,0.319c-0.231-0.053-0.627-0.371-1.074-0.361 c-0.448,0.018-2.539,0.37-3.313,0.37c-0.772,0-1.146-0.328-1.764-0.481c-0.621-0.154-0.966-0.154-0.966-0.154 s1.49-1.464,4.191-2.213c2.693-0.758,4.131-0.895,5.621-0.826C48.129,27.309,48.361,28.643,48.129,29.582L48.129,29.582z', + run: 'path://M13.676,32.955c0.919-0.031,1.843-0.008,2.767-0.008v0.007c0.827,0,1.659,0.041,2.486-0.019 c0.417-0.028,1.118,0.325,1.14-0.545c0.014-0.637-0.156-1.279-0.873-1.367c-1.919-0.241-3.858-0.233-5.774,0.019 c-0.465,0.062-0.998,0.442-0.832,1.069C12.715,32.602,13.045,32.977,13.676,32.955z M14.108,29.013 c1.47-0.007,2.96-0.122,4.414,0.035c1.792,0.192,3.1-0.412,4.273-2.105c-3.044,0-5.882,0.014-8.719-0.01 c-0.768-0.005-1.495,0.118-1.461,1C12.642,28.731,13.329,29.014,14.108,29.013z M23.678,36.593c-0.666-0.69-1.258-1.497-2.483-1.448 c-2.341,0.095-4.689,0.051-7.035,0.012c-0.834-0.014-1.599,0.177-1.569,1.066c0.031,0.854,0.812,1.062,1.636,1.043 c1.425-0.033,2.852-0.01,4.278-0.01v-0.01c1.562,0,3.126,0.008,4.691-0.005C23.614,37.239,24.233,37.174,23.678,36.593z M32.234,42.292h-0.002c-1.075,0.793-2.589,0.345-3.821,1.048c-0.359,0.193-0.663,0.465-0.899,0.799 c-1.068,1.623-2.052,3.301-3.117,4.928c-0.625,0.961-0.386,1.805,0.409,2.395c0.844,0.628,1.874,0.617,2.548-0.299 c1.912-2.573,3.761-5.197,5.621-7.814C33.484,42.619,33.032,42.387,32.234,42.292z M43.527,28.401 c-0.688-1.575-2.012-0.831-3.121-0.895c-1.047-0.058-2.119,1.128-3.002,0.345c-0.768-0.677-1.213-1.804-1.562-2.813 c-0.45-1.305-1.495-2.225-2.329-3.583c2.953,1.139,4.729,0.077,5.592-1.322c0.99-1.61,0.718-3.725-0.627-4.967 c-1.362-1.255-3.414-1.445-4.927-0.452c-1.933,1.268-2.206,2.893-0.899,6.11c-2.098-0.659-3.835-1.654-5.682-2.383 c-0.735-0.291-1.437-1.017-2.293-0.666c-2.263,0.927-4.522,1.885-6.723,2.95c-1.357,0.658-1.649,1.593-1.076,2.638 c0.462,0.851,1.643,1.126,2.806,0.617c0.993-0.433,1.994-0.857,2.951-1.374c1.599-0.86,3.044-0.873,4.604,0.214 c1.017,0.707,0.873,1.137,0.123,1.849c-1.701,1.615-3.516,3.12-4.933,5.006c-1.042,1.388-0.993,2.817,0.255,4.011 c1.538,1.471,3.148,2.869,4.708,4.315c0.485,0.444,0.907,0.896-0.227,1.104c-1.523,0.285-3.021,0.694-4.538,1.006 c-1.109,0.225-2.02,1.259-1.83,2.16c0.223,1.07,1.548,1.756,2.687,1.487c3.003-0.712,6.008-1.413,9.032-2.044 c1.549-0.324,2.273-1.869,1.344-3.115c-0.868-1.156-1.801-2.267-2.639-3.445c-1.964-2.762-1.95-2.771,0.528-5.189 c1.394-1.357,1.379-1.351,2.437,0.417c0.461,0.769,0.854,1.703,1.99,1.613c2.238-0.181,4.407-0.755,6.564-1.331 C43.557,30.447,43.88,29.206,43.527,28.401z', + walk: 'path://M29.902,23.275c1.86,0,3.368-1.506,3.368-3.365c0-1.859-1.508-3.365-3.368-3.365 c-1.857,0-3.365,1.506-3.365,3.365C26.537,21.769,28.045,23.275,29.902,23.275z M36.867,30.74c-1.666-0.467-3.799-1.6-4.732-4.199 c-0.932-2.6-3.131-2.998-4.797-2.998s-7.098,3.894-7.098,3.894c-1.133,1.001-2.1,6.502-0.967,6.769 c1.133,0.269,1.266-1.533,1.934-3.599c0.666-2.065,3.797-3.466,3.797-3.466s0.201,2.467-0.398,3.866 c-0.599,1.399-1.133,2.866-1.467,6.198s-1.6,3.665-3.799,6.266c-2.199,2.598-0.6,3.797,0.398,3.664 c1.002-0.133,5.865-5.598,6.398-6.998c0.533-1.397,0.668-3.732,0.668-3.732s0,0,2.199,1.867c2.199,1.865,2.332,4.6,2.998,7.73 s2.332,0.934,2.332-0.467c0-1.401,0.269-5.465-1-7.064c-1.265-1.6-3.73-3.465-3.73-5.265s1.199-3.732,1.199-3.732 c0.332,1.667,3.335,3.065,5.599,3.399C38.668,33.206,38.533,31.207,36.867,30.74z' +}; +option = { + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'none' + }, + formatter: function (params) { + return params[0].name + ': ' + params[0].value; + } + }, + xAxis: { + data: ['驯鹿', '火箭', '飞机', '高铁', '轮船', '汽车', '跑步', '步行'], + axisTick: { show: false }, + axisLine: { show: false }, + axisLabel: { + color: '#e54035' + } + }, + yAxis: { + splitLine: { show: false }, + axisTick: { show: false }, + axisLine: { show: false }, + axisLabel: { show: false } + }, + color: ['#e54035'], + series: [ + { + name: 'hill', + type: 'pictorialBar', + barCategoryGap: '-130%', + // symbol: 'path://M0,10 L10,10 L5,0 L0,10 z', + symbol: 'path://M0,10 L10,10 C5.5,10 5.5,5 5,0 C4.5,5 4.5,10 0,10 z', + itemStyle: { + opacity: 0.5 + }, + emphasis: { + itemStyle: { + opacity: 1 + } + }, + data: [123, 60, 25, 18, 12, 9, 2, 1], + z: 10 + }, + { + name: 'glyph', + type: 'pictorialBar', + barGap: '-100%', + symbolPosition: 'end', + symbolSize: 50, + symbolOffset: [0, '-120%'], + data: [ + { + value: 123, + symbol: pathSymbols.reindeer, + symbolSize: [60, 60] + }, + { + value: 60, + symbol: pathSymbols.rocket, + symbolSize: [50, 60] + }, + { + value: 25, + symbol: pathSymbols.plane, + symbolSize: [65, 35] + }, + { + value: 18, + symbol: pathSymbols.train, + symbolSize: [50, 30] + }, + { + value: 12, + symbol: pathSymbols.ship, + symbolSize: [50, 35] + }, + { + value: 9, + symbol: pathSymbols.car, + symbolSize: [40, 30] + }, + { + value: 2, + symbol: pathSymbols.run, + symbolSize: [40, 50] + }, + { + value: 1, + symbol: pathSymbols.walk, + symbolSize: [40, 50] + } + ] + } + ] +}; +export {}; diff --git a/testdata/pictorialBar-velocity.js.svg b/testdata/pictorialBar-velocity.js.svg new file mode 100644 index 0000000..cb25f06 --- /dev/null +++ b/testdata/pictorialBar-velocity.js.svg @@ -0,0 +1,223 @@ + + +驯鹿 +火箭 +飞机 +高铁 +轮船 +汽车 +跑步 +步行 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/pie-alignTo.js b/testdata/pie-alignTo.js new file mode 100644 index 0000000..8ca43e4 --- /dev/null +++ b/testdata/pie-alignTo.js @@ -0,0 +1,110 @@ +/* +title: Pie Label Align +category: pie +titleCN: 饼图标签对齐 +difficulty: 3 +*/ +const data = [ + { + name: 'Apples', + value: 70 + }, + { + name: 'Strawberries', + value: 68 + }, + { + name: 'Bananas', + value: 48 + }, + { + name: 'Oranges', + value: 40 + }, + { + name: 'Pears', + value: 32 + }, + { + name: 'Pineapples', + value: 27 + }, + { + name: 'Grapes', + value: 18 + } +]; +option = { + title: [ + { + text: 'Pie label alignTo', + left: 'center' + }, + { + subtext: 'alignTo: "none" (default)', + left: '16.67%', + top: '75%', + textAlign: 'center' + }, + { + subtext: 'alignTo: "labelLine"', + left: '50%', + top: '75%', + textAlign: 'center' + }, + { + subtext: 'alignTo: "edge"', + left: '83.33%', + top: '75%', + textAlign: 'center' + } + ], + series: [ + { + type: 'pie', + radius: '25%', + center: ['50%', '50%'], + data: data, + label: { + position: 'outer', + alignTo: 'none', + bleedMargin: 5 + }, + left: 0, + right: '66.6667%', + top: 0, + bottom: 0 + }, + { + type: 'pie', + radius: '25%', + center: ['50%', '50%'], + data: data, + label: { + position: 'outer', + alignTo: 'labelLine', + bleedMargin: 5 + }, + left: '33.3333%', + right: '33.3333%', + top: 0, + bottom: 0 + }, + { + type: 'pie', + radius: '25%', + center: ['50%', '50%'], + data: data, + label: { + position: 'outer', + alignTo: 'edge', + margin: 20 + }, + left: '66.6667%', + right: 0, + top: 0, + bottom: 0 + } + ] +}; +export {}; diff --git a/testdata/pie-alignTo.js.svg b/testdata/pie-alignTo.js.svg new file mode 100644 index 0000000..c692ac2 --- /dev/null +++ b/testdata/pie-alignTo.js.svg @@ -0,0 +1,309 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Apples +Strawberries +Bananas +Oranges +Pears +Pineapples +Grapes +Apples +Strawberries +Bananas +Oranges +Pears +Pineapples +Grapes +Apples +Strawber... +Bananas +Oranges +Pears +Pineapples +Grapes + + + + +Pie label alignTo +alignTo: "none" (default) +alignTo: "labelLine" +alignTo: "edge" + + \ No newline at end of file diff --git a/testdata/pie-borderRadius.js b/testdata/pie-borderRadius.js new file mode 100644 index 0000000..5267236 --- /dev/null +++ b/testdata/pie-borderRadius.js @@ -0,0 +1,50 @@ +/* +title: Doughnut Chart with Rounded Corner +category: pie +titleCN: 圆角环形图 +difficulty: 1 +*/ +option = { + tooltip: { + trigger: 'item' + }, + legend: { + top: '5%', + left: 'center' + }, + series: [ + { + name: 'Access From', + type: 'pie', + radius: ['40%', '70%'], + avoidLabelOverlap: false, + itemStyle: { + borderRadius: 10, + borderColor: '#fff', + borderWidth: 2 + }, + label: { + show: false, + position: 'center' + }, + emphasis: { + label: { + show: true, + fontSize: 40, + fontWeight: 'bold' + } + }, + labelLine: { + show: false + }, + data: [ + { value: 1048, name: 'Search Engine' }, + { value: 735, name: 'Direct' }, + { value: 580, name: 'Email' }, + { value: 484, name: 'Union Ads' }, + { value: 300, name: 'Video Ads' } + ] + } + ] +}; +export {}; diff --git a/testdata/pie-borderRadius.js.svg b/testdata/pie-borderRadius.js.svg new file mode 100644 index 0000000..e88eaca --- /dev/null +++ b/testdata/pie-borderRadius.js.svg @@ -0,0 +1,78 @@ + + + + + + + + + +Search Engine + +Direct + +Email + +Union Ads + +Video Ads + + \ No newline at end of file diff --git a/testdata/pie-custom.js b/testdata/pie-custom.js new file mode 100644 index 0000000..39bd942 --- /dev/null +++ b/testdata/pie-custom.js @@ -0,0 +1,68 @@ +/* +title: Customized Pie +category: pie +titleCN: 饼图自定义样式 +difficulty: 2 +*/ +option = { + backgroundColor: '#2c343c', + title: { + text: 'Customized Pie', + left: 'center', + top: 20, + textStyle: { + color: '#ccc' + } + }, + tooltip: { + trigger: 'item' + }, + visualMap: { + show: false, + min: 80, + max: 600, + inRange: { + colorLightness: [0, 1] + } + }, + series: [ + { + name: 'Access From', + type: 'pie', + radius: '55%', + center: ['50%', '50%'], + data: [ + { value: 335, name: 'Direct' }, + { value: 310, name: 'Email' }, + { value: 274, name: 'Union Ads' }, + { value: 235, name: 'Video Ads' }, + { value: 400, name: 'Search Engine' } + ].sort(function (a, b) { + return a.value - b.value; + }), + roseType: 'radius', + label: { + color: 'rgba(255, 255, 255, 0.3)' + }, + labelLine: { + lineStyle: { + color: 'rgba(255, 255, 255, 0.3)' + }, + smooth: 0.2, + length: 10, + length2: 20 + }, + itemStyle: { + color: '#c23531', + shadowBlur: 200, + shadowColor: 'rgba(0, 0, 0, 0.5)' + }, + animationType: 'scale', + animationEasing: 'elasticOut', + animationDelay: function (idx) { + return Math.random() * 200; + } + } + ] +}; +export {}; diff --git a/testdata/pie-custom.js.svg b/testdata/pie-custom.js.svg new file mode 100644 index 0000000..5e5e538 --- /dev/null +++ b/testdata/pie-custom.js.svg @@ -0,0 +1,84 @@ + + + + + + + + + + + + +Video Ads +Union Ads +Email +Direct +Search Engine + +Customized Pie + + + + + + + \ No newline at end of file diff --git a/testdata/pie-doughnut.js b/testdata/pie-doughnut.js new file mode 100644 index 0000000..70b4531 --- /dev/null +++ b/testdata/pie-doughnut.js @@ -0,0 +1,45 @@ +/* +title: Doughnut Chart +category: pie +titleCN: 环形图 +difficulty: 1 +*/ +option = { + tooltip: { + trigger: 'item' + }, + legend: { + top: '5%', + left: 'center' + }, + series: [ + { + name: 'Access From', + type: 'pie', + radius: ['40%', '70%'], + avoidLabelOverlap: false, + label: { + show: false, + position: 'center' + }, + emphasis: { + label: { + show: true, + fontSize: 40, + fontWeight: 'bold' + } + }, + labelLine: { + show: false + }, + data: [ + { value: 1048, name: 'Search Engine' }, + { value: 735, name: 'Direct' }, + { value: 580, name: 'Email' }, + { value: 484, name: 'Union Ads' }, + { value: 300, name: 'Video Ads' } + ] + } + ] +}; +export {}; diff --git a/testdata/pie-doughnut.js.svg b/testdata/pie-doughnut.js.svg new file mode 100644 index 0000000..782440e --- /dev/null +++ b/testdata/pie-doughnut.js.svg @@ -0,0 +1,78 @@ + + + + + + + + + +Search Engine + +Direct + +Email + +Union Ads + +Video Ads + + \ No newline at end of file diff --git a/testdata/pie-half-donut.js b/testdata/pie-half-donut.js new file mode 100644 index 0000000..a88af26 --- /dev/null +++ b/testdata/pie-half-donut.js @@ -0,0 +1,56 @@ +/* +title: Half Doughnut Chart +category: pie +titleCN: 半环形图 +difficulty: 1 +*/ +option = { + tooltip: { + trigger: 'item' + }, + legend: { + top: '5%', + left: 'center', + // doesn't perfectly work with our tricks, disable it + selectedMode: false + }, + series: [ + { + name: 'Access From', + type: 'pie', + radius: ['40%', '70%'], + center: ['50%', '70%'], + // adjust the start angle + startAngle: 180, + label: { + show: true, + formatter(param) { + // correct the percentage + return param.name + ' (' + param.percent * 2 + '%)'; + } + }, + data: [ + { value: 1048, name: 'Search Engine' }, + { value: 735, name: 'Direct' }, + { value: 580, name: 'Email' }, + { value: 484, name: 'Union Ads' }, + { value: 300, name: 'Video Ads' }, + { + // make an record to fill the bottom 50% + value: 1048 + 735 + 580 + 484 + 300, + itemStyle: { + // stop the chart from rendering this piece + color: 'none', + decal: { + symbol: 'none' + } + }, + label: { + show: false + } + } + ] + } + ] +}; +export {}; diff --git a/testdata/pie-half-donut.js.svg b/testdata/pie-half-donut.js.svg new file mode 100644 index 0000000..e3f053a --- /dev/null +++ b/testdata/pie-half-donut.js.svg @@ -0,0 +1,111 @@ + + + + + + + + + + + + + + +Search Engine +Direct +Email +Union Ads +Video Ads + + +Search Engine + +Direct + +Email + +Union Ads + +Video Ads + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/pie-labelLine-adjust.js b/testdata/pie-labelLine-adjust.js new file mode 100644 index 0000000..aef4305 --- /dev/null +++ b/testdata/pie-labelLine-adjust.js @@ -0,0 +1,92 @@ +/* +title: Label Line Adjust +category: pie +titleCN: 饼图引导线调整 +difficulty: 3 +*/ +var datas = [ + //////////////////////////////////////// + [ + { name: '圣彼得堡来客', value: 5.6 }, + { name: '陀思妥耶夫斯基全集', value: 1 }, + { name: '史记精注全译(全6册)', value: 0.8 }, + { name: '加德纳艺术通史', value: 0.5 }, + { name: '表象与本质', value: 0.5 }, + { name: '其它', value: 3.8 } + ], + // //////////////////////////////////////// + [ + { name: '银河帝国5:迈向基地', value: 3.8 }, + { name: '俞军产品方法论', value: 2.3 }, + { name: '艺术的逃难', value: 2.2 }, + { name: '第一次世界大战回忆录(全五卷)', value: 1.3 }, + { name: 'Scrum 精髓', value: 1.2 }, + { name: '其它', value: 5.7 } + ], + //////////////////////////////////////// + [ + { name: '克莱因壶', value: 3.5 }, + { name: '投资最重要的事', value: 2.8 }, + { name: '简读中国史', value: 1.7 }, + { name: '你当像鸟飞往你的山', value: 1.4 }, + { name: '表象与本质', value: 0.5 }, + { name: '其它', value: 3.8 } + ] +]; +option = { + title: { + text: '阅读书籍分布', + left: 'center', + textStyle: { + color: '#999', + fontWeight: 'normal', + fontSize: 14 + } + }, + series: datas.map(function (data, idx) { + var top = idx * 33.3; + return { + type: 'pie', + radius: [20, 60], + top: top + '%', + height: '33.33%', + left: 'center', + width: 400, + itemStyle: { + borderColor: '#fff', + borderWidth: 1 + }, + label: { + alignTo: 'edge', + formatter: '{name|{b}}\n{time|{c} 小时}', + minMargin: 5, + edgeDistance: 10, + lineHeight: 15, + rich: { + time: { + fontSize: 10, + color: '#999' + } + } + }, + labelLine: { + length: 15, + length2: 0, + maxSurfaceAngle: 80 + }, + labelLayout: function (params) { + const isLeft = params.labelRect.x < myChart.getWidth() / 2; + const points = params.labelLinePoints; + // Update the end point. + points[2][0] = isLeft + ? params.labelRect.x + : params.labelRect.x + params.labelRect.width; + return { + labelLinePoints: points + }; + }, + data: data + }; + }) +}; +export {}; diff --git a/testdata/pie-labelLine-adjust.js.svg b/testdata/pie-labelLine-adjust.js.svg new file mode 100644 index 0000000..a404540 --- /dev/null +++ b/testdata/pie-labelLine-adjust.js.svg @@ -0,0 +1,297 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +圣彼得堡来客 +5.6 小时 + +陀思妥耶夫斯基全集 +1 小时 + +史记精注全译(全6册) +0.8 小时 + +加德纳艺术通史 +0.5 小时 + +表象与本质 +0.5 小时 + +其它 +3.8 小时 + +银河帝国5:迈向基地 +3.8 小时 + +俞军产品方法论 +2.3 小时 + +艺术的逃难 +2.2 小时 + +第一次世界大战回忆录(全... +1.3 小时 + +Scrum 精髓 +1.2 小时 + +其它 +5.7 小时 + +克莱因壶 +3.5 小时 + +投资最重要的事 +2.8 小时 + +简读中国史 +1.7 小时 + +你当像鸟飞往你的山 +1.4 小时 + +表象与本质 +0.5 小时 + +其它 +3.8 小时 + +阅读书籍分布 + + \ No newline at end of file diff --git a/testdata/pie-legend.js b/testdata/pie-legend.js new file mode 100644 index 0000000..d79052a --- /dev/null +++ b/testdata/pie-legend.js @@ -0,0 +1,73 @@ +/* +title: Pie with Scrollable Legend +category: pie +titleCN: 可滚动的图例 +difficulty: 4 +*/ +const data = genData(50); +option = { + title: { + text: '同名数量统计', + subtext: '纯属虚构', + left: 'center' + }, + tooltip: { + trigger: 'item', + formatter: '{a}
{b} : {c} ({d}%)' + }, + legend: { + type: 'scroll', + orient: 'vertical', + right: 10, + top: 20, + bottom: 20, + data: data.legendData + }, + series: [ + { + name: '姓名', + type: 'pie', + radius: '55%', + center: ['40%', '50%'], + data: data.seriesData, + emphasis: { + itemStyle: { + shadowBlur: 10, + shadowOffsetX: 0, + shadowColor: 'rgba(0, 0, 0, 0.5)' + } + } + } + ] +}; +function genData(count) { + // prettier-ignore + const nameList = [ + '赵', '钱', '孙', '李', '周', '吴', '郑', '王', '冯', '陈', '褚', '卫', '蒋', '沈', '韩', '杨', '朱', '秦', '尤', '许', '何', '吕', '施', '张', '孔', '曹', '严', '华', '金', '魏', '陶', '姜', '戚', '谢', '邹', '喻', '柏', '水', '窦', '章', '云', '苏', '潘', '葛', '奚', '范', '彭', '郎', '鲁', '韦', '昌', '马', '苗', '凤', '花', '方', '俞', '任', '袁', '柳', '酆', '鲍', '史', '唐', '费', '廉', '岑', '薛', '雷', '贺', '倪', '汤', '滕', '殷', '罗', '毕', '郝', '邬', '安', '常', '乐', '于', '时', '傅', '皮', '卞', '齐', '康', '伍', '余', '元', '卜', '顾', '孟', '平', '黄', '和', '穆', '萧', '尹', '姚', '邵', '湛', '汪', '祁', '毛', '禹', '狄', '米', '贝', '明', '臧', '计', '伏', '成', '戴', '谈', '宋', '茅', '庞', '熊', '纪', '舒', '屈', '项', '祝', '董', '梁', '杜', '阮', '蓝', '闵', '席', '季', '麻', '强', '贾', '路', '娄', '危' + ]; + const legendData = []; + const seriesData = []; + for (var i = 0; i < count; i++) { + var name = Math.random() > 0.65 + ? makeWord(4, 1) + '·' + makeWord(3, 0) + : makeWord(2, 1); + legendData.push(name); + seriesData.push({ + name: name, + value: Math.round(Math.random() * 100000) + }); + } + return { + legendData: legendData, + seriesData: seriesData + }; + function makeWord(max, min) { + const nameLen = Math.ceil(Math.random() * max + min); + const name = []; + for (var i = 0; i < nameLen; i++) { + name.push(nameList[Math.round(Math.random() * nameList.length - 1)]); + } + return name.join(''); + } +} +export {}; diff --git a/testdata/pie-legend.js.svg b/testdata/pie-legend.js.svg new file mode 100644 index 0000000..065959b --- /dev/null +++ b/testdata/pie-legend.js.svg @@ -0,0 +1,821 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +茅葛姜 +闵彭 +祁于祝·蒋阮 +尹齐 +谈喻路·戴秦 +汤杨 +鲁倪严赵·褚 +傅赵明·邹鲍 +鲍蓝余 +吴顾杜·强 +邵皮 +贾萧·黄 +熊雷 +柏赵汪 +和任湛沈彭·卜 +陶卞元 +秦李 +平柳 +时贝 +何季卞·潘 +贺凤杨麻·席 +明鲍祁 +窦安吕 +水毕 +潘杜 +茅戚薛·谢奚齐 +祁张苏·严苏常 +窦卞·董 +邵阮吕 +奚姜罗·毕齐席 +熊尹伏 +平韦黄 +李娄 +纪戚 +汪傅·郝 +于喻谈·伏 +罗云梁 +成杜 +沈唐 +吕喻戴于滕·鲁周萧 +梁季戚·时 +和任毛路·汤纪 +柳路袁 +黄薛·任许钱 +纪屈 +朱华狄 +韩方吕·安 +凤时冯 +米孙·黄雷 +常麻·孙强傅 + + + +茅葛姜 + +闵彭 + +祁于祝·蒋阮 + +尹齐 + +谈喻路·戴秦 + +汤杨 + +鲁倪严赵·褚 + +傅赵明·邹鲍 + +鲍蓝余 + +吴顾杜·强 + +邵皮 + +贾萧·黄 + +熊雷 + +柏赵汪 + +和任湛沈彭·卜 + +陶卞元 + +秦李 + +平柳 + +时贝 + +何季卞·潘 + +贺凤杨麻·席 + +明鲍祁 + +窦安吕 + +水毕 + +潘杜 + +茅戚薛·谢奚齐 + +祁张苏·严苏常 + +窦卞·董 + +邵阮吕 + +奚姜罗·毕齐席 + +熊尹伏 + +平韦黄 + +李娄 + +纪戚 + +汪傅·郝 + +于喻谈·伏 + +罗云梁 + +成杜 + +沈唐 + +吕喻戴于滕·鲁周萧 + +梁季戚·时 + +和任毛路·汤纪 + +柳路袁 + +黄薛·任许钱 + +纪屈 + +朱华狄 + +韩方吕·安 + +凤时冯 + +米孙·黄雷 + +常麻·孙强傅 + + +1/3 + + +同名数量统计 +纯属虚构 + + + + + + + \ No newline at end of file diff --git a/testdata/pie-nest.js b/testdata/pie-nest.js new file mode 100644 index 0000000..90b21ec --- /dev/null +++ b/testdata/pie-nest.js @@ -0,0 +1,97 @@ +/* +title: Nested Pies +category: 'pie, rich' +titleCN: 嵌套环形图 +difficulty: 5 +*/ +option = { + tooltip: { + trigger: 'item', + formatter: '{a}
{b}: {c} ({d}%)' + }, + legend: { + data: [ + 'Direct', + 'Marketing', + 'Search Engine', + 'Email', + 'Union Ads', + 'Video Ads', + 'Baidu', + 'Google', + 'Bing', + 'Others' + ] + }, + series: [ + { + name: 'Access From', + type: 'pie', + selectedMode: 'single', + radius: [0, '30%'], + label: { + position: 'inner', + fontSize: 14 + }, + labelLine: { + show: false + }, + data: [ + { value: 1548, name: 'Search Engine' }, + { value: 775, name: 'Direct' }, + { value: 679, name: 'Marketing', selected: true } + ] + }, + { + name: 'Access From', + type: 'pie', + radius: ['45%', '60%'], + labelLine: { + length: 30 + }, + label: { + formatter: '{a|{a}}{abg|}\n{hr|}\n {b|{b}:}{c} {per|{d}%} ', + backgroundColor: '#F6F8FC', + borderColor: '#8C8D8E', + borderWidth: 1, + borderRadius: 4, + rich: { + a: { + color: '#6E7079', + lineHeight: 22, + align: 'center' + }, + hr: { + borderColor: '#8C8D8E', + width: '100%', + borderWidth: 1, + height: 0 + }, + b: { + color: '#4C5058', + fontSize: 14, + fontWeight: 'bold', + lineHeight: 33 + }, + per: { + color: '#fff', + backgroundColor: '#4C5058', + padding: [3, 4], + borderRadius: 4 + } + } + }, + data: [ + { value: 1048, name: 'Baidu' }, + { value: 335, name: 'Direct' }, + { value: 310, name: 'Email' }, + { value: 251, name: 'Google' }, + { value: 234, name: 'Union Ads' }, + { value: 147, name: 'Bing' }, + { value: 135, name: 'Video Ads' }, + { value: 102, name: 'Others' } + ] + } + ] +}; +export {}; diff --git a/testdata/pie-nest.js.svg b/testdata/pie-nest.js.svg new file mode 100644 index 0000000..6c99963 --- /dev/null +++ b/testdata/pie-nest.js.svg @@ -0,0 +1,259 @@ + + + + + + + + + + + + + + + + + + + + +Search Engine +Direct + + +Access From + + + +Baidu: +1048 + +40.9% + + + +Access From + + + +Direct: +335 + +13.08% + + + +Access From + + + +12.1% +310 + +Email: + + + +Access From + + + +9.8% +251 + +Google: + + + +Access From + + + +9.13% +234 + +Union Ads: + + + +Access From + + + +5.74% +147 + +Bing: + + + +Access From + + + +5.27% +135 + +Video Ads: + + + +Access From + + + +3.98% +102 + +Others: + + +Marketing + + +Direct + +Marketing + +Search Engine + +Email + +Union Ads + +Video Ads + +Baidu + +Google + +Bing + +Others + + \ No newline at end of file diff --git a/testdata/pie-parliament-transition.js b/testdata/pie-parliament-transition.js new file mode 100644 index 0000000..0445d03 --- /dev/null +++ b/testdata/pie-parliament-transition.js @@ -0,0 +1,118 @@ +/* +title: Transition of Parliament and Pie Chart +category: custom, animtion +titleCN: 自定义议会图与饼图过渡动画 +difficulty: 10 +videoStart: 1000 +videoEnd: 6000 +*/ +const data = [ + { value: 800, name: 'A' }, + { value: 635, name: 'B' }, + { value: 580, name: 'C' }, + { value: 484, name: 'D' }, + { value: 300, name: 'E' }, + { value: 200, name: 'F' } +]; +const defaultPalette = [ + // '#51689b', '#ce5c5c', '#fbc357', '#8fbf8f', '#659d84', '#fb8e6a', '#c77288', '#786090', '#91c4c5', '#6890ba' + '#5470c6', + '#91cc75', + '#fac858', + '#ee6666', + '#73c0de', + '#3ba272', + '#fc8452', + '#9a60b4', + '#ea7ccc' +]; +const radius = ['30%', '80%']; +const pieOption = { + series: [ + { + type: 'pie', + id: 'distribution', + radius: radius, + label: { + show: false + }, + universalTransition: true, + animationDurationUpdate: 1000, + data: data + } + ] +}; +const parliamentOption = (function () { + let sum = data.reduce(function (sum, cur) { + return sum + cur.value; + }, 0); + let angles = []; + let startAngle = -Math.PI / 2; + let curAngle = startAngle; + data.forEach(function (item) { + angles.push(curAngle); + curAngle += (item.value / sum) * Math.PI * 2; + }); + angles.push(startAngle + Math.PI * 2); + function parliamentLayout(startAngle, endAngle, totalAngle, r0, r1, size) { + let rowsCount = Math.ceil((r1 - r0) / size); + let points = []; + let r = r0; + for (let i = 0; i < rowsCount; i++) { + // Recalculate size + let totalRingSeatsNumber = Math.round((totalAngle * r) / size); + let newSize = (totalAngle * r) / totalRingSeatsNumber; + for (let k = Math.floor((startAngle * r) / newSize) * newSize; k < Math.floor((endAngle * r) / newSize) * newSize - 1e-6; k += newSize) { + let angle = k / r; + let x = Math.cos(angle) * r; + let y = Math.sin(angle) * r; + points.push([x, y]); + } + r += size; + } + return points; + } + return { + series: { + type: 'custom', + id: 'distribution', + data: data, + coordinateSystem: undefined, + universalTransition: true, + animationDurationUpdate: 1000, + renderItem: function (params, api) { + var idx = params.dataIndex; + var viewSize = Math.min(api.getWidth(), api.getHeight()); + var r0 = ((parseFloat(radius[0]) / 100) * viewSize) / 2; + var r1 = ((parseFloat(radius[1]) / 100) * viewSize) / 2; + var cx = api.getWidth() * 0.5; + var cy = api.getHeight() * 0.5; + var size = viewSize / 50; + var points = parliamentLayout(angles[idx], angles[idx + 1], Math.PI * 2, r0, r1, size + 3); + return { + type: 'group', + children: points.map(function (pt) { + return { + type: 'circle', + autoBatch: true, + shape: { + cx: cx + pt[0], + cy: cy + pt[1], + r: size / 2 + }, + style: { + fill: defaultPalette[idx % defaultPalette.length] + } + }; + }) + }; + } + } + }; +})(); +let currentOption = (option = pieOption); +setInterval(function () { + currentOption = currentOption === pieOption ? parliamentOption : pieOption; + myChart.setOption(currentOption); +}, 2000); +export {}; diff --git a/testdata/pie-parliament-transition.js.svg b/testdata/pie-parliament-transition.js.svg new file mode 100644 index 0000000..34389c6 --- /dev/null +++ b/testdata/pie-parliament-transition.js.svg @@ -0,0 +1,79 @@ + + + + + + + + + + \ No newline at end of file diff --git a/testdata/pie-pattern.js b/testdata/pie-pattern.js new file mode 100644 index 0000000..e51282c --- /dev/null +++ b/testdata/pie-pattern.js @@ -0,0 +1,60 @@ +/* +title: Texture on Pie Chart +category: pie +titleCN: 饼图纹理 +difficulty: 2 +*/ +const piePatternSrc = 'data:image/jpeg;base64,/9j/4AAQSkZJRgABAQAAAQABAAD/2wCEAAQEBAQEBAQEBAQGBgUGBggHBwcHCAwJCQkJ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hh8gkvMc8V72jDtYgXPsdo4XcEr0srZ9uE10ehy7MPvzGmDBjajnBGoPYrvMMM8G5ZEbBB0zYyyFtdhdOAKQL+OooCrdSIEx/DXO5YSJSHcIttVYQqZAgXLMVc1dLB50YPZN4BBcPViNWGD+Cwa+cVI8VaPbJTklGCgFHy3xDDNRkRpq/vZspJgGjV9LjVXbb0I3pUZEJVqLTo2nRBi1nXmxJt4kklikuMcQyAphMSz9Cs//v5BlN+3x2en/j6SmBN+jIqblnCTvg3McI6elPGL4EZ7yhh9xPUzpSBSnv89XiDJ1LAQS0g5QPFvtd0dpJh0vEu8eIBiopXTSHd1rT4qeAdZOkh1AkixJQLOPmEcnYh5cQnSwy5MDuSBVSLmWWJgLSUS+OJkRIwlApMJEYn2slj0Nr79RtK5JmOANpwSS/9uEbBUVCRLKGRpUz9qxUCDw+q5STXbRAXLXMVeUcg9An901p7zro3b5DYC6xqUwVHoGHwmnhJSItJVzFDGH91B0AQNEoW4SJDZDaaL2U+lo7PRMsTyVbjqgRhcaUoV+QkKUL6Z4g2/jL2iQdfl49g54eH9r6872s+3Os62t+9udTufp0+0ftjt3ftjqdDa3O3c6d54962w93O48297evrt9Z/vb7e07m1udO9t3trc6d7fvdLbvdp7dvX93e3u7s/3t1t2tztbm3U7nh637m5sP7z/c7DzdfLi5ufn7zYf3Nz9/eP/p099vdrbvPPu8c+eHTqfz8O7m0879rc7mw4ebTz/fvL+1udX5vLO1ufXD9t2tTueHrWfPvv1h89nnd+88e9i5v3n32Z1vt7fubD/sdLbvdDa3H96///nnm0+f3v8//xcn+8ysvLHpFAAAAABJRU5ErkJggg=='; +const piePatternImg = new Image(); +piePatternImg.src = piePatternSrc; +const bgPatternImg = new Image(); +bgPatternImg.src = bgPatternSrc; +option = { + backgroundColor: { + image: bgPatternImg, + repeat: 'repeat' + }, + title: { + text: '饼图纹理', + textStyle: { + color: '#235894' + } + }, + tooltip: {}, + series: [ + { + name: 'pie', + type: 'pie', + selectedMode: 'single', + selectedOffset: 30, + clockwise: true, + label: { + fontSize: 18, + color: '#235894' + }, + labelLine: { + lineStyle: { + color: '#235894' + } + }, + data: [ + { value: 1048, name: 'Search Engine' }, + { value: 735, name: 'Direct' }, + { value: 580, name: 'Email' }, + { value: 484, name: 'Union Ads' }, + { value: 300, name: 'Video Ads' } + ], + itemStyle: { + opacity: 0.7, + color: { + image: piePatternImg, + repeat: 'repeat' + }, + borderWidth: 3, + borderColor: '#235894' + } + } + ] +}; +export {}; diff --git a/testdata/pie-rich-text.js b/testdata/pie-rich-text.js new file mode 100644 index 0000000..9a25c97 --- /dev/null +++ b/testdata/pie-rich-text.js @@ -0,0 +1,134 @@ +/* +title: Pie Special Label +category: 'pie, rich' +titleCN: 富文本标签 +difficulty: 4 +*/ +const weatherIcons = { + Sunny: ROOT_PATH + '/data/asset/img/weather/sunny_128.png', + Cloudy: ROOT_PATH + '/data/asset/img/weather/cloudy_128.png', + Showers: ROOT_PATH + '/data/asset/img/weather/showers_128.png' +}; +option = { + title: { + text: 'Weather Statistics', + subtext: 'Fake Data', + left: 'center' + }, + tooltip: { + trigger: 'item', + formatter: '{a}
{b} : {c} ({d}%)' + }, + legend: { + bottom: 10, + left: 'center', + data: ['CityA', 'CityB', 'CityD', 'CityC', 'CityE'] + }, + series: [ + { + type: 'pie', + radius: '65%', + center: ['50%', '50%'], + selectedMode: 'single', + data: [ + { + value: 1548, + name: 'CityE', + label: { + formatter: [ + '{title|{b}}{abg|}', + ' {weatherHead|Weather}{valueHead|Days}{rateHead|Percent}', + '{hr|}', + ' {Sunny|}{value|202}{rate|55.3%}', + ' {Cloudy|}{value|142}{rate|38.9%}', + ' {Showers|}{value|21}{rate|5.8%}' + ].join('\n'), + backgroundColor: '#eee', + borderColor: '#777', + borderWidth: 1, + borderRadius: 4, + rich: { + title: { + color: '#eee', + align: 'center' + }, + abg: { + backgroundColor: '#333', + width: '100%', + align: 'right', + height: 25, + borderRadius: [4, 4, 0, 0] + }, + Sunny: { + height: 30, + align: 'left', + backgroundColor: { + image: weatherIcons.Sunny + } + }, + Cloudy: { + height: 30, + align: 'left', + backgroundColor: { + image: weatherIcons.Cloudy + } + }, + Showers: { + height: 30, + align: 'left', + backgroundColor: { + image: weatherIcons.Showers + } + }, + weatherHead: { + color: '#333', + height: 24, + align: 'left' + }, + hr: { + borderColor: '#777', + width: '100%', + borderWidth: 0.5, + height: 0 + }, + value: { + width: 20, + padding: [0, 20, 0, 30], + align: 'left' + }, + valueHead: { + color: '#333', + width: 20, + padding: [0, 20, 0, 30], + align: 'center' + }, + rate: { + width: 40, + align: 'right', + padding: [0, 10, 0, 0] + }, + rateHead: { + color: '#333', + width: 40, + align: 'center', + padding: [0, 10, 0, 0] + } + } + } + }, + { value: 735, name: 'CityC' }, + { value: 510, name: 'CityD' }, + { value: 434, name: 'CityB' }, + { value: 335, name: 'CityA' } + ], + emphasis: { + itemStyle: { + shadowBlur: 10, + shadowOffsetX: 0, + shadowColor: 'rgba(0, 0, 0, 0.5)' + } + } + } + ] +}; +export {}; diff --git a/testdata/pie-roseType-simple.js b/testdata/pie-roseType-simple.js new file mode 100644 index 0000000..2eae0ad --- /dev/null +++ b/testdata/pie-roseType-simple.js @@ -0,0 +1,44 @@ +/* +title: Nightingale Chart +category: pie +titleCN: 基础南丁格尔玫瑰图 +shotWidth: 800 +difficulty: 2 +*/ +option = { + legend: { + top: 'bottom' + }, + toolbox: { + show: true, + feature: { + mark: { show: true }, + dataView: { show: true, readOnly: false }, + restore: { show: true }, + saveAsImage: { show: true } + } + }, + series: [ + { + name: 'Nightingale Chart', + type: 'pie', + radius: [50, 250], + center: ['50%', '50%'], + roseType: 'area', + itemStyle: { + borderRadius: 8 + }, + data: [ + { value: 40, name: 'rose 1' }, + { value: 38, name: 'rose 2' }, + { value: 32, name: 'rose 3' }, + { value: 30, name: 'rose 4' }, + { value: 28, name: 'rose 5' }, + { value: 26, name: 'rose 6' }, + { value: 22, name: 'rose 7' }, + { value: 18, name: 'rose 8' } + ] + } + ] +}; +export {}; diff --git a/testdata/pie-roseType-simple.js.svg b/testdata/pie-roseType-simple.js.svg new file mode 100644 index 0000000..c479a35 --- /dev/null +++ b/testdata/pie-roseType-simple.js.svg @@ -0,0 +1,140 @@ + + + + + + + + + + + + + + + + + + +rose 1 +rose 2 +rose 3 +rose 4 +rose 5 +rose 6 +rose 7 +rose 8 + + +rose 1 + +rose 2 + +rose 3 + +rose 4 + +rose 5 + +rose 6 + +rose 7 + +rose 8 + + + + + + \ No newline at end of file diff --git a/testdata/pie-roseType.js b/testdata/pie-roseType.js new file mode 100644 index 0000000..4708da7 --- /dev/null +++ b/testdata/pie-roseType.js @@ -0,0 +1,91 @@ +/* +title: Nightingale Chart +category: pie +titleCN: 南丁格尔玫瑰图 +difficulty: 2 +*/ +option = { + title: { + text: 'Nightingale Chart', + subtext: 'Fake Data', + left: 'center' + }, + tooltip: { + trigger: 'item', + formatter: '{a}
{b} : {c} ({d}%)' + }, + legend: { + left: 'center', + top: 'bottom', + data: [ + 'rose1', + 'rose2', + 'rose3', + 'rose4', + 'rose5', + 'rose6', + 'rose7', + 'rose8' + ] + }, + toolbox: { + show: true, + feature: { + mark: { show: true }, + dataView: { show: true, readOnly: false }, + restore: { show: true }, + saveAsImage: { show: true } + } + }, + series: [ + { + name: 'Radius Mode', + type: 'pie', + radius: [20, 140], + center: ['25%', '50%'], + roseType: 'radius', + itemStyle: { + borderRadius: 5 + }, + label: { + show: false + }, + emphasis: { + label: { + show: true + } + }, + data: [ + { value: 40, name: 'rose 1' }, + { value: 33, name: 'rose 2' }, + { value: 28, name: 'rose 3' }, + { value: 22, name: 'rose 4' }, + { value: 20, name: 'rose 5' }, + { value: 15, name: 'rose 6' }, + { value: 12, name: 'rose 7' }, + { value: 10, name: 'rose 8' } + ] + }, + { + name: 'Area Mode', + type: 'pie', + radius: [20, 140], + center: ['75%', '50%'], + roseType: 'area', + itemStyle: { + borderRadius: 5 + }, + data: [ + { value: 30, name: 'rose 1' }, + { value: 28, name: 'rose 2' }, + { value: 26, name: 'rose 3' }, + { value: 24, name: 'rose 4' }, + { value: 22, name: 'rose 5' }, + { value: 20, name: 'rose 6' }, + { value: 18, name: 'rose 7' }, + { value: 16, name: 'rose 8' } + ] + } + ] +}; +export {}; diff --git a/testdata/pie-roseType.js.svg b/testdata/pie-roseType.js.svg new file mode 100644 index 0000000..3a46cb5 --- /dev/null +++ b/testdata/pie-roseType.js.svg @@ -0,0 +1,223 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + +rose 1 +rose 2 +rose 3 +rose 4 +rose 5 +rose 6 +rose 7 +rose 8 + + + + + + +Nightingale Chart +Fake Data + + \ No newline at end of file diff --git a/testdata/pie-simple.js b/testdata/pie-simple.js new file mode 100644 index 0000000..bd775b4 --- /dev/null +++ b/testdata/pie-simple.js @@ -0,0 +1,42 @@ +/* +title: Referer of a Website +category: pie +titleCN: 某站点用户Access From +difficulty: 0 +*/ +option = { + title: { + text: 'Referer of a Website', + subtext: 'Fake Data', + left: 'center' + }, + tooltip: { + trigger: 'item' + }, + legend: { + orient: 'vertical', + left: 'left' + }, + series: [ + { + name: 'Access From', + type: 'pie', + radius: '50%', + data: [ + { value: 1048, name: 'Search Engine' }, + { value: 735, name: 'Direct' }, + { value: 580, name: 'Email' }, + { value: 484, name: 'Union Ads' }, + { value: 300, name: 'Video Ads' } + ], + emphasis: { + itemStyle: { + shadowBlur: 10, + shadowOffsetX: 0, + shadowColor: 'rgba(0, 0, 0, 0.5)' + } + } + } + ] +}; +export {}; diff --git a/testdata/pie-simple.js.svg b/testdata/pie-simple.js.svg new file mode 100644 index 0000000..a7bd660 --- /dev/null +++ b/testdata/pie-simple.js.svg @@ -0,0 +1,91 @@ + + + + + + + + + + + + +Search Engine +Direct +Email +Union Ads +Video Ads + + +Search Engine + +Direct + +Email + +Union Ads + +Video Ads + +Referer of a Website +Fake Data + + \ No newline at end of file diff --git a/testdata/polar-roundCap.js b/testdata/polar-roundCap.js new file mode 100644 index 0000000..a753aef --- /dev/null +++ b/testdata/polar-roundCap.js @@ -0,0 +1,51 @@ +/* +title: Rounded Bar on Polar +category: bar +titleCN: 圆角环形图 +difficulty: 7 +*/ +option = { + angleAxis: { + max: 2, + startAngle: 30, + splitLine: { + show: false + } + }, + radiusAxis: { + type: 'category', + data: ['v', 'w', 'x', 'y', 'z'], + z: 10 + }, + polar: {}, + series: [ + { + type: 'bar', + data: [4, 3, 2, 1, 0], + coordinateSystem: 'polar', + name: 'Without Round Cap', + itemStyle: { + borderColor: 'red', + opacity: 0.8, + borderWidth: 1 + } + }, + { + type: 'bar', + data: [4, 3, 2, 1, 0], + coordinateSystem: 'polar', + name: 'With Round Cap', + roundCap: true, + itemStyle: { + borderColor: 'green', + opacity: 0.8, + borderWidth: 1 + } + } + ], + legend: { + show: true, + data: ['Without Round Cap', 'With Round Cap'] + } +}; +export {}; diff --git a/testdata/polar-roundCap.js.svg b/testdata/polar-roundCap.js.svg new file mode 100644 index 0000000..1c7c108 --- /dev/null +++ b/testdata/polar-roundCap.js.svg @@ -0,0 +1,57 @@ + + +0 +0.2 +0.4 +0.6 +0.8 +1 +1.2 +1.4 +1.6 +1.8 + + + + + + + + + + + + + + +Without Round Cap + +With Round Cap + + + + + + + +v +w +x +y +z + + \ No newline at end of file diff --git a/testdata/radar-aqi.js b/testdata/radar-aqi.js new file mode 100644 index 0000000..50f0646 --- /dev/null +++ b/testdata/radar-aqi.js @@ -0,0 +1,208 @@ +/* +title: AQI - Radar Chart +category: radar +titleCN: AQI - 雷达图 +difficulty: 1 +*/ +// Schema: +// date,AQIindex,PM2.5,PM10,CO,NO2,SO2 +const dataBJ = [ + [55, 9, 56, 0.46, 18, 6, 1], + [25, 11, 21, 0.65, 34, 9, 2], + [56, 7, 63, 0.3, 14, 5, 3], + [33, 7, 29, 0.33, 16, 6, 4], + [42, 24, 44, 0.76, 40, 16, 5], + [82, 58, 90, 1.77, 68, 33, 6], + [74, 49, 77, 1.46, 48, 27, 7], + [78, 55, 80, 1.29, 59, 29, 8], + [267, 216, 280, 4.8, 108, 64, 9], + [185, 127, 216, 2.52, 61, 27, 10], + [39, 19, 38, 0.57, 31, 15, 11], + [41, 11, 40, 0.43, 21, 7, 12], + [64, 38, 74, 1.04, 46, 22, 13], + [108, 79, 120, 1.7, 75, 41, 14], + [108, 63, 116, 1.48, 44, 26, 15], + [33, 6, 29, 0.34, 13, 5, 16], + [94, 66, 110, 1.54, 62, 31, 17], + [186, 142, 192, 3.88, 93, 79, 18], + [57, 31, 54, 0.96, 32, 14, 19], + [22, 8, 17, 0.48, 23, 10, 20], + [39, 15, 36, 0.61, 29, 13, 21], + [94, 69, 114, 2.08, 73, 39, 22], + [99, 73, 110, 2.43, 76, 48, 23], + [31, 12, 30, 0.5, 32, 16, 24], + [42, 27, 43, 1, 53, 22, 25], + [154, 117, 157, 3.05, 92, 58, 26], + [234, 185, 230, 4.09, 123, 69, 27], + [160, 120, 186, 2.77, 91, 50, 28], + [134, 96, 165, 2.76, 83, 41, 29], + [52, 24, 60, 1.03, 50, 21, 30], + [46, 5, 49, 0.28, 10, 6, 31] +]; +const dataGZ = [ + [26, 37, 27, 1.163, 27, 13, 1], + [85, 62, 71, 1.195, 60, 8, 2], + [78, 38, 74, 1.363, 37, 7, 3], + [21, 21, 36, 0.634, 40, 9, 4], + [41, 42, 46, 0.915, 81, 13, 5], + [56, 52, 69, 1.067, 92, 16, 6], + [64, 30, 28, 0.924, 51, 2, 7], + [55, 48, 74, 1.236, 75, 26, 8], + [76, 85, 113, 1.237, 114, 27, 9], + [91, 81, 104, 1.041, 56, 40, 10], + [84, 39, 60, 0.964, 25, 11, 11], + [64, 51, 101, 0.862, 58, 23, 12], + [70, 69, 120, 1.198, 65, 36, 13], + [77, 105, 178, 2.549, 64, 16, 14], + [109, 68, 87, 0.996, 74, 29, 15], + [73, 68, 97, 0.905, 51, 34, 16], + [54, 27, 47, 0.592, 53, 12, 17], + [51, 61, 97, 0.811, 65, 19, 18], + [91, 71, 121, 1.374, 43, 18, 19], + [73, 102, 182, 2.787, 44, 19, 20], + [73, 50, 76, 0.717, 31, 20, 21], + [84, 94, 140, 2.238, 68, 18, 22], + [93, 77, 104, 1.165, 53, 7, 23], + [99, 130, 227, 3.97, 55, 15, 24], + [146, 84, 139, 1.094, 40, 17, 25], + [113, 108, 137, 1.481, 48, 15, 26], + [81, 48, 62, 1.619, 26, 3, 27], + [56, 48, 68, 1.336, 37, 9, 28], + [82, 92, 174, 3.29, 0, 13, 29], + [106, 116, 188, 3.628, 101, 16, 30], + [118, 50, 0, 1.383, 76, 11, 31] +]; +const dataSH = [ + [91, 45, 125, 0.82, 34, 23, 1], + [65, 27, 78, 0.86, 45, 29, 2], + [83, 60, 84, 1.09, 73, 27, 3], + [109, 81, 121, 1.28, 68, 51, 4], + [106, 77, 114, 1.07, 55, 51, 5], + [109, 81, 121, 1.28, 68, 51, 6], + [106, 77, 114, 1.07, 55, 51, 7], + [89, 65, 78, 0.86, 51, 26, 8], + [53, 33, 47, 0.64, 50, 17, 9], + [80, 55, 80, 1.01, 75, 24, 10], + [117, 81, 124, 1.03, 45, 24, 11], + [99, 71, 142, 1.1, 62, 42, 12], + [95, 69, 130, 1.28, 74, 50, 13], + [116, 87, 131, 1.47, 84, 40, 14], + [108, 80, 121, 1.3, 85, 37, 15], + [134, 83, 167, 1.16, 57, 43, 16], + [79, 43, 107, 1.05, 59, 37, 17], + [71, 46, 89, 0.86, 64, 25, 18], + [97, 71, 113, 1.17, 88, 31, 19], + [84, 57, 91, 0.85, 55, 31, 20], + [87, 63, 101, 0.9, 56, 41, 21], + [104, 77, 119, 1.09, 73, 48, 22], + [87, 62, 100, 1, 72, 28, 23], + [168, 128, 172, 1.49, 97, 56, 24], + [65, 45, 51, 0.74, 39, 17, 25], + [39, 24, 38, 0.61, 47, 17, 26], + [39, 24, 39, 0.59, 50, 19, 27], + [93, 68, 96, 1.05, 79, 29, 28], + [188, 143, 197, 1.66, 99, 51, 29], + [174, 131, 174, 1.55, 108, 50, 30], + [187, 143, 201, 1.39, 89, 53, 31] +]; +const lineStyle = { + width: 1, + opacity: 0.5 +}; +option = { + backgroundColor: '#161627', + title: { + text: 'AQI - Radar', + left: 'center', + textStyle: { + color: '#eee' + } + }, + legend: { + bottom: 5, + data: ['Beijing', 'Shanghai', 'Guangzhou'], + itemGap: 20, + textStyle: { + color: '#fff', + fontSize: 14 + }, + selectedMode: 'single' + }, + radar: { + indicator: [ + { name: 'AQI', max: 300 }, + { name: 'PM2.5', max: 250 }, + { name: 'PM10', max: 300 }, + { name: 'CO', max: 5 }, + { name: 'NO2', max: 200 }, + { name: 'SO2', max: 100 } + ], + shape: 'circle', + splitNumber: 5, + axisName: { + color: 'rgb(238, 197, 102)' + }, + splitLine: { + lineStyle: { + color: [ + 'rgba(238, 197, 102, 0.1)', + 'rgba(238, 197, 102, 0.2)', + 'rgba(238, 197, 102, 0.4)', + 'rgba(238, 197, 102, 0.6)', + 'rgba(238, 197, 102, 0.8)', + 'rgba(238, 197, 102, 1)' + ].reverse() + } + }, + splitArea: { + show: false + }, + axisLine: { + lineStyle: { + color: 'rgba(238, 197, 102, 0.5)' + } + } + }, + series: [ + { + name: 'Beijing', + type: 'radar', + lineStyle: lineStyle, + data: dataBJ, + symbol: 'none', + itemStyle: { + color: '#F9713C' + }, + areaStyle: { + opacity: 0.1 + } + }, + { + name: 'Shanghai', + type: 'radar', + lineStyle: lineStyle, + data: dataSH, + symbol: 'none', + itemStyle: { + color: '#B3E4A1' + }, + areaStyle: { + opacity: 0.05 + } + }, + { + name: 'Guangzhou', + type: 'radar', + lineStyle: lineStyle, + data: dataGZ, + symbol: 'none', + itemStyle: { + color: 'rgb(238, 197, 102)' + }, + areaStyle: { + opacity: 0.05 + } + } + ] +}; +export {}; diff --git a/testdata/radar-aqi.js.svg b/testdata/radar-aqi.js.svg new file mode 100644 index 0000000..59c2a6d --- /dev/null +++ b/testdata/radar-aqi.js.svg @@ -0,0 +1,92 @@ + + + + + + + + + +AQI + +PM2.5 + +PM10 + +CO + +NO2 + +SO2 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Beijing + +Shanghai + +Guangzhou + +AQI - Radar + \ No newline at end of file diff --git a/testdata/radar-custom.js b/testdata/radar-custom.js new file mode 100644 index 0000000..21a6cf5 --- /dev/null +++ b/testdata/radar-custom.js @@ -0,0 +1,129 @@ +/* +title: Customized Radar Chart +category: radar +titleCN: 自定义雷达图 +difficulty: 2 +*/ +option = { + color: ['#67F9D8', '#FFE434', '#56A3F1', '#FF917C'], + title: { + text: 'Customized Radar Chart' + }, + legend: {}, + radar: [ + { + indicator: [ + { text: 'Indicator1' }, + { text: 'Indicator2' }, + { text: 'Indicator3' }, + { text: 'Indicator4' }, + { text: 'Indicator5' } + ], + center: ['25%', '50%'], + radius: 120, + startAngle: 90, + splitNumber: 4, + shape: 'circle', + axisName: { + formatter: '【{value}】', + color: '#428BD4' + }, + splitArea: { + areaStyle: { + color: ['#77EADF', '#26C3BE', '#64AFE9', '#428BD4'], + shadowColor: 'rgba(0, 0, 0, 0.2)', + shadowBlur: 10 + } + }, + axisLine: { + lineStyle: { + color: 'rgba(211, 253, 250, 0.8)' + } + }, + splitLine: { + lineStyle: { + color: 'rgba(211, 253, 250, 0.8)' + } + } + }, + { + indicator: [ + { text: 'Indicator1', max: 150 }, + { text: 'Indicator2', max: 150 }, + { text: 'Indicator3', max: 150 }, + { text: 'Indicator4', max: 120 }, + { text: 'Indicator5', max: 108 }, + { text: 'Indicator6', max: 72 } + ], + center: ['75%', '50%'], + radius: 120, + axisName: { + color: '#fff', + backgroundColor: '#666', + borderRadius: 3, + padding: [3, 5] + } + } + ], + series: [ + { + type: 'radar', + emphasis: { + lineStyle: { + width: 4 + } + }, + data: [ + { + value: [100, 8, 0.4, -80, 2000], + name: 'Data A' + }, + { + value: [60, 5, 0.3, -100, 1500], + name: 'Data B', + areaStyle: { + color: 'rgba(255, 228, 52, 0.6)' + } + } + ] + }, + { + type: 'radar', + radarIndex: 1, + data: [ + { + value: [120, 118, 130, 100, 99, 70], + name: 'Data C', + symbol: 'rect', + symbolSize: 12, + lineStyle: { + type: 'dashed' + }, + label: { + show: true, + formatter: function (params) { + return params.value; + } + } + }, + { + value: [100, 93, 50, 90, 70, 60], + name: 'Data D', + areaStyle: { + color: new echarts.graphic.RadialGradient(0.1, 0.6, 1, [ + { + color: 'rgba(255, 145, 124, 0.1)', + offset: 0 + }, + { + color: 'rgba(255, 145, 124, 0.9)', + offset: 1 + } + ]) + } + } + ] + } + ] +}; +export {}; diff --git a/testdata/radar-custom.js.svg b/testdata/radar-custom.js.svg new file mode 100644 index 0000000..9675caa --- /dev/null +++ b/testdata/radar-custom.js.svg @@ -0,0 +1,93 @@ + + + + + + + + + + + +【Indicator1】 + +【Indicator2】 + +【Indicator3】 + +【Indicator4】 + +【Indicator5】 + + +Indicator1 + + +Indicator2 + + +Indicator3 + + +Indicator4 + + +Indicator5 + + +Indicator6 + + + + + + + + + + + + + + + + + + + + + + + + + + + + +120 +118 +130 +100 +99 +70 + + +Data A + +Data B + +Data C + +Data D + +Customized Radar Chart + + + + + + + + + + \ No newline at end of file diff --git a/testdata/radar-multiple.js b/testdata/radar-multiple.js new file mode 100644 index 0000000..eaac01f --- /dev/null +++ b/testdata/radar-multiple.js @@ -0,0 +1,107 @@ +/* +title: Multiple Radar +category: radar +titleCN: 多雷达图 +*/ +option = { + title: { + text: 'Multiple Radar' + }, + tooltip: { + trigger: 'axis' + }, + legend: { + left: 'center', + data: [ + 'A Software', + 'A Phone', + 'Another Phone', + 'Precipitation', + 'Evaporation' + ] + }, + radar: [ + { + indicator: [ + { text: 'Brand', max: 100 }, + { text: 'Content', max: 100 }, + { text: 'Usability', max: 100 }, + { text: 'Function', max: 100 } + ], + center: ['25%', '40%'], + radius: 80 + }, + { + indicator: [ + { text: 'Look', max: 100 }, + { text: 'Photo', max: 100 }, + { text: 'System', max: 100 }, + { text: 'Performance', max: 100 }, + { text: 'Screen', max: 100 } + ], + radius: 80, + center: ['50%', '60%'] + }, + { + indicator: (function () { + var res = []; + for (var i = 1; i <= 12; i++) { + res.push({ text: i + '月', max: 100 }); + } + return res; + })(), + center: ['75%', '40%'], + radius: 80 + } + ], + series: [ + { + type: 'radar', + tooltip: { + trigger: 'item' + }, + areaStyle: {}, + data: [ + { + value: [60, 73, 85, 40], + name: 'A Software' + } + ] + }, + { + type: 'radar', + radarIndex: 1, + areaStyle: {}, + data: [ + { + value: [85, 90, 90, 95, 95], + name: 'A Phone' + }, + { + value: [95, 80, 95, 90, 93], + name: 'Another Phone' + } + ] + }, + { + type: 'radar', + radarIndex: 2, + areaStyle: {}, + data: [ + { + name: 'Precipitation', + value: [ + 2.6, 5.9, 9.0, 26.4, 28.7, 70.7, 75.6, 82.2, 48.7, 18.8, 6.0, 2.3 + ] + }, + { + name: 'Evaporation', + value: [ + 2.0, 4.9, 7.0, 23.2, 25.6, 76.7, 35.6, 62.2, 32.6, 20.0, 6.4, 3.3 + ] + } + ] + } + ] +}; +export {}; diff --git a/testdata/radar-multiple.js.svg b/testdata/radar-multiple.js.svg new file mode 100644 index 0000000..56c1290 --- /dev/null +++ b/testdata/radar-multiple.js.svg @@ -0,0 +1,115 @@ + + + + + + + + + + + + +Brand + +Content + +Usability + +Function + +Look + +Photo + +System + +Performance + +Screen + +1月 + +2月 + +3月 + +4月 + +5月 + +6月 + +7月 + +8月 + +9月 + +10月 + +11月 + +12月 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +A Software + +A Phone + +Another Phone + +Precipitation + +Evaporation + +Multiple Radar + \ No newline at end of file diff --git a/testdata/radar.js b/testdata/radar.js new file mode 100644 index 0000000..d95cfcb --- /dev/null +++ b/testdata/radar.js @@ -0,0 +1,42 @@ +/* +title: Basic Radar Chart +category: radar +titleCN: 基础雷达图 +difficulty: 0 +*/ +option = { + title: { + text: 'Basic Radar Chart' + }, + legend: { + data: ['Allocated Budget', 'Actual Spending'] + }, + radar: { + // shape: 'circle', + indicator: [ + { name: 'Sales', max: 6500 }, + { name: 'Administration', max: 16000 }, + { name: 'Information Technology', max: 30000 }, + { name: 'Customer Support', max: 38000 }, + { name: 'Development', max: 52000 }, + { name: 'Marketing', max: 25000 } + ] + }, + series: [ + { + name: 'Budget vs spending', + type: 'radar', + data: [ + { + value: [4200, 3000, 20000, 35000, 50000, 18000], + name: 'Allocated Budget' + }, + { + value: [5000, 14000, 28000, 26000, 42000, 21000], + name: 'Actual Spending' + } + ] + } + ] +}; +export {}; diff --git a/testdata/radar.js.svg b/testdata/radar.js.svg new file mode 100644 index 0000000..a34dd11 --- /dev/null +++ b/testdata/radar.js.svg @@ -0,0 +1,39 @@ + + + + + + +Sales + +Administration + +Information Technology + +Customer Support + +Development + +Marketing + + + + + + + + + + + + + + + + +Allocated Budget + +Actual Spending + +Basic Radar Chart + \ No newline at end of file diff --git a/testdata/radar2.js b/testdata/radar2.js new file mode 100644 index 0000000..46909c1 --- /dev/null +++ b/testdata/radar2.js @@ -0,0 +1,74 @@ +/* +title: Proportion of Browsers +category: radar +titleCN: 浏览器占比变化 +difficulty: 3 +*/ +option = { + title: { + text: 'Proportion of Browsers', + subtext: 'Fake Data', + top: 10, + left: 10 + }, + tooltip: { + trigger: 'item' + }, + legend: { + type: 'scroll', + bottom: 10, + data: (function () { + var list = []; + for (var i = 1; i <= 28; i++) { + list.push(i + 2000 + ''); + } + return list; + })() + }, + visualMap: { + top: 'middle', + right: 10, + color: ['red', 'yellow'], + calculable: true + }, + radar: { + indicator: [ + { text: 'IE8-', max: 400 }, + { text: 'IE9+', max: 400 }, + { text: 'Safari', max: 400 }, + { text: 'Firefox', max: 400 }, + { text: 'Chrome', max: 400 } + ] + }, + series: (function () { + var series = []; + for (var i = 1; i <= 28; i++) { + series.push({ + type: 'radar', + symbol: 'none', + lineStyle: { + width: 1 + }, + emphasis: { + areaStyle: { + color: 'rgba(0,250,0,0.3)' + } + }, + data: [ + { + value: [ + (40 - i) * 10, + (38 - i) * 4 + 60, + i * 5 + 10, + i * 9, + (i * i) / 2 + ], + name: i + 2000 + '' + } + ] + }); + } + return series; + })() +}; +export {}; diff --git a/testdata/radar2.js.svg b/testdata/radar2.js.svg new file mode 100644 index 0000000..5038db1 --- /dev/null +++ b/testdata/radar2.js.svg @@ -0,0 +1,332 @@ + + + + + + +IE8- + +IE9+ + +Safari + +Firefox + +Chrome + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +0 +200 + + + + + + + + +2001 + +2002 + +2003 + +2004 + +2005 + +2006 + +2007 + +2008 + +2009 + +2010 + +2011 + +2012 + +2013 + +2014 + +2015 + +2016 + +2017 + +2018 + +2019 + +2020 + +2021 + +2022 + +2023 + +2024 + +2025 + +2026 + +2027 + +2028 + + +1/3 + + +Proportion of Browsers +Fake Data + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/sankey-energy.js b/testdata/sankey-energy.js new file mode 100644 index 0000000..221f1cb --- /dev/null +++ b/testdata/sankey-energy.js @@ -0,0 +1,34 @@ +/* +title: Gradient Edge +category: sankey +titleCN: 桑基图渐变色边 +difficulty: 3 +*/ +myChart.showLoading(); +$.get(ROOT_PATH + '/data/asset/data/energy.json', function (data) { + myChart.hideLoading(); + myChart.setOption((option = { + title: { + text: 'Sankey Diagram' + }, + tooltip: { + trigger: 'item', + triggerOn: 'mousemove' + }, + series: [ + { + type: 'sankey', + data: data.nodes, + links: data.links, + emphasis: { + focus: 'adjacency' + }, + lineStyle: { + color: 'gradient', + curveness: 0.5 + } + } + ] + })); +}); +export {}; diff --git a/testdata/sankey-itemstyle.js b/testdata/sankey-itemstyle.js new file mode 100644 index 0000000..fc04630 --- /dev/null +++ b/testdata/sankey-itemstyle.js @@ -0,0 +1,1281 @@ +/* +title: Specify ItemStyle for Each Node in Sankey +category: sankey +titleCN: 桑基图节点自定义样式 +difficulty: 2 +*/ +option = { + backgroundColor: '#fff', + title: { + subtext: 'Data From lisachristina1234 on GitHub', + left: 'center' + }, + series: [ + { + type: 'sankey', + left: 50.0, + top: 20.0, + right: 150.0, + bottom: 25.0, + data: [ + { + name: 'Werne', + itemStyle: { + color: '#f18bbf', + borderColor: '#f18bbf' + } + }, + { + name: 'Duesseldorf', + itemStyle: { + color: '#0078D7', + borderColor: '#0078D7' + } + }, + { + name: 'Cambridge', + itemStyle: { + color: '#3891A7', + borderColor: '#3891A7' + } + }, + { + name: 'Colma', + itemStyle: { + color: '#0037DA', + borderColor: '#0037DA' + } + }, + { + name: 'W. York', + itemStyle: { + color: '#C0BEAF', + borderColor: '#C0BEAF' + } + }, + { + name: 'Frankfurt am Main', + itemStyle: { + color: '#EA005E', + borderColor: '#EA005E' + } + }, + { + name: 'Metz', + itemStyle: { + color: '#D13438', + borderColor: '#D13438' + } + }, + { + name: 'Orleans', + itemStyle: { + color: '#567C73', + borderColor: '#567C73' + } + }, + { + name: 'Saint-Denis', + itemStyle: { + color: '#9ed566', + borderColor: '#9ed566' + } + }, + { + name: 'Hof', + itemStyle: { + color: '#2BCC7F', + borderColor: '#2BCC7F' + } + }, + { + name: 'Cliffside', + itemStyle: { + color: '#809B48', + borderColor: '#809B48' + } + }, + { + name: 'Leeds', + itemStyle: { + color: '#9B2D1F', + borderColor: '#9B2D1F' + } + }, + { + name: 'Victoria', + itemStyle: { + color: '#604878', + borderColor: '#604878' + } + }, + { + name: 'Erlangen', + itemStyle: { + color: '#A5644E', + borderColor: '#A5644E' + } + }, + { + name: 'Saint Germain en Laye', + itemStyle: { + color: '#2D3F3A', + borderColor: '#2D3F3A' + } + }, + { + name: 'Roissy en Brie', + itemStyle: { + color: '#761721', + borderColor: '#761721' + } + }, + { + name: 'Wokingham', + itemStyle: { + color: '#B1BADD', + borderColor: '#B1BADD' + } + }, + { + name: 'Runcorn', + itemStyle: { + color: '#B0CCB0', + borderColor: '#B0CCB0' + } + }, + { + name: 'Newton', + itemStyle: { + color: '#8164A3', + borderColor: '#8164A3' + } + }, + { + name: 'Morangis', + itemStyle: { + color: '#8E562E', + borderColor: '#8E562E' + } + }, + { + name: 'Metchosin', + itemStyle: { + color: '#C1504D', + borderColor: '#C1504D' + } + }, + { + name: 'Kirkby', + itemStyle: { + color: '#CCAF0A', + borderColor: '#CCAF0A' + } + }, + { + name: 'London', + itemStyle: { + color: '#956251', + borderColor: '#956251' + } + }, + { + name: 'Offenbach', + itemStyle: { + color: '#C17529', + borderColor: '#C17529' + } + }, + { + name: 'Warrington', + itemStyle: { + color: '#CEC597', + borderColor: '#CEC597' + } + }, + { + name: 'Vancouver', + itemStyle: { + color: '#9F2936', + borderColor: '#9F2936' + } + }, + { + name: 'SuperiorCard', + itemStyle: { + color: 'rgba(128,155,72,255)', + borderColor: 'rgba(128,155,72,255)' + } + }, + { + name: 'Lille', + itemStyle: { + color: '#ac7430', + borderColor: '#ac7430' + } + }, + { + name: 'Hamburg', + itemStyle: { + color: '#00BCF2', + borderColor: '#00BCF2' + } + }, + { + name: 'Langley', + itemStyle: { + color: '#CD7B38', + borderColor: '#CD7B38' + } + }, + { + name: 'Les Ulis', + itemStyle: { + color: '#424242', + borderColor: '#424242' + } + }, + { + name: 'Saarbrücken', + itemStyle: { + color: '#f63185', + borderColor: '#f63185' + } + }, + { + name: 'N. Vancouver', + itemStyle: { + color: '#9CBC59', + borderColor: '#9CBC59' + } + }, + { + name: 'Chalk Riber', + itemStyle: { + color: '#4F4BD9', + borderColor: '#4F4BD9' + } + }, + { + name: 'Esher-Molesey', + itemStyle: { + color: '#3EC562', + borderColor: '#3EC562' + } + }, + { + name: 'Chatou', + itemStyle: { + color: '#F06F2E', + borderColor: '#F06F2E' + } + }, + { + name: 'Hannover', + itemStyle: { + color: '#C3986D', + borderColor: '#C3986D' + } + }, + { + name: 'Roncq', + itemStyle: { + color: '#4D291C', + borderColor: '#4D291C' + } + }, + { + name: 'Ingolstadt', + itemStyle: { + color: '#009c7a', + borderColor: '#009c7a' + } + }, + { + name: 'Drancy', + itemStyle: { + color: '#986F0B', + borderColor: '#986F0B' + } + }, + { + name: 'Langford', + itemStyle: { + color: '#3C8EA4', + borderColor: '#3C8EA4' + } + }, + { + name: 'Lebanon', + itemStyle: { + color: '#4F82BE', + borderColor: '#4F82BE' + } + }, + { + name: 'Maidenhead', + itemStyle: { + color: '#D38017', + borderColor: '#D38017' + } + }, + { + name: 'Stoke-on-Trent', + itemStyle: { + color: '#A8CDD7', + borderColor: '#A8CDD7' + } + }, + { + name: 'Peterborough', + itemStyle: { + color: '#7A072D', + borderColor: '#7A072D' + } + }, + { + name: 'Suresnes', + itemStyle: { + color: '#859599', + borderColor: '#859599' + } + }, + { + name: 'Versailles', + itemStyle: { + color: '#84AA33', + borderColor: '#84AA33' + } + }, + { + name: 'Neunkirchen', + itemStyle: { + color: '#ff8b67', + borderColor: '#ff8b67' + } + }, + { + name: 'Vista', + itemStyle: { + color: 'rgba(106,82,134,255)', + borderColor: 'rgba(106,82,134,255)' + } + }, + { + name: 'Westminster', + itemStyle: { + color: '#1B587C', + borderColor: '#1B587C' + } + }, + { + name: 'Kiel', + itemStyle: { + color: '#A19574', + borderColor: '#A19574' + } + }, + { + name: 'Newcastle upon Tyne', + itemStyle: { + color: '#918485', + borderColor: '#918485' + } + }, + { + name: 'Oxon', + itemStyle: { + color: '#FFA98C', + borderColor: '#FFA98C' + } + }, + { + name: 'West Sussex', + itemStyle: { + color: '#B0E3C0', + borderColor: '#B0E3C0' + } + }, + { + name: 'Oak Bay', + itemStyle: { + color: '#4BADC7', + borderColor: '#4BADC7' + } + }, + { + name: 'Milton Keynes', + itemStyle: { + color: '#BA144C', + borderColor: '#BA144C' + } + }, + { + name: 'Eilenburg', + itemStyle: { + color: '#F0A22E', + borderColor: '#F0A22E' + } + }, + { + name: 'ColonialVoice', + itemStyle: { + color: 'rgba(64,105,157,255)', + borderColor: 'rgba(64,105,157,255)' + } + }, + { + name: 'Liverpool', + itemStyle: { + color: '#A28E6A', + borderColor: '#A28E6A' + } + }, + { + name: 'Calgary', + itemStyle: { + color: '#9F413E', + borderColor: '#9F413E' + } + }, + { + name: 'CAD', + itemStyle: { + color: '#40699D', + borderColor: '#40699D' + } + }, + { + name: 'Paris La Defense', + itemStyle: { + color: '#989391', + borderColor: '#989391' + } + }, + { + name: "Villeneuve-d'Ascq", + itemStyle: { + color: '#886CE4', + borderColor: '#886CE4' + } + }, + { + name: 'Gloucestershire', + itemStyle: { + color: '#964305', + borderColor: '#964305' + } + }, + { + name: 'Gateshead', + itemStyle: { + color: '#485FB5', + borderColor: '#485FB5' + } + }, + { + name: 'Salzgitter', + itemStyle: { + color: '#87a0c7', + borderColor: '#87a0c7' + } + }, + { + name: 'Woolston', + itemStyle: { + color: '#FFE2C5', + borderColor: '#FFE2C5' + } + }, + { + name: 'Frankfurt', + itemStyle: { + color: '#40699D', + borderColor: '#40699D' + } + }, + { + name: 'Münster', + itemStyle: { + color: '#7e7eb2', + borderColor: '#7e7eb2' + } + }, + { + name: 'York', + itemStyle: { + color: '#587C7D', + borderColor: '#587C7D' + } + }, + { + name: 'High Wycombe', + itemStyle: { + color: '#F07F09', + borderColor: '#F07F09' + } + }, + { + name: 'Stuttgart', + itemStyle: { + color: '#E3008C', + borderColor: '#E3008C' + } + }, + { + name: 'Sooke', + itemStyle: { + color: '#4E8542', + borderColor: '#4E8542' + } + }, + { + name: 'Essen', + itemStyle: { + color: '#B58B80', + borderColor: '#B58B80' + } + }, + { + name: 'München', + itemStyle: { + color: '#4dc0a6', + borderColor: '#4dc0a6' + } + }, + { + name: 'Haney', + itemStyle: { + color: '#6A5286', + borderColor: '#6A5286' + } + }, + { + name: 'Port Hammond', + itemStyle: { + color: '#F89746', + borderColor: '#F89746' + } + }, + { + name: 'Saint Ouen', + itemStyle: { + color: '#744DA9', + borderColor: '#744DA9' + } + }, + { + name: 'Watford', + itemStyle: { + color: '#E8B7B7', + borderColor: '#E8B7B7' + } + }, + { + name: 'GBP', + itemStyle: { + color: '#C32D2E', + borderColor: '#C32D2E' + } + }, + { + name: 'Paderborn', + itemStyle: { + color: '#F0C42E', + borderColor: '#F0C42E' + } + }, + { + name: 'Dunkerque', + itemStyle: { + color: '#881798', + borderColor: '#881798' + } + }, + { + name: 'Colomiers', + itemStyle: { + color: '#efa835', + borderColor: '#efa835' + } + }, + { + name: 'Oxford', + itemStyle: { + color: '#D8B25C', + borderColor: '#D8B25C' + } + }, + { + name: 'Bury', + itemStyle: { + color: '#FEB80A', + borderColor: '#FEB80A' + } + }, + { + name: 'Royal Oak', + itemStyle: { + color: '#009DD9', + borderColor: '#009DD9' + } + }, + { + name: 'Shawnee', + itemStyle: { + color: '#F07F09', + borderColor: '#F07F09' + } + }, + { + name: 'Lancaster', + itemStyle: { + color: '#D34817', + borderColor: '#D34817' + } + }, + { + name: 'DEM', + itemStyle: { + color: '#4E342E', + borderColor: '#4E342E' + } + }, + { + name: 'Grevenbroich', + itemStyle: { + color: '#FFA836', + borderColor: '#FFA836' + } + }, + { + name: 'Distinguish', + itemStyle: { + color: 'rgba(159,65,62,255)', + borderColor: 'rgba(159,65,62,255)' + } + }, + { + name: 'Cheltenham', + itemStyle: { + color: '#FF6551', + borderColor: '#FF6551' + } + }, + { + name: 'Reading', + itemStyle: { + color: '#72A376', + borderColor: '#72A376' + } + }, + { + name: 'Pantin', + itemStyle: { + color: '#69797E', + borderColor: '#69797E' + } + }, + { + name: 'Kassel', + itemStyle: { + color: '#e65e20', + borderColor: '#e65e20' + } + }, + { + name: 'Orly', + itemStyle: { + color: '#6E6A68', + borderColor: '#6E6A68' + } + }, + { + name: 'FRF', + itemStyle: { + color: '#5ba33b', + borderColor: '#5ba33b' + } + }, + { + name: 'Cergy', + itemStyle: { + color: '#B4009E', + borderColor: '#B4009E' + } + }, + { + name: 'Paris', + itemStyle: { + color: '#666666', + borderColor: '#666666' + } + } + ], + links: [ + { + source: 'FRF', + target: 'Colomiers', + value: 357.8399963378906 + }, + { + source: 'SuperiorCard', + target: 'FRF', + value: 894.5999908447266 + }, + { + source: 'DEM', + target: 'München', + value: 178.9199981689453 + }, + { + source: 'GBP', + target: 'Reading', + value: 188.52999836206436 + }, + { + source: 'CAD', + target: 'Shawnee', + value: 2346.919983509928 + }, + { + source: 'GBP', + target: 'Kirkby', + value: 753.4000000059605 + }, + { + source: 'FRF', + target: 'Roncq', + value: 178.9199981689453 + }, + { + source: 'GBP', + target: 'Peterborough', + value: 999.159998036921 + }, + { + source: 'DEM', + target: 'Frankfurt am Main', + value: 536.7599945068359 + }, + { + source: 'GBP', + target: 'Oxford', + value: 1831.3799968883395 + }, + { + source: 'Vista', + target: 'FRF', + value: 1789.1999816894531 + }, + { + source: 'CAD', + target: 'Langley', + value: 1274.8199949413538 + }, + { + source: 'DEM', + target: 'Offenbach', + value: 357.8399963378906 + }, + { + source: 'FRF', + target: "Villeneuve-d'Ascq", + value: 178.9199981689453 + }, + { + source: 'FRF', + target: 'Dunkerque', + value: 357.8399963378906 + }, + { + source: 'DEM', + target: 'Eilenburg', + value: 178.9199981689453 + }, + { + source: 'FRF', + target: 'Paris', + value: 1073.5199890136719 + }, + { + source: 'GBP', + target: 'Maidenhead', + value: 549.8400026857853 + }, + { + source: 'CAD', + target: 'Sooke', + value: 1764.499989286065 + }, + { + source: 'CAD', + target: 'Vancouver', + value: 1528.580000281334 + }, + { + source: 'DEM', + target: 'Hamburg', + value: 357.8399963378906 + }, + { + source: 'GBP', + target: 'London', + value: 8619.309983983636 + }, + { + source: 'CAD', + target: 'Oak Bay', + value: 1565.109990529716 + }, + { + source: 'Distinguish', + target: 'FRF', + value: 2683.7999725341797 + }, + { + source: 'DEM', + target: 'Neunkirchen', + value: 178.9199981689453 + }, + { + source: 'FRF', + target: 'Cergy', + value: 178.9199981689453 + }, + { + source: 'DEM', + target: 'Hof', + value: 357.8399963378906 + }, + { + source: 'FRF', + target: 'Paris La Defense', + value: 178.9199981689453 + }, + { + source: 'CAD', + target: 'Westminster', + value: 1149.7999994903803 + }, + { + source: 'DEM', + target: 'Ingolstadt', + value: 536.7599945068359 + }, + { + source: 'GBP', + target: 'Saint Ouen', + value: 0.5899999737739563 + }, + { + source: 'FRF', + target: 'Lille', + value: 357.8399963378906 + }, + { + source: 'GBP', + target: 'Leeds', + value: 1356.6899970173836 + }, + { + source: 'FRF', + target: 'Morangis', + value: 357.8399963378906 + }, + { + source: 'GBP', + target: 'Orly', + value: 0.5899999737739563 + }, + { + source: 'SuperiorCard', + target: 'DEM', + value: 1431.3599853515625 + }, + { + source: 'Vista', + target: 'CAD', + value: 5369.929964579642 + }, + { + source: 'GBP', + target: 'Paris', + value: 0.6399999856948853 + }, + { + source: 'GBP', + target: 'Liverpool', + value: 857.1999968588352 + }, + { + source: 'GBP', + target: 'Stoke-on-Trent', + value: 1131.7099939212203 + }, + { + source: 'Distinguish', + target: 'DEM', + value: 2504.8799743652344 + }, + { + source: 'CAD', + target: 'Langford', + value: 2343.4599857851863 + }, + { + source: 'DEM', + target: 'Kassel', + value: 536.7599945068359 + }, + { + source: 'GBP', + target: 'High Wycombe', + value: 216.83999809622765 + }, + { + source: 'CAD', + target: 'Port Hammond', + value: 1711.1399984136224 + }, + { + source: 'DEM', + target: 'Duesseldorf', + value: 178.9199981689453 + }, + { + source: 'GBP', + target: 'Gloucestershire', + value: 422.28999888151884 + }, + { + source: 'Distinguish', + target: 'GBP', + value: 10384.949975416064 + }, + { + source: 'FRF', + target: 'Roissy en Brie', + value: 178.9199981689453 + }, + { + source: 'GBP', + target: 'West Sussex', + value: 592.1700052022934 + }, + { + source: 'CAD', + target: 'Cliffside', + value: 2906.2699892893434 + }, + { + source: 'GBP', + target: 'Newcastle upon Tyne', + value: 1448.2899911925197 + }, + { + source: 'GBP', + target: 'Runcorn', + value: 1120.4800013303757 + }, + { + source: 'GBP', + target: 'W. York', + value: 612.1199932694435 + }, + { + source: 'DEM', + target: 'Kiel', + value: 178.9199981689453 + }, + { + source: 'GBP', + target: 'Woolston', + value: 833.3199937939644 + }, + { + source: 'Distinguish', + target: 'CAD', + value: 6950.059956334531 + }, + { + source: 'DEM', + target: 'Frankfurt', + value: 715.6799926757812 + }, + { + source: 'CAD', + target: 'Colma', + value: 0.2199999988079071 + }, + { + source: 'DEM', + target: 'Essen', + value: 178.9199981689453 + }, + { + source: 'FRF', + target: 'Chatou', + value: 178.9199981689453 + }, + { + source: 'GBP', + target: 'Cheltenham', + value: 573.0499979257584 + }, + { + source: 'SuperiorCard', + target: 'GBP', + value: 8228.39999615401 + }, + { + source: 'CAD', + target: 'Haney', + value: 2310.4499812424183 + }, + { + source: 'FRF', + target: 'Saint Ouen', + value: 178.9199981689453 + }, + { + source: 'CAD', + target: 'Chalk Riber', + value: 0.9200000166893005 + }, + { + source: 'DEM', + target: 'Salzgitter', + value: 178.9199981689453 + }, + { + source: 'ColonialVoice', + target: 'FRF', + value: 1610.2799835205078 + }, + { + source: 'DEM', + target: 'Stuttgart', + value: 357.8399963378906 + }, + { + source: 'FRF', + target: 'Saint-Denis', + value: 178.9199981689453 + }, + { + source: 'CAD', + target: 'Royal Oak', + value: 2128.459992274642 + }, + { + source: 'FRF', + target: 'Les Ulis', + value: 715.6799926757812 + }, + { + source: 'FRF', + target: 'Drancy', + value: 178.9199981689453 + }, + { + source: 'GBP', + target: 'Esher-Molesey', + value: 911.4700058028102 + }, + { + source: 'SuperiorCard', + target: 'CAD', + value: 7388.099954992533 + }, + { + source: 'GBP', + target: 'Bury', + value: 903.9400005489588 + }, + { + source: 'GBP', + target: 'Watford', + value: 1326.5300009772182 + }, + { + source: 'CAD', + target: 'Victoria', + value: 827.3899968340993 + }, + { + source: 'DEM', + target: 'Saarbrücken', + value: 178.9199981689453 + }, + { + source: 'GBP', + target: 'Lancaster', + value: 685.6899967193604 + }, + { + source: 'FRF', + target: 'Pantin', + value: 178.9199981689453 + }, + { + source: 'CAD', + target: 'Newton', + value: 1781.909985654056 + }, + { + source: 'GBP', + target: 'Oxon', + value: 493.6499986946583 + }, + { + source: 'CAD', + target: 'Calgary', + value: 361.3899962902069 + }, + { + source: 'DEM', + target: 'Münster', + value: 715.6799926757812 + }, + { + source: 'DEM', + target: 'Grevenbroich', + value: 536.7599945068359 + }, + { + source: 'DEM', + target: 'Paderborn', + value: 357.8399963378906 + }, + { + source: 'GBP', + target: 'York', + value: 3172.9999914616346 + }, + { + source: 'CAD', + target: 'Metchosin', + value: 1750.7899813987315 + }, + { + source: 'FRF', + target: 'Suresnes', + value: 357.8399963378906 + }, + { + source: 'FRF', + target: 'Versailles', + value: 894.5999908447266 + }, + { + source: 'DEM', + target: 'Erlangen', + value: 536.7599945068359 + }, + { + source: 'CAD', + target: 'Lebanon', + value: 0.8700000047683716 + }, + { + source: 'GBP', + target: 'Wokingham', + value: 812.6600027084351 + }, + { + source: 'GBP', + target: 'Cambridge', + value: 500.36999743431807 + }, + { + source: 'ColonialVoice', + target: 'GBP', + value: 8040.7799860313535 + }, + { + source: 'FRF', + target: 'Saint Germain en Laye', + value: 178.9199981689453 + }, + { + source: 'FRF', + target: 'Metz', + value: 178.9199981689453 + }, + { + source: 'FRF', + target: 'Orleans', + value: 357.8399963378906 + }, + { + source: 'GBP', + target: 'Milton Keynes', + value: 1648.2200061008334 + }, + { + source: 'GBP', + target: 'Warrington', + value: 2162.8300000429153 + }, + { + source: 'CAD', + target: 'N. Vancouver', + value: 1862.4599857926369 + }, + { + source: 'DEM', + target: 'Hannover', + value: 178.9199981689453 + }, + { + source: 'Vista', + target: 'GBP', + value: 9497.539981640875 + }, + { + source: 'DEM', + target: 'Werne', + value: 178.9199981689453 + }, + { + source: 'ColonialVoice', + target: 'DEM', + value: 1789.1999816894531 + }, + { + source: 'ColonialVoice', + target: 'CAD', + value: 7907.36997512728 + }, + { + source: 'GBP', + target: 'Gateshead', + value: 1425.7099913656712 + }, + { + source: 'Vista', + target: 'DEM', + value: 1968.1199798583984 + } + ], + lineStyle: { + color: 'source', + curveness: 0.5 + }, + itemStyle: { + color: '#1f77b4', + borderColor: '#1f77b4' + }, + label: { + color: 'rgba(0,0,0,0.7)', + fontFamily: 'Arial', + fontSize: 10 + } + } + ], + tooltip: { + trigger: 'item' + } +}; +export {}; diff --git a/testdata/sankey-itemstyle.js.svg b/testdata/sankey-itemstyle.js.svg new file mode 100644 index 0000000..d7a0e26 --- /dev/null +++ b/testdata/sankey-itemstyle.js.svg @@ -0,0 +1,334 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Werne +Duesseldorf +Cambridge +Colma +W. York +Frankfurt am Main +Metz +Orleans +Saint-Denis +Hof +Cliffside +Leeds +Victoria +Erlangen +Saint Germain en Laye +Roissy en Brie +Wokingham +Runcorn +Newton +Morangis +Metchosin +Kirkby +London +Offenbach +Warrington +Vancouver +SuperiorCard +Lille +Hamburg +Langley +Les Ulis +Saarbrücken +N. Vancouver +Chalk Riber +Esher-Molesey +Chatou +Hannover +Roncq +Ingolstadt +Drancy +Langford +Lebanon +Maidenhead +Stoke-on-Trent +Peterborough +Suresnes +Versailles +Neunkirchen +Vista +Westminster +Kiel +Newcastle upon Tyne +Oxon +West Sussex +Oak Bay +Milton Keynes +Eilenburg +ColonialVoice +Liverpool +Calgary +CAD +Paris La Defense +Villeneuve-d'Ascq +Gloucestershire +Gateshead +Salzgitter +Woolston +Frankfurt +Münster +York +High Wycombe +Stuttgart +Sooke +Essen +München +Haney +Port Hammond +Saint Ouen +Watford +GBP +Paderborn +Dunkerque +Colomiers +Oxford +Bury +Royal Oak +Shawnee +Lancaster +DEM +Grevenbroich +Distinguish +Cheltenham +Reading +Pantin +Kassel +Orly +FRF +Cergy +Paris + + +Data From lisachristina1234 on GitHub + + + + + + + \ No newline at end of file diff --git a/testdata/sankey-levels.js b/testdata/sankey-levels.js new file mode 100644 index 0000000..5b0332e --- /dev/null +++ b/testdata/sankey-levels.js @@ -0,0 +1,75 @@ +/* +title: Sankey with Levels Setting +category: sankey +titleCN: 桑基图层级自定义样式 +difficulty: 2 +*/ +myChart.showLoading(); +$.get(ROOT_PATH + '/data/asset/data/product.json', function (data) { + myChart.hideLoading(); + myChart.setOption((option = { + title: { + text: 'Sankey Diagram' + }, + tooltip: { + trigger: 'item', + triggerOn: 'mousemove' + }, + series: [ + { + type: 'sankey', + data: data.nodes, + links: data.links, + emphasis: { + focus: 'adjacency' + }, + levels: [ + { + depth: 0, + itemStyle: { + color: '#fbb4ae' + }, + lineStyle: { + color: 'source', + opacity: 0.6 + } + }, + { + depth: 1, + itemStyle: { + color: '#b3cde3' + }, + lineStyle: { + color: 'source', + opacity: 0.6 + } + }, + { + depth: 2, + itemStyle: { + color: '#ccebc5' + }, + lineStyle: { + color: 'source', + opacity: 0.6 + } + }, + { + depth: 3, + itemStyle: { + color: '#decbe4' + }, + lineStyle: { + color: 'source', + opacity: 0.6 + } + } + ], + lineStyle: { + curveness: 0.5 + } + } + ] + })); +}); +export {}; diff --git a/testdata/sankey-nodeAlign-left.js b/testdata/sankey-nodeAlign-left.js new file mode 100644 index 0000000..b8dd96f --- /dev/null +++ b/testdata/sankey-nodeAlign-left.js @@ -0,0 +1,35 @@ +/* +title: Node Align Left in Sankey +category: sankey +titleCN: 桑基图左对齐布局 +difficulty: 3 +*/ +myChart.showLoading(); +$.get(ROOT_PATH + '/data/asset/data/energy.json', function (data) { + myChart.hideLoading(); + myChart.setOption((option = { + title: { + text: 'Node Align Right' + }, + tooltip: { + trigger: 'item', + triggerOn: 'mousemove' + }, + series: [ + { + type: 'sankey', + emphasis: { + focus: 'adjacency' + }, + nodeAlign: 'left', + data: data.nodes, + links: data.links, + lineStyle: { + color: 'source', + curveness: 0.5 + } + } + ] + })); +}); +export {}; diff --git a/testdata/sankey-nodeAlign-right.js b/testdata/sankey-nodeAlign-right.js new file mode 100644 index 0000000..fdb92d6 --- /dev/null +++ b/testdata/sankey-nodeAlign-right.js @@ -0,0 +1,36 @@ +/* +title: Node Align Right in Sankey +category: sankey +titleCN: 桑基图右对齐布局 +difficulty: 3 +*/ +myChart.showLoading(); +$.get(ROOT_PATH + '/data/asset/data/energy.json', function (data) { + myChart.hideLoading(); + myChart.setOption((option = { + title: { + text: 'Node Align Left' + }, + tooltip: { + trigger: 'item', + triggerOn: 'mousemove' + }, + animation: false, + series: [ + { + type: 'sankey', + emphasis: { + focus: 'adjacency' + }, + nodeAlign: 'right', + data: data.nodes, + links: data.links, + lineStyle: { + color: 'source', + curveness: 0.5 + } + } + ] + })); +}); +export {}; diff --git a/testdata/sankey-simple.js b/testdata/sankey-simple.js new file mode 100644 index 0000000..a733eba --- /dev/null +++ b/testdata/sankey-simple.js @@ -0,0 +1,68 @@ +/* +title: Basic Sankey +category: sankey +titleCN: 基础桑基图 +difficulty: 0 +*/ +option = { + series: { + type: 'sankey', + layout: 'none', + emphasis: { + focus: 'adjacency' + }, + data: [ + { + name: 'a' + }, + { + name: 'b' + }, + { + name: 'a1' + }, + { + name: 'a2' + }, + { + name: 'b1' + }, + { + name: 'c' + } + ], + links: [ + { + source: 'a', + target: 'a1', + value: 5 + }, + { + source: 'a', + target: 'a2', + value: 3 + }, + { + source: 'b', + target: 'b1', + value: 8 + }, + { + source: 'a', + target: 'b1', + value: 3 + }, + { + source: 'b1', + target: 'a1', + value: 1 + }, + { + source: 'b1', + target: 'c', + value: 2 + } + ] + } +}; +export {}; diff --git a/testdata/sankey-simple.js.svg b/testdata/sankey-simple.js.svg new file mode 100644 index 0000000..6e224d3 --- /dev/null +++ b/testdata/sankey-simple.js.svg @@ -0,0 +1,43 @@ + + + + + + + + + + + + + + + +a +b +a1 +a2 +b1 +c + + + + + + + + \ No newline at end of file diff --git a/testdata/sankey-vertical.js b/testdata/sankey-vertical.js new file mode 100644 index 0000000..74b0903 --- /dev/null +++ b/testdata/sankey-vertical.js @@ -0,0 +1,47 @@ +/* +title: Sankey Orient Vertical +category: sankey +titleCN: 垂直方向的桑基图 +difficulty: 1 +*/ +option = { + tooltip: { + trigger: 'item', + triggerOn: 'mousemove' + }, + animation: false, + series: [ + { + type: 'sankey', + bottom: '10%', + emphasis: { + focus: 'adjacency' + }, + data: [ + { name: 'a' }, + { name: 'b' }, + { name: 'a1' }, + { name: 'b1' }, + { name: 'c' }, + { name: 'e' } + ], + links: [ + { source: 'a', target: 'a1', value: 5 }, + { source: 'e', target: 'b', value: 3 }, + { source: 'a', target: 'b1', value: 3 }, + { source: 'b1', target: 'a1', value: 1 }, + { source: 'b1', target: 'c', value: 2 }, + { source: 'b', target: 'c', value: 1 } + ], + orient: 'vertical', + label: { + position: 'top' + }, + lineStyle: { + color: 'source', + curveness: 0.5 + } + } + ] +}; +export {}; diff --git a/testdata/sankey-vertical.js.svg b/testdata/sankey-vertical.js.svg new file mode 100644 index 0000000..8cc4316 --- /dev/null +++ b/testdata/sankey-vertical.js.svg @@ -0,0 +1,21 @@ + + + + + + + + + + + + + + +a +b +a1 +b1 +c +e + \ No newline at end of file diff --git a/testdata/scatter-aggregate-bar.js b/testdata/scatter-aggregate-bar.js new file mode 100644 index 0000000..9f8c444 --- /dev/null +++ b/testdata/scatter-aggregate-bar.js @@ -0,0 +1,191 @@ +/* +title: Aggregate Scatter to Bar +category: scatter, animation +titleCN: 散点图聚合为柱状图动画 +difficulty: 4 +videoStart: 2000 +videoEnd: 6000 +*/ +// prettier-ignore +const femaleData = [[161.2, 51.6], [167.5, 59.0], [159.5, 49.2], [157.0, 63.0], [155.8, 53.6], + [170.0, 59.0], [159.1, 47.6], [166.0, 69.8], [176.2, 66.8], [160.2, 75.2], + [172.5, 55.2], [170.9, 54.2], [172.9, 62.5], [153.4, 42.0], [160.0, 50.0], + [147.2, 49.8], [168.2, 49.2], [175.0, 73.2], [157.0, 47.8], [167.6, 68.8], + [159.5, 50.6], [175.0, 82.5], [166.8, 57.2], [176.5, 87.8], [170.2, 72.8], + [174.0, 54.5], [173.0, 59.8], [179.9, 67.3], [170.5, 67.8], [160.0, 47.0], + [154.4, 46.2], [162.0, 55.0], [176.5, 83.0], [160.0, 54.4], [152.0, 45.8], + [162.1, 53.6], [170.0, 73.2], [160.2, 52.1], [161.3, 67.9], [166.4, 56.6], + [168.9, 62.3], [163.8, 58.5], [167.6, 54.5], [160.0, 50.2], [161.3, 60.3], + [167.6, 58.3], [165.1, 56.2], [160.0, 50.2], [170.0, 72.9], [157.5, 59.8], + [167.6, 61.0], [160.7, 69.1], [163.2, 55.9], [152.4, 46.5], [157.5, 54.3], + [168.3, 54.8], [180.3, 60.7], [165.5, 60.0], [165.0, 62.0], [164.5, 60.3], + [156.0, 52.7], [160.0, 74.3], [163.0, 62.0], [165.7, 73.1], [161.0, 80.0], + [162.0, 54.7], [166.0, 53.2], [174.0, 75.7], [172.7, 61.1], [167.6, 55.7], + [151.1, 48.7], [164.5, 52.3], [163.5, 50.0], [152.0, 59.3], [169.0, 62.5], + [164.0, 55.7], [161.2, 54.8], [155.0, 45.9], [170.0, 70.6], [176.2, 67.2], + [170.0, 69.4], [162.5, 58.2], [170.3, 64.8], [164.1, 71.6], [169.5, 52.8], + [163.2, 59.8], [154.5, 49.0], [159.8, 50.0], [173.2, 69.2], [170.0, 55.9], + [161.4, 63.4], [169.0, 58.2], [166.2, 58.6], [159.4, 45.7], [162.5, 52.2], + [159.0, 48.6], [162.8, 57.8], [159.0, 55.6], [179.8, 66.8], [162.9, 59.4], + [161.0, 53.6], [151.1, 73.2], [168.2, 53.4], [168.9, 69.0], [173.2, 58.4], + [171.8, 56.2], [178.0, 70.6], [164.3, 59.8], [163.0, 72.0], [168.5, 65.2], + [166.8, 56.6], [172.7, 105.2], [163.5, 51.8], [169.4, 63.4], [167.8, 59.0], + [159.5, 47.6], [167.6, 63.0], [161.2, 55.2], [160.0, 45.0], [163.2, 54.0], + [162.2, 50.2], [161.3, 60.2], [149.5, 44.8], [157.5, 58.8], [163.2, 56.4], + [172.7, 62.0], [155.0, 49.2], [156.5, 67.2], [164.0, 53.8], [160.9, 54.4], + [162.8, 58.0], [167.0, 59.8], [160.0, 54.8], [160.0, 43.2], [168.9, 60.5], + [158.2, 46.4], [156.0, 64.4], [160.0, 48.8], [167.1, 62.2], [158.0, 55.5], + [167.6, 57.8], [156.0, 54.6], [162.1, 59.2], [173.4, 52.7], [159.8, 53.2], + [170.5, 64.5], [159.2, 51.8], [157.5, 56.0], [161.3, 63.6], [162.6, 63.2], + [160.0, 59.5], [168.9, 56.8], [165.1, 64.1], [162.6, 50.0], [165.1, 72.3], + [166.4, 55.0], [160.0, 55.9], [152.4, 60.4], [170.2, 69.1], [162.6, 84.5], + [170.2, 55.9], [158.8, 55.5], [172.7, 69.5], [167.6, 76.4], [162.6, 61.4], + [167.6, 65.9], [156.2, 58.6], [175.2, 66.8], [172.1, 56.6], [162.6, 58.6], + [160.0, 55.9], [165.1, 59.1], [182.9, 81.8], [166.4, 70.7], [165.1, 56.8], + [177.8, 60.0], [165.1, 58.2], [175.3, 72.7], [154.9, 54.1], [158.8, 49.1], + [172.7, 75.9], [168.9, 55.0], [161.3, 57.3], [167.6, 55.0], [165.1, 65.5], + [175.3, 65.5], [157.5, 48.6], [163.8, 58.6], [167.6, 63.6], [165.1, 55.2], + [165.1, 62.7], [168.9, 56.6], [162.6, 53.9], [164.5, 63.2], [176.5, 73.6], + [168.9, 62.0], [175.3, 63.6], [159.4, 53.2], [160.0, 53.4], [170.2, 55.0], + [162.6, 70.5], [167.6, 54.5], [162.6, 54.5], [160.7, 55.9], [160.0, 59.0], + [157.5, 63.6], [162.6, 54.5], [152.4, 47.3], [170.2, 67.7], [165.1, 80.9], + [172.7, 70.5], [165.1, 60.9], [170.2, 63.6], [170.2, 54.5], [170.2, 59.1], + [161.3, 70.5], [167.6, 52.7], [167.6, 62.7], [165.1, 86.3], [162.6, 66.4], + [152.4, 67.3], [168.9, 63.0], [170.2, 73.6], [175.2, 62.3], [175.2, 57.7], + [160.0, 55.4], [165.1, 104.1], [174.0, 55.5], [170.2, 77.3], [160.0, 80.5], + [167.6, 64.5], [167.6, 72.3], [167.6, 61.4], [154.9, 58.2], [162.6, 81.8], + [175.3, 63.6], [171.4, 53.4], [157.5, 54.5], [165.1, 53.6], [160.0, 60.0], + [174.0, 73.6], [162.6, 61.4], [174.0, 55.5], [162.6, 63.6], [161.3, 60.9], + [156.2, 60.0], [149.9, 46.8], [169.5, 57.3], [160.0, 64.1], [175.3, 63.6], + [169.5, 67.3], [160.0, 75.5], [172.7, 68.2], [162.6, 61.4], [157.5, 76.8], + [176.5, 71.8], [164.4, 55.5], [160.7, 48.6], [174.0, 66.4], [163.8, 67.3] +]; +// prettier-ignore +const maleDeta = [[174.0, 65.6], [175.3, 71.8], [193.5, 80.7], [186.5, 72.6], [187.2, 78.8], + [181.5, 74.8], [184.0, 86.4], [184.5, 78.4], [175.0, 62.0], [184.0, 81.6], + [180.0, 76.6], [177.8, 83.6], [192.0, 90.0], [176.0, 74.6], [174.0, 71.0], + [184.0, 79.6], [192.7, 93.8], [171.5, 70.0], [173.0, 72.4], [176.0, 85.9], + [176.0, 78.8], [180.5, 77.8], [172.7, 66.2], [176.0, 86.4], [173.5, 81.8], + [178.0, 89.6], [180.3, 82.8], [180.3, 76.4], [164.5, 63.2], [173.0, 60.9], + [183.5, 74.8], [175.5, 70.0], [188.0, 72.4], [189.2, 84.1], [172.8, 69.1], + [170.0, 59.5], [182.0, 67.2], [170.0, 61.3], [177.8, 68.6], [184.2, 80.1], + [186.7, 87.8], [171.4, 84.7], [172.7, 73.4], [175.3, 72.1], [180.3, 82.6], + [182.9, 88.7], [188.0, 84.1], [177.2, 94.1], [172.1, 74.9], [167.0, 59.1], + [169.5, 75.6], [174.0, 86.2], [172.7, 75.3], [182.2, 87.1], [164.1, 55.2], + [163.0, 57.0], [171.5, 61.4], [184.2, 76.8], [174.0, 86.8], [174.0, 72.2], + [177.0, 71.6], [186.0, 84.8], [167.0, 68.2], [171.8, 66.1], [182.0, 72.0], + [167.0, 64.6], [177.8, 74.8], [164.5, 70.0], [192.0, 101.6], [175.5, 63.2], + [171.2, 79.1], [181.6, 78.9], [167.4, 67.7], [181.1, 66.0], [177.0, 68.2], + [174.5, 63.9], [177.5, 72.0], [170.5, 56.8], [182.4, 74.5], [197.1, 90.9], + [180.1, 93.0], [175.5, 80.9], [180.6, 72.7], [184.4, 68.0], [175.5, 70.9], + [180.6, 72.5], [177.0, 72.5], [177.1, 83.4], [181.6, 75.5], [176.5, 73.0], + [175.0, 70.2], [174.0, 73.4], [165.1, 70.5], [177.0, 68.9], [192.0, 102.3], + [176.5, 68.4], [169.4, 65.9], [182.1, 75.7], [179.8, 84.5], [175.3, 87.7], + [184.9, 86.4], [177.3, 73.2], [167.4, 53.9], [178.1, 72.0], [168.9, 55.5], + [157.2, 58.4], [180.3, 83.2], [170.2, 72.7], [177.8, 64.1], [172.7, 72.3], + [165.1, 65.0], [186.7, 86.4], [165.1, 65.0], [174.0, 88.6], [175.3, 84.1], + [185.4, 66.8], [177.8, 75.5], [180.3, 93.2], [180.3, 82.7], [177.8, 58.0], + [177.8, 79.5], [177.8, 78.6], [177.8, 71.8], [177.8, 116.4], [163.8, 72.2], + [188.0, 83.6], [198.1, 85.5], [175.3, 90.9], [166.4, 85.9], [190.5, 89.1], + [166.4, 75.0], [177.8, 77.7], [179.7, 86.4], [172.7, 90.9], [190.5, 73.6], + [185.4, 76.4], [168.9, 69.1], [167.6, 84.5], [175.3, 64.5], [170.2, 69.1], + [190.5, 108.6], [177.8, 86.4], [190.5, 80.9], [177.8, 87.7], [184.2, 94.5], + [176.5, 80.2], [177.8, 72.0], [180.3, 71.4], [171.4, 72.7], [172.7, 84.1], + [172.7, 76.8], [177.8, 63.6], [177.8, 80.9], [182.9, 80.9], [170.2, 85.5], + [167.6, 68.6], [175.3, 67.7], [165.1, 66.4], [185.4, 102.3], [181.6, 70.5], + [172.7, 95.9], [190.5, 84.1], [179.1, 87.3], [175.3, 71.8], [170.2, 65.9], + [193.0, 95.9], [171.4, 91.4], [177.8, 81.8], [177.8, 96.8], [167.6, 69.1], + [167.6, 82.7], [180.3, 75.5], [182.9, 79.5], [176.5, 73.6], [186.7, 91.8], + [188.0, 84.1], [188.0, 85.9], [177.8, 81.8], [174.0, 82.5], [177.8, 80.5], + [171.4, 70.0], [185.4, 81.8], [185.4, 84.1], [188.0, 90.5], [188.0, 91.4], + [182.9, 89.1], [176.5, 85.0], [175.3, 69.1], [175.3, 73.6], [188.0, 80.5], + [188.0, 82.7], [175.3, 86.4], [170.5, 67.7], [179.1, 92.7], [177.8, 93.6], + [175.3, 70.9], [182.9, 75.0], [170.8, 93.2], [188.0, 93.2], [180.3, 77.7], + [177.8, 61.4], [185.4, 94.1], [168.9, 75.0], [185.4, 83.6], [180.3, 85.5], + [174.0, 73.9], [167.6, 66.8], [182.9, 87.3], [160.0, 72.3], [180.3, 88.6], + [167.6, 75.5], [186.7, 101.4], [175.3, 91.1], [175.3, 67.3], [175.9, 77.7], + [175.3, 81.8], [179.1, 75.5], [181.6, 84.5], [177.8, 76.6], [182.9, 85.0], + [177.8, 102.5], [184.2, 77.3], [179.1, 71.8], [176.5, 87.9], [188.0, 94.3], + [174.0, 70.9], [167.6, 64.5], [170.2, 77.3], [167.6, 72.3], [188.0, 87.3], + [174.0, 80.0], [176.5, 82.3], [180.3, 73.6], [167.6, 74.1], [188.0, 85.9], + [180.3, 73.2], [167.6, 76.3], [183.0, 65.9], [183.0, 90.9], [179.1, 89.1], + [170.2, 62.3], [177.8, 82.7], [179.1, 79.1], [190.5, 98.2], [177.8, 84.1], + [180.3, 83.2], [180.3, 83.2] +]; +function calculateAverage(data, dim) { + let total = 0; + for (var i = 0; i < data.length; i++) { + total += data[i][dim]; + } + return (total /= data.length); +} +const scatterOption = (option = { + xAxis: { + scale: true + }, + yAxis: { + scale: true + }, + series: [ + { + type: 'scatter', + id: 'female', + dataGroupId: 'female', + universalTransition: { + enabled: true, + delay: function (idx, count) { + return Math.random() * 400; + } + }, + data: femaleData + }, + { + type: 'scatter', + id: 'male', + dataGroupId: 'male', + universalTransition: { + enabled: true, + delay: function (idx, count) { + return Math.random() * 400; + } + }, + data: maleDeta + } + ] +}); +const barOption = { + xAxis: { + type: 'category', + data: ['Female', 'Male'] + }, + yAxis: {}, + series: [ + { + type: 'bar', + id: 'total', + data: [ + { + value: calculateAverage(maleDeta, 0), + groupId: 'male' + }, + { + value: calculateAverage(femaleData, 0), + groupId: 'female' + } + ], + universalTransition: { + enabled: true, + seriesKey: ['female', 'male'], + delay: function (idx, count) { + return Math.random() * 400; + } + } + } + ] +}; +let currentOption = scatterOption; +setInterval(function () { + currentOption = currentOption === scatterOption ? barOption : scatterOption; + myChart.setOption(currentOption, true); +}, 2000); +export {}; diff --git a/testdata/scatter-aggregate-bar.js.svg b/testdata/scatter-aggregate-bar.js.svg new file mode 100644 index 0000000..8d9487e --- /dev/null +++ b/testdata/scatter-aggregate-bar.js.svg @@ -0,0 +1,7155 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +40 +50 +60 +70 +80 +90 +100 +110 +120 +140 +150 +160 +170 +180 +190 +200 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/scatter-anscombe-quartet.js b/testdata/scatter-anscombe-quartet.js new file mode 100644 index 0000000..aecd3e2 --- /dev/null +++ b/testdata/scatter-anscombe-quartet.js @@ -0,0 +1,148 @@ +/* +title: Anscomb's quartet +category: scatter +titleCN: Anscomb's quartet +difficulty: 1 +*/ +const dataAll = [ + [ + [10.0, 8.04], + [8.0, 6.95], + [13.0, 7.58], + [9.0, 8.81], + [11.0, 8.33], + [14.0, 9.96], + [6.0, 7.24], + [4.0, 4.26], + [12.0, 10.84], + [7.0, 4.82], + [5.0, 5.68] + ], + [ + [10.0, 9.14], + [8.0, 8.14], + [13.0, 8.74], + [9.0, 8.77], + [11.0, 9.26], + [14.0, 8.1], + [6.0, 6.13], + [4.0, 3.1], + [12.0, 9.13], + [7.0, 7.26], + [5.0, 4.74] + ], + [ + [10.0, 7.46], + [8.0, 6.77], + [13.0, 12.74], + [9.0, 7.11], + [11.0, 7.81], + [14.0, 8.84], + [6.0, 6.08], + [4.0, 5.39], + [12.0, 8.15], + [7.0, 6.42], + [5.0, 5.73] + ], + [ + [8.0, 6.58], + [8.0, 5.76], + [8.0, 7.71], + [8.0, 8.84], + [8.0, 8.47], + [8.0, 7.04], + [8.0, 5.25], + [19.0, 12.5], + [8.0, 5.56], + [8.0, 7.91], + [8.0, 6.89] + ] +]; +const markLineOpt = { + animation: false, + label: { + formatter: 'y = 0.5 * x + 3', + align: 'right' + }, + lineStyle: { + type: 'solid' + }, + tooltip: { + formatter: 'y = 0.5 * x + 3' + }, + data: [ + [ + { + coord: [0, 3], + symbol: 'none' + }, + { + coord: [20, 13], + symbol: 'none' + } + ] + ] +}; +option = { + title: { + text: "Anscombe's quartet", + left: 'center', + top: 0 + }, + grid: [ + { left: '7%', top: '7%', width: '38%', height: '38%' }, + { right: '7%', top: '7%', width: '38%', height: '38%' }, + { left: '7%', bottom: '7%', width: '38%', height: '38%' }, + { right: '7%', bottom: '7%', width: '38%', height: '38%' } + ], + tooltip: { + formatter: 'Group {a}: ({c})' + }, + xAxis: [ + { gridIndex: 0, min: 0, max: 20 }, + { gridIndex: 1, min: 0, max: 20 }, + { gridIndex: 2, min: 0, max: 20 }, + { gridIndex: 3, min: 0, max: 20 } + ], + yAxis: [ + { gridIndex: 0, min: 0, max: 15 }, + { gridIndex: 1, min: 0, max: 15 }, + { gridIndex: 2, min: 0, max: 15 }, + { gridIndex: 3, min: 0, max: 15 } + ], + series: [ + { + name: 'I', + type: 'scatter', + xAxisIndex: 0, + yAxisIndex: 0, + data: dataAll[0], + markLine: markLineOpt + }, + { + name: 'II', + type: 'scatter', + xAxisIndex: 1, + yAxisIndex: 1, + data: dataAll[1], + markLine: markLineOpt + }, + { + name: 'III', + type: 'scatter', + xAxisIndex: 2, + yAxisIndex: 2, + data: dataAll[2], + markLine: markLineOpt + }, + { + name: 'IV', + type: 'scatter', + xAxisIndex: 3, + yAxisIndex: 3, + data: dataAll[3], + markLine: markLineOpt + } + ] +}; +export {}; diff --git a/testdata/scatter-anscombe-quartet.js.svg b/testdata/scatter-anscombe-quartet.js.svg new file mode 100644 index 0000000..1566075 --- /dev/null +++ b/testdata/scatter-anscombe-quartet.js.svg @@ -0,0 +1,773 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +0 +3 +6 +9 +12 +15 +0 +3 +6 +9 +12 +15 +0 +3 +6 +9 +12 +15 +0 +3 +6 +9 +12 +15 +0 +5 +10 +15 +20 +0 +5 +10 +15 +20 +0 +5 +10 +15 +20 +0 +5 +10 +15 +20 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +y = 0.5 * x + 3 +y = 0.5 * x + 3 +y = 0.5 * x + 3 +y = 0.5 * x + 3 + +Anscombe's quartet + + \ No newline at end of file diff --git a/testdata/scatter-aqi-color.js b/testdata/scatter-aqi-color.js new file mode 100644 index 0000000..aaeb18e --- /dev/null +++ b/testdata/scatter-aqi-color.js @@ -0,0 +1,253 @@ +/* +title: Scatter Aqi Color +category: scatter +titleCN: AQI 气泡图 +difficulty: 7 +*/ +const dataBJ = [ + [1, 55, 9, 56, 0.46, 18, 6, '良'], + [2, 25, 11, 21, 0.65, 34, 9, '优'], + [3, 56, 7, 63, 0.3, 14, 5, '良'], + [4, 33, 7, 29, 0.33, 16, 6, '优'], + [5, 42, 24, 44, 0.76, 40, 16, '优'], + [6, 82, 58, 90, 1.77, 68, 33, '良'], + [7, 74, 49, 77, 1.46, 48, 27, '良'], + [8, 78, 55, 80, 1.29, 59, 29, '良'], + [9, 267, 216, 280, 4.8, 108, 64, '重度污染'], + [10, 185, 127, 216, 2.52, 61, 27, '中度污染'], + [11, 39, 19, 38, 0.57, 31, 15, '优'], + [12, 41, 11, 40, 0.43, 21, 7, '优'], + [13, 64, 38, 74, 1.04, 46, 22, '良'], + [14, 108, 79, 120, 1.7, 75, 41, '轻度污染'], + [15, 108, 63, 116, 1.48, 44, 26, '轻度污染'], + [16, 33, 6, 29, 0.34, 13, 5, '优'], + [17, 94, 66, 110, 1.54, 62, 31, '良'], + [18, 186, 142, 192, 3.88, 93, 79, '中度污染'], + [19, 57, 31, 54, 0.96, 32, 14, '良'], + [20, 22, 8, 17, 0.48, 23, 10, '优'], + [21, 39, 15, 36, 0.61, 29, 13, '优'], + [22, 94, 69, 114, 2.08, 73, 39, '良'], + [23, 99, 73, 110, 2.43, 76, 48, '良'], + [24, 31, 12, 30, 0.5, 32, 16, '优'], + [25, 42, 27, 43, 1, 53, 22, '优'], + [26, 154, 117, 157, 3.05, 92, 58, '中度污染'], + [27, 234, 185, 230, 4.09, 123, 69, '重度污染'], + [28, 160, 120, 186, 2.77, 91, 50, '中度污染'], + [29, 134, 96, 165, 2.76, 83, 41, '轻度污染'], + [30, 52, 24, 60, 1.03, 50, 21, '良'], + [31, 46, 5, 49, 0.28, 10, 6, '优'] +]; +const dataGZ = [ + [1, 26, 37, 27, 1.163, 27, 13, '优'], + [2, 85, 62, 71, 1.195, 60, 8, '良'], + [3, 78, 38, 74, 1.363, 37, 7, '良'], + [4, 21, 21, 36, 0.634, 40, 9, '优'], + [5, 41, 42, 46, 0.915, 81, 13, '优'], + [6, 56, 52, 69, 1.067, 92, 16, '良'], + [7, 64, 30, 28, 0.924, 51, 2, '良'], + [8, 55, 48, 74, 1.236, 75, 26, '良'], + [9, 76, 85, 113, 1.237, 114, 27, '良'], + [10, 91, 81, 104, 1.041, 56, 40, '良'], + [11, 84, 39, 60, 0.964, 25, 11, '良'], + [12, 64, 51, 101, 0.862, 58, 23, '良'], + [13, 70, 69, 120, 1.198, 65, 36, '良'], + [14, 77, 105, 178, 2.549, 64, 16, '良'], + [15, 109, 68, 87, 0.996, 74, 29, '轻度污染'], + [16, 73, 68, 97, 0.905, 51, 34, '良'], + [17, 54, 27, 47, 0.592, 53, 12, '良'], + [18, 51, 61, 97, 0.811, 65, 19, '良'], + [19, 91, 71, 121, 1.374, 43, 18, '良'], + [20, 73, 102, 182, 2.787, 44, 19, '良'], + [21, 73, 50, 76, 0.717, 31, 20, '良'], + [22, 84, 94, 140, 2.238, 68, 18, '良'], + [23, 93, 77, 104, 1.165, 53, 7, '良'], + [24, 99, 130, 227, 3.97, 55, 15, '良'], + [25, 146, 84, 139, 1.094, 40, 17, '轻度污染'], + [26, 113, 108, 137, 1.481, 48, 15, '轻度污染'], + [27, 81, 48, 62, 1.619, 26, 3, '良'], + [28, 56, 48, 68, 1.336, 37, 9, '良'], + [29, 82, 92, 174, 3.29, 0, 13, '良'], + [30, 106, 116, 188, 3.628, 101, 16, '轻度污染'], + [31, 118, 50, 0, 1.383, 76, 11, '轻度污染'] +]; +const dataSH = [ + [1, 91, 45, 125, 0.82, 34, 23, '良'], + [2, 65, 27, 78, 0.86, 45, 29, '良'], + [3, 83, 60, 84, 1.09, 73, 27, '良'], + [4, 109, 81, 121, 1.28, 68, 51, '轻度污染'], + [5, 106, 77, 114, 1.07, 55, 51, '轻度污染'], + [6, 109, 81, 121, 1.28, 68, 51, '轻度污染'], + [7, 106, 77, 114, 1.07, 55, 51, '轻度污染'], + [8, 89, 65, 78, 0.86, 51, 26, '良'], + [9, 53, 33, 47, 0.64, 50, 17, '良'], + [10, 80, 55, 80, 1.01, 75, 24, '良'], + [11, 117, 81, 124, 1.03, 45, 24, '轻度污染'], + [12, 99, 71, 142, 1.1, 62, 42, '良'], + [13, 95, 69, 130, 1.28, 74, 50, '良'], + [14, 116, 87, 131, 1.47, 84, 40, '轻度污染'], + [15, 108, 80, 121, 1.3, 85, 37, '轻度污染'], + [16, 134, 83, 167, 1.16, 57, 43, '轻度污染'], + [17, 79, 43, 107, 1.05, 59, 37, '良'], + [18, 71, 46, 89, 0.86, 64, 25, '良'], + [19, 97, 71, 113, 1.17, 88, 31, '良'], + [20, 84, 57, 91, 0.85, 55, 31, '良'], + [21, 87, 63, 101, 0.9, 56, 41, '良'], + [22, 104, 77, 119, 1.09, 73, 48, '轻度污染'], + [23, 87, 62, 100, 1, 72, 28, '良'], + [24, 168, 128, 172, 1.49, 97, 56, '中度污染'], + [25, 65, 45, 51, 0.74, 39, 17, '良'], + [26, 39, 24, 38, 0.61, 47, 17, '优'], + [27, 39, 24, 39, 0.59, 50, 19, '优'], + [28, 93, 68, 96, 1.05, 79, 29, '良'], + [29, 188, 143, 197, 1.66, 99, 51, '中度污染'], + [30, 174, 131, 174, 1.55, 108, 50, '中度污染'], + [31, 187, 143, 201, 1.39, 89, 53, '中度污染'] +]; +const schema = [ + { name: 'date', index: 0, text: '日' }, + { name: 'AQIindex', index: 1, text: 'AQI指数' }, + { name: 'PM25', index: 2, text: 'PM2.5' }, + { name: 'PM10', index: 3, text: 'PM10' }, + { name: 'CO', index: 4, text: '一氧化碳(CO)' }, + { name: 'NO2', index: 5, text: '二氧化氮(NO2)' }, + { name: 'SO2', index: 6, text: '二氧化硫(SO2)' } +]; +const itemStyle = { + opacity: 0.8, + shadowBlur: 10, + shadowOffsetX: 0, + shadowOffsetY: 0, + shadowColor: 'rgba(0,0,0,0.3)' +}; +option = { + color: ['#dd4444', '#fec42c', '#80F1BE'], + legend: { + top: 10, + data: ['北京', '上海', '广州'], + textStyle: { + fontSize: 16 + } + }, + grid: { + left: '10%', + right: 150, + top: '18%', + bottom: '10%' + }, + tooltip: { + backgroundColor: 'rgba(255,255,255,0.7)', + formatter: function (param) { + var value = param.value; + // prettier-ignore + return '
' + + param.seriesName + ' ' + value[0] + '日:' + + value[7] + + '
' + + schema[1].text + ':' + value[1] + '
' + + schema[2].text + ':' + value[2] + '
' + + schema[3].text + ':' + value[3] + '
' + + schema[4].text + ':' + value[4] + '
' + + schema[5].text + ':' + value[5] + '
' + + schema[6].text + ':' + value[6] + '
'; + } + }, + xAxis: { + type: 'value', + name: '日期', + nameGap: 16, + nameTextStyle: { + fontSize: 16 + }, + max: 31, + splitLine: { + show: false + } + }, + yAxis: { + type: 'value', + name: 'AQI指数', + nameLocation: 'end', + nameGap: 20, + nameTextStyle: { + fontSize: 16 + }, + splitLine: { + show: false + } + }, + visualMap: [ + { + left: 'right', + top: '10%', + dimension: 2, + min: 0, + max: 250, + itemWidth: 30, + itemHeight: 120, + calculable: true, + precision: 0.1, + text: ['圆形大小:PM2.5'], + textGap: 30, + inRange: { + symbolSize: [10, 70] + }, + outOfRange: { + symbolSize: [10, 70], + color: ['rgba(255,255,255,0.4)'] + }, + controller: { + inRange: { + color: ['#c23531'] + }, + outOfRange: { + color: ['#999'] + } + } + }, + { + left: 'right', + bottom: '5%', + dimension: 6, + min: 0, + max: 50, + itemHeight: 120, + text: ['明暗:二氧化硫'], + textGap: 30, + inRange: { + colorLightness: [0.9, 0.5] + }, + outOfRange: { + color: ['rgba(255,255,255,0.4)'] + }, + controller: { + inRange: { + color: ['#c23531'] + }, + outOfRange: { + color: ['#999'] + } + } + } + ], + series: [ + { + name: '北京', + type: 'scatter', + itemStyle: itemStyle, + data: dataBJ + }, + { + name: '上海', + type: 'scatter', + itemStyle: itemStyle, + data: dataSH + }, + { + name: '广州', + type: 'scatter', + itemStyle: itemStyle, + data: dataGZ + } + ] +}; +export {}; diff --git a/testdata/scatter-aqi-color.js.svg b/testdata/scatter-aqi-color.js.svg new file mode 100644 index 0000000..7a6df40 --- /dev/null +++ b/testdata/scatter-aqi-color.js.svg @@ -0,0 +1,1878 @@ + + + +AQI指数 + +日期 + + + + + + + + + + + + + + + +0 +50 +100 +150 +200 +250 +300 +0 +5 +10 +15 +20 +25 +30 +31 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +0 +250 + + + + + + +圆形大小:PM2.5 + + + + +明暗:二氧化硫 + +北京 + +上海 + +广州 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/scatter-clustering-process.js b/testdata/scatter-clustering-process.js new file mode 100644 index 0000000..a973af6 --- /dev/null +++ b/testdata/scatter-clustering-process.js @@ -0,0 +1,231 @@ +"use strict"; +/* +title: Clustering Process +category: scatter +titleCN: 聚合过程可视化 +difficulty: 1 +*/ +var originalData = [ + [3.275154, 2.957587], + [-3.344465, 2.603513], + [0.355083, -3.376585], + [1.852435, 3.547351], + [-2.078973, 2.552013], + [-0.993756, -0.884433], + [2.682252, 4.007573], + [-3.087776, 2.878713], + [-1.565978, -1.256985], + [2.441611, 0.444826], + [-0.659487, 3.111284], + [-0.459601, -2.618005], + [2.17768, 2.387793], + [-2.920969, 2.917485], + [-0.028814, -4.168078], + [3.625746, 2.119041], + [-3.912363, 1.325108], + [-0.551694, -2.814223], + [2.855808, 3.483301], + [-3.594448, 2.856651], + [0.421993, -2.372646], + [1.650821, 3.407572], + [-2.082902, 3.384412], + [-0.718809, -2.492514], + [4.513623, 3.841029], + [-4.822011, 4.607049], + [-0.656297, -1.449872], + [1.919901, 4.439368], + [-3.287749, 3.918836], + [-1.576936, -2.977622], + [3.598143, 1.97597], + [-3.977329, 4.900932], + [-1.79108, -2.184517], + [3.914654, 3.559303], + [-1.910108, 4.166946], + [-1.226597, -3.317889], + [1.148946, 3.345138], + [-2.113864, 3.548172], + [0.845762, -3.589788], + [2.629062, 3.535831], + [-1.640717, 2.990517], + [-1.881012, -2.485405], + [4.606999, 3.510312], + [-4.366462, 4.023316], + [0.765015, -3.00127], + [3.121904, 2.173988], + [-4.025139, 4.65231], + [-0.559558, -3.840539], + [4.376754, 4.863579], + [-1.874308, 4.032237], + [-0.089337, -3.026809], + [3.997787, 2.518662], + [-3.082978, 2.884822], + [0.845235, -3.454465], + [1.327224, 3.358778], + [-2.889949, 3.596178], + [-0.966018, -2.839827], + [2.960769, 3.079555], + [-3.275518, 1.577068], + [0.639276, -3.41284] +]; +var DIM_CLUSTER_INDEX = 2; +var DATA_DIM_IDX = [0, 1]; +var CENTER_DIM_IDX = [3, 4]; +// See https://github.com/ecomfe/echarts-stat +var step = ecStat.clustering.hierarchicalKMeans(originalData, { + clusterCount: 6, + outputType: 'single', + outputClusterIndexDimension: DIM_CLUSTER_INDEX, + outputCentroidDimensions: CENTER_DIM_IDX, + stepByStep: true +}); +var colorAll = [ + '#bbb', + '#37A2DA', + '#e06343', + '#37a354', + '#b55dba', + '#b5bd48', + '#8378EA', + '#96BFFF' +]; +var ANIMATION_DURATION_UPDATE = 1500; +function renderItemPoint(params, api) { + var coord = api.coord([api.value(0), api.value(1)]); + var clusterIdx = api.value(2); + if (clusterIdx == null || isNaN(clusterIdx)) { + clusterIdx = 0; + } + var isNewCluster = clusterIdx === api.value(3); + var extra = { + transition: [] + }; + var contentColor = colorAll[clusterIdx]; + return { + type: 'circle', + x: coord[0], + y: coord[1], + shape: { + cx: 0, + cy: 0, + r: 10 + }, + extra: extra, + style: { + fill: contentColor, + stroke: '#333', + lineWidth: 1, + shadowColor: contentColor, + shadowBlur: isNewCluster ? 12 : 0, + transition: ['shadowBlur', 'fill'] + } + }; +} +function renderBoundary(params, api) { + var xVal = api.value(0); + var yVal = api.value(1); + var maxDist = api.value(2); + var center = api.coord([xVal, yVal]); + var size = api.size([maxDist, maxDist]); + return { + type: 'ellipse', + shape: { + cx: isNaN(center[0]) ? 0 : center[0], + cy: isNaN(center[1]) ? 0 : center[1], + rx: isNaN(size[0]) ? 0 : size[0] + 15, + ry: isNaN(size[1]) ? 0 : size[1] + 15 + }, + extra: { + renderProgress: ++targetRenderProgress, + enterFrom: { + renderProgress: 0 + }, + transition: 'renderProgress' + }, + style: { + fill: null, + stroke: 'rgba(0,0,0,0.2)', + lineDash: [4, 4], + lineWidth: 4 + } + }; +} +function makeStepOption(option, data, centroids) { + var newCluIdx = centroids ? centroids.length - 1 : -1; + var maxDist = 0; + for (var i = 0; i < data.length; i++) { + var line = data[i]; + if (line[DIM_CLUSTER_INDEX] === newCluIdx) { + var dist0 = Math.pow(line[DATA_DIM_IDX[0]] - line[CENTER_DIM_IDX[0]], 2); + var dist1 = Math.pow(line[DATA_DIM_IDX[1]] - line[CENTER_DIM_IDX[1]], 2); + maxDist = Math.max(maxDist, dist0 + dist1); + } + } + var boundaryData = centroids + ? [[centroids[newCluIdx][0], centroids[newCluIdx][1], Math.sqrt(maxDist)]] + : []; + option.options.push({ + series: [ + { + type: 'custom', + encode: { + tooltip: [0, 1] + }, + renderItem: renderItemPoint, + data: data + }, + { + type: 'custom', + renderItem: renderBoundary, + animationDuration: 3000, + silent: true, + data: boundaryData + } + ] + }); +} +var targetRenderProgress = 0; +option = { + timeline: { + top: 'center', + right: 50, + height: 300, + width: 10, + inverse: true, + autoPlay: false, + playInterval: 2500, + symbol: 'none', + orient: 'vertical', + axisType: 'category', + label: { + formatter: 'step {value}', + position: 10 + }, + checkpointStyle: { + animationDuration: ANIMATION_DURATION_UPDATE + }, + data: [] + }, + baseOption: { + animationDurationUpdate: ANIMATION_DURATION_UPDATE, + transition: ['shape'], + tooltip: {}, + xAxis: { + type: 'value' + }, + yAxis: { + type: 'value' + }, + series: [ + { + type: 'scatter' + } + ] + }, + options: [] +}; +makeStepOption(option, originalData); +option.timeline.data.push('0'); +for (var i = 1, stepResult; !(stepResult = step.next()).isEnd; i++) { + makeStepOption(option, echarts.util.clone(stepResult.data), echarts.util.clone(stepResult.centroids)); + option.timeline.data.push(i + ''); +} diff --git a/testdata/scatter-clustering.js b/testdata/scatter-clustering.js new file mode 100644 index 0000000..563b871 --- /dev/null +++ b/testdata/scatter-clustering.js @@ -0,0 +1,135 @@ +/* +title: Clustering Process +category: scatter +titleCN: 数据聚合 +difficulty: 1 +*/ +// See https://github.com/ecomfe/echarts-stat +echarts.registerTransform(ecStat.transform.clustering); +const data = [ + [3.275154, 2.957587], + [-3.344465, 2.603513], + [0.355083, -3.376585], + [1.852435, 3.547351], + [-2.078973, 2.552013], + [-0.993756, -0.884433], + [2.682252, 4.007573], + [-3.087776, 2.878713], + [-1.565978, -1.256985], + [2.441611, 0.444826], + [-0.659487, 3.111284], + [-0.459601, -2.618005], + [2.17768, 2.387793], + [-2.920969, 2.917485], + [-0.028814, -4.168078], + [3.625746, 2.119041], + [-3.912363, 1.325108], + [-0.551694, -2.814223], + [2.855808, 3.483301], + [-3.594448, 2.856651], + [0.421993, -2.372646], + [1.650821, 3.407572], + [-2.082902, 3.384412], + [-0.718809, -2.492514], + [4.513623, 3.841029], + [-4.822011, 4.607049], + [-0.656297, -1.449872], + [1.919901, 4.439368], + [-3.287749, 3.918836], + [-1.576936, -2.977622], + [3.598143, 1.97597], + [-3.977329, 4.900932], + [-1.79108, -2.184517], + [3.914654, 3.559303], + [-1.910108, 4.166946], + [-1.226597, -3.317889], + [1.148946, 3.345138], + [-2.113864, 3.548172], + [0.845762, -3.589788], + [2.629062, 3.535831], + [-1.640717, 2.990517], + [-1.881012, -2.485405], + [4.606999, 3.510312], + [-4.366462, 4.023316], + [0.765015, -3.00127], + [3.121904, 2.173988], + [-4.025139, 4.65231], + [-0.559558, -3.840539], + [4.376754, 4.863579], + [-1.874308, 4.032237], + [-0.089337, -3.026809], + [3.997787, 2.518662], + [-3.082978, 2.884822], + [0.845235, -3.454465], + [1.327224, 3.358778], + [-2.889949, 3.596178], + [-0.966018, -2.839827], + [2.960769, 3.079555], + [-3.275518, 1.577068], + [0.639276, -3.41284] +]; +var CLUSTER_COUNT = 6; +var DIENSIION_CLUSTER_INDEX = 2; +var COLOR_ALL = [ + '#37A2DA', + '#e06343', + '#37a354', + '#b55dba', + '#b5bd48', + '#8378EA', + '#96BFFF' +]; +var pieces = []; +for (var i = 0; i < CLUSTER_COUNT; i++) { + pieces.push({ + value: i, + label: 'cluster ' + i, + color: COLOR_ALL[i] + }); +} +option = { + dataset: [ + { + source: data + }, + { + transform: { + type: 'ecStat:clustering', + // print: true, + config: { + clusterCount: CLUSTER_COUNT, + outputType: 'single', + outputClusterIndexDimension: DIENSIION_CLUSTER_INDEX + } + } + } + ], + tooltip: { + position: 'top' + }, + visualMap: { + type: 'piecewise', + top: 'middle', + min: 0, + max: CLUSTER_COUNT, + left: 10, + splitNumber: CLUSTER_COUNT, + dimension: DIENSIION_CLUSTER_INDEX, + pieces: pieces + }, + grid: { + left: 120 + }, + xAxis: {}, + yAxis: {}, + series: { + type: 'scatter', + encode: { tooltip: [0, 1] }, + symbolSize: 15, + itemStyle: { + borderColor: '#555' + }, + datasetIndex: 1 + } +}; +export {}; diff --git a/testdata/scatter-effect.js b/testdata/scatter-effect.js new file mode 100644 index 0000000..95d35fc --- /dev/null +++ b/testdata/scatter-effect.js @@ -0,0 +1,82 @@ +/* +title: Effect Scatter Chart +category: scatter +titleCN: 涟漪特效散点图 +difficulty: 2 +*/ +option = { + xAxis: { + scale: true + }, + yAxis: { + scale: true + }, + series: [ + { + type: 'effectScatter', + symbolSize: 20, + data: [ + [172.7, 105.2], + [153.4, 42] + ] + }, + { + type: 'scatter', + // prettier-ignore + data: [[161.2, 51.6], [167.5, 59.0], [159.5, 49.2], [157.0, 63.0], [155.8, 53.6], + [170.0, 59.0], [159.1, 47.6], [166.0, 69.8], [176.2, 66.8], [160.2, 75.2], + [172.5, 55.2], [170.9, 54.2], [172.9, 62.5], [153.4, 42.0], [160.0, 50.0], + [147.2, 49.8], [168.2, 49.2], [175.0, 73.2], [157.0, 47.8], [167.6, 68.8], + [159.5, 50.6], [175.0, 82.5], [166.8, 57.2], [176.5, 87.8], [170.2, 72.8], + [174.0, 54.5], [173.0, 59.8], [179.9, 67.3], [170.5, 67.8], [160.0, 47.0], + [154.4, 46.2], [162.0, 55.0], [176.5, 83.0], [160.0, 54.4], [152.0, 45.8], + [162.1, 53.6], [170.0, 73.2], [160.2, 52.1], [161.3, 67.9], [166.4, 56.6], + [168.9, 62.3], [163.8, 58.5], [167.6, 54.5], [160.0, 50.2], [161.3, 60.3], + [167.6, 58.3], [165.1, 56.2], [160.0, 50.2], [170.0, 72.9], [157.5, 59.8], + [167.6, 61.0], [160.7, 69.1], [163.2, 55.9], [152.4, 46.5], [157.5, 54.3], + [168.3, 54.8], [180.3, 60.7], [165.5, 60.0], [165.0, 62.0], [164.5, 60.3], + [156.0, 52.7], [160.0, 74.3], [163.0, 62.0], [165.7, 73.1], [161.0, 80.0], + [162.0, 54.7], [166.0, 53.2], [174.0, 75.7], [172.7, 61.1], [167.6, 55.7], + [151.1, 48.7], [164.5, 52.3], [163.5, 50.0], [152.0, 59.3], [169.0, 62.5], + [164.0, 55.7], [161.2, 54.8], [155.0, 45.9], [170.0, 70.6], [176.2, 67.2], + [170.0, 69.4], [162.5, 58.2], [170.3, 64.8], [164.1, 71.6], [169.5, 52.8], + [163.2, 59.8], [154.5, 49.0], [159.8, 50.0], [173.2, 69.2], [170.0, 55.9], + [161.4, 63.4], [169.0, 58.2], [166.2, 58.6], [159.4, 45.7], [162.5, 52.2], + [159.0, 48.6], [162.8, 57.8], [159.0, 55.6], [179.8, 66.8], [162.9, 59.4], + [161.0, 53.6], [151.1, 73.2], [168.2, 53.4], [168.9, 69.0], [173.2, 58.4], + [171.8, 56.2], [178.0, 70.6], [164.3, 59.8], [163.0, 72.0], [168.5, 65.2], + [166.8, 56.6], [172.7, 105.2], [163.5, 51.8], [169.4, 63.4], [167.8, 59.0], + [159.5, 47.6], [167.6, 63.0], [161.2, 55.2], [160.0, 45.0], [163.2, 54.0], + [162.2, 50.2], [161.3, 60.2], [149.5, 44.8], [157.5, 58.8], [163.2, 56.4], + [172.7, 62.0], [155.0, 49.2], [156.5, 67.2], [164.0, 53.8], [160.9, 54.4], + [162.8, 58.0], [167.0, 59.8], [160.0, 54.8], [160.0, 43.2], [168.9, 60.5], + [158.2, 46.4], [156.0, 64.4], [160.0, 48.8], [167.1, 62.2], [158.0, 55.5], + [167.6, 57.8], [156.0, 54.6], [162.1, 59.2], [173.4, 52.7], [159.8, 53.2], + [170.5, 64.5], [159.2, 51.8], [157.5, 56.0], [161.3, 63.6], [162.6, 63.2], + [160.0, 59.5], [168.9, 56.8], [165.1, 64.1], [162.6, 50.0], [165.1, 72.3], + [166.4, 55.0], [160.0, 55.9], [152.4, 60.4], [170.2, 69.1], [162.6, 84.5], + [170.2, 55.9], [158.8, 55.5], [172.7, 69.5], [167.6, 76.4], [162.6, 61.4], + [167.6, 65.9], [156.2, 58.6], [175.2, 66.8], [172.1, 56.6], [162.6, 58.6], + [160.0, 55.9], [165.1, 59.1], [182.9, 81.8], [166.4, 70.7], [165.1, 56.8], + [177.8, 60.0], [165.1, 58.2], [175.3, 72.7], [154.9, 54.1], [158.8, 49.1], + [172.7, 75.9], [168.9, 55.0], [161.3, 57.3], [167.6, 55.0], [165.1, 65.5], + [175.3, 65.5], [157.5, 48.6], [163.8, 58.6], [167.6, 63.6], [165.1, 55.2], + [165.1, 62.7], [168.9, 56.6], [162.6, 53.9], [164.5, 63.2], [176.5, 73.6], + [168.9, 62.0], [175.3, 63.6], [159.4, 53.2], [160.0, 53.4], [170.2, 55.0], + [162.6, 70.5], [167.6, 54.5], [162.6, 54.5], [160.7, 55.9], [160.0, 59.0], + [157.5, 63.6], [162.6, 54.5], [152.4, 47.3], [170.2, 67.7], [165.1, 80.9], + [172.7, 70.5], [165.1, 60.9], [170.2, 63.6], [170.2, 54.5], [170.2, 59.1], + [161.3, 70.5], [167.6, 52.7], [167.6, 62.7], [165.1, 86.3], [162.6, 66.4], + [152.4, 67.3], [168.9, 63.0], [170.2, 73.6], [175.2, 62.3], [175.2, 57.7], + [160.0, 55.4], [165.1, 104.1], [174.0, 55.5], [170.2, 77.3], [160.0, 80.5], + [167.6, 64.5], [167.6, 72.3], [167.6, 61.4], [154.9, 58.2], [162.6, 81.8], + [175.3, 63.6], [171.4, 53.4], [157.5, 54.5], [165.1, 53.6], [160.0, 60.0], + [174.0, 73.6], [162.6, 61.4], [174.0, 55.5], [162.6, 63.6], [161.3, 60.9], + [156.2, 60.0], [149.9, 46.8], [169.5, 57.3], [160.0, 64.1], [175.3, 63.6], + [169.5, 67.3], [160.0, 75.5], [172.7, 68.2], [162.6, 61.4], [157.5, 76.8], + [176.5, 71.8], [164.4, 55.5], [160.7, 48.6], [174.0, 66.4], [163.8, 67.3] + ] + } + ] +}; +export {}; diff --git a/testdata/scatter-effect.js.svg b/testdata/scatter-effect.js.svg new file mode 100644 index 0000000..5b08d90 --- /dev/null +++ b/testdata/scatter-effect.js.svg @@ -0,0 +1,3815 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +40 +50 +60 +70 +80 +90 +100 +110 +140 +150 +160 +170 +180 +190 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/scatter-exponential-regression.js b/testdata/scatter-exponential-regression.js new file mode 100644 index 0000000..7563dd2 --- /dev/null +++ b/testdata/scatter-exponential-regression.js @@ -0,0 +1,89 @@ +/* +title: Exponential Regression +category: scatter +titleCN: 指数回归(使用统计插件) +difficulty: 1 +*/ +// See https://github.com/ecomfe/echarts-stat +echarts.registerTransform(ecStat.transform.regression); +option = { + dataset: [ + { + source: [ + [1, 4862.4], + [2, 5294.7], + [3, 5934.5], + [4, 7171.0], + [5, 8964.4], + [6, 10202.2], + [7, 11962.5], + [8, 14928.3], + [9, 16909.2], + [10, 18547.9], + [11, 21617.8], + [12, 26638.1], + [13, 34634.4], + [14, 46759.4], + [15, 58478.1], + [16, 67884.6], + [17, 74462.6], + [18, 79395.7] + ] + }, + { + transform: { + type: 'ecStat:regression', + config: { + method: 'exponential' + // 'end' by default + // formulaOn: 'start' + } + } + } + ], + title: { + text: '1981 - 1998 gross domestic product GDP (trillion yuan)', + subtext: 'By ecStat.regression', + sublink: 'https://github.com/ecomfe/echarts-stat', + left: 'center' + }, + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'cross' + } + }, + xAxis: { + splitLine: { + lineStyle: { + type: 'dashed' + } + } + }, + yAxis: { + splitLine: { + lineStyle: { + type: 'dashed' + } + } + }, + series: [ + { + name: 'scatter', + type: 'scatter', + datasetIndex: 0 + }, + { + name: 'line', + type: 'line', + smooth: true, + datasetIndex: 1, + symbolSize: 0.1, + symbol: 'circle', + label: { show: true, fontSize: 16 }, + labelLayout: { dx: -20 }, + encode: { label: 2, tooltip: 1 } + } + ] +}; +export {}; diff --git a/testdata/scatter-label-align-right.js b/testdata/scatter-label-align-right.js new file mode 100644 index 0000000..e715e9e --- /dev/null +++ b/testdata/scatter-label-align-right.js @@ -0,0 +1,59 @@ +/* +title: Align Label on the Top +category: scatter +titleCN: 散点图标签顶部对齐 +difficulty: 4 +*/ +// prettier-ignore +const data = [ + [[28604, 77, 17096869, 'Australia', 1990], [31163, 77.4, 27662440, 'Canada', 1990], [1516, 68, 1154605773, 'China', 1990], [13670, 74.7, 10582082, 'Cuba', 1990], [28599, 75, 4986705, 'Finland', 1990], [29476, 77.1, 56943299, 'France', 1990], [31476, 75.4, 78958237, 'Germany', 1990], [28666, 78.1, 254830, 'Iceland', 1990], [1777, 57.7, 870601776, 'India', 1990], [29550, 79.1, 122249285, 'Japan', 1990], [2076, 67.9, 20194354, 'North Korea', 1990], [12087, 72, 42972254, 'South Korea', 1990], [24021, 75.4, 3397534, 'New Zealand', 1990], [43296, 76.8, 4240375, 'Norway', 1990], [10088, 70.8, 38195258, 'Poland', 1990], [19349, 69.6, 147568552, 'Russia', 1990], [10670, 67.3, 53994605, 'Turkey', 1990], [26424, 75.7, 57110117, 'United Kingdom', 1990], [37062, 75.4, 252847810, 'United States', 1990]], + [[44056, 81.8, 23968973, 'Australia', 2015], [43294, 81.7, 35939927, 'Canada', 2015], [13334, 76.9, 1376048943, 'China', 2015], [21291, 78.5, 11389562, 'Cuba', 2015], [38923, 80.8, 5503457, 'Finland', 2015], [37599, 81.9, 64395345, 'France', 2015], [44053, 81.1, 80688545, 'Germany', 2015], [42182, 82.8, 329425, 'Iceland', 2015], [5903, 66.8, 1311050527, 'India', 2015], [36162, 83.5, 126573481, 'Japan', 2015], [1390, 71.4, 25155317, 'North Korea', 2015], [34644, 80.7, 50293439, 'South Korea', 2015], [34186, 80.6, 4528526, 'New Zealand', 2015], [64304, 81.6, 5210967, 'Norway', 2015], [24787, 77.3, 38611794, 'Poland', 2015], [23038, 73.13, 143456918, 'Russia', 2015], [19360, 76.5, 78665830, 'Turkey', 2015], [38225, 81.4, 64715810, 'United Kingdom', 2015], [53354, 79.1, 321773631, 'United States', 2015]] +]; +option = { + xAxis: { + splitLine: { show: false } + }, + yAxis: { + splitLine: { show: false }, + scale: true + }, + grid: { + left: 40, + right: 130 + }, + series: [ + { + name: '1990', + data: data[0], + type: 'scatter', + symbolSize: function (data) { + return Math.sqrt(data[2]) / 5e2; + }, + emphasis: { + focus: 'self' + }, + labelLayout: function () { + return { + x: myChart.getWidth() - 100, + moveOverlap: 'shiftY' + }; + }, + labelLine: { + show: true, + length2: 5, + lineStyle: { + color: '#bbb' + } + }, + label: { + show: true, + formatter: function (param) { + return param.data[3]; + }, + position: 'right', + minMargin: 2 + } + } + ] +}; +export {}; diff --git a/testdata/scatter-label-align-right.js.svg b/testdata/scatter-label-align-right.js.svg new file mode 100644 index 0000000..1157aa8 --- /dev/null +++ b/testdata/scatter-label-align-right.js.svg @@ -0,0 +1,337 @@ + + + + + + + + + + + + + + + + +55 +60 +65 +70 +75 +80 +0 +10,000 +20,000 +30,000 +40,000 +50,000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +77 +77.4 +68 +74.7 +75 +77.1 +75.4 +78.1 +57.7 +79.1 +67.9 +72 +75.4 +76.8 +70.8 +69.6 +67.3 +75.7 +75.4 + + \ No newline at end of file diff --git a/testdata/scatter-label-align-top.js b/testdata/scatter-label-align-top.js new file mode 100644 index 0000000..2e8a98b --- /dev/null +++ b/testdata/scatter-label-align-top.js @@ -0,0 +1,52 @@ +/* +title: Align Label on the Top +category: scatter +titleCN: 散点图标签顶部对齐 +difficulty: 4 +*/ +// prettier-ignore +const data = [ + [[28604, 77, 17096869, 'Australia', 1990], [31163, 77.4, 27662440, 'Canada', 1990], [1516, 68, 1154605773, 'China', 1990], [13670, 74.7, 10582082, 'Cuba', 1990], [28599, 75, 4986705, 'Finland', 1990], [29476, 77.1, 56943299, 'France', 1990], [31476, 75.4, 78958237, 'Germany', 1990], [28666, 78.1, 254830, 'Iceland', 1990], [1777, 57.7, 870601776, 'India', 1990], [29550, 79.1, 122249285, 'Japan', 1990], [2076, 67.9, 20194354, 'North Korea', 1990], [12087, 72, 42972254, 'South Korea', 1990], [24021, 75.4, 3397534, 'New Zealand', 1990], [43296, 76.8, 4240375, 'Norway', 1990], [10088, 70.8, 38195258, 'Poland', 1990], [19349, 69.6, 147568552, 'Russia', 1990], [10670, 67.3, 53994605, 'Turkey', 1990], [26424, 75.7, 57110117, 'United Kingdom', 1990], [37062, 75.4, 252847810, 'United States', 1990]], + [[44056, 81.8, 23968973, 'Australia', 2015], [43294, 81.7, 35939927, 'Canada', 2015], [13334, 76.9, 1376048943, 'China', 2015], [21291, 78.5, 11389562, 'Cuba', 2015], [38923, 80.8, 5503457, 'Finland', 2015], [37599, 81.9, 64395345, 'France', 2015], [44053, 81.1, 80688545, 'Germany', 2015], [42182, 82.8, 329425, 'Iceland', 2015], [5903, 66.8, 1311050527, 'India', 2015], [36162, 83.5, 126573481, 'Japan', 2015], [1390, 71.4, 25155317, 'North Korea', 2015], [34644, 80.7, 50293439, 'South Korea', 2015], [34186, 80.6, 4528526, 'New Zealand', 2015], [64304, 81.6, 5210967, 'Norway', 2015], [24787, 77.3, 38611794, 'Poland', 2015], [23038, 73.13, 143456918, 'Russia', 2015], [19360, 76.5, 78665830, 'Turkey', 2015], [38225, 81.4, 64715810, 'United Kingdom', 2015], [53354, 79.1, 321773631, 'United States', 2015]] +]; +option = { + xAxis: {}, + yAxis: { + scale: true + }, + series: [ + { + name: '1990', + data: data[0], + type: 'scatter', + symbolSize: function (data) { + return Math.sqrt(data[2]) / 5e2; + }, + emphasis: { + focus: 'self' + }, + labelLayout: { + y: 20, + align: 'center', + hideOverlap: true, + moveOverlap: 'shiftX' + }, + labelLine: { + show: true, + length2: 5, + lineStyle: { + color: '#bbb' + } + }, + label: { + show: true, + formatter: function (param) { + return param.data[3]; + }, + minMargin: 10, + position: 'top' + } + } + ] +}; +export {}; diff --git a/testdata/scatter-label-align-top.js.svg b/testdata/scatter-label-align-top.js.svg new file mode 100644 index 0000000..2a69fc1 --- /dev/null +++ b/testdata/scatter-label-align-top.js.svg @@ -0,0 +1,349 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +55 +60 +65 +70 +75 +80 +0 +10,000 +20,000 +30,000 +40,000 +50,000 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +77 +77.4 +68 +74.7 +75 +77.1 +75.4 +78.1 +57.7 +79.1 +67.9 +72 +75.4 +76.8 +70.8 +69.6 +67.3 +75.7 +75.4 + + \ No newline at end of file diff --git a/testdata/scatter-large.js b/testdata/scatter-large.js new file mode 100644 index 0000000..9ad402a --- /dev/null +++ b/testdata/scatter-large.js @@ -0,0 +1,73 @@ +/* +title: Large Scatter +category: scatter +titleCN: 大规模散点图 +difficulty: 5 +*/ +function genData(len, offset) { + let arr = new Float32Array(len * 2); + let off = 0; + for (let i = 0; i < len; i++) { + let x = +Math.random() * 10; + let y = +Math.sin(x) - + x * (len % 2 ? 0.1 : -0.1) * Math.random() + + (offset || 0) / 10; + arr[off++] = x; + arr[off++] = y; + } + return arr; +} +const data1 = genData(5e5); +const data2 = genData(5e5, 10); +option = { + title: { + text: echarts.format.addCommas(data1.length / 2 + data2.length / 2) + ' Points' + }, + tooltip: {}, + toolbox: { + left: 'center', + feature: { + dataZoom: {} + } + }, + legend: { + orient: 'vertical', + right: 10 + }, + xAxis: [{}], + yAxis: [{}], + dataZoom: [ + { + type: 'inside' + }, + { + type: 'slider' + } + ], + animation: false, + series: [ + { + name: 'A', + type: 'scatter', + data: data1, + dimensions: ['x', 'y'], + symbolSize: 3, + itemStyle: { + opacity: 0.4 + }, + large: true + }, + { + name: 'B', + type: 'scatter', + data: data2, + dimensions: ['x', 'y'], + symbolSize: 3, + itemStyle: { + opacity: 0.4 + }, + large: true + } + ] +}; +export {}; diff --git a/testdata/scatter-large.js.svg b/testdata/scatter-large.js.svg new file mode 100644 index 0000000..e07d1df --- /dev/null +++ b/testdata/scatter-large.js.svg @@ -0,0 +1,52 @@ + + + + + + + + + + + + + + + + + + + + + + + + + +A + +B + + + + + + + + + + + +1,000,000 Points + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/scatter-life-expectancy-timeline.js b/testdata/scatter-life-expectancy-timeline.js new file mode 100644 index 0000000..412d98e --- /dev/null +++ b/testdata/scatter-life-expectancy-timeline.js @@ -0,0 +1,166 @@ +"use strict"; +/* +title: Life Expectancy and GDP +category: scatter +titleCN: 各国人均寿命与GDP关系演变 +difficulty: 9 +*/ +myChart.showLoading(); +$.get(ROOT_PATH + '/data/asset/data/life-expectancy.json', function (data) { + myChart.hideLoading(); + var itemStyle = { + opacity: 0.8 + }; + var sizeFunction = function (x) { + var y = Math.sqrt(x / 5e8) + 0.1; + return y * 80; + }; + // Schema: + var schema = [ + { name: 'Income', index: 0, text: '人均收入', unit: '美元' }, + { name: 'LifeExpectancy', index: 1, text: '人均寿命', unit: '岁' }, + { name: 'Population', index: 2, text: '总人口', unit: '' }, + { name: 'Country', index: 3, text: '国家', unit: '' } + ]; + option = { + baseOption: { + timeline: { + axisType: 'category', + orient: 'vertical', + autoPlay: true, + inverse: true, + playInterval: 1000, + left: null, + right: 0, + top: 20, + bottom: 20, + width: 55, + height: null, + symbol: 'none', + checkpointStyle: { + borderWidth: 2 + }, + controlStyle: { + showNextBtn: false, + showPrevBtn: false + }, + data: [] + }, + title: [ + { + text: data.timeline[0], + textAlign: 'center', + left: '63%', + top: '55%', + textStyle: { + fontSize: 100 + } + }, + { + text: '各国人均寿命与GDP关系演变', + left: 'center', + top: 10, + textStyle: { + fontWeight: 'normal', + fontSize: 20 + } + } + ], + tooltip: { + padding: 5, + borderWidth: 1, + formatter: function (obj) { + var value = obj.value; + // prettier-ignore + return schema[3].text + ':' + value[3] + '
' + + schema[1].text + ':' + value[1] + schema[1].unit + '
' + + schema[0].text + ':' + value[0] + schema[0].unit + '
' + + schema[2].text + ':' + value[2] + '
'; + } + }, + grid: { + top: 100, + containLabel: true, + left: 30, + right: '110' + }, + xAxis: { + type: 'log', + name: '人均收入', + max: 100000, + min: 300, + nameGap: 25, + nameLocation: 'middle', + nameTextStyle: { + fontSize: 18 + }, + splitLine: { + show: false + }, + axisLabel: { + formatter: '{value} $' + } + }, + yAxis: { + type: 'value', + name: '平均寿命', + max: 100, + nameTextStyle: { + fontSize: 18 + }, + splitLine: { + show: false + }, + axisLabel: { + formatter: '{value} 岁' + } + }, + visualMap: [ + { + show: false, + dimension: 3, + categories: data.counties, + inRange: { + color: (function () { + // prettier-ignore + var colors = ['#51689b', '#ce5c5c', '#fbc357', '#8fbf8f', '#659d84', '#fb8e6a', '#c77288', '#786090', '#91c4c5', '#6890ba']; + return colors.concat(colors); + })() + } + } + ], + series: [ + { + type: 'scatter', + itemStyle: itemStyle, + data: data.series[0], + symbolSize: function (val) { + return sizeFunction(val[2]); + } + } + ], + animationDurationUpdate: 1000, + animationEasingUpdate: 'quinticInOut' + }, + options: [] + }; + for (var n = 0; n < data.timeline.length; n++) { + option.baseOption.timeline.data.push(data.timeline[n]); + option.options.push({ + title: { + show: true, + text: data.timeline[n] + '' + }, + series: { + name: data.timeline[n], + type: 'scatter', + itemStyle: itemStyle, + data: data.series[n], + symbolSize: function (val) { + return sizeFunction(val[2]); + } + } + }); + } + myChart.setOption(option); +}); diff --git a/testdata/scatter-linear-regression.js b/testdata/scatter-linear-regression.js new file mode 100644 index 0000000..7540754 --- /dev/null +++ b/testdata/scatter-linear-regression.js @@ -0,0 +1,270 @@ +/* +title: Linear Regression +category: scatter +titleCN: 线性回归(使用统计插件) +difficulty: 2 +*/ +// See https://github.com/ecomfe/echarts-stat +echarts.registerTransform(ecStat.transform.regression); +const data = [ + [0.067732, 3.176513], + [0.42781, 3.816464], + [0.995731, 4.550095], + [0.738336, 4.256571], + [0.981083, 4.560815], + [0.526171, 3.929515], + [0.378887, 3.52617], + [0.033859, 3.156393], + [0.132791, 3.110301], + [0.138306, 3.149813], + [0.247809, 3.476346], + [0.64827, 4.119688], + [0.731209, 4.282233], + [0.236833, 3.486582], + [0.969788, 4.655492], + [0.607492, 3.965162], + [0.358622, 3.5149], + [0.147846, 3.125947], + [0.63782, 4.094115], + [0.230372, 3.476039], + [0.070237, 3.21061], + [0.067154, 3.190612], + [0.925577, 4.631504], + [0.717733, 4.29589], + [0.015371, 3.085028], + [0.33507, 3.44808], + [0.040486, 3.16744], + [0.212575, 3.364266], + [0.617218, 3.993482], + [0.541196, 3.891471], + [0.045353, 3.143259], + [0.126762, 3.114204], + [0.556486, 3.851484], + [0.901144, 4.621899], + [0.958476, 4.580768], + [0.274561, 3.620992], + [0.394396, 3.580501], + [0.87248, 4.618706], + [0.409932, 3.676867], + [0.908969, 4.641845], + [0.166819, 3.175939], + [0.665016, 4.26498], + [0.263727, 3.558448], + [0.231214, 3.436632], + [0.552928, 3.831052], + [0.047744, 3.182853], + [0.365746, 3.498906], + [0.495002, 3.946833], + [0.493466, 3.900583], + [0.792101, 4.238522], + [0.76966, 4.23308], + [0.251821, 3.521557], + [0.181951, 3.203344], + [0.808177, 4.278105], + [0.334116, 3.555705], + [0.33863, 3.502661], + [0.452584, 3.859776], + [0.69477, 4.275956], + [0.590902, 3.916191], + [0.307928, 3.587961], + [0.148364, 3.183004], + [0.70218, 4.225236], + [0.721544, 4.231083], + [0.666886, 4.240544], + [0.124931, 3.222372], + [0.618286, 4.021445], + [0.381086, 3.567479], + [0.385643, 3.56258], + [0.777175, 4.262059], + [0.116089, 3.208813], + [0.115487, 3.169825], + [0.66351, 4.193949], + [0.254884, 3.491678], + [0.993888, 4.533306], + [0.295434, 3.550108], + [0.952523, 4.636427], + [0.307047, 3.557078], + [0.277261, 3.552874], + [0.279101, 3.494159], + [0.175724, 3.206828], + [0.156383, 3.195266], + [0.733165, 4.221292], + [0.848142, 4.413372], + [0.771184, 4.184347], + [0.429492, 3.742878], + [0.162176, 3.201878], + [0.917064, 4.648964], + [0.315044, 3.510117], + [0.201473, 3.274434], + [0.297038, 3.579622], + [0.336647, 3.489244], + [0.666109, 4.237386], + [0.583888, 3.913749], + [0.085031, 3.22899], + [0.687006, 4.286286], + [0.949655, 4.628614], + [0.189912, 3.239536], + [0.844027, 4.457997], + [0.333288, 3.513384], + [0.427035, 3.729674], + [0.466369, 3.834274], + [0.550659, 3.811155], + [0.278213, 3.598316], + [0.918769, 4.692514], + [0.886555, 4.604859], + [0.569488, 3.864912], + [0.066379, 3.184236], + [0.335751, 3.500796], + [0.426863, 3.743365], + [0.395746, 3.622905], + [0.694221, 4.310796], + [0.27276, 3.583357], + [0.503495, 3.901852], + [0.067119, 3.233521], + [0.038326, 3.105266], + [0.599122, 3.865544], + [0.947054, 4.628625], + [0.671279, 4.231213], + [0.434811, 3.791149], + [0.509381, 3.968271], + [0.749442, 4.25391], + [0.058014, 3.19471], + [0.482978, 3.996503], + [0.466776, 3.904358], + [0.357767, 3.503976], + [0.949123, 4.557545], + [0.41732, 3.699876], + [0.920461, 4.613614], + [0.156433, 3.140401], + [0.656662, 4.206717], + [0.616418, 3.969524], + [0.853428, 4.476096], + [0.133295, 3.136528], + [0.693007, 4.279071], + [0.178449, 3.200603], + [0.199526, 3.299012], + [0.073224, 3.209873], + [0.286515, 3.632942], + [0.182026, 3.248361], + [0.621523, 3.995783], + [0.344584, 3.563262], + [0.398556, 3.649712], + [0.480369, 3.951845], + [0.15335, 3.145031], + [0.171846, 3.181577], + [0.867082, 4.637087], + [0.223855, 3.404964], + [0.528301, 3.873188], + [0.890192, 4.633648], + [0.106352, 3.154768], + [0.917886, 4.623637], + [0.014855, 3.078132], + [0.567682, 3.913596], + [0.068854, 3.221817], + [0.603535, 3.938071], + [0.53205, 3.880822], + [0.651362, 4.176436], + [0.901225, 4.648161], + [0.204337, 3.332312], + [0.696081, 4.240614], + [0.963924, 4.532224], + [0.98139, 4.557105], + [0.987911, 4.610072], + [0.990947, 4.636569], + [0.736021, 4.229813], + [0.253574, 3.50086], + [0.674722, 4.245514], + [0.939368, 4.605182], + [0.235419, 3.45434], + [0.110521, 3.180775], + [0.218023, 3.38082], + [0.869778, 4.56502], + [0.19683, 3.279973], + [0.958178, 4.554241], + [0.972673, 4.63352], + [0.745797, 4.281037], + [0.445674, 3.844426], + [0.470557, 3.891601], + [0.549236, 3.849728], + [0.335691, 3.492215], + [0.884739, 4.592374], + [0.918916, 4.632025], + [0.441815, 3.75675], + [0.116598, 3.133555], + [0.359274, 3.567919], + [0.814811, 4.363382], + [0.387125, 3.560165], + [0.982243, 4.564305], + [0.78088, 4.215055], + [0.652565, 4.174999], + [0.87003, 4.58664], + [0.604755, 3.960008], + [0.255212, 3.529963], + [0.730546, 4.213412], + [0.493829, 3.908685], + [0.257017, 3.585821], + [0.833735, 4.374394], + [0.070095, 3.213817], + [0.52707, 3.952681], + [0.116163, 3.129283] +]; +option = { + dataset: [ + { + source: data + }, + { + transform: { + type: 'ecStat:regression' + // 'linear' by default. + // config: { method: 'linear', formulaOn: 'end'} + } + } + ], + title: { + text: 'Linear Regression', + subtext: 'By ecStat.regression', + sublink: 'https://github.com/ecomfe/echarts-stat', + left: 'center' + }, + legend: { + bottom: 5 + }, + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'cross' + } + }, + xAxis: { + splitLine: { + lineStyle: { + type: 'dashed' + } + } + }, + yAxis: { + splitLine: { + lineStyle: { + type: 'dashed' + } + } + }, + series: [ + { + name: 'scatter', + type: 'scatter' + }, + { + name: 'line', + type: 'line', + datasetIndex: 1, + symbolSize: 0.1, + symbol: 'circle', + label: { show: true, fontSize: 16 }, + labelLayout: { dx: -20 }, + encode: { label: 2, tooltip: 1 } + } + ] +}; +export {}; diff --git a/testdata/scatter-logarithmic-regression.js b/testdata/scatter-logarithmic-regression.js new file mode 100644 index 0000000..27c85c9 --- /dev/null +++ b/testdata/scatter-logarithmic-regression.js @@ -0,0 +1,140 @@ +/* +title: Logarithmic Regression +category: scatter +titleCN: 对数回归(使用统计插件) +difficulty: 16 +*/ +// See https://github.com/ecomfe/echarts-stat +echarts.registerTransform(ecStat.transform.regression); +option = { + dataset: [ + { + source: [ + [28604, 77, 17096869, 'Australia', 1990], + [31163, 77.4, 27662440, 'Canada', 1990], + [1516, 68, 1154605773, 'China', 1990], + [13670, 74.7, 10582082, 'Cuba', 1990], + [28599, 75, 4986705, 'Finland', 1990], + [29476, 77.1, 56943299, 'France', 1990], + [31476, 75.4, 78958237, 'Germany', 1990], + [28666, 78.1, 254830, 'Iceland', 1990], + [1777, 57.7, 870601776, 'India', 1990], + [29550, 79.1, 122249285, 'Japan', 1990], + [2076, 67.9, 20194354, 'North Korea', 1990], + [12087, 72, 42972254, 'South Korea', 1990], + [24021, 75.4, 3397534, 'New Zealand', 1990], + [43296, 76.8, 4240375, 'Norway', 1990], + [10088, 70.8, 38195258, 'Poland', 1990], + [19349, 69.6, 147568552, 'Russia', 1990], + [10670, 67.3, 53994605, 'Turkey', 1990], + [26424, 75.7, 57110117, 'United Kingdom', 1990], + [37062, 75.4, 252847810, 'United States', 1990], + [44056, 81.8, 23968973, 'Australia', 2015], + [43294, 81.7, 35939927, 'Canada', 2015], + [13334, 76.9, 1376048943, 'China', 2015], + [21291, 78.5, 11389562, 'Cuba', 2015], + [38923, 80.8, 5503457, 'Finland', 2015], + [37599, 81.9, 64395345, 'France', 2015], + [44053, 81.1, 80688545, 'Germany', 2015], + [42182, 82.8, 329425, 'Iceland', 2015], + [5903, 66.8, 1311050527, 'India', 2015], + [36162, 83.5, 126573481, 'Japan', 2015], + [1390, 71.4, 25155317, 'North Korea', 2015], + [34644, 80.7, 50293439, 'South Korea', 2015], + [34186, 80.6, 4528526, 'New Zealand', 2015], + [64304, 81.6, 5210967, 'Norway', 2015], + [24787, 77.3, 38611794, 'Poland', 2015], + [23038, 73.13, 143456918, 'Russia', 2015], + [19360, 76.5, 78665830, 'Turkey', 2015], + [38225, 81.4, 64715810, 'United Kingdom', 2015], + [53354, 79.1, 321773631, 'United States', 2015] + ] + }, + { + transform: { + type: 'filter', + config: { dimension: 4, eq: 1990 } + } + }, + { + transform: { + type: 'filter', + config: { dimension: 4, eq: 2015 } + } + }, + { + transform: { + type: 'ecStat:regression', + config: { + method: 'logarithmic' + } + } + } + ], + title: { + text: '1990 and 2015 per capita life expectancy and GDP', + subtext: 'By ecStat.regression', + sublink: 'https://github.com/ecomfe/echarts-stat', + left: 'center' + }, + legend: { + data: ['1990', '2015'], + bottom: 10 + }, + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'cross' + } + }, + xAxis: { + type: 'value', + splitLine: { + lineStyle: { + type: 'dashed' + } + } + }, + yAxis: { + type: 'value', + splitLine: { + lineStyle: { + type: 'dashed' + } + } + }, + visualMap: { + show: false, + dimension: 2, + min: 20000, + max: 1500000000, + seriesIndex: [0, 1], + inRange: { + symbolSize: [10, 70] + } + }, + series: [ + { + name: '1990', + type: 'scatter', + datasetIndex: 1 + }, + { + name: '2015', + type: 'scatter', + datasetIndex: 2 + }, + { + name: 'line', + type: 'line', + smooth: true, + datasetIndex: 3, + symbolSize: 0.1, + symbol: 'circle', + label: { show: true, fontSize: 16 }, + labelLayout: { dx: -20 }, + encode: { label: 2, tooltip: 1 } + } + ] +}; +export {}; diff --git a/testdata/scatter-map-brush.js b/testdata/scatter-map-brush.js new file mode 100644 index 0000000..234c39d --- /dev/null +++ b/testdata/scatter-map-brush.js @@ -0,0 +1,818 @@ +/* +title: Scatter Map Brush +category: scatter +titleCN: Scatter Map Brush +*/ +const geoCoordMap = { + 海门: [121.15, 31.89], + 鄂尔多斯: [109.781327, 39.608266], + 招远: [120.38, 37.35], + 舟山: [122.207216, 29.985295], + 齐齐哈尔: [123.97, 47.33], + 盐城: [120.13, 33.38], + 赤峰: [118.87, 42.28], + 青岛: [120.33, 36.07], + 乳山: [121.52, 36.89], + 金昌: [102.188043, 38.520089], + 泉州: [118.58, 24.93], + 莱西: [120.53, 36.86], + 日照: [119.46, 35.42], + 胶南: [119.97, 35.88], + 南通: [121.05, 32.08], + 拉萨: [91.11, 29.97], + 云浮: [112.02, 22.93], + 梅州: [116.1, 24.55], + 文登: [122.05, 37.2], + 上海: [121.48, 31.22], + 攀枝花: [101.718637, 26.582347], + 威海: [122.1, 37.5], + 承德: [117.93, 40.97], + 厦门: [118.1, 24.46], + 汕尾: [115.375279, 22.786211], + 潮州: [116.63, 23.68], + 丹东: [124.37, 40.13], + 太仓: [121.1, 31.45], + 曲靖: [103.79, 25.51], + 烟台: [121.39, 37.52], + 福州: [119.3, 26.08], + 瓦房店: [121.979603, 39.627114], + 即墨: [120.45, 36.38], + 抚顺: [123.97, 41.97], + 玉溪: [102.52, 24.35], + 张家口: [114.87, 40.82], + 阳泉: [113.57, 37.85], + 莱州: [119.942327, 37.177017], + 湖州: [120.1, 30.86], + 汕头: [116.69, 23.39], + 昆山: [120.95, 31.39], + 宁波: [121.56, 29.86], + 湛江: [110.359377, 21.270708], + 揭阳: [116.35, 23.55], + 荣成: [122.41, 37.16], + 连云港: [119.16, 34.59], + 葫芦岛: [120.836932, 40.711052], + 常熟: [120.74, 31.64], + 东莞: [113.75, 23.04], + 河源: [114.68, 23.73], + 淮安: [119.15, 33.5], + 泰州: [119.9, 32.49], + 南宁: [108.33, 22.84], + 营口: [122.18, 40.65], + 惠州: [114.4, 23.09], + 江阴: [120.26, 31.91], + 蓬莱: [120.75, 37.8], + 韶关: [113.62, 24.84], + 嘉峪关: [98.289152, 39.77313], + 广州: [113.23, 23.16], + 延安: [109.47, 36.6], + 太原: [112.53, 37.87], + 清远: [113.01, 23.7], + 中山: [113.38, 22.52], + 昆明: [102.73, 25.04], + 寿光: [118.73, 36.86], + 盘锦: [122.070714, 41.119997], + 长治: [113.08, 36.18], + 深圳: [114.07, 22.62], + 珠海: [113.52, 22.3], + 宿迁: [118.3, 33.96], + 咸阳: [108.72, 34.36], + 铜川: [109.11, 35.09], + 平度: [119.97, 36.77], + 佛山: [113.11, 23.05], + 海口: [110.35, 20.02], + 江门: [113.06, 22.61], + 章丘: [117.53, 36.72], + 肇庆: [112.44, 23.05], + 大连: [121.62, 38.92], + 临汾: [111.5, 36.08], + 吴江: [120.63, 31.16], + 石嘴山: [106.39, 39.04], + 沈阳: [123.38, 41.8], + 苏州: [120.62, 31.32], + 茂名: [110.88, 21.68], + 嘉兴: [120.76, 30.77], + 长春: [125.35, 43.88], + 胶州: [120.03336, 36.264622], + 银川: [106.27, 38.47], + 张家港: [120.555821, 31.875428], + 三门峡: [111.19, 34.76], + 锦州: [121.15, 41.13], + 南昌: [115.89, 28.68], + 柳州: [109.4, 24.33], + 三亚: [109.511909, 18.252847], + 自贡: [104.778442, 29.33903], + 吉林: [126.57, 43.87], + 阳江: [111.95, 21.85], + 泸州: [105.39, 28.91], + 西宁: [101.74, 36.56], + 宜宾: [104.56, 29.77], + 呼和浩特: [111.65, 40.82], + 成都: [104.06, 30.67], + 大同: [113.3, 40.12], + 镇江: [119.44, 32.2], + 桂林: [110.28, 25.29], + 张家界: [110.479191, 29.117096], + 宜兴: [119.82, 31.36], + 北海: [109.12, 21.49], + 西安: [108.95, 34.27], + 金坛: [119.56, 31.74], + 东营: [118.49, 37.46], + 牡丹江: [129.58, 44.6], + 遵义: [106.9, 27.7], + 绍兴: [120.58, 30.01], + 扬州: [119.42, 32.39], + 常州: [119.95, 31.79], + 潍坊: [119.1, 36.62], + 重庆: [106.54, 29.59], + 台州: [121.420757, 28.656386], + 南京: [118.78, 32.04], + 滨州: [118.03, 37.36], + 贵阳: [106.71, 26.57], + 无锡: [120.29, 31.59], + 本溪: [123.73, 41.3], + 克拉玛依: [84.77, 45.59], + 渭南: [109.5, 34.52], + 马鞍山: [118.48, 31.56], + 宝鸡: [107.15, 34.38], + 焦作: [113.21, 35.24], + 句容: [119.16, 31.95], + 北京: [116.46, 39.92], + 徐州: [117.2, 34.26], + 衡水: [115.72, 37.72], + 包头: [110, 40.58], + 绵阳: [104.73, 31.48], + 乌鲁木齐: [87.68, 43.77], + 枣庄: [117.57, 34.86], + 杭州: [120.19, 30.26], + 淄博: [118.05, 36.78], + 鞍山: [122.85, 41.12], + 溧阳: [119.48, 31.43], + 库尔勒: [86.06, 41.68], + 安阳: [114.35, 36.1], + 开封: [114.35, 34.79], + 济南: [117, 36.65], + 德阳: [104.37, 31.13], + 温州: [120.65, 28.01], + 九江: [115.97, 29.71], + 邯郸: [114.47, 36.6], + 临安: [119.72, 30.23], + 兰州: [103.73, 36.03], + 沧州: [116.83, 38.33], + 临沂: [118.35, 35.05], + 南充: [106.110698, 30.837793], + 天津: [117.2, 39.13], + 富阳: [119.95, 30.07], + 泰安: [117.13, 36.18], + 诸暨: [120.23, 29.71], + 郑州: [113.65, 34.76], + 哈尔滨: [126.63, 45.75], + 聊城: [115.97, 36.45], + 芜湖: [118.38, 31.33], + 唐山: [118.02, 39.63], + 平顶山: [113.29, 33.75], + 邢台: [114.48, 37.05], + 德州: [116.29, 37.45], + 济宁: [116.59, 35.38], + 荆州: [112.239741, 30.335165], + 宜昌: [111.3, 30.7], + 义乌: [120.06, 29.32], + 丽水: [119.92, 28.45], + 洛阳: [112.44, 34.7], + 秦皇岛: [119.57, 39.95], + 株洲: [113.16, 27.83], + 石家庄: [114.48, 38.03], + 莱芜: [117.67, 36.19], + 常德: [111.69, 29.05], + 保定: [115.48, 38.85], + 湘潭: [112.91, 27.87], + 金华: [119.64, 29.12], + 岳阳: [113.09, 29.37], + 长沙: [113, 28.21], + 衢州: [118.88, 28.97], + 廊坊: [116.7, 39.53], + 菏泽: [115.480656, 35.23375], + 合肥: [117.27, 31.86], + 武汉: [114.31, 30.52], + 大庆: [125.03, 46.58] +}; +const data = [ + { name: '海门', value: 9 }, + { name: '鄂尔多斯', value: 12 }, + { name: '招远', value: 12 }, + { name: '舟山', value: 12 }, + { name: '齐齐哈尔', value: 14 }, + { name: '盐城', value: 15 }, + { name: '赤峰', value: 16 }, + { name: '青岛', value: 18 }, + { name: '乳山', value: 18 }, + { name: '金昌', value: 19 }, + { name: '泉州', value: 21 }, + { name: '莱西', value: 21 }, + { name: '日照', value: 21 }, + { name: '胶南', value: 22 }, + { name: '南通', value: 23 }, + { name: '拉萨', value: 24 }, + { name: '云浮', value: 24 }, + { name: '梅州', value: 25 }, + { name: '文登', value: 25 }, + { name: '上海', value: 25 }, + { name: '攀枝花', value: 25 }, + { name: '威海', value: 25 }, + { name: '承德', value: 25 }, + { name: '厦门', value: 26 }, + { name: '汕尾', value: 26 }, + { name: '潮州', value: 26 }, + { name: '丹东', value: 27 }, + { name: '太仓', value: 27 }, + { name: '曲靖', value: 27 }, + { name: '烟台', value: 28 }, + { name: '福州', value: 29 }, + { name: '瓦房店', value: 30 }, + { name: '即墨', value: 30 }, + { name: '抚顺', value: 31 }, + { name: '玉溪', value: 31 }, + { name: '张家口', value: 31 }, + { name: '阳泉', value: 31 }, + { name: '莱州', value: 32 }, + { name: '湖州', value: 32 }, + { name: '汕头', value: 32 }, + { name: '昆山', value: 33 }, + { name: '宁波', value: 33 }, + { name: '湛江', value: 33 }, + { name: '揭阳', value: 34 }, + { name: '荣成', value: 34 }, + { name: '连云港', value: 35 }, + { name: '葫芦岛', value: 35 }, + { name: '常熟', value: 36 }, + { name: '东莞', value: 36 }, + { name: '河源', value: 36 }, + { name: '淮安', value: 36 }, + { name: '泰州', value: 36 }, + { name: '南宁', value: 37 }, + { name: '营口', value: 37 }, + { name: '惠州', value: 37 }, + { name: '江阴', value: 37 }, + { name: '蓬莱', value: 37 }, + { name: '韶关', value: 38 }, + { name: '嘉峪关', value: 38 }, + { name: '广州', value: 38 }, + { name: '延安', value: 38 }, + { name: '太原', value: 39 }, + { name: '清远', value: 39 }, + { name: '中山', value: 39 }, + { name: '昆明', value: 39 }, + { name: '寿光', value: 40 }, + { name: '盘锦', value: 40 }, + { name: '长治', value: 41 }, + { name: '深圳', value: 41 }, + { name: '珠海', value: 42 }, + { name: '宿迁', value: 43 }, + { name: '咸阳', value: 43 }, + { name: '铜川', value: 44 }, + { name: '平度', value: 44 }, + { name: '佛山', value: 44 }, + { name: '海口', value: 44 }, + { name: '江门', value: 45 }, + { name: '章丘', value: 45 }, + { name: '肇庆', value: 46 }, + { name: '大连', value: 47 }, + { name: '临汾', value: 47 }, + { name: '吴江', value: 47 }, + { name: '石嘴山', value: 49 }, + { name: '沈阳', value: 50 }, + { name: '苏州', value: 50 }, + { name: '茂名', value: 50 }, + { name: '嘉兴', value: 51 }, + { name: '长春', value: 51 }, + { name: '胶州', value: 52 }, + { name: '银川', value: 52 }, + { name: '张家港', value: 52 }, + { name: '三门峡', value: 53 }, + { name: '锦州', value: 54 }, + { name: '南昌', value: 54 }, + { name: '柳州', value: 54 }, + { name: '三亚', value: 54 }, + { name: '自贡', value: 56 }, + { name: '吉林', value: 56 }, + { name: '阳江', value: 57 }, + { name: '泸州', value: 57 }, + { name: '西宁', value: 57 }, + { name: '宜宾', value: 58 }, + { name: '呼和浩特', value: 58 }, + { name: '成都', value: 58 }, + { name: '大同', value: 58 }, + { name: '镇江', value: 59 }, + { name: '桂林', value: 59 }, + { name: '张家界', value: 59 }, + { name: '宜兴', value: 59 }, + { name: '北海', value: 60 }, + { name: '西安', value: 61 }, + { name: '金坛', value: 62 }, + { name: '东营', value: 62 }, + { name: '牡丹江', value: 63 }, + { name: '遵义', value: 63 }, + { name: '绍兴', value: 63 }, + { name: '扬州', value: 64 }, + { name: '常州', value: 64 }, + { name: '潍坊', value: 65 }, + { name: '重庆', value: 66 }, + { name: '台州', value: 67 }, + { name: '南京', value: 67 }, + { name: '滨州', value: 70 }, + { name: '贵阳', value: 71 }, + { name: '无锡', value: 71 }, + { name: '本溪', value: 71 }, + { name: '克拉玛依', value: 72 }, + { name: '渭南', value: 72 }, + { name: '马鞍山', value: 72 }, + { name: '宝鸡', value: 72 }, + { name: '焦作', value: 75 }, + { name: '句容', value: 75 }, + { name: '北京', value: 79 }, + { name: '徐州', value: 79 }, + { name: '衡水', value: 80 }, + { name: '包头', value: 80 }, + { name: '绵阳', value: 80 }, + { name: '乌鲁木齐', value: 84 }, + { name: '枣庄', value: 84 }, + { name: '杭州', value: 84 }, + { name: '淄博', value: 85 }, + { name: '鞍山', value: 86 }, + { name: '溧阳', value: 86 }, + { name: '库尔勒', value: 86 }, + { name: '安阳', value: 90 }, + { name: '开封', value: 90 }, + { name: '济南', value: 92 }, + { name: '德阳', value: 93 }, + { name: '温州', value: 95 }, + { name: '九江', value: 96 }, + { name: '邯郸', value: 98 }, + { name: '临安', value: 99 }, + { name: '兰州', value: 99 }, + { name: '沧州', value: 100 }, + { name: '临沂', value: 103 }, + { name: '南充', value: 104 }, + { name: '天津', value: 105 }, + { name: '富阳', value: 106 }, + { name: '泰安', value: 112 }, + { name: '诸暨', value: 112 }, + { name: '郑州', value: 113 }, + { name: '哈尔滨', value: 114 }, + { name: '聊城', value: 116 }, + { name: '芜湖', value: 117 }, + { name: '唐山', value: 119 }, + { name: '平顶山', value: 119 }, + { name: '邢台', value: 119 }, + { name: '德州', value: 120 }, + { name: '济宁', value: 120 }, + { name: '荆州', value: 127 }, + { name: '宜昌', value: 130 }, + { name: '义乌', value: 132 }, + { name: '丽水', value: 133 }, + { name: '洛阳', value: 134 }, + { name: '秦皇岛', value: 136 }, + { name: '株洲', value: 143 }, + { name: '石家庄', value: 147 }, + { name: '莱芜', value: 148 }, + { name: '常德', value: 152 }, + { name: '保定', value: 153 }, + { name: '湘潭', value: 154 }, + { name: '金华', value: 157 }, + { name: '岳阳', value: 169 }, + { name: '长沙', value: 175 }, + { name: '衢州', value: 177 }, + { name: '廊坊', value: 193 }, + { name: '菏泽', value: 194 }, + { name: '合肥', value: 229 }, + { name: '武汉', value: 273 }, + { name: '大庆', value: 279 } +]; +var convertData = function (data) { + var res = []; + for (var i = 0; i < data.length; i++) { + var geoCoord = geoCoordMap[data[i].name]; + if (geoCoord) { + res.push({ + name: data[i].name, + value: geoCoord.concat(data[i].value) + }); + } + } + return res; +}; +var convertedData = [ + convertData(data), + convertData(data + .sort(function (a, b) { + return b.value - a.value; + }) + .slice(0, 6)) +]; +option = { + backgroundColor: '#404a59', + animation: true, + animationDuration: 1000, + animationEasing: 'cubicInOut', + animationDurationUpdate: 1000, + animationEasingUpdate: 'cubicInOut', + title: [ + { + text: '全国主要城市 PM 2.5', + subtext: 'data from PM25.in', + sublink: 'http://www.pm25.in', + left: 'center', + textStyle: { + color: '#fff' + } + }, + { + id: 'statistic', + right: 120, + top: 40, + width: 100, + textStyle: { + color: '#fff', + fontSize: 16 + } + } + ], + toolbox: { + iconStyle: { + borderColor: '#fff' + }, + emphasis: { + iconStyle: { + borderColor: '#b1e4ff' + } + } + }, + brush: { + outOfBrush: { + color: '#abc' + }, + brushStyle: { + borderWidth: 2, + color: 'rgba(0,0,0,0.2)', + borderColor: 'rgba(0,0,0,0.5)' + }, + seriesIndex: [0, 1], + throttleType: 'debounce', + throttleDelay: 300, + geoIndex: 0 + }, + geo: { + map: 'china', + left: '10', + right: '35%', + center: [117.98561551896913, 31.205000490896193], + zoom: 2.5, + emphasis: { + itemStyle: { + areaColor: '#2a333d' + }, + label: { + show: false + } + }, + roam: true, + itemStyle: { + areaColor: '#323c48', + borderColor: '#111' + } + }, + tooltip: { + trigger: 'item' + }, + grid: { + right: 40, + top: 100, + bottom: 40, + width: '30%' + }, + xAxis: { + type: 'value', + scale: true, + position: 'top', + boundaryGap: false, + splitLine: { show: false }, + axisLine: { show: false }, + axisTick: { show: false }, + axisLabel: { margin: 2, color: '#aaa' } + }, + yAxis: { + type: 'category', + name: 'TOP 20', + nameGap: 16, + axisLine: { show: false, lineStyle: { color: '#ddd' } }, + axisTick: { show: false, lineStyle: { color: '#ddd' } }, + axisLabel: { interval: 0, color: '#ddd' }, + data: [] + }, + series: [ + { + name: 'pm2.5', + type: 'scatter', + coordinateSystem: 'geo', + data: convertedData[0], + symbolSize: function (val) { + return Math.max(val[2] / 10, 8); + }, + label: { + formatter: '{b}', + position: 'right', + show: false + }, + itemStyle: { + color: '#ddb926' + }, + emphasis: { + label: { + show: true + } + } + }, + { + name: 'Top 5', + type: 'effectScatter', + coordinateSystem: 'geo', + data: convertedData[1], + symbolSize: function (val) { + return Math.max(val[2] / 10, 8); + }, + showEffectOn: 'emphasis', + rippleEffect: { + brushType: 'stroke' + }, + emphasis: { + scale: true + }, + label: { + formatter: '{b}', + position: 'right', + show: true + }, + itemStyle: { + color: '#f4e925', + shadowBlur: 10, + shadowColor: '#333' + }, + zlevel: 1 + }, + { + id: 'bar', + zlevel: 2, + type: 'bar', + itemStyle: { + color: '#ddb926' + }, + data: [] + } + ] +}; +myChart.on('brushselected', renderBrushed); +// myChart.setOption(option); +setTimeout(function () { + myChart.dispatchAction({ + type: 'brush', + areas: [ + { + geoIndex: 0, + brushType: 'polygon', + coordRange: [ + [119.72, 34.85], + [119.68, 34.85], + [119.5, 34.84], + [119.19, 34.77], + [118.76, 34.63], + [118.6, 34.6], + [118.46, 34.6], + [118.33, 34.57], + [118.05, 34.56], + [117.6, 34.56], + [117.41, 34.56], + [117.25, 34.56], + [117.11, 34.56], + [117.02, 34.56], + [117, 34.56], + [116.94, 34.56], + [116.94, 34.55], + [116.9, 34.5], + [116.88, 34.44], + [116.88, 34.37], + [116.88, 34.33], + [116.88, 34.24], + [116.92, 34.15], + [116.98, 34.09], + [117.05, 34.06], + [117.19, 33.96], + [117.29, 33.9], + [117.43, 33.8], + [117.49, 33.75], + [117.54, 33.68], + [117.6, 33.65], + [117.62, 33.61], + [117.64, 33.59], + [117.68, 33.58], + [117.7, 33.52], + [117.74, 33.5], + [117.74, 33.46], + [117.8, 33.44], + [117.82, 33.41], + [117.86, 33.37], + [117.9, 33.3], + [117.9, 33.28], + [117.9, 33.27], + [118.09, 32.97], + [118.21, 32.7], + [118.29, 32.56], + [118.31, 32.5], + [118.35, 32.46], + [118.35, 32.42], + [118.35, 32.36], + [118.35, 32.34], + [118.37, 32.24], + [118.37, 32.14], + [118.37, 32.09], + [118.44, 32.05], + [118.46, 32.01], + [118.54, 31.98], + [118.6, 31.93], + [118.68, 31.86], + [118.72, 31.8], + [118.74, 31.78], + [118.76, 31.74], + [118.78, 31.7], + [118.82, 31.64], + [118.82, 31.62], + [118.86, 31.58], + [118.86, 31.55], + [118.88, 31.54], + [118.88, 31.52], + [118.9, 31.51], + [118.91, 31.48], + [118.93, 31.43], + [118.95, 31.4], + [118.97, 31.39], + [118.97, 31.37], + [118.97, 31.34], + [118.97, 31.27], + [118.97, 31.21], + [118.97, 31.17], + [118.97, 31.12], + [118.97, 31.02], + [118.97, 30.93], + [118.97, 30.87], + [118.97, 30.85], + [118.95, 30.8], + [118.95, 30.77], + [118.95, 30.76], + [118.93, 30.7], + [118.91, 30.63], + [118.91, 30.61], + [118.91, 30.6], + [118.9, 30.6], + [118.88, 30.54], + [118.88, 30.51], + [118.86, 30.51], + [118.86, 30.46], + [118.72, 30.18], + [118.68, 30.1], + [118.66, 30.07], + [118.62, 29.91], + [118.56, 29.73], + [118.52, 29.63], + [118.48, 29.51], + [118.44, 29.42], + [118.44, 29.32], + [118.43, 29.19], + [118.43, 29.14], + [118.43, 29.08], + [118.44, 29.05], + [118.46, 29.05], + [118.6, 28.95], + [118.64, 28.94], + [119.07, 28.51], + [119.25, 28.41], + [119.36, 28.28], + [119.46, 28.19], + [119.54, 28.13], + [119.66, 28.03], + [119.78, 28], + [119.87, 27.94], + [120.03, 27.86], + [120.17, 27.79], + [120.23, 27.76], + [120.3, 27.72], + [120.42, 27.66], + [120.52, 27.64], + [120.58, 27.63], + [120.64, 27.63], + [120.77, 27.63], + [120.89, 27.61], + [120.97, 27.6], + [121.07, 27.59], + [121.15, 27.59], + [121.28, 27.59], + [121.38, 27.61], + [121.56, 27.73], + [121.73, 27.89], + [122.03, 28.2], + [122.3, 28.5], + [122.46, 28.72], + [122.5, 28.77], + [122.54, 28.82], + [122.56, 28.82], + [122.58, 28.85], + [122.6, 28.86], + [122.61, 28.91], + [122.71, 29.02], + [122.73, 29.08], + [122.93, 29.44], + [122.99, 29.54], + [123.03, 29.66], + [123.05, 29.73], + [123.16, 29.92], + [123.24, 30.02], + [123.28, 30.13], + [123.32, 30.29], + [123.36, 30.36], + [123.36, 30.55], + [123.36, 30.74], + [123.36, 31.05], + [123.36, 31.14], + [123.36, 31.26], + [123.38, 31.42], + [123.46, 31.74], + [123.48, 31.83], + [123.48, 31.95], + [123.46, 32.09], + [123.34, 32.25], + [123.22, 32.39], + [123.12, 32.46], + [123.07, 32.48], + [123.05, 32.49], + [122.97, 32.53], + [122.91, 32.59], + [122.83, 32.81], + [122.77, 32.87], + [122.71, 32.9], + [122.56, 32.97], + [122.38, 33.05], + [122.3, 33.12], + [122.26, 33.15], + [122.22, 33.21], + [122.22, 33.3], + [122.22, 33.39], + [122.18, 33.44], + [122.07, 33.56], + [121.99, 33.69], + [121.89, 33.78], + [121.69, 34.02], + [121.66, 34.05], + [121.64, 34.08] + ] + } + ] + }); +}, 0); +function renderBrushed(params) { + const mainSeries = params.batch[0].selected[0]; + const selectedItems = []; + const categoryData = []; + const barData = []; + const maxBar = 30; + let sum = 0; + let count = 0; + for (var i = 0; i < mainSeries.dataIndex.length; i++) { + var rawIndex = mainSeries.dataIndex[i]; + var dataItem = convertedData[0][rawIndex]; + var pmValue = dataItem.value[2]; + sum += pmValue; + count++; + selectedItems.push(dataItem); + } + selectedItems.sort(function (a, b) { + return a.value[2] - b.value[2]; + }); + for (var i = 0; i < Math.min(selectedItems.length, maxBar); i++) { + categoryData.push(selectedItems[i].name); + barData.push(selectedItems[i].value[2]); + } + myChart.setOption({ + yAxis: { + data: categoryData + }, + xAxis: { + axisLabel: { show: !!count } + }, + title: { + id: 'statistic', + text: count ? '平均: ' + (sum / count).toFixed(4) : '' + }, + series: { + id: 'bar', + data: barData + } + }); +} +export {}; diff --git a/testdata/scatter-map.js b/testdata/scatter-map.js new file mode 100644 index 0000000..5cd8687 --- /dev/null +++ b/testdata/scatter-map.js @@ -0,0 +1,470 @@ +"use strict"; +/* +title: Air Quality +category: scatter +titleCN: 全国主要城市空气质量 +*/ +var geoCoordMap = { + 海门: [121.15, 31.89], + 鄂尔多斯: [109.781327, 39.608266], + 招远: [120.38, 37.35], + 舟山: [122.207216, 29.985295], + 齐齐哈尔: [123.97, 47.33], + 盐城: [120.13, 33.38], + 赤峰: [118.87, 42.28], + 青岛: [120.33, 36.07], + 乳山: [121.52, 36.89], + 金昌: [102.188043, 38.520089], + 泉州: [118.58, 24.93], + 莱西: [120.53, 36.86], + 日照: [119.46, 35.42], + 胶南: [119.97, 35.88], + 南通: [121.05, 32.08], + 拉萨: [91.11, 29.97], + 云浮: [112.02, 22.93], + 梅州: [116.1, 24.55], + 文登: [122.05, 37.2], + 上海: [121.48, 31.22], + 攀枝花: [101.718637, 26.582347], + 威海: [122.1, 37.5], + 承德: [117.93, 40.97], + 厦门: [118.1, 24.46], + 汕尾: [115.375279, 22.786211], + 潮州: [116.63, 23.68], + 丹东: [124.37, 40.13], + 太仓: [121.1, 31.45], + 曲靖: [103.79, 25.51], + 烟台: [121.39, 37.52], + 福州: [119.3, 26.08], + 瓦房店: [121.979603, 39.627114], + 即墨: [120.45, 36.38], + 抚顺: [123.97, 41.97], + 玉溪: [102.52, 24.35], + 张家口: [114.87, 40.82], + 阳泉: [113.57, 37.85], + 莱州: [119.942327, 37.177017], + 湖州: [120.1, 30.86], + 汕头: [116.69, 23.39], + 昆山: [120.95, 31.39], + 宁波: [121.56, 29.86], + 湛江: [110.359377, 21.270708], + 揭阳: [116.35, 23.55], + 荣成: [122.41, 37.16], + 连云港: [119.16, 34.59], + 葫芦岛: [120.836932, 40.711052], + 常熟: [120.74, 31.64], + 东莞: [113.75, 23.04], + 河源: [114.68, 23.73], + 淮安: [119.15, 33.5], + 泰州: [119.9, 32.49], + 南宁: [108.33, 22.84], + 营口: [122.18, 40.65], + 惠州: [114.4, 23.09], + 江阴: [120.26, 31.91], + 蓬莱: [120.75, 37.8], + 韶关: [113.62, 24.84], + 嘉峪关: [98.289152, 39.77313], + 广州: [113.23, 23.16], + 延安: [109.47, 36.6], + 太原: [112.53, 37.87], + 清远: [113.01, 23.7], + 中山: [113.38, 22.52], + 昆明: [102.73, 25.04], + 寿光: [118.73, 36.86], + 盘锦: [122.070714, 41.119997], + 长治: [113.08, 36.18], + 深圳: [114.07, 22.62], + 珠海: [113.52, 22.3], + 宿迁: [118.3, 33.96], + 咸阳: [108.72, 34.36], + 铜川: [109.11, 35.09], + 平度: [119.97, 36.77], + 佛山: [113.11, 23.05], + 海口: [110.35, 20.02], + 江门: [113.06, 22.61], + 章丘: [117.53, 36.72], + 肇庆: [112.44, 23.05], + 大连: [121.62, 38.92], + 临汾: [111.5, 36.08], + 吴江: [120.63, 31.16], + 石嘴山: [106.39, 39.04], + 沈阳: [123.38, 41.8], + 苏州: [120.62, 31.32], + 茂名: [110.88, 21.68], + 嘉兴: [120.76, 30.77], + 长春: [125.35, 43.88], + 胶州: [120.03336, 36.264622], + 银川: [106.27, 38.47], + 张家港: [120.555821, 31.875428], + 三门峡: [111.19, 34.76], + 锦州: [121.15, 41.13], + 南昌: [115.89, 28.68], + 柳州: [109.4, 24.33], + 三亚: [109.511909, 18.252847], + 自贡: [104.778442, 29.33903], + 吉林: [126.57, 43.87], + 阳江: [111.95, 21.85], + 泸州: [105.39, 28.91], + 西宁: [101.74, 36.56], + 宜宾: [104.56, 29.77], + 呼和浩特: [111.65, 40.82], + 成都: [104.06, 30.67], + 大同: [113.3, 40.12], + 镇江: [119.44, 32.2], + 桂林: [110.28, 25.29], + 张家界: [110.479191, 29.117096], + 宜兴: [119.82, 31.36], + 北海: [109.12, 21.49], + 西安: [108.95, 34.27], + 金坛: [119.56, 31.74], + 东营: [118.49, 37.46], + 牡丹江: [129.58, 44.6], + 遵义: [106.9, 27.7], + 绍兴: [120.58, 30.01], + 扬州: [119.42, 32.39], + 常州: [119.95, 31.79], + 潍坊: [119.1, 36.62], + 重庆: [106.54, 29.59], + 台州: [121.420757, 28.656386], + 南京: [118.78, 32.04], + 滨州: [118.03, 37.36], + 贵阳: [106.71, 26.57], + 无锡: [120.29, 31.59], + 本溪: [123.73, 41.3], + 克拉玛依: [84.77, 45.59], + 渭南: [109.5, 34.52], + 马鞍山: [118.48, 31.56], + 宝鸡: [107.15, 34.38], + 焦作: [113.21, 35.24], + 句容: [119.16, 31.95], + 北京: [116.46, 39.92], + 徐州: [117.2, 34.26], + 衡水: [115.72, 37.72], + 包头: [110, 40.58], + 绵阳: [104.73, 31.48], + 乌鲁木齐: [87.68, 43.77], + 枣庄: [117.57, 34.86], + 杭州: [120.19, 30.26], + 淄博: [118.05, 36.78], + 鞍山: [122.85, 41.12], + 溧阳: [119.48, 31.43], + 库尔勒: [86.06, 41.68], + 安阳: [114.35, 36.1], + 开封: [114.35, 34.79], + 济南: [117, 36.65], + 德阳: [104.37, 31.13], + 温州: [120.65, 28.01], + 九江: [115.97, 29.71], + 邯郸: [114.47, 36.6], + 临安: [119.72, 30.23], + 兰州: [103.73, 36.03], + 沧州: [116.83, 38.33], + 临沂: [118.35, 35.05], + 南充: [106.110698, 30.837793], + 天津: [117.2, 39.13], + 富阳: [119.95, 30.07], + 泰安: [117.13, 36.18], + 诸暨: [120.23, 29.71], + 郑州: [113.65, 34.76], + 哈尔滨: [126.63, 45.75], + 聊城: [115.97, 36.45], + 芜湖: [118.38, 31.33], + 唐山: [118.02, 39.63], + 平顶山: [113.29, 33.75], + 邢台: [114.48, 37.05], + 德州: [116.29, 37.45], + 济宁: [116.59, 35.38], + 荆州: [112.239741, 30.335165], + 宜昌: [111.3, 30.7], + 义乌: [120.06, 29.32], + 丽水: [119.92, 28.45], + 洛阳: [112.44, 34.7], + 秦皇岛: [119.57, 39.95], + 株洲: [113.16, 27.83], + 石家庄: [114.48, 38.03], + 莱芜: [117.67, 36.19], + 常德: [111.69, 29.05], + 保定: [115.48, 38.85], + 湘潭: [112.91, 27.87], + 金华: [119.64, 29.12], + 岳阳: [113.09, 29.37], + 长沙: [113, 28.21], + 衢州: [118.88, 28.97], + 廊坊: [116.7, 39.53], + 菏泽: [115.480656, 35.23375], + 合肥: [117.27, 31.86], + 武汉: [114.31, 30.52], + 大庆: [125.03, 46.58] +}; +var convertData = function (data) { + var res = []; + for (var i = 0; i < data.length; i++) { + var geoCoord = geoCoordMap[data[i].name]; + if (geoCoord) { + res.push({ + name: data[i].name, + value: geoCoord.concat(data[i].value) + }); + } + } + return res; +}; +option = { + backgroundColor: '#404a59', + title: { + text: '全国主要城市空气质量', + subtext: 'data from PM25.in', + sublink: 'http://www.pm25.in', + x: 'center', + textStyle: { + color: '#fff' + } + }, + tooltip: { + trigger: 'item', + formatter: function (params) { + return params.name + ' : ' + params.value[2]; + } + }, + legend: { + orient: 'vertical', + top: 'bottom', + left: 'right', + data: ['pm2.5'], + textStyle: { + color: '#fff' + } + }, + visualMap: { + min: 0, + max: 200, + calculable: true, + inRange: { + color: ['#50a3ba', '#eac736', '#d94e5d'] + }, + textStyle: { + color: '#fff' + } + }, + geo: { + map: 'china', + itemStyle: { + areaColor: '#323c48', + borderColor: '#111' + }, + emphasis: { + itemStyle: { + areaColor: '#2a333d' + }, + label: { + show: false + } + } + }, + series: [ + { + name: 'pm2.5', + type: 'scatter', + coordinateSystem: 'geo', + data: convertData([ + { name: '海门', value: 9 }, + { name: '鄂尔多斯', value: 12 }, + { name: '招远', value: 12 }, + { name: '舟山', value: 12 }, + { name: '齐齐哈尔', value: 14 }, + { name: '盐城', value: 15 }, + { name: '赤峰', value: 16 }, + { name: '青岛', value: 18 }, + { name: '乳山', value: 18 }, + { name: '金昌', value: 19 }, + { name: '泉州', value: 21 }, + { name: '莱西', value: 21 }, + { name: '日照', value: 21 }, + { name: '胶南', value: 22 }, + { name: '南通', value: 23 }, + { name: '拉萨', value: 24 }, + { name: '云浮', value: 24 }, + { name: '梅州', value: 25 }, + { name: '文登', value: 25 }, + { name: '上海', value: 25 }, + { name: '攀枝花', value: 25 }, + { name: '威海', value: 25 }, + { name: '承德', value: 25 }, + { name: '厦门', value: 26 }, + { name: '汕尾', value: 26 }, + { name: '潮州', value: 26 }, + { name: '丹东', value: 27 }, + { name: '太仓', value: 27 }, + { name: '曲靖', value: 27 }, + { name: '烟台', value: 28 }, + { name: '福州', value: 29 }, + { name: '瓦房店', value: 30 }, + { name: '即墨', value: 30 }, + { name: '抚顺', value: 31 }, + { name: '玉溪', value: 31 }, + { name: '张家口', value: 31 }, + { name: '阳泉', value: 31 }, + { name: '莱州', value: 32 }, + { name: '湖州', value: 32 }, + { name: '汕头', value: 32 }, + { name: '昆山', value: 33 }, + { name: '宁波', value: 33 }, + { name: '湛江', value: 33 }, + { name: '揭阳', value: 34 }, + { name: '荣成', value: 34 }, + { name: '连云港', value: 35 }, + { name: '葫芦岛', value: 35 }, + { name: '常熟', value: 36 }, + { name: '东莞', value: 36 }, + { name: '河源', value: 36 }, + { name: '淮安', value: 36 }, + { name: '泰州', value: 36 }, + { name: '南宁', value: 37 }, + { name: '营口', value: 37 }, + { name: '惠州', value: 37 }, + { name: '江阴', value: 37 }, + { name: '蓬莱', value: 37 }, + { name: '韶关', value: 38 }, + { name: '嘉峪关', value: 38 }, + { name: '广州', value: 38 }, + { name: '延安', value: 38 }, + { name: '太原', value: 39 }, + { name: '清远', value: 39 }, + { name: '中山', value: 39 }, + { name: '昆明', value: 39 }, + { name: '寿光', value: 40 }, + { name: '盘锦', value: 40 }, + { name: '长治', value: 41 }, + { name: '深圳', value: 41 }, + { name: '珠海', value: 42 }, + { name: '宿迁', value: 43 }, + { name: '咸阳', value: 43 }, + { name: '铜川', value: 44 }, + { name: '平度', value: 44 }, + { name: '佛山', value: 44 }, + { name: '海口', value: 44 }, + { name: '江门', value: 45 }, + { name: '章丘', value: 45 }, + { name: '肇庆', value: 46 }, + { name: '大连', value: 47 }, + { name: '临汾', value: 47 }, + { name: '吴江', value: 47 }, + { name: '石嘴山', value: 49 }, + { name: '沈阳', value: 50 }, + { name: '苏州', value: 50 }, + { name: '茂名', value: 50 }, + { name: '嘉兴', value: 51 }, + { name: '长春', value: 51 }, + { name: '胶州', value: 52 }, + { name: '银川', value: 52 }, + { name: '张家港', value: 52 }, + { name: '三门峡', value: 53 }, + { name: '锦州', value: 54 }, + { name: '南昌', value: 54 }, + { name: '柳州', value: 54 }, + { name: '三亚', value: 54 }, + { name: '自贡', value: 56 }, + { name: '吉林', value: 56 }, + { name: '阳江', value: 57 }, + { name: '泸州', value: 57 }, + { name: '西宁', value: 57 }, + { name: '宜宾', value: 58 }, + { name: '呼和浩特', value: 58 }, + { name: '成都', value: 58 }, + { name: '大同', value: 58 }, + { name: '镇江', value: 59 }, + { name: '桂林', value: 59 }, + { name: '张家界', value: 59 }, + { name: '宜兴', value: 59 }, + { name: '北海', value: 60 }, + { name: '西安', value: 61 }, + { name: '金坛', value: 62 }, + { name: '东营', value: 62 }, + { name: '牡丹江', value: 63 }, + { name: '遵义', value: 63 }, + { name: '绍兴', value: 63 }, + { name: '扬州', value: 64 }, + { name: '常州', value: 64 }, + { name: '潍坊', value: 65 }, + { name: '重庆', value: 66 }, + { name: '台州', value: 67 }, + { name: '南京', value: 67 }, + { name: '滨州', value: 70 }, + { name: '贵阳', value: 71 }, + { name: '无锡', value: 71 }, + { name: '本溪', value: 71 }, + { name: '克拉玛依', value: 72 }, + { name: '渭南', value: 72 }, + { name: '马鞍山', value: 72 }, + { name: '宝鸡', value: 72 }, + { name: '焦作', value: 75 }, + { name: '句容', value: 75 }, + { name: '北京', value: 79 }, + { name: '徐州', value: 79 }, + { name: '衡水', value: 80 }, + { name: '包头', value: 80 }, + { name: '绵阳', value: 80 }, + { name: '乌鲁木齐', value: 84 }, + { name: '枣庄', value: 84 }, + { name: '杭州', value: 84 }, + { name: '淄博', value: 85 }, + { name: '鞍山', value: 86 }, + { name: '溧阳', value: 86 }, + { name: '库尔勒', value: 86 }, + { name: '安阳', value: 90 }, + { name: '开封', value: 90 }, + { name: '济南', value: 92 }, + { name: '德阳', value: 93 }, + { name: '温州', value: 95 }, + { name: '九江', value: 96 }, + { name: '邯郸', value: 98 }, + { name: '临安', value: 99 }, + { name: '兰州', value: 99 }, + { name: '沧州', value: 100 }, + { name: '临沂', value: 103 }, + { name: '南充', value: 104 }, + { name: '天津', value: 105 }, + { name: '富阳', value: 106 }, + { name: '泰安', value: 112 }, + { name: '诸暨', value: 112 }, + { name: '郑州', value: 113 }, + { name: '哈尔滨', value: 114 }, + { name: '聊城', value: 116 }, + { name: '芜湖', value: 117 }, + { name: '唐山', value: 119 }, + { name: '平顶山', value: 119 }, + { name: '邢台', value: 119 }, + { name: '德州', value: 120 }, + { name: '济宁', value: 120 }, + { name: '荆州', value: 127 }, + { name: '宜昌', value: 130 }, + { name: '义乌', value: 132 }, + { name: '丽水', value: 133 }, + { name: '洛阳', value: 134 }, + { name: '秦皇岛', value: 136 }, + { name: '株洲', value: 143 }, + { name: '石家庄', value: 147 }, + { name: '莱芜', value: 148 }, + { name: '常德', value: 152 }, + { name: '保定', value: 153 }, + { name: '湘潭', value: 154 }, + { name: '金华', value: 157 }, + { name: '岳阳', value: 169 }, + { name: '长沙', value: 175 }, + { name: '衢州', value: 177 }, + { name: '廊坊', value: 193 }, + { name: '菏泽', value: 194 }, + { name: '合肥', value: 229 }, + { name: '武汉', value: 273 }, + { name: '大庆', value: 279 } + ]), + symbolSize: 12, + emphasis: { + itemStyle: { + borderColor: '#fff', + borderWidth: 1 + } + } + } + ] +}; diff --git a/testdata/scatter-matrix.js b/testdata/scatter-matrix.js new file mode 100644 index 0000000..0691ff1 --- /dev/null +++ b/testdata/scatter-matrix.js @@ -0,0 +1,300 @@ +/* +title: Scatter Matrix +category: 'parallel, scatter' +titleCN: 散点矩阵和平行坐标 +difficulty: 10 +*/ +// Schema: +// date,AQIindex,PM2.5,PM10,CO,NO2,SO2 +const schema = [ + { name: 'AQIindex', index: 1, text: 'AQI' }, + { name: 'PM25', index: 2, text: 'PM 2.5' }, + { name: 'PM10', index: 3, text: 'PM 10' }, + { name: 'CO', index: 4, text: 'CO' }, + { name: 'NO2', index: 5, text: 'NO₂' }, + { name: 'SO2', index: 6, text: 'SO₂' }, + { name: '等级', index: 7, text: '等级' } +]; +const rawData = [ + [55, 9, 56, 0.46, 18, 6, '良', '北京'], + [25, 11, 21, 0.65, 34, 9, '优', '北京'], + [56, 7, 63, 0.3, 14, 5, '良', '北京'], + [33, 7, 29, 0.33, 16, 6, '优', '北京'], + [42, 24, 44, 0.76, 40, 16, '优', '北京'], + [82, 58, 90, 1.77, 68, 33, '良', '北京'], + [74, 49, 77, 1.46, 48, 27, '良', '北京'], + [78, 55, 80, 1.29, 59, 29, '良', '北京'], + [267, 216, 280, 4.8, 108, 64, '重度', '北京'], + [185, 127, 216, 2.52, 61, 27, '中度', '北京'], + [39, 19, 38, 0.57, 31, 15, '优', '北京'], + [41, 11, 40, 0.43, 21, 7, '优', '北京'], + [64, 38, 74, 1.04, 46, 22, '良', '北京'], + [108, 79, 120, 1.7, 75, 41, '轻度', '北京'], + [108, 63, 116, 1.48, 44, 26, '轻度', '北京'], + [33, 6, 29, 0.34, 13, 5, '优', '北京'], + [94, 66, 110, 1.54, 62, 31, '良', '北京'], + [186, 142, 192, 3.88, 93, 79, '中度', '北京'], + [57, 31, 54, 0.96, 32, 14, '良', '北京'], + [22, 8, 17, 0.48, 23, 10, '优', '北京'], + [39, 15, 36, 0.61, 29, 13, '优', '北京'], + [94, 69, 114, 2.08, 73, 39, '良', '北京'], + [99, 73, 110, 2.43, 76, 48, '良', '北京'], + [31, 12, 30, 0.5, 32, 16, '优', '北京'], + [42, 27, 43, 1, 53, 22, '优', '北京'], + [154, 117, 157, 3.05, 92, 58, '中度', '北京'], + [234, 185, 230, 4.09, 123, 69, '重度', '北京'], + [160, 120, 186, 2.77, 91, 50, '中度', '北京'], + [134, 96, 165, 2.76, 83, 41, '轻度', '北京'], + [52, 24, 60, 1.03, 50, 21, '良', '北京'], + [46, 5, 49, 0.28, 10, 6, '优', '北京'], + [26, 37, 27, 1.163, 27, 13, '优', '广州'], + [85, 62, 71, 1.195, 60, 8, '良', '广州'], + [78, 38, 74, 1.363, 37, 7, '良', '广州'], + [21, 21, 36, 0.634, 40, 9, '优', '广州'], + [41, 42, 46, 0.915, 81, 13, '优', '广州'], + [56, 52, 69, 1.067, 92, 16, '良', '广州'], + [64, 30, 28, 0.924, 51, 2, '良', '广州'], + [55, 48, 74, 1.236, 75, 26, '良', '广州'], + [76, 85, 113, 1.237, 114, 27, '良', '广州'], + [91, 81, 104, 1.041, 56, 40, '良', '广州'], + [84, 39, 60, 0.964, 25, 11, '良', '广州'], + [64, 51, 101, 0.862, 58, 23, '良', '广州'], + [70, 69, 120, 1.198, 65, 36, '良', '广州'], + [77, 105, 178, 2.549, 64, 16, '良', '广州'], + [109, 68, 87, 0.996, 74, 29, '轻度', '广州'], + [73, 68, 97, 0.905, 51, 34, '良', '广州'], + [54, 27, 47, 0.592, 53, 12, '良', '广州'], + [51, 61, 97, 0.811, 65, 19, '良', '广州'], + [91, 71, 121, 1.374, 43, 18, '良', '广州'], + [73, 102, 182, 2.787, 44, 19, '良', '广州'], + [73, 50, 76, 0.717, 31, 20, '良', '广州'], + [84, 94, 140, 2.238, 68, 18, '良', '广州'], + [93, 77, 104, 1.165, 53, 7, '良', '广州'], + [99, 130, 227, 3.97, 55, 15, '良', '广州'], + [146, 84, 139, 1.094, 40, 17, '轻度', '广州'], + [113, 108, 137, 1.481, 48, 15, '轻度', '广州'], + [81, 48, 62, 1.619, 26, 3, '良', '广州'], + [56, 48, 68, 1.336, 37, 9, '良', '广州'], + [82, 92, 174, 3.29, 0, 13, '良', '广州'], + [106, 116, 188, 3.628, 101, 16, '轻度', '广州'], + [118, 50, 0, 1.383, 76, 11, '轻度', '广州'], + [91, 45, 125, 0.82, 34, 23, '良', '上海'], + [65, 27, 78, 0.86, 45, 29, '良', '上海'], + [83, 60, 84, 1.09, 73, 27, '良', '上海'], + [109, 81, 121, 1.28, 68, 51, '轻度', '上海'], + [106, 77, 114, 1.07, 55, 51, '轻度', '上海'], + [109, 81, 121, 1.28, 68, 51, '轻度', '上海'], + [106, 77, 114, 1.07, 55, 51, '轻度', '上海'], + [89, 65, 78, 0.86, 51, 26, '良', '上海'], + [53, 33, 47, 0.64, 50, 17, '良', '上海'], + [80, 55, 80, 1.01, 75, 24, '良', '上海'], + [117, 81, 124, 1.03, 45, 24, '轻度', '上海'], + [99, 71, 142, 1.1, 62, 42, '良', '上海'], + [95, 69, 130, 1.28, 74, 50, '良', '上海'], + [116, 87, 131, 1.47, 84, 40, '轻度', '上海'], + [108, 80, 121, 1.3, 85, 37, '轻度', '上海'], + [134, 83, 167, 1.16, 57, 43, '轻度', '上海'], + [79, 43, 107, 1.05, 59, 37, '良', '上海'], + [71, 46, 89, 0.86, 64, 25, '良', '上海'], + [97, 71, 113, 1.17, 88, 31, '良', '上海'], + [84, 57, 91, 0.85, 55, 31, '良', '上海'], + [87, 63, 101, 0.9, 56, 41, '良', '上海'], + [104, 77, 119, 1.09, 73, 48, '轻度', '上海'], + [87, 62, 100, 1, 72, 28, '良', '上海'], + [168, 128, 172, 1.49, 97, 56, '中度', '上海'], + [65, 45, 51, 0.74, 39, 17, '良', '上海'], + [39, 24, 38, 0.61, 47, 17, '优', '上海'], + [39, 24, 39, 0.59, 50, 19, '优', '上海'], + [93, 68, 96, 1.05, 79, 29, '良', '上海'], + [188, 143, 197, 1.66, 99, 51, '中度', '上海'], + [174, 131, 174, 1.55, 108, 50, '中度', '上海'], + [187, 143, 201, 1.39, 89, 53, '中度', '上海'] +]; +const CATEGORY_DIM_COUNT = 6; +const GAP = 2; +const BASE_LEFT = 5; +const BASE_TOP = 10; +// const GRID_WIDTH = 220; +// const GRID_HEIGHT = 220; +const GRID_WIDTH = (100 - BASE_LEFT - GAP) / CATEGORY_DIM_COUNT - GAP; +const GRID_HEIGHT = (100 - BASE_TOP - GAP) / CATEGORY_DIM_COUNT - GAP; +const CATEGORY_DIM = 7; +const SYMBOL_SIZE = 4; +function retrieveScatterData(data, dimX, dimY) { + let result = []; + for (let i = 0; i < data.length; i++) { + let item = [data[i][dimX], data[i][dimY]]; + item[CATEGORY_DIM] = data[i][CATEGORY_DIM]; + result.push(item); + } + return result; +} +function generateGrids() { + let index = 0; + const grid = []; + const xAxis = []; + const yAxis = []; + const series = []; + for (let i = 0; i < CATEGORY_DIM_COUNT; i++) { + for (let j = 0; j < CATEGORY_DIM_COUNT; j++) { + if (CATEGORY_DIM_COUNT - i + j >= CATEGORY_DIM_COUNT) { + continue; + } + grid.push({ + left: BASE_LEFT + i * (GRID_WIDTH + GAP) + '%', + top: BASE_TOP + j * (GRID_HEIGHT + GAP) + '%', + width: GRID_WIDTH + '%', + height: GRID_HEIGHT + '%' + }); + xAxis.push({ + splitNumber: 3, + position: 'top', + axisLine: { + show: j === 0, + onZero: false + }, + axisTick: { + show: j === 0, + inside: true + }, + axisLabel: { + show: j === 0 + }, + type: 'value', + gridIndex: index, + scale: true + }); + yAxis.push({ + splitNumber: 3, + position: 'right', + axisLine: { + show: i === CATEGORY_DIM_COUNT - 1, + onZero: false + }, + axisTick: { + show: i === CATEGORY_DIM_COUNT - 1, + inside: true + }, + axisLabel: { + show: i === CATEGORY_DIM_COUNT - 1 + }, + type: 'value', + gridIndex: index, + scale: true + }); + series.push({ + type: 'scatter', + symbolSize: SYMBOL_SIZE, + xAxisIndex: index, + yAxisIndex: index, + data: retrieveScatterData(rawData, i, j) + }); + index++; + } + } + return { + grid, + xAxis, + yAxis, + series + }; +} +const gridOption = generateGrids(); +option = { + animation: false, + brush: { + brushLink: 'all', + xAxisIndex: gridOption.xAxis.map(function (_, idx) { + return idx; + }), + yAxisIndex: gridOption.yAxis.map(function (_, idx) { + return idx; + }), + inBrush: { + opacity: 1 + } + }, + visualMap: { + type: 'piecewise', + categories: ['北京', '上海', '广州'], + dimension: CATEGORY_DIM, + orient: 'horizontal', + top: 0, + left: 'center', + inRange: { + color: ['#51689b', '#ce5c5c', '#fbc357'] + }, + outOfRange: { + color: '#ddd' + }, + seriesIndex: gridOption.series.map(function (_, idx) { + return idx; + }) + }, + tooltip: { + trigger: 'item' + }, + parallelAxis: [ + { dim: 0, name: schema[0].text }, + { dim: 1, name: schema[1].text }, + { dim: 2, name: schema[2].text }, + { dim: 3, name: schema[3].text }, + { dim: 4, name: schema[4].text }, + { dim: 5, name: schema[5].text }, + { + dim: 6, + name: schema[6].text, + type: 'category', + data: ['优', '良', '轻度', '中度', '重度', '严重'] + } + ], + parallel: { + bottom: '5%', + left: '2%', + height: '30%', + width: '55%', + parallelAxisDefault: { + type: 'value', + name: 'AQI指数', + nameLocation: 'end', + nameGap: 20, + splitNumber: 3, + nameTextStyle: { + fontSize: 14 + }, + axisLine: { + lineStyle: { + color: '#555' + } + }, + axisTick: { + lineStyle: { + color: '#555' + } + }, + splitLine: { + show: false + }, + axisLabel: { + color: '#555' + } + } + }, + xAxis: gridOption.xAxis, + yAxis: gridOption.yAxis, + grid: gridOption.grid, + series: [ + { + name: 'parallel', + type: 'parallel', + smooth: true, + lineStyle: { + width: 1, + opacity: 0.3 + }, + data: rawData + }, + ...gridOption.series + ] +}; +export {}; diff --git a/testdata/scatter-matrix.js.svg b/testdata/scatter-matrix.js.svg new file mode 100644 index 0000000..d416d63 --- /dev/null +++ b/testdata/scatter-matrix.js.svg @@ -0,0 +1,1795 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +0 +100 +200 +300 +0 +100 +200 +300 +0 +100 +200 +300 +0 +2 +4 +6 +0 +50 +100 +150 +0 +100 +200 +300 +0 +100 +200 +300 +0 +2 +4 +6 +0 +50 +100 +150 +0 +30 +60 +90 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +北京 + +上海 + +广州 + + + + + + +AQI + +PM 2.5 + +PM 10 + +CO + +NO₂ + +SO₂ + +等级 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +0 +100 +200 +300 +0 +100 +200 +300 +0 +100 +200 +300 +0 +2 +4 +6 +0 +50 +100 +150 +0 +30 +60 +90 + + +轻度 +中度 +重度 +严重 + + + + + + \ No newline at end of file diff --git a/testdata/scatter-nebula.js b/testdata/scatter-nebula.js new file mode 100644 index 0000000..c9603be --- /dev/null +++ b/testdata/scatter-nebula.js @@ -0,0 +1,75 @@ +/* +title: Scatter Nebula +category: scatter +titleCN: 大规模星云散点图 +difficulty: 5 +*/ +const dataURL = ROOT_PATH + '/data/asset/data/fake-nebula.bin'; +const xhr = new XMLHttpRequest(); +xhr.open('GET', dataURL, true); +xhr.responseType = 'arraybuffer'; +myChart.showLoading(); +xhr.onload = function (e) { + myChart.hideLoading(); + var rawData = new Float32Array(this.response); + option = { + title: { + left: 'center', + text: echarts.format.addCommas(Math.round(rawData.length / 2)) + ' Points', + subtext: 'Fake data' + }, + tooltip: {}, + toolbox: { + right: 20, + feature: { + dataZoom: {} + } + }, + grid: { + right: 70, + bottom: 70 + }, + xAxis: [{}], + yAxis: [{}], + dataZoom: [ + { + type: 'inside' + }, + { + type: 'slider', + showDataShadow: false, + handleIcon: 'path://M10.7,11.9v-1.3H9.3v1.3c-4.9,0.3-8.8,4.4-8.8,9.4c0,5,3.9,9.1,8.8,9.4v1.3h1.3v-1.3c4.9-0.3,8.8-4.4,8.8-9.4C19.5,16.3,15.6,12.2,10.7,11.9z M13.3,24.4H6.7V23h6.6V24.4z M13.3,19.6H6.7v-1.4h6.6V19.6z', + handleSize: '80%' + }, + { + type: 'inside', + orient: 'vertical' + }, + { + type: 'slider', + orient: 'vertical', + showDataShadow: false, + handleIcon: 'path://M10.7,11.9v-1.3H9.3v1.3c-4.9,0.3-8.8,4.4-8.8,9.4c0,5,3.9,9.1,8.8,9.4v1.3h1.3v-1.3c4.9-0.3,8.8-4.4,8.8-9.4C19.5,16.3,15.6,12.2,10.7,11.9z M13.3,24.4H6.7V23h6.6V24.4z M13.3,19.6H6.7v-1.4h6.6V19.6z', + handleSize: '80%' + } + ], + animation: false, + series: [ + { + type: 'scatter', + data: rawData, + dimensions: ['x', 'y'], + symbolSize: 3, + itemStyle: { + opacity: 0.4 + }, + blendMode: 'source-over', + large: true, + largeThreshold: 500 + } + ] + }; + myChart.setOption(option); +}; +xhr.send(); +export {}; diff --git a/testdata/scatter-nutrients-matrix.js b/testdata/scatter-nutrients-matrix.js new file mode 100644 index 0000000..4cd162b --- /dev/null +++ b/testdata/scatter-nutrients-matrix.js @@ -0,0 +1,438 @@ +/* +title: Scatter Nutrients Matrix +category: scatter +titleCN: 营养分布散点矩阵 +difficulty: 7 +*/ +const indices = { + name: 0, + group: 1, + id: 16 +}; +const schema = [ + { name: 'name', index: 0 }, + { name: 'group', index: 1 }, + { name: 'protein', index: 2 }, + { name: 'calcium', index: 3 }, + { name: 'sodium', index: 4 }, + { name: 'fiber', index: 5 }, + { name: 'vitaminc', index: 6 }, + { name: 'potassium', index: 7 }, + { name: 'carbohydrate', index: 8 }, + { name: 'sugars', index: 9 }, + { name: 'fat', index: 10 }, + { name: 'water', index: 11 }, + { name: 'calories', index: 12 }, + { name: 'saturated', index: 13 }, + { name: 'monounsat', index: 14 }, + { name: 'polyunsat', index: 15 }, + { name: 'id', index: 16 } +]; +const axisColors = { + xAxisLeft: '#2A8339', + xAxisRight: '#367DA6', + yAxisTop: '#A68B36', + yAxisBottom: '#BD5692' +}; +const colorBySchema = {}; +const fieldIndices = schema.reduce(function (obj, item) { + obj[item.name] = item.index; + return obj; +}, {}); +const groupCategories = []; +const groupColors = []; +let data; +// zlevel 为 1 的层开启尾迹特效 +myChart.getZr().configLayer(1, { + motionBlur: true +}); +function normalizeData(originData) { + let groupMap = {}; + originData.forEach(function (row) { + let groupName = row[indices.group]; + if (!groupMap.hasOwnProperty(groupName)) { + groupMap[groupName] = 1; + } + }); + originData.forEach(function (row) { + row.forEach(function (item, index) { + if (index !== indices.name && + index !== indices.group && + index !== indices.id) { + // Convert null to zero, as all of them under unit "g". + row[index] = parseFloat(item) || 0; + } + }); + }); + for (let groupName in groupMap) { + if (groupMap.hasOwnProperty(groupName)) { + groupCategories.push(groupName); + } + } + let hStep = Math.round(300 / (groupCategories.length - 1)); + for (let i = 0; i < groupCategories.length; i++) { + groupColors.push(echarts.color.modifyHSL('#5A94DF', hStep * i)); + } + return originData; +} +function makeAxis(dimIndex, id, name, nameLocation) { + const axisColor = axisColors[id.split('-')[dimIndex]]; + colorBySchema[name] = axisColor; + return { + id: id, + name: name, + nameLocation: nameLocation, + nameGap: nameLocation === 'middle' ? 30 : 10, + gridId: id, + splitLine: { show: false }, + axisLine: { + lineStyle: { + color: axisColor + } + }, + axisLabel: { + color: axisColor + }, + axisTick: { + lineStyle: { + color: axisColor + } + } + }; +} +function makeSeriesData(xLeftOrRight, yTopOrBottom) { + return data.map(function (item, idx) { + const schemaX = app.config[xLeftOrRight]; + const schemaY = app.config[yTopOrBottom]; + return [ + item[fieldIndices[schemaX]], + item[fieldIndices[schemaY]], + item[1], + item[0], + schemaX, + schemaY, + idx // 6 + ]; + }); +} +function makeSeries(xLeftOrRight, yTopOrBottom) { + let id = xLeftOrRight + '-' + yTopOrBottom; + return { + zlevel: 1, + type: 'scatter', + name: 'nutrients', + xAxisId: id, + yAxisId: id, + symbolSize: 8, + emphasis: { + itemStyle: { + color: '#fff' + } + }, + data: makeSeriesData(xLeftOrRight, yTopOrBottom) + }; +} +function makeDataZoom(opt) { + return Object.assign({ + type: 'slider', + filterMode: 'empty', + realtime: false + }, opt); +} +function tooltipFormatter(params) { + // Remove duplicate by data name. + let mapByDataName = {}; + let mapOnDim = { + x: {}, + y: {}, + xy: {} + }; + params.forEach(function (item) { + let data = item.data; + let dataName = data[3]; + let mapItem = mapByDataName[dataName] || (mapByDataName[dataName] = {}); + mapItem[data[4]] = data[0]; + mapItem[data[5]] = data[1]; + mapOnDim[item.axisDim][dataName] = mapItem; + }); + Object.keys(mapByDataName).forEach(function (dataName) { + if (mapOnDim.x[dataName] && mapOnDim.y[dataName]) { + mapOnDim.xy[dataName] = mapByDataName[dataName]; + delete mapOnDim.x[dataName]; + delete mapOnDim.y[dataName]; + } + }); + let resultHTML = []; + [ + ['xy', 'CROSS'], + ['x', 'V LINE'], + ['y', 'H LINE'] + ].forEach(function (dimDefine) { + let html = []; + Object.keys(mapOnDim[dimDefine[0]]).forEach(function (dataName) { + let mapItem = mapOnDim[dimDefine[0]][dataName]; + let valuesHTML = []; + Object.keys(mapItem).forEach(function (dataName) { + valuesHTML.push('' + + dataName + + ': ' + + mapItem[dataName]); + }); + html.push('
' + + dataName + + '
' + + valuesHTML.join('
') + + '
'); + }); + html.length && + resultHTML.push('
' + + '
POINTS ON ' + + dimDefine[1] + + '
' + + html.join('') + + '
'); + }); + return resultHTML.join(''); +} +function getOption(data) { + let gridWidth = '35%'; + let gridHeight = '35%'; + let gridLeft = 80; + let gridRight = 50; + let gridTop = 50; + let gridBottom = 80; + return { + tooltip: { + trigger: 'none', + padding: [10, 20, 10, 20], + backgroundColor: 'rgba(0,0,0,0.7)', + transitionDuration: 0, + extraCssText: 'width: 300px; white-space: normal', + textStyle: { + color: '#fff', + fontSize: 12 + }, + position: function (pos, params, el, elRect, size) { + let obj = {}; + obj[['left', 'right'][+(pos[0] < size.viewSize[0] / 2)]] = 60; + obj[['top', 'bottom'][+(pos[1] < size.viewSize[1] / 2)]] = 20; + return obj; + }, + formatter: tooltipFormatter + }, + axisPointer: { + show: true, + snap: true, + lineStyle: { + type: 'dashed' + }, + label: { + show: true, + margin: 6, + backgroundColor: '#556', + color: '#fff' + }, + link: [ + { + xAxisId: ['xAxisLeft-yAxisTop', 'xAxisLeft-yAxisBottom'] + }, + { + xAxisId: ['xAxisRight-yAxisTop', 'xAxisRight-yAxisBottom'] + }, + { + yAxisId: ['xAxisLeft-yAxisTop', 'xAxisRight-yAxisTop'] + }, + { + yAxisId: ['xAxisLeft-yAxisBottom', 'xAxisRight-yAxisBottom'] + } + ] + }, + xAxis: [ + makeAxis(0, 'xAxisLeft-yAxisTop', 'carbohydrate', 'middle'), + makeAxis(0, 'xAxisLeft-yAxisBottom', 'carbohydrate', 'middle'), + makeAxis(0, 'xAxisRight-yAxisTop', 'potassium', 'middle'), + makeAxis(0, 'xAxisRight-yAxisBottom', 'potassium', 'middle') + ], + yAxis: [ + makeAxis(1, 'xAxisLeft-yAxisTop', 'calcium', 'end'), + makeAxis(1, 'xAxisLeft-yAxisBottom', 'fiber', 'end'), + makeAxis(1, 'xAxisRight-yAxisTop', 'calcium', 'end'), + makeAxis(1, 'xAxisRight-yAxisBottom', 'fiber', 'end') + ], + grid: [ + { + id: 'xAxisLeft-yAxisTop', + left: gridLeft, + top: gridTop, + width: gridWidth, + height: gridHeight + }, + { + id: 'xAxisLeft-yAxisBottom', + left: gridLeft, + bottom: gridBottom, + width: gridWidth, + height: gridHeight + }, + { + id: 'xAxisRight-yAxisTop', + right: gridRight, + top: gridTop, + width: gridWidth, + height: gridHeight + }, + { + id: 'xAxisRight-yAxisBottom', + right: gridRight, + bottom: gridBottom, + width: gridWidth, + height: gridHeight + } + ], + dataZoom: [ + makeDataZoom({ + width: gridWidth, + height: 20, + left: gridLeft, + bottom: 10, + xAxisIndex: [0, 1] + }), + makeDataZoom({ + width: gridWidth, + height: 20, + right: gridRight, + bottom: 10, + xAxisIndex: [2, 3] + }), + makeDataZoom({ + orient: 'vertical', + width: 20, + height: gridHeight, + left: 10, + top: gridTop, + yAxisIndex: [0, 2] + }), + makeDataZoom({ + orient: 'vertical', + width: 20, + height: gridHeight, + left: 10, + bottom: gridBottom, + yAxisIndex: [1, 3] + }) + ], + visualMap: [ + { + show: false, + type: 'piecewise', + categories: groupCategories, + dimension: 2, + inRange: { + color: groupColors //['#d94e5d','#eac736','#50a3ba'] + }, + outOfRange: { + color: ['#ccc'] //['#d94e5d','#eac736','#50a3ba'] + }, + top: 20, + textStyle: { + color: '#fff' + }, + realtime: false + } + ], + series: [ + makeSeries('xAxisLeft', 'yAxisTop'), + makeSeries('xAxisLeft', 'yAxisBottom'), + makeSeries('xAxisRight', 'yAxisTop'), + makeSeries('xAxisRight', 'yAxisBottom') + ], + animationThreshold: 5000, + progressiveThreshold: 5000, + animationEasingUpdate: 'cubicInOut', + animationDurationUpdate: 2000 + }; +} +const fieldNames = schema + .map(function (item) { + return item.name; +}) + .slice(2); +app.config = { + xAxisLeft: 'carbohydrate', + yAxisTop: 'calcium', + xAxisRight: 'potassium', + yAxisBottom: 'fiber', + onChange: function () { + if (data) { + colorBySchema[app.config.xAxisLeft] = axisColors.xAxisLeft; + colorBySchema[app.config.xAxisRight] = axisColors.xAxisRight; + colorBySchema[app.config.yAxisTop] = axisColors.yAxisTop; + colorBySchema[app.config.yAxisBottom] = axisColors.yAxisBottom; + myChart.setOption({ + xAxis: [ + { + name: app.config.xAxisLeft + }, + { + name: app.config.xAxisLeft + }, + { + name: app.config.xAxisRight + }, + { + name: app.config.xAxisRight + } + ], + yAxis: [ + { + name: app.config.yAxisTop + }, + { + name: app.config.yAxisBottom + }, + { + name: app.config.yAxisTop + }, + { + name: app.config.yAxisBottom + } + ], + series: [ + { + data: makeSeriesData('xAxisLeft', 'yAxisTop') + }, + { + data: makeSeriesData('xAxisLeft', 'yAxisBottom') + }, + { + data: makeSeriesData('xAxisRight', 'yAxisTop') + }, + { + data: makeSeriesData('xAxisRight', 'yAxisBottom') + } + ] + }); + } + } +}; +app.configParameters = { + xAxisLeft: { + options: fieldNames + }, + xAxisRight: { + options: fieldNames + }, + yAxisTop: { + options: fieldNames + }, + yAxisBottom: { + options: fieldNames + } +}; +$.get(ROOT_PATH + '/data/asset/data/nutrients.json', function (originData) { + data = normalizeData(originData).slice(0, 1000); + myChart.setOption((option = getOption(data))); +}); +export {}; diff --git a/testdata/scatter-nutrients.js b/testdata/scatter-nutrients.js new file mode 100644 index 0000000..110019b --- /dev/null +++ b/testdata/scatter-nutrients.js @@ -0,0 +1,167 @@ +/* +title: Scatter Nutrients +category: scatter +titleCN: 营养分布散点图 +difficulty: 7 +*/ +const indices = { + name: 0, + group: 1, + id: 16 +}; +const schema = [ + { name: 'name', index: 0 }, + { name: 'group', index: 1 }, + { name: 'protein', index: 2 }, + { name: 'calcium', index: 3 }, + { name: 'sodium', index: 4 }, + { name: 'fiber', index: 5 }, + { name: 'vitaminc', index: 6 }, + { name: 'potassium', index: 7 }, + { name: 'carbohydrate', index: 8 }, + { name: 'sugars', index: 9 }, + { name: 'fat', index: 10 }, + { name: 'water', index: 11 }, + { name: 'calories', index: 12 }, + { name: 'saturated', index: 13 }, + { name: 'monounsat', index: 14 }, + { name: 'polyunsat', index: 15 }, + { name: 'id', index: 16 } +]; +const fieldIndices = schema.reduce(function (obj, item) { + obj[item.name] = item.index; + return obj; +}, {}); +const groupCategories = []; +const groupColors = []; +let data; +// zlevel 为 1 的层开启尾迹特效 +myChart.getZr().configLayer(1, { + motionBlur: true +}); +$.get(ROOT_PATH + '/data/asset/data/nutrients.json', function (originData) { + data = normalizeData(originData).slice(0, 1000); + myChart.setOption((option = getOption(data))); +}); +function normalizeData(originData) { + let groupMap = {}; + originData.forEach(function (row) { + let groupName = row[indices.group]; + if (!groupMap.hasOwnProperty(groupName)) { + groupMap[groupName] = 1; + } + }); + originData.forEach(function (row) { + row.forEach(function (item, index) { + if (index !== indices.name && + index !== indices.group && + index !== indices.id) { + // Convert null to zero, as all of them under unit "g". + row[index] = parseFloat(item) || 0; + } + }); + }); + for (let groupName in groupMap) { + if (groupMap.hasOwnProperty(groupName)) { + groupCategories.push(groupName); + } + } + let hStep = Math.round(300 / (groupCategories.length - 1)); + for (let i = 0; i < groupCategories.length; i++) { + groupColors.push(echarts.color.modifyHSL('#5A94DF', hStep * i)); + } + return originData; +} +function getOption(data) { + return { + xAxis: { + name: 'protein', + splitLine: { show: false } + }, + yAxis: { + name: 'calcium', + splitLine: { show: false } + }, + visualMap: [ + { + show: false, + type: 'piecewise', + categories: groupCategories, + dimension: 2, + inRange: { + color: groupColors + }, + outOfRange: { + color: ['#ccc'] + }, + top: 20, + textStyle: { + color: '#fff' + }, + realtime: false + }, + { + show: false, + dimension: 3, + max: 100, + inRange: { + colorLightness: [0.15, 0.6] + } + } + ], + series: [ + { + zlevel: 1, + name: 'nutrients', + type: 'scatter', + data: data.map(function (item, idx) { + return [item[2], item[3], item[1], idx]; + }), + animationThreshold: 5000, + progressiveThreshold: 5000 + } + ], + animationEasingUpdate: 'cubicInOut', + animationDurationUpdate: 2000 + }; +} +let fieldNames = schema + .map(function (item) { + return item.name; +}) + .slice(2); +app.config = { + xAxis: 'protein', + yAxis: 'calcium', + onChange: function () { + if (data) { + myChart.setOption({ + xAxis: { + name: app.config.xAxis + }, + yAxis: { + name: app.config.yAxis + }, + series: { + data: data.map(function (item, idx) { + return [ + item[fieldIndices[app.config.xAxis]], + item[fieldIndices[app.config.yAxis]], + item[1], + idx + ]; + }) + } + }); + } + } +}; +app.configParameters = { + xAxis: { + options: fieldNames + }, + yAxis: { + options: fieldNames + } +}; +export {}; diff --git a/testdata/scatter-painter-choice.js b/testdata/scatter-painter-choice.js new file mode 100644 index 0000000..6c7e115 --- /dev/null +++ b/testdata/scatter-painter-choice.js @@ -0,0 +1,60 @@ +/* +title: Master Painter Color Choices Throughout History +category: scatter +titleCN: Master Painter Color Choices Throughout History +difficulty: 9 +*/ +myChart.showLoading(); +$.get(ROOT_PATH + '/data/asset/data/masterPainterColorChoice.json', function (json) { + myChart.hideLoading(); + var data = json[0].x.map(function (x, idx) { + return [+x, +json[0].y[idx]]; + }); + myChart.setOption((option = { + title: { + text: 'Master Painter Color Choices Throughout History', + subtext: 'Data From Plot.ly', + left: 'right' + }, + xAxis: { + type: 'value', + splitLine: { + show: false + }, + scale: true, + splitNumber: 5, + max: 'dataMax', + axisLabel: { + formatter: function (val) { + return val + 's'; + } + } + }, + yAxis: { + type: 'value', + min: 0, + max: 360, + interval: 60, + name: 'Hue', + splitLine: { + show: false + } + }, + series: [ + { + name: 'scatter', + type: 'scatter', + symbolSize: function (val, param) { + return (json[0].marker.size[param.dataIndex] / json[0].marker.sizeref); + }, + itemStyle: { + color: function (param) { + return json[0].marker.color[param.dataIndex]; + } + }, + data: data + } + ] + })); +}); +export {}; diff --git a/testdata/scatter-polar-punchCard.js b/testdata/scatter-polar-punchCard.js new file mode 100644 index 0000000..a09b424 --- /dev/null +++ b/testdata/scatter-polar-punchCard.js @@ -0,0 +1,75 @@ +/* +title: Punch Card of Github +category: scatter +titleCN: GitHub 打卡气泡图(极坐标) +difficulty: 8 +*/ +// prettier-ignore +const hours = [ + '12a', '1a', '2a', '3a', '4a', '5a', '6a', + '7a', '8a', '9a', '10a', '11a', + '12p', '1p', '2p', '3p', '4p', '5p', + '6p', '7p', '8p', '9p', '10p', '11p' +]; +// prettier-ignore +const days = [ + 'Saturday', 'Friday', 'Thursday', + 'Wednesday', 'Tuesday', 'Monday', 'Sunday' +]; +// prettier-ignore +const data = [[0, 0, 5], [0, 1, 1], [0, 2, 0], [0, 3, 0], [0, 4, 0], [0, 5, 0], [0, 6, 0], [0, 7, 0], [0, 8, 0], [0, 9, 0], [0, 10, 0], [0, 11, 2], [0, 12, 4], [0, 13, 1], [0, 14, 1], [0, 15, 3], [0, 16, 4], [0, 17, 6], [0, 18, 4], [0, 19, 4], [0, 20, 3], [0, 21, 3], [0, 22, 2], [0, 23, 5], [1, 0, 7], [1, 1, 0], [1, 2, 0], [1, 3, 0], [1, 4, 0], [1, 5, 0], [1, 6, 0], [1, 7, 0], [1, 8, 0], [1, 9, 0], [1, 10, 5], [1, 11, 2], [1, 12, 2], [1, 13, 6], [1, 14, 9], [1, 15, 11], [1, 16, 6], [1, 17, 7], [1, 18, 8], [1, 19, 12], [1, 20, 5], [1, 21, 5], [1, 22, 7], [1, 23, 2], [2, 0, 1], [2, 1, 1], [2, 2, 0], [2, 3, 0], [2, 4, 0], [2, 5, 0], [2, 6, 0], [2, 7, 0], [2, 8, 0], [2, 9, 0], [2, 10, 3], [2, 11, 2], [2, 12, 1], [2, 13, 9], [2, 14, 8], [2, 15, 10], [2, 16, 6], [2, 17, 5], [2, 18, 5], [2, 19, 5], [2, 20, 7], [2, 21, 4], [2, 22, 2], [2, 23, 4], [3, 0, 7], [3, 1, 3], [3, 2, 0], [3, 3, 0], [3, 4, 0], [3, 5, 0], [3, 6, 0], [3, 7, 0], [3, 8, 1], [3, 9, 0], [3, 10, 5], [3, 11, 4], [3, 12, 7], [3, 13, 14], [3, 14, 13], [3, 15, 12], [3, 16, 9], [3, 17, 5], [3, 18, 5], [3, 19, 10], [3, 20, 6], [3, 21, 4], [3, 22, 4], [3, 23, 1], [4, 0, 1], [4, 1, 3], [4, 2, 0], [4, 3, 0], [4, 4, 0], [4, 5, 1], [4, 6, 0], [4, 7, 0], [4, 8, 0], [4, 9, 2], [4, 10, 4], [4, 11, 4], [4, 12, 2], [4, 13, 4], [4, 14, 4], [4, 15, 14], [4, 16, 12], [4, 17, 1], [4, 18, 8], [4, 19, 5], [4, 20, 3], [4, 21, 7], [4, 22, 3], [4, 23, 0], [5, 0, 2], [5, 1, 1], [5, 2, 0], [5, 3, 3], [5, 4, 0], [5, 5, 0], [5, 6, 0], [5, 7, 0], [5, 8, 2], [5, 9, 0], [5, 10, 4], [5, 11, 1], [5, 12, 5], [5, 13, 10], [5, 14, 5], [5, 15, 7], [5, 16, 11], [5, 17, 6], [5, 18, 0], [5, 19, 5], [5, 20, 3], [5, 21, 4], [5, 22, 2], [5, 23, 0], [6, 0, 1], [6, 1, 0], [6, 2, 0], [6, 3, 0], [6, 4, 0], [6, 5, 0], [6, 6, 0], [6, 7, 0], [6, 8, 0], [6, 9, 0], [6, 10, 1], [6, 11, 0], [6, 12, 2], [6, 13, 1], [6, 14, 3], [6, 15, 4], [6, 16, 0], [6, 17, 0], [6, 18, 0], [6, 19, 0], [6, 20, 1], [6, 21, 2], [6, 22, 2], [6, 23, 6]]; +option = { + title: { + text: 'Punch Card of Github' + }, + legend: { + data: ['Punch Card'], + left: 'right' + }, + polar: {}, + tooltip: { + formatter: function (params) { + return (params.value[2] + + ' commits in ' + + hours[params.value[1]] + + ' of ' + + days[params.value[0]]); + } + }, + angleAxis: { + type: 'category', + data: hours, + boundaryGap: false, + splitLine: { + show: true + }, + axisLine: { + show: false + } + }, + radiusAxis: { + type: 'category', + data: days, + axisLine: { + show: false + }, + axisLabel: { + rotate: 45 + } + }, + series: [ + { + name: 'Punch Card', + type: 'scatter', + coordinateSystem: 'polar', + symbolSize: function (val) { + return val[2] * 2; + }, + data: data, + animationDelay: function (idx) { + return idx * 5; + } + } + ] +}; +export {}; diff --git a/testdata/scatter-polar-punchCard.js.svg b/testdata/scatter-polar-punchCard.js.svg new file mode 100644 index 0000000..6e9a166 --- /dev/null +++ b/testdata/scatter-polar-punchCard.js.svg @@ -0,0 +1,2405 @@ + + +12a +1a +2a +3a +4a +5a +6a +7a +8a +9a +10a +11a +12p +1p +2p +3p +4p +5p +6p +7p +8p +9p +10p +11p + + + + + + + + + + +Saturday +Friday +Thursday +Wednesday +Tuesday +Monday +Sunday + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Punch Card + +Punch Card of Github + + \ No newline at end of file diff --git a/testdata/scatter-polynomial-regression.js b/testdata/scatter-polynomial-regression.js new file mode 100644 index 0000000..73a101d --- /dev/null +++ b/testdata/scatter-polynomial-regression.js @@ -0,0 +1,88 @@ +/* +title: Polynomial Regression +category: scatter +titleCN: 多项式回归(使用统计插件) +difficulty: 2 +*/ +// See https://github.com/ecomfe/echarts-stat +echarts.registerTransform(ecStat.transform.regression); +const data = [ + [96.24, 11.35], + [33.09, 85.11], + [57.6, 36.61], + [36.77, 27.26], + [20.1, 6.72], + [45.53, 36.37], + [110.07, 80.13], + [72.05, 20.88], + [39.82, 37.15], + [48.05, 70.5], + [0.85, 2.57], + [51.66, 63.7], + [61.07, 127.13], + [64.54, 33.59], + [35.5, 25.01], + [226.55, 664.02], + [188.6, 175.31], + [81.31, 108.68] +]; +option = { + dataset: [ + { + source: data + }, + { + transform: { + type: 'ecStat:regression', + config: { method: 'polynomial', order: 3 } + } + } + ], + title: { + text: '18 companies net profit and main business income (million)', + subtext: 'By ecStat.regression', + sublink: 'https://github.com/ecomfe/echarts-stat', + left: 'center', + top: 16 + }, + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'cross' + } + }, + xAxis: { + splitLine: { + lineStyle: { + type: 'dashed' + } + }, + splitNumber: 20 + }, + yAxis: { + min: -40, + splitLine: { + lineStyle: { + type: 'dashed' + } + } + }, + series: [ + { + name: 'scatter', + type: 'scatter' + }, + { + name: 'line', + type: 'line', + smooth: true, + datasetIndex: 1, + symbolSize: 0.1, + symbol: 'circle', + label: { show: true, fontSize: 16 }, + labelLayout: { dx: -20 }, + encode: { label: 2, tooltip: 1 } + } + ] +}; +export {}; diff --git a/testdata/scatter-punchCard.js b/testdata/scatter-punchCard.js new file mode 100644 index 0000000..d5c364a --- /dev/null +++ b/testdata/scatter-punchCard.js @@ -0,0 +1,80 @@ +/* +title: Punch Card of Github +category: scatter +titleCN: GitHub 打卡气泡图 +difficulty: 3 +*/ +// prettier-ignore +const hours = [ + '12a', '1a', '2a', '3a', '4a', '5a', '6a', + '7a', '8a', '9a', '10a', '11a', + '12p', '1p', '2p', '3p', '4p', '5p', + '6p', '7p', '8p', '9p', '10p', '11p' +]; +// prettier-ignore +const days = [ + 'Saturday', 'Friday', 'Thursday', + 'Wednesday', 'Tuesday', 'Monday', 'Sunday' +]; +// prettier-ignore +const data = [[0, 0, 5], [0, 1, 1], [0, 2, 0], [0, 3, 0], [0, 4, 0], [0, 5, 0], [0, 6, 0], [0, 7, 0], [0, 8, 0], [0, 9, 0], [0, 10, 0], [0, 11, 2], [0, 12, 4], [0, 13, 1], [0, 14, 1], [0, 15, 3], [0, 16, 4], [0, 17, 6], [0, 18, 4], [0, 19, 4], [0, 20, 3], [0, 21, 3], [0, 22, 2], [0, 23, 5], [1, 0, 7], [1, 1, 0], [1, 2, 0], [1, 3, 0], [1, 4, 0], [1, 5, 0], [1, 6, 0], [1, 7, 0], [1, 8, 0], [1, 9, 0], [1, 10, 5], [1, 11, 2], [1, 12, 2], [1, 13, 6], [1, 14, 9], [1, 15, 11], [1, 16, 6], [1, 17, 7], [1, 18, 8], [1, 19, 12], [1, 20, 5], [1, 21, 5], [1, 22, 7], [1, 23, 2], [2, 0, 1], [2, 1, 1], [2, 2, 0], [2, 3, 0], [2, 4, 0], [2, 5, 0], [2, 6, 0], [2, 7, 0], [2, 8, 0], [2, 9, 0], [2, 10, 3], [2, 11, 2], [2, 12, 1], [2, 13, 9], [2, 14, 8], [2, 15, 10], [2, 16, 6], [2, 17, 5], [2, 18, 5], [2, 19, 5], [2, 20, 7], [2, 21, 4], [2, 22, 2], [2, 23, 4], [3, 0, 7], [3, 1, 3], [3, 2, 0], [3, 3, 0], [3, 4, 0], [3, 5, 0], [3, 6, 0], [3, 7, 0], [3, 8, 1], [3, 9, 0], [3, 10, 5], [3, 11, 4], [3, 12, 7], [3, 13, 14], [3, 14, 13], [3, 15, 12], [3, 16, 9], [3, 17, 5], [3, 18, 5], [3, 19, 10], [3, 20, 6], [3, 21, 4], [3, 22, 4], [3, 23, 1], [4, 0, 1], [4, 1, 3], [4, 2, 0], [4, 3, 0], [4, 4, 0], [4, 5, 1], [4, 6, 0], [4, 7, 0], [4, 8, 0], [4, 9, 2], [4, 10, 4], [4, 11, 4], [4, 12, 2], [4, 13, 4], [4, 14, 4], [4, 15, 14], [4, 16, 12], [4, 17, 1], [4, 18, 8], [4, 19, 5], [4, 20, 3], [4, 21, 7], [4, 22, 3], [4, 23, 0], [5, 0, 2], [5, 1, 1], [5, 2, 0], [5, 3, 3], [5, 4, 0], [5, 5, 0], [5, 6, 0], [5, 7, 0], [5, 8, 2], [5, 9, 0], [5, 10, 4], [5, 11, 1], [5, 12, 5], [5, 13, 10], [5, 14, 5], [5, 15, 7], [5, 16, 11], [5, 17, 6], [5, 18, 0], [5, 19, 5], [5, 20, 3], [5, 21, 4], [5, 22, 2], [5, 23, 0], [6, 0, 1], [6, 1, 0], [6, 2, 0], [6, 3, 0], [6, 4, 0], [6, 5, 0], [6, 6, 0], [6, 7, 0], [6, 8, 0], [6, 9, 0], [6, 10, 1], [6, 11, 0], [6, 12, 2], [6, 13, 1], [6, 14, 3], [6, 15, 4], [6, 16, 0], [6, 17, 0], [6, 18, 0], [6, 19, 0], [6, 20, 1], [6, 21, 2], [6, 22, 2], [6, 23, 6]] + .map(function (item) { + return [item[1], item[0], item[2]]; +}); +option = { + title: { + text: 'Punch Card of Github' + }, + legend: { + data: ['Punch Card'], + left: 'right' + }, + tooltip: { + position: 'top', + formatter: function (params) { + return (params.value[2] + + ' commits in ' + + hours[params.value[0]] + + ' of ' + + days[params.value[1]]); + } + }, + grid: { + left: 2, + bottom: 10, + right: 10, + containLabel: true + }, + xAxis: { + type: 'category', + data: hours, + boundaryGap: false, + splitLine: { + show: true + }, + axisLine: { + show: false + } + }, + yAxis: { + type: 'category', + data: days, + axisLine: { + show: false + } + }, + series: [ + { + name: 'Punch Card', + type: 'scatter', + symbolSize: function (val) { + return val[2] * 2; + }, + data: data, + animationDelay: function (idx) { + return idx * 5; + } + } + ] +}; +export {}; diff --git a/testdata/scatter-punchCard.js.svg b/testdata/scatter-punchCard.js.svg new file mode 100644 index 0000000..1210fcd --- /dev/null +++ b/testdata/scatter-punchCard.js.svg @@ -0,0 +1,2451 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Saturday +Friday +Thursday +Wednesday +Tuesday +Monday +Sunday +12a +1a +2a +3a +4a +5a +6a +7a +8a +9a +10a +11a +12p +1p +2p +3p +4p +5p +6p +7p +8p +9p +10p +11p + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Punch Card + +Punch Card of Github + + \ No newline at end of file diff --git a/testdata/scatter-simple.js b/testdata/scatter-simple.js new file mode 100644 index 0000000..a535dd6 --- /dev/null +++ b/testdata/scatter-simple.js @@ -0,0 +1,41 @@ +/* +title: Basic Scatter Chart +category: scatter +titleCN: 基础散点图 +difficulty: 0 +*/ +option = { + xAxis: {}, + yAxis: {}, + series: [ + { + symbolSize: 20, + data: [ + [10.0, 8.04], + [8.07, 6.95], + [13.0, 7.58], + [9.05, 8.81], + [11.0, 8.33], + [14.0, 7.66], + [13.4, 6.81], + [10.0, 6.33], + [14.0, 8.96], + [12.5, 6.82], + [9.15, 7.2], + [11.5, 7.2], + [3.03, 4.23], + [12.2, 7.83], + [2.02, 4.47], + [1.05, 3.33], + [4.05, 4.96], + [6.03, 7.24], + [12.0, 6.26], + [12.0, 8.84], + [7.08, 5.82], + [5.02, 5.68] + ], + type: 'scatter' + } + ] +}; +export {}; diff --git a/testdata/scatter-simple.js.svg b/testdata/scatter-simple.js.svg new file mode 100644 index 0000000..1a14ea9 --- /dev/null +++ b/testdata/scatter-simple.js.svg @@ -0,0 +1,353 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +0 +2 +4 +6 +8 +10 +0 +3 +6 +9 +12 +15 + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/scatter-single-axis.js b/testdata/scatter-single-axis.js new file mode 100644 index 0000000..413dbb3 --- /dev/null +++ b/testdata/scatter-single-axis.js @@ -0,0 +1,62 @@ +/* +title: Scatter on Single Axis +category: scatter +titleCN: 单轴散点图 +difficulty: 3 +*/ +// prettier-ignore +const hours = [ + '12a', '1a', '2a', '3a', '4a', '5a', '6a', + '7a', '8a', '9a', '10a', '11a', + '12p', '1p', '2p', '3p', '4p', '5p', + '6p', '7p', '8p', '9p', '10p', '11p' +]; +// prettier-ignore +const days = [ + 'Saturday', 'Friday', 'Thursday', + 'Wednesday', 'Tuesday', 'Monday', 'Sunday' +]; +// prettier-ignore +const data = [[0, 0, 5], [0, 1, 1], [0, 2, 0], [0, 3, 0], [0, 4, 0], [0, 5, 0], [0, 6, 0], [0, 7, 0], [0, 8, 0], [0, 9, 0], [0, 10, 0], [0, 11, 2], [0, 12, 4], [0, 13, 1], [0, 14, 1], [0, 15, 3], [0, 16, 4], [0, 17, 6], [0, 18, 4], [0, 19, 4], [0, 20, 3], [0, 21, 3], [0, 22, 2], [0, 23, 5], [1, 0, 7], [1, 1, 0], [1, 2, 0], [1, 3, 0], [1, 4, 0], [1, 5, 0], [1, 6, 0], [1, 7, 0], [1, 8, 0], [1, 9, 0], [1, 10, 5], [1, 11, 2], [1, 12, 2], [1, 13, 6], [1, 14, 9], [1, 15, 11], [1, 16, 6], [1, 17, 7], [1, 18, 8], [1, 19, 12], [1, 20, 5], [1, 21, 5], [1, 22, 7], [1, 23, 2], [2, 0, 1], [2, 1, 1], [2, 2, 0], [2, 3, 0], [2, 4, 0], [2, 5, 0], [2, 6, 0], [2, 7, 0], [2, 8, 0], [2, 9, 0], [2, 10, 3], [2, 11, 2], [2, 12, 1], [2, 13, 9], [2, 14, 8], [2, 15, 10], [2, 16, 6], [2, 17, 5], [2, 18, 5], [2, 19, 5], [2, 20, 7], [2, 21, 4], [2, 22, 2], [2, 23, 4], [3, 0, 7], [3, 1, 3], [3, 2, 0], [3, 3, 0], [3, 4, 0], [3, 5, 0], [3, 6, 0], [3, 7, 0], [3, 8, 1], [3, 9, 0], [3, 10, 5], [3, 11, 4], [3, 12, 7], [3, 13, 14], [3, 14, 13], [3, 15, 12], [3, 16, 9], [3, 17, 5], [3, 18, 5], [3, 19, 10], [3, 20, 6], [3, 21, 4], [3, 22, 4], [3, 23, 1], [4, 0, 1], [4, 1, 3], [4, 2, 0], [4, 3, 0], [4, 4, 0], [4, 5, 1], [4, 6, 0], [4, 7, 0], [4, 8, 0], [4, 9, 2], [4, 10, 4], [4, 11, 4], [4, 12, 2], [4, 13, 4], [4, 14, 4], [4, 15, 14], [4, 16, 12], [4, 17, 1], [4, 18, 8], [4, 19, 5], [4, 20, 3], [4, 21, 7], [4, 22, 3], [4, 23, 0], [5, 0, 2], [5, 1, 1], [5, 2, 0], [5, 3, 3], [5, 4, 0], [5, 5, 0], [5, 6, 0], [5, 7, 0], [5, 8, 2], [5, 9, 0], [5, 10, 4], [5, 11, 1], [5, 12, 5], [5, 13, 10], [5, 14, 5], [5, 15, 7], [5, 16, 11], [5, 17, 6], [5, 18, 0], [5, 19, 5], [5, 20, 3], [5, 21, 4], [5, 22, 2], [5, 23, 0], [6, 0, 1], [6, 1, 0], [6, 2, 0], [6, 3, 0], [6, 4, 0], [6, 5, 0], [6, 6, 0], [6, 7, 0], [6, 8, 0], [6, 9, 0], [6, 10, 1], [6, 11, 0], [6, 12, 2], [6, 13, 1], [6, 14, 3], [6, 15, 4], [6, 16, 0], [6, 17, 0], [6, 18, 0], [6, 19, 0], [6, 20, 1], [6, 21, 2], [6, 22, 2], [6, 23, 6]]; +const title = []; +const singleAxis = []; +const series = []; +days.forEach(function (day, idx) { + title.push({ + textBaseline: 'middle', + top: ((idx + 0.5) * 100) / 7 + '%', + text: day + }); + singleAxis.push({ + left: 150, + type: 'category', + boundaryGap: false, + data: hours, + top: (idx * 100) / 7 + 5 + '%', + height: 100 / 7 - 10 + '%', + axisLabel: { + interval: 2 + } + }); + series.push({ + singleAxisIndex: idx, + coordinateSystem: 'singleAxis', + type: 'scatter', + data: [], + symbolSize: function (dataItem) { + return dataItem[1] * 4; + } + }); +}); +data.forEach(function (dataItem) { + series[dataItem[0]].data.push([dataItem[1], dataItem[2]]); +}); +option = { + tooltip: { + position: 'top' + }, + title: title, + singleAxis: singleAxis, + series: series +}; +export {}; diff --git a/testdata/scatter-single-axis.js.svg b/testdata/scatter-single-axis.js.svg new file mode 100644 index 0000000..fd5bf73 --- /dev/null +++ b/testdata/scatter-single-axis.js.svg @@ -0,0 +1,2499 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +12a +3a +6a +9a +12p +3p +6p +9p +12a +3a +6a +9a +12p +3p +6p +9p +12a +3a +6a +9a +12p +3p +6p +9p +12a +3a +6a +9a +12p +3p +6p +9p +12a +3a +6a +9a +12p +3p +6p +9p +12a +3a +6a +9a +12p +3p +6p +9p +12a +3a +6a +9a +12p +3p +6p +9p + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Saturday +Friday +Thursday +Wednesday +Tuesday +Monday +Sunday + + \ No newline at end of file diff --git a/testdata/scatter-stream-visual.js b/testdata/scatter-stream-visual.js new file mode 100644 index 0000000..4908545 --- /dev/null +++ b/testdata/scatter-stream-visual.js @@ -0,0 +1,57 @@ +/* +title: Visual interaction with stream +category: scatter +titleCN: 流式渲染和视觉映射操作 +difficulty: 5 +*/ +// Thanks to: 若怀冰 +// http://gallery.echartsjs.com/explore.html?u=bd-16906679 +// http://gallery.echartsjs.com/editor.html?c=xHJw-hVqjW +$.getJSON(ROOT_PATH + '/data/asset/data/house-price-area2.json', function (data) { + var option = { + title: { + text: 'Dispersion of house price based on the area', + left: 'center', + top: 0 + }, + visualMap: { + min: 15202, + max: 159980, + dimension: 1, + orient: 'vertical', + right: 10, + top: 'center', + text: ['HIGH', 'LOW'], + calculable: true, + inRange: { + color: ['#f2c31a', '#24b7f2'] + } + }, + tooltip: { + trigger: 'item', + axisPointer: { + type: 'cross' + } + }, + xAxis: [ + { + type: 'value' + } + ], + yAxis: [ + { + type: 'value' + } + ], + series: [ + { + name: 'price-area', + type: 'scatter', + symbolSize: 5, + data: data + } + ] + }; + myChart.setOption(option); +}); +export {}; diff --git a/testdata/scatter-symbol-morph.js b/testdata/scatter-symbol-morph.js new file mode 100644 index 0000000..2abcbcf --- /dev/null +++ b/testdata/scatter-symbol-morph.js @@ -0,0 +1,137 @@ +/* +title: Symbol Shape Morph +category: scatter +titleCN: 散点图变形动画 +difficulty: 4 +videoStart: 1000 +videoEnd: 8000 +*/ +let xData = []; +let yData = []; +let data = []; +for (let y = 0; y < 10; y++) { + yData.push(y); + for (let x = 0; x < 10; x++) { + data.push([x, y, 10]); + } +} +for (let x = 0; x < 10; x++) { + xData.push(x); +} +const options = [ + { + grid: { + left: 0, + right: 0, + top: 0, + bottom: 0 + }, + xAxis: { + show: false, + type: 'category', + data: xData + }, + yAxis: { + show: false, + type: 'category', + data: yData + }, + series: [ + { + type: 'scatter', + data: data, + symbol: 'roundRect', + symbolKeepAspect: true, + universalTransition: true, + symbolSize: 50 + } + ] + }, + { + series: [ + { + type: 'scatter', + symbol: 'circle' + } + ] + }, + { + // heart + series: [ + { + symbol: 'path://M23.6 2c-3.363 0-6.258 2.736-7.599 5.594-1.342-2.858-4.237-5.594-7.601-5.594-4.637 0-8.4 3.764-8.4 8.401 0 9.433 9.516 11.906 16.001 21.232 6.13-9.268 15.999-12.1 15.999-21.232 0-4.637-3.763-8.401-8.4-8.401z' + } + ] + }, + { + // happy + series: [ + { + symbol: 'path://M16 0c-8.837 0-16 7.163-16 16s7.163 16 16 16 16-7.163 16-16-7.163-16-16-16zM22 8c1.105 0 2 1.343 2 3s-0.895 3-2 3-2-1.343-2-3 0.895-3 2-3zM10 8c1.105 0 2 1.343 2 3s-0.895 3-2 3-2-1.343-2-3 0.895-3 2-3zM16 28c-5.215 0-9.544-4.371-10-9.947 2.93 1.691 6.377 2.658 10 2.658s7.070-0.963 10-2.654c-0.455 5.576-4.785 9.942-10 9.942z' + } + ] + }, + { + // evil + series: [ + { + symbol: 'path://M32 2c0-1.422-0.298-2.775-0.833-4-1.049 2.401-3.014 4.31-5.453 5.287-2.694-2.061-6.061-3.287-9.714-3.287s-7.021 1.226-9.714 3.287c-2.439-0.976-4.404-2.886-5.453-5.287-0.535 1.225-0.833 2.578-0.833 4 0 2.299 0.777 4.417 2.081 6.106-1.324 2.329-2.081 5.023-2.081 7.894 0 8.837 7.163 16 16 16s16-7.163 16-16c0-2.871-0.757-5.565-2.081-7.894 1.304-1.689 2.081-3.806 2.081-6.106zM18.003 11.891c0.064-1.483 1.413-2.467 2.55-3.036 1.086-0.543 2.16-0.814 2.205-0.826 0.536-0.134 1.079 0.192 1.213 0.728s-0.192 1.079-0.728 1.213c-0.551 0.139-1.204 0.379-1.779 0.667 0.333 0.357 0.537 0.836 0.537 1.363 0 1.105-0.895 2-2 2s-2-0.895-2-2c0-0.037 0.001-0.073 0.003-0.109zM8.030 8.758c0.134-0.536 0.677-0.862 1.213-0.728 0.045 0.011 1.119 0.283 2.205 0.826 1.137 0.569 2.486 1.553 2.55 3.036 0.002 0.036 0.003 0.072 0.003 0.109 0 1.105-0.895 2-2 2s-2-0.895-2-2c0-0.527 0.204-1.005 0.537-1.363-0.575-0.288-1.228-0.528-1.779-0.667-0.536-0.134-0.861-0.677-0.728-1.213zM16 26c-3.641 0-6.827-1.946-8.576-4.855l2.573-1.544c1.224 2.036 3.454 3.398 6.003 3.398s4.779-1.362 6.003-3.398l2.573 1.544c-1.749 2.908-4.935 4.855-8.576 4.855z' + } + ] + }, + { + // hipster + series: [ + { + symbol: 'path://M16 0c-8.837 0-16 7.163-16 16s7.163 16 16 16 16-7.163 16-16-7.163-16-16-16zM22 8c1.105 0 2 0.895 2 2s-0.895 2-2 2-2-0.895-2-2 0.895-2 2-2zM10 8c1.105 0 2 0.895 2 2s-0.895 2-2 2-2-0.895-2-2 0.895-2 2-2zM16.994 21.23c-0.039-0.035-0.078-0.072-0.115-0.109-0.586-0.586-0.878-1.353-0.879-2.121-0 0.768-0.293 1.535-0.879 2.121-0.038 0.038-0.076 0.074-0.115 0.109-2.704 2.453-9.006-0.058-9.006-3.23 1.938 1.25 3.452 0.306 4.879-1.121 1.172-1.172 3.071-1.172 4.243 0 0.586 0.586 0.879 1.353 0.879 2.121 0-0.768 0.293-1.535 0.879-2.121 1.172-1.172 3.071-1.172 4.243 0 1.427 1.427 2.941 2.371 4.879 1.121 0 3.173-6.302 5.684-9.006 3.23z' + } + ] + }, + { + // shocked + series: [ + { + symbol: 'path://M16 0c-8.837 0-16 7.163-16 16s7.163 16 16 16 16-7.163 16-16-7.163-16-16-16zM10 14c-1.105 0-2-1.343-2-3s0.895-3 2-3 2 1.343 2 3-0.895 3-2 3zM16 26c-2.209 0-4-1.791-4-4s1.791-4 4-4c2.209 0 4 1.791 4 4s-1.791 4-4 4zM22 14c-1.105 0-2-1.343-2-3s0.895-3 2-3 2 1.343 2 3-0.895 3-2 3z' + } + ] + }, + { + // pie chart + series: [ + { + symbol: 'path://M14 18v-14c-7.732 0-14 6.268-14 14s6.268 14 14 14 14-6.268 14-14c0-2.251-0.532-4.378-1.476-6.262l-12.524 6.262zM28.524 7.738c-2.299-4.588-7.043-7.738-12.524-7.738v14l12.524-6.262z' + } + ] + }, + { + // users + series: [ + { + symbol: 'path://M10.225 24.854c1.728-1.13 3.877-1.989 6.243-2.513-0.47-0.556-0.897-1.176-1.265-1.844-0.95-1.726-1.453-3.627-1.453-5.497 0-2.689 0-5.228 0.956-7.305 0.928-2.016 2.598-3.265 4.976-3.734-0.529-2.39-1.936-3.961-5.682-3.961-6 0-6 4.029-6 9 0 3.096 1.797 6.191 4 7.432v1.649c-6.784 0.555-12 3.888-12 7.918h8.719c0.454-0.403 0.956-0.787 1.506-1.146zM24 24.082v-1.649c2.203-1.241 4-4.337 4-7.432 0-4.971 0-9-6-9s-6 4.029-6 9c0 3.096 1.797 6.191 4 7.432v1.649c-6.784 0.555-12 3.888-12 7.918h28c0-4.030-5.216-7.364-12-7.918z' + } + ] + }, + { + // mug + series: [ + { + symbol: 'path://M30 10h-6v-3c0-2.761-5.373-5-12-5s-12 2.239-12 5v20c0 2.761 5.373 5 12 5s12-2.239 12-5v-3h6c1.105 0 2-0.895 2-2v-10c0-1.105-0.895-2-2-2zM5.502 8.075c-1.156-0.381-1.857-0.789-2.232-1.075 0.375-0.286 1.075-0.694 2.232-1.075 1.811-0.597 4.118-0.925 6.498-0.925s4.688 0.329 6.498 0.925c1.156 0.381 1.857 0.789 2.232 1.075-0.375 0.286-1.076 0.694-2.232 1.075-1.811 0.597-4.118 0.925-6.498 0.925s-4.688-0.329-6.498-0.925zM28 20h-4v-6h4v6z' + } + ] + }, + { + // plane + series: [ + { + symbol: 'path://M24 19.999l-5.713-5.713 13.713-10.286-4-4-17.141 6.858-5.397-5.397c-1.556-1.556-3.728-1.928-4.828-0.828s-0.727 3.273 0.828 4.828l5.396 5.396-6.858 17.143 4 4 10.287-13.715 5.713 5.713v7.999h4l2-6 6-2v-4l-7.999 0z' + } + ] + } +]; +let optionIndex = 0; +option = options[optionIndex]; +setInterval(function () { + optionIndex = (optionIndex + 1) % options.length; + myChart.setOption(options[optionIndex]); +}, 700); +export {}; diff --git a/testdata/scatter-symbol-morph.js.svg b/testdata/scatter-symbol-morph.js.svg new file mode 100644 index 0000000..2ae9d24 --- /dev/null +++ b/testdata/scatter-symbol-morph.js.svg @@ -0,0 +1,1407 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/scatter-weibo.js b/testdata/scatter-weibo.js new file mode 100644 index 0000000..603f4fc --- /dev/null +++ b/testdata/scatter-weibo.js @@ -0,0 +1,103 @@ +/* +title: Sign in of weibo +category: scatter +titleCN: 微博签到数据点亮中国 +*/ +myChart.showLoading(); +$.get(ROOT_PATH + '/data/asset/data/weibo.json', function (weiboData) { + myChart.hideLoading(); + const newWeiboData = weiboData.map(function (serieData, idx) { + let px = serieData[0] / 1000; + let py = serieData[1] / 1000; + let res = [[px, py]]; + for (let i = 2; i < serieData.length; i += 2) { + let dx = serieData[i] / 1000; + let dy = serieData[i + 1] / 1000; + let x = px + dx; + let y = py + dy; + res.push([+x.toFixed(2), +y.toFixed(2), 1]); + px = x; + py = y; + } + return res; + }); + myChart.setOption((option = { + backgroundColor: '#404a59', + title: { + text: '微博签到数据点亮中国', + subtext: 'From ThinkGIS', + sublink: 'http://www.thinkgis.cn/public/sina', + left: 'center', + top: 'top', + textStyle: { + color: '#fff' + } + }, + tooltip: {}, + legend: { + left: 'left', + data: ['强', '中', '弱'], + textStyle: { + color: '#ccc' + } + }, + geo: { + map: 'china', + roam: true, + emphasis: { + label: { + show: false + }, + itemStyle: { + areaColor: '#2a333d' + } + }, + itemStyle: { + areaColor: '#323c48', + borderColor: '#111' + } + }, + series: [ + { + name: '弱', + type: 'scatter', + coordinateSystem: 'geo', + symbolSize: 1, + large: true, + itemStyle: { + shadowBlur: 2, + shadowColor: 'rgba(37, 140, 249, 0.8)', + color: 'rgba(37, 140, 249, 0.8)' + }, + data: newWeiboData[0] + }, + { + name: '中', + type: 'scatter', + coordinateSystem: 'geo', + symbolSize: 1, + large: true, + itemStyle: { + shadowBlur: 2, + shadowColor: 'rgba(14, 241, 242, 0.8)', + color: 'rgba(14, 241, 242, 0.8)' + }, + data: newWeiboData[1] + }, + { + name: '强', + type: 'scatter', + coordinateSystem: 'geo', + symbolSize: 1, + large: true, + itemStyle: { + shadowBlur: 2, + shadowColor: 'rgba(255, 255, 255, 0.8)', + color: 'rgba(255, 255, 255, 0.8)' + }, + data: newWeiboData[2] + } + ] + })); +}); +export {}; diff --git a/testdata/scatter-weight.js b/testdata/scatter-weight.js new file mode 100644 index 0000000..087f623 --- /dev/null +++ b/testdata/scatter-weight.js @@ -0,0 +1,275 @@ +/* +title: Distribution of Height and Weight +category: scatter +titleCN: 男性女性身高体重分布 +difficulty: 3 +*/ +option = { + title: { + text: 'Male and female height and weight distribution', + subtext: 'Data from: Heinz 2003' + }, + grid: { + left: '3%', + right: '7%', + bottom: '7%', + containLabel: true + }, + tooltip: { + // trigger: 'axis', + showDelay: 0, + formatter: function (params) { + if (params.value.length > 1) { + return (params.seriesName + + ' :
' + + params.value[0] + + 'cm ' + + params.value[1] + + 'kg '); + } + else { + return (params.seriesName + + ' :
' + + params.name + + ' : ' + + params.value + + 'kg '); + } + }, + axisPointer: { + show: true, + type: 'cross', + lineStyle: { + type: 'dashed', + width: 1 + } + } + }, + toolbox: { + feature: { + dataZoom: {}, + brush: { + type: ['rect', 'polygon', 'clear'] + } + } + }, + brush: {}, + legend: { + data: ['Female', 'Male'], + left: 'center', + bottom: 10 + }, + xAxis: [ + { + type: 'value', + scale: true, + axisLabel: { + formatter: '{value} cm' + }, + splitLine: { + show: false + } + } + ], + yAxis: [ + { + type: 'value', + scale: true, + axisLabel: { + formatter: '{value} kg' + }, + splitLine: { + show: false + } + } + ], + series: [ + { + name: 'Female', + type: 'scatter', + emphasis: { + focus: 'series' + }, + // prettier-ignore + data: [[161.2, 51.6], [167.5, 59.0], [159.5, 49.2], [157.0, 63.0], [155.8, 53.6], + [170.0, 59.0], [159.1, 47.6], [166.0, 69.8], [176.2, 66.8], [160.2, 75.2], + [172.5, 55.2], [170.9, 54.2], [172.9, 62.5], [153.4, 42.0], [160.0, 50.0], + [147.2, 49.8], [168.2, 49.2], [175.0, 73.2], [157.0, 47.8], [167.6, 68.8], + [159.5, 50.6], [175.0, 82.5], [166.8, 57.2], [176.5, 87.8], [170.2, 72.8], + [174.0, 54.5], [173.0, 59.8], [179.9, 67.3], [170.5, 67.8], [160.0, 47.0], + [154.4, 46.2], [162.0, 55.0], [176.5, 83.0], [160.0, 54.4], [152.0, 45.8], + [162.1, 53.6], [170.0, 73.2], [160.2, 52.1], [161.3, 67.9], [166.4, 56.6], + [168.9, 62.3], [163.8, 58.5], [167.6, 54.5], [160.0, 50.2], [161.3, 60.3], + [167.6, 58.3], [165.1, 56.2], [160.0, 50.2], [170.0, 72.9], [157.5, 59.8], + [167.6, 61.0], [160.7, 69.1], [163.2, 55.9], [152.4, 46.5], [157.5, 54.3], + [168.3, 54.8], [180.3, 60.7], [165.5, 60.0], [165.0, 62.0], [164.5, 60.3], + [156.0, 52.7], [160.0, 74.3], [163.0, 62.0], [165.7, 73.1], [161.0, 80.0], + [162.0, 54.7], [166.0, 53.2], [174.0, 75.7], [172.7, 61.1], [167.6, 55.7], + [151.1, 48.7], [164.5, 52.3], [163.5, 50.0], [152.0, 59.3], [169.0, 62.5], + [164.0, 55.7], [161.2, 54.8], [155.0, 45.9], [170.0, 70.6], [176.2, 67.2], + [170.0, 69.4], [162.5, 58.2], [170.3, 64.8], [164.1, 71.6], [169.5, 52.8], + [163.2, 59.8], [154.5, 49.0], [159.8, 50.0], [173.2, 69.2], [170.0, 55.9], + [161.4, 63.4], [169.0, 58.2], [166.2, 58.6], [159.4, 45.7], [162.5, 52.2], + [159.0, 48.6], [162.8, 57.8], [159.0, 55.6], [179.8, 66.8], [162.9, 59.4], + [161.0, 53.6], [151.1, 73.2], [168.2, 53.4], [168.9, 69.0], [173.2, 58.4], + [171.8, 56.2], [178.0, 70.6], [164.3, 59.8], [163.0, 72.0], [168.5, 65.2], + [166.8, 56.6], [172.7, 105.2], [163.5, 51.8], [169.4, 63.4], [167.8, 59.0], + [159.5, 47.6], [167.6, 63.0], [161.2, 55.2], [160.0, 45.0], [163.2, 54.0], + [162.2, 50.2], [161.3, 60.2], [149.5, 44.8], [157.5, 58.8], [163.2, 56.4], + [172.7, 62.0], [155.0, 49.2], [156.5, 67.2], [164.0, 53.8], [160.9, 54.4], + [162.8, 58.0], [167.0, 59.8], [160.0, 54.8], [160.0, 43.2], [168.9, 60.5], + [158.2, 46.4], [156.0, 64.4], [160.0, 48.8], [167.1, 62.2], [158.0, 55.5], + [167.6, 57.8], [156.0, 54.6], [162.1, 59.2], [173.4, 52.7], [159.8, 53.2], + [170.5, 64.5], [159.2, 51.8], [157.5, 56.0], [161.3, 63.6], [162.6, 63.2], + [160.0, 59.5], [168.9, 56.8], [165.1, 64.1], [162.6, 50.0], [165.1, 72.3], + [166.4, 55.0], [160.0, 55.9], [152.4, 60.4], [170.2, 69.1], [162.6, 84.5], + [170.2, 55.9], [158.8, 55.5], [172.7, 69.5], [167.6, 76.4], [162.6, 61.4], + [167.6, 65.9], [156.2, 58.6], [175.2, 66.8], [172.1, 56.6], [162.6, 58.6], + [160.0, 55.9], [165.1, 59.1], [182.9, 81.8], [166.4, 70.7], [165.1, 56.8], + [177.8, 60.0], [165.1, 58.2], [175.3, 72.7], [154.9, 54.1], [158.8, 49.1], + [172.7, 75.9], [168.9, 55.0], [161.3, 57.3], [167.6, 55.0], [165.1, 65.5], + [175.3, 65.5], [157.5, 48.6], [163.8, 58.6], [167.6, 63.6], [165.1, 55.2], + [165.1, 62.7], [168.9, 56.6], [162.6, 53.9], [164.5, 63.2], [176.5, 73.6], + [168.9, 62.0], [175.3, 63.6], [159.4, 53.2], [160.0, 53.4], [170.2, 55.0], + [162.6, 70.5], [167.6, 54.5], [162.6, 54.5], [160.7, 55.9], [160.0, 59.0], + [157.5, 63.6], [162.6, 54.5], [152.4, 47.3], [170.2, 67.7], [165.1, 80.9], + [172.7, 70.5], [165.1, 60.9], [170.2, 63.6], [170.2, 54.5], [170.2, 59.1], + [161.3, 70.5], [167.6, 52.7], [167.6, 62.7], [165.1, 86.3], [162.6, 66.4], + [152.4, 67.3], [168.9, 63.0], [170.2, 73.6], [175.2, 62.3], [175.2, 57.7], + [160.0, 55.4], [165.1, 104.1], [174.0, 55.5], [170.2, 77.3], [160.0, 80.5], + [167.6, 64.5], [167.6, 72.3], [167.6, 61.4], [154.9, 58.2], [162.6, 81.8], + [175.3, 63.6], [171.4, 53.4], [157.5, 54.5], [165.1, 53.6], [160.0, 60.0], + [174.0, 73.6], [162.6, 61.4], [174.0, 55.5], [162.6, 63.6], [161.3, 60.9], + [156.2, 60.0], [149.9, 46.8], [169.5, 57.3], [160.0, 64.1], [175.3, 63.6], + [169.5, 67.3], [160.0, 75.5], [172.7, 68.2], [162.6, 61.4], [157.5, 76.8], + [176.5, 71.8], [164.4, 55.5], [160.7, 48.6], [174.0, 66.4], [163.8, 67.3] + ], + markArea: { + silent: true, + itemStyle: { + color: 'transparent', + borderWidth: 1, + borderType: 'dashed' + }, + data: [ + [ + { + name: 'Female Data Range', + xAxis: 'min', + yAxis: 'min' + }, + { + xAxis: 'max', + yAxis: 'max' + } + ] + ] + }, + markPoint: { + data: [ + { type: 'max', name: 'Max' }, + { type: 'min', name: 'Min' } + ] + }, + markLine: { + lineStyle: { + type: 'solid' + }, + data: [{ type: 'average', name: 'AVG' }, { xAxis: 160 }] + } + }, + { + name: 'Male', + type: 'scatter', + emphasis: { + focus: 'series' + }, + // prettier-ignore + data: [[174.0, 65.6], [175.3, 71.8], [193.5, 80.7], [186.5, 72.6], [187.2, 78.8], + [181.5, 74.8], [184.0, 86.4], [184.5, 78.4], [175.0, 62.0], [184.0, 81.6], + [180.0, 76.6], [177.8, 83.6], [192.0, 90.0], [176.0, 74.6], [174.0, 71.0], + [184.0, 79.6], [192.7, 93.8], [171.5, 70.0], [173.0, 72.4], [176.0, 85.9], + [176.0, 78.8], [180.5, 77.8], [172.7, 66.2], [176.0, 86.4], [173.5, 81.8], + [178.0, 89.6], [180.3, 82.8], [180.3, 76.4], [164.5, 63.2], [173.0, 60.9], + [183.5, 74.8], [175.5, 70.0], [188.0, 72.4], [189.2, 84.1], [172.8, 69.1], + [170.0, 59.5], [182.0, 67.2], [170.0, 61.3], [177.8, 68.6], [184.2, 80.1], + [186.7, 87.8], [171.4, 84.7], [172.7, 73.4], [175.3, 72.1], [180.3, 82.6], + [182.9, 88.7], [188.0, 84.1], [177.2, 94.1], [172.1, 74.9], [167.0, 59.1], + [169.5, 75.6], [174.0, 86.2], [172.7, 75.3], [182.2, 87.1], [164.1, 55.2], + [163.0, 57.0], [171.5, 61.4], [184.2, 76.8], [174.0, 86.8], [174.0, 72.2], + [177.0, 71.6], [186.0, 84.8], [167.0, 68.2], [171.8, 66.1], [182.0, 72.0], + [167.0, 64.6], [177.8, 74.8], [164.5, 70.0], [192.0, 101.6], [175.5, 63.2], + [171.2, 79.1], [181.6, 78.9], [167.4, 67.7], [181.1, 66.0], [177.0, 68.2], + [174.5, 63.9], [177.5, 72.0], [170.5, 56.8], [182.4, 74.5], [197.1, 90.9], + [180.1, 93.0], [175.5, 80.9], [180.6, 72.7], [184.4, 68.0], [175.5, 70.9], + [180.6, 72.5], [177.0, 72.5], [177.1, 83.4], [181.6, 75.5], [176.5, 73.0], + [175.0, 70.2], [174.0, 73.4], [165.1, 70.5], [177.0, 68.9], [192.0, 102.3], + [176.5, 68.4], [169.4, 65.9], [182.1, 75.7], [179.8, 84.5], [175.3, 87.7], + [184.9, 86.4], [177.3, 73.2], [167.4, 53.9], [178.1, 72.0], [168.9, 55.5], + [157.2, 58.4], [180.3, 83.2], [170.2, 72.7], [177.8, 64.1], [172.7, 72.3], + [165.1, 65.0], [186.7, 86.4], [165.1, 65.0], [174.0, 88.6], [175.3, 84.1], + [185.4, 66.8], [177.8, 75.5], [180.3, 93.2], [180.3, 82.7], [177.8, 58.0], + [177.8, 79.5], [177.8, 78.6], [177.8, 71.8], [177.8, 116.4], [163.8, 72.2], + [188.0, 83.6], [198.1, 85.5], [175.3, 90.9], [166.4, 85.9], [190.5, 89.1], + [166.4, 75.0], [177.8, 77.7], [179.7, 86.4], [172.7, 90.9], [190.5, 73.6], + [185.4, 76.4], [168.9, 69.1], [167.6, 84.5], [175.3, 64.5], [170.2, 69.1], + [190.5, 108.6], [177.8, 86.4], [190.5, 80.9], [177.8, 87.7], [184.2, 94.5], + [176.5, 80.2], [177.8, 72.0], [180.3, 71.4], [171.4, 72.7], [172.7, 84.1], + [172.7, 76.8], [177.8, 63.6], [177.8, 80.9], [182.9, 80.9], [170.2, 85.5], + [167.6, 68.6], [175.3, 67.7], [165.1, 66.4], [185.4, 102.3], [181.6, 70.5], + [172.7, 95.9], [190.5, 84.1], [179.1, 87.3], [175.3, 71.8], [170.2, 65.9], + [193.0, 95.9], [171.4, 91.4], [177.8, 81.8], [177.8, 96.8], [167.6, 69.1], + [167.6, 82.7], [180.3, 75.5], [182.9, 79.5], [176.5, 73.6], [186.7, 91.8], + [188.0, 84.1], [188.0, 85.9], [177.8, 81.8], [174.0, 82.5], [177.8, 80.5], + [171.4, 70.0], [185.4, 81.8], [185.4, 84.1], [188.0, 90.5], [188.0, 91.4], + [182.9, 89.1], [176.5, 85.0], [175.3, 69.1], [175.3, 73.6], [188.0, 80.5], + [188.0, 82.7], [175.3, 86.4], [170.5, 67.7], [179.1, 92.7], [177.8, 93.6], + [175.3, 70.9], [182.9, 75.0], [170.8, 93.2], [188.0, 93.2], [180.3, 77.7], + [177.8, 61.4], [185.4, 94.1], [168.9, 75.0], [185.4, 83.6], [180.3, 85.5], + [174.0, 73.9], [167.6, 66.8], [182.9, 87.3], [160.0, 72.3], [180.3, 88.6], + [167.6, 75.5], [186.7, 101.4], [175.3, 91.1], [175.3, 67.3], [175.9, 77.7], + [175.3, 81.8], [179.1, 75.5], [181.6, 84.5], [177.8, 76.6], [182.9, 85.0], + [177.8, 102.5], [184.2, 77.3], [179.1, 71.8], [176.5, 87.9], [188.0, 94.3], + [174.0, 70.9], [167.6, 64.5], [170.2, 77.3], [167.6, 72.3], [188.0, 87.3], + [174.0, 80.0], [176.5, 82.3], [180.3, 73.6], [167.6, 74.1], [188.0, 85.9], + [180.3, 73.2], [167.6, 76.3], [183.0, 65.9], [183.0, 90.9], [179.1, 89.1], + [170.2, 62.3], [177.8, 82.7], [179.1, 79.1], [190.5, 98.2], [177.8, 84.1], + [180.3, 83.2], [180.3, 83.2] + ], + markArea: { + silent: true, + itemStyle: { + color: 'transparent', + borderWidth: 1, + borderType: 'dashed' + }, + data: [ + [ + { + name: 'Male Data Range', + xAxis: 'min', + yAxis: 'min' + }, + { + xAxis: 'max', + yAxis: 'max' + } + ] + ] + }, + markPoint: { + data: [ + { type: 'max', name: 'Max' }, + { type: 'min', name: 'Min' } + ] + }, + markLine: { + lineStyle: { + type: 'solid' + }, + data: [{ type: 'average', name: 'Average' }, { xAxis: 170 }] + } + } + ] +}; +export {}; diff --git a/testdata/scatter-weight.js.svg b/testdata/scatter-weight.js.svg new file mode 100644 index 0000000..536d5c3 --- /dev/null +++ b/testdata/scatter-weight.js.svg @@ -0,0 +1,7181 @@ + + + + + + + + + + + + + + + + + + + + +40 kg +50 kg +60 kg +70 kg +80 kg +90 kg +100 kg +110 kg +120 kg +140 cm +150 cm +160 cm +170 cm +180 cm +190 cm +200 cm + + +Female Data Range +Male Data Range + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Female + +Male + + + + + + + + + + + + +60.6 +160 +78.14 +170 + + + + +105.2 +42 +116.4 +53.9 + + + + + + + +Male and female height and weight distribution +Data from: Heinz 2003 + + \ No newline at end of file diff --git a/testdata/scatter-world-population.js b/testdata/scatter-world-population.js new file mode 100644 index 0000000..01cafc9 --- /dev/null +++ b/testdata/scatter-world-population.js @@ -0,0 +1,517 @@ +"use strict"; +/* +title: World Population (2011) +category: scatter +titleCN: World Population (2011) +*/ +var latlong = {}; +latlong.AD = { latitude: 42.5, longitude: 1.5 }; +latlong.AE = { latitude: 24, longitude: 54 }; +latlong.AF = { latitude: 33, longitude: 65 }; +latlong.AG = { latitude: 17.05, longitude: -61.8 }; +latlong.AI = { latitude: 18.25, longitude: -63.1667 }; +latlong.AL = { latitude: 41, longitude: 20 }; +latlong.AM = { latitude: 40, longitude: 45 }; +latlong.AN = { latitude: 12.25, longitude: -68.75 }; +latlong.AO = { latitude: -12.5, longitude: 18.5 }; +latlong.AP = { latitude: 35, longitude: 105 }; +latlong.AQ = { latitude: -90, longitude: 0 }; +latlong.AR = { latitude: -34, longitude: -64 }; +latlong.AS = { latitude: -14.3333, longitude: -170 }; +latlong.AT = { latitude: 47.3333, longitude: 13.3333 }; +latlong.AU = { latitude: -27, longitude: 133 }; +latlong.AW = { latitude: 12.5, longitude: -69.9667 }; +latlong.AZ = { latitude: 40.5, longitude: 47.5 }; +latlong.BA = { latitude: 44, longitude: 18 }; +latlong.BB = { latitude: 13.1667, longitude: -59.5333 }; +latlong.BD = { latitude: 24, longitude: 90 }; +latlong.BE = { latitude: 50.8333, longitude: 4 }; +latlong.BF = { latitude: 13, longitude: -2 }; +latlong.BG = { latitude: 43, longitude: 25 }; +latlong.BH = { latitude: 26, longitude: 50.55 }; +latlong.BI = { latitude: -3.5, longitude: 30 }; +latlong.BJ = { latitude: 9.5, longitude: 2.25 }; +latlong.BM = { latitude: 32.3333, longitude: -64.75 }; +latlong.BN = { latitude: 4.5, longitude: 114.6667 }; +latlong.BO = { latitude: -17, longitude: -65 }; +latlong.BR = { latitude: -10, longitude: -55 }; +latlong.BS = { latitude: 24.25, longitude: -76 }; +latlong.BT = { latitude: 27.5, longitude: 90.5 }; +latlong.BV = { latitude: -54.4333, longitude: 3.4 }; +latlong.BW = { latitude: -22, longitude: 24 }; +latlong.BY = { latitude: 53, longitude: 28 }; +latlong.BZ = { latitude: 17.25, longitude: -88.75 }; +latlong.CA = { latitude: 54, longitude: -100 }; +latlong.CC = { latitude: -12.5, longitude: 96.8333 }; +latlong.CD = { latitude: 0, longitude: 25 }; +latlong.CF = { latitude: 7, longitude: 21 }; +latlong.CG = { latitude: -1, longitude: 15 }; +latlong.CH = { latitude: 47, longitude: 8 }; +latlong.CI = { latitude: 8, longitude: -5 }; +latlong.CK = { latitude: -21.2333, longitude: -159.7667 }; +latlong.CL = { latitude: -30, longitude: -71 }; +latlong.CM = { latitude: 6, longitude: 12 }; +latlong.CN = { latitude: 35, longitude: 105 }; +latlong.CO = { latitude: 4, longitude: -72 }; +latlong.CR = { latitude: 10, longitude: -84 }; +latlong.CU = { latitude: 21.5, longitude: -80 }; +latlong.CV = { latitude: 16, longitude: -24 }; +latlong.CX = { latitude: -10.5, longitude: 105.6667 }; +latlong.CY = { latitude: 35, longitude: 33 }; +latlong.CZ = { latitude: 49.75, longitude: 15.5 }; +latlong.DE = { latitude: 51, longitude: 9 }; +latlong.DJ = { latitude: 11.5, longitude: 43 }; +latlong.DK = { latitude: 56, longitude: 10 }; +latlong.DM = { latitude: 15.4167, longitude: -61.3333 }; +latlong.DO = { latitude: 19, longitude: -70.6667 }; +latlong.DZ = { latitude: 28, longitude: 3 }; +latlong.EC = { latitude: -2, longitude: -77.5 }; +latlong.EE = { latitude: 59, longitude: 26 }; +latlong.EG = { latitude: 27, longitude: 30 }; +latlong.EH = { latitude: 24.5, longitude: -13 }; +latlong.ER = { latitude: 15, longitude: 39 }; +latlong.ES = { latitude: 40, longitude: -4 }; +latlong.ET = { latitude: 8, longitude: 38 }; +latlong.EU = { latitude: 47, longitude: 8 }; +latlong.FI = { latitude: 62, longitude: 26 }; +latlong.FJ = { latitude: -18, longitude: 175 }; +latlong.FK = { latitude: -51.75, longitude: -59 }; +latlong.FM = { latitude: 6.9167, longitude: 158.25 }; +latlong.FO = { latitude: 62, longitude: -7 }; +latlong.FR = { latitude: 46, longitude: 2 }; +latlong.GA = { latitude: -1, longitude: 11.75 }; +latlong.GB = { latitude: 54, longitude: -2 }; +latlong.GD = { latitude: 12.1167, longitude: -61.6667 }; +latlong.GE = { latitude: 42, longitude: 43.5 }; +latlong.GF = { latitude: 4, longitude: -53 }; +latlong.GH = { latitude: 8, longitude: -2 }; +latlong.GI = { latitude: 36.1833, longitude: -5.3667 }; +latlong.GL = { latitude: 72, longitude: -40 }; +latlong.GM = { latitude: 13.4667, longitude: -16.5667 }; +latlong.GN = { latitude: 11, longitude: -10 }; +latlong.GP = { latitude: 16.25, longitude: -61.5833 }; +latlong.GQ = { latitude: 2, longitude: 10 }; +latlong.GR = { latitude: 39, longitude: 22 }; +latlong.GS = { latitude: -54.5, longitude: -37 }; +latlong.GT = { latitude: 15.5, longitude: -90.25 }; +latlong.GU = { latitude: 13.4667, longitude: 144.7833 }; +latlong.GW = { latitude: 12, longitude: -15 }; +latlong.GY = { latitude: 5, longitude: -59 }; +latlong.HK = { latitude: 22.25, longitude: 114.1667 }; +latlong.HM = { latitude: -53.1, longitude: 72.5167 }; +latlong.HN = { latitude: 15, longitude: -86.5 }; +latlong.HR = { latitude: 45.1667, longitude: 15.5 }; +latlong.HT = { latitude: 19, longitude: -72.4167 }; +latlong.HU = { latitude: 47, longitude: 20 }; +latlong.ID = { latitude: -5, longitude: 120 }; +latlong.IE = { latitude: 53, longitude: -8 }; +latlong.IL = { latitude: 31.5, longitude: 34.75 }; +latlong.IN = { latitude: 20, longitude: 77 }; +latlong.IO = { latitude: -6, longitude: 71.5 }; +latlong.IQ = { latitude: 33, longitude: 44 }; +latlong.IR = { latitude: 32, longitude: 53 }; +latlong.IS = { latitude: 65, longitude: -18 }; +latlong.IT = { latitude: 42.8333, longitude: 12.8333 }; +latlong.JM = { latitude: 18.25, longitude: -77.5 }; +latlong.JO = { latitude: 31, longitude: 36 }; +latlong.JP = { latitude: 36, longitude: 138 }; +latlong.KE = { latitude: 1, longitude: 38 }; +latlong.KG = { latitude: 41, longitude: 75 }; +latlong.KH = { latitude: 13, longitude: 105 }; +latlong.KI = { latitude: 1.4167, longitude: 173 }; +latlong.KM = { latitude: -12.1667, longitude: 44.25 }; +latlong.KN = { latitude: 17.3333, longitude: -62.75 }; +latlong.KP = { latitude: 40, longitude: 127 }; +latlong.KR = { latitude: 37, longitude: 127.5 }; +latlong.KW = { latitude: 29.3375, longitude: 47.6581 }; +latlong.KY = { latitude: 19.5, longitude: -80.5 }; +latlong.KZ = { latitude: 48, longitude: 68 }; +latlong.LA = { latitude: 18, longitude: 105 }; +latlong.LB = { latitude: 33.8333, longitude: 35.8333 }; +latlong.LC = { latitude: 13.8833, longitude: -61.1333 }; +latlong.LI = { latitude: 47.1667, longitude: 9.5333 }; +latlong.LK = { latitude: 7, longitude: 81 }; +latlong.LR = { latitude: 6.5, longitude: -9.5 }; +latlong.LS = { latitude: -29.5, longitude: 28.5 }; +latlong.LT = { latitude: 55, longitude: 24 }; +latlong.LU = { latitude: 49.75, longitude: 6 }; +latlong.LV = { latitude: 57, longitude: 25 }; +latlong.LY = { latitude: 25, longitude: 17 }; +latlong.MA = { latitude: 32, longitude: -5 }; +latlong.MC = { latitude: 43.7333, longitude: 7.4 }; +latlong.MD = { latitude: 47, longitude: 29 }; +latlong.ME = { latitude: 42.5, longitude: 19.4 }; +latlong.MG = { latitude: -20, longitude: 47 }; +latlong.MH = { latitude: 9, longitude: 168 }; +latlong.MK = { latitude: 41.8333, longitude: 22 }; +latlong.ML = { latitude: 17, longitude: -4 }; +latlong.MM = { latitude: 22, longitude: 98 }; +latlong.MN = { latitude: 46, longitude: 105 }; +latlong.MO = { latitude: 22.1667, longitude: 113.55 }; +latlong.MP = { latitude: 15.2, longitude: 145.75 }; +latlong.MQ = { latitude: 14.6667, longitude: -61 }; +latlong.MR = { latitude: 20, longitude: -12 }; +latlong.MS = { latitude: 16.75, longitude: -62.2 }; +latlong.MT = { latitude: 35.8333, longitude: 14.5833 }; +latlong.MU = { latitude: -20.2833, longitude: 57.55 }; +latlong.MV = { latitude: 3.25, longitude: 73 }; +latlong.MW = { latitude: -13.5, longitude: 34 }; +latlong.MX = { latitude: 23, longitude: -102 }; +latlong.MY = { latitude: 2.5, longitude: 112.5 }; +latlong.MZ = { latitude: -18.25, longitude: 35 }; +latlong.NA = { latitude: -22, longitude: 17 }; +latlong.NC = { latitude: -21.5, longitude: 165.5 }; +latlong.NE = { latitude: 16, longitude: 8 }; +latlong.NF = { latitude: -29.0333, longitude: 167.95 }; +latlong.NG = { latitude: 10, longitude: 8 }; +latlong.NI = { latitude: 13, longitude: -85 }; +latlong.NL = { latitude: 52.5, longitude: 5.75 }; +latlong.NO = { latitude: 62, longitude: 10 }; +latlong.NP = { latitude: 28, longitude: 84 }; +latlong.NR = { latitude: -0.5333, longitude: 166.9167 }; +latlong.NU = { latitude: -19.0333, longitude: -169.8667 }; +latlong.NZ = { latitude: -41, longitude: 174 }; +latlong.OM = { latitude: 21, longitude: 57 }; +latlong.PA = { latitude: 9, longitude: -80 }; +latlong.PE = { latitude: -10, longitude: -76 }; +latlong.PF = { latitude: -15, longitude: -140 }; +latlong.PG = { latitude: -6, longitude: 147 }; +latlong.PH = { latitude: 13, longitude: 122 }; +latlong.PK = { latitude: 30, longitude: 70 }; +latlong.PL = { latitude: 52, longitude: 20 }; +latlong.PM = { latitude: 46.8333, longitude: -56.3333 }; +latlong.PR = { latitude: 18.25, longitude: -66.5 }; +latlong.PS = { latitude: 32, longitude: 35.25 }; +latlong.PT = { latitude: 39.5, longitude: -8 }; +latlong.PW = { latitude: 7.5, longitude: 134.5 }; +latlong.PY = { latitude: -23, longitude: -58 }; +latlong.QA = { latitude: 25.5, longitude: 51.25 }; +latlong.RE = { latitude: -21.1, longitude: 55.6 }; +latlong.RO = { latitude: 46, longitude: 25 }; +latlong.RS = { latitude: 44, longitude: 21 }; +latlong.RU = { latitude: 60, longitude: 100 }; +latlong.RW = { latitude: -2, longitude: 30 }; +latlong.SA = { latitude: 25, longitude: 45 }; +latlong.SB = { latitude: -8, longitude: 159 }; +latlong.SC = { latitude: -4.5833, longitude: 55.6667 }; +latlong.SD = { latitude: 15, longitude: 30 }; +latlong.SE = { latitude: 62, longitude: 15 }; +latlong.SG = { latitude: 1.3667, longitude: 103.8 }; +latlong.SH = { latitude: -15.9333, longitude: -5.7 }; +latlong.SI = { latitude: 46, longitude: 15 }; +latlong.SJ = { latitude: 78, longitude: 20 }; +latlong.SK = { latitude: 48.6667, longitude: 19.5 }; +latlong.SL = { latitude: 8.5, longitude: -11.5 }; +latlong.SM = { latitude: 43.7667, longitude: 12.4167 }; +latlong.SN = { latitude: 14, longitude: -14 }; +latlong.SO = { latitude: 10, longitude: 49 }; +latlong.SR = { latitude: 4, longitude: -56 }; +latlong.ST = { latitude: 1, longitude: 7 }; +latlong.SV = { latitude: 13.8333, longitude: -88.9167 }; +latlong.SY = { latitude: 35, longitude: 38 }; +latlong.SZ = { latitude: -26.5, longitude: 31.5 }; +latlong.TC = { latitude: 21.75, longitude: -71.5833 }; +latlong.TD = { latitude: 15, longitude: 19 }; +latlong.TF = { latitude: -43, longitude: 67 }; +latlong.TG = { latitude: 8, longitude: 1.1667 }; +latlong.TH = { latitude: 15, longitude: 100 }; +latlong.TJ = { latitude: 39, longitude: 71 }; +latlong.TK = { latitude: -9, longitude: -172 }; +latlong.TM = { latitude: 40, longitude: 60 }; +latlong.TN = { latitude: 34, longitude: 9 }; +latlong.TO = { latitude: -20, longitude: -175 }; +latlong.TR = { latitude: 39, longitude: 35 }; +latlong.TT = { latitude: 11, longitude: -61 }; +latlong.TV = { latitude: -8, longitude: 178 }; +latlong.TW = { latitude: 23.5, longitude: 121 }; +latlong.TZ = { latitude: -6, longitude: 35 }; +latlong.UA = { latitude: 49, longitude: 32 }; +latlong.UG = { latitude: 1, longitude: 32 }; +latlong.UM = { latitude: 19.2833, longitude: 166.6 }; +latlong.US = { latitude: 38, longitude: -97 }; +latlong.UY = { latitude: -33, longitude: -56 }; +latlong.UZ = { latitude: 41, longitude: 64 }; +latlong.VA = { latitude: 41.9, longitude: 12.45 }; +latlong.VC = { latitude: 13.25, longitude: -61.2 }; +latlong.VE = { latitude: 8, longitude: -66 }; +latlong.VG = { latitude: 18.5, longitude: -64.5 }; +latlong.VI = { latitude: 18.3333, longitude: -64.8333 }; +latlong.VN = { latitude: 16, longitude: 106 }; +latlong.VU = { latitude: -16, longitude: 167 }; +latlong.WF = { latitude: -13.3, longitude: -176.2 }; +latlong.WS = { latitude: -13.5833, longitude: -172.3333 }; +latlong.YE = { latitude: 15, longitude: 48 }; +latlong.YT = { latitude: -12.8333, longitude: 45.1667 }; +latlong.ZA = { latitude: -29, longitude: 24 }; +latlong.ZM = { latitude: -15, longitude: 30 }; +latlong.ZW = { latitude: -20, longitude: 30 }; +var mapData = [ + { code: 'AF', name: 'Afghanistan', value: 32358260, color: '#eea638' }, + { code: 'AL', name: 'Albania', value: 3215988, color: '#d8854f' }, + { code: 'DZ', name: 'Algeria', value: 35980193, color: '#de4c4f' }, + { code: 'AO', name: 'Angola', value: 19618432, color: '#de4c4f' }, + { code: 'AR', name: 'Argentina', value: 40764561, color: '#86a965' }, + { code: 'AM', name: 'Armenia', value: 3100236, color: '#d8854f' }, + { code: 'AU', name: 'Australia', value: 22605732, color: '#8aabb0' }, + { code: 'AT', name: 'Austria', value: 8413429, color: '#d8854f' }, + { code: 'AZ', name: 'Azerbaijan', value: 9306023, color: '#d8854f' }, + { code: 'BH', name: 'Bahrain', value: 1323535, color: '#eea638' }, + { code: 'BD', name: 'Bangladesh', value: 150493658, color: '#eea638' }, + { code: 'BY', name: 'Belarus', value: 9559441, color: '#d8854f' }, + { code: 'BE', name: 'Belgium', value: 10754056, color: '#d8854f' }, + { code: 'BJ', name: 'Benin', value: 9099922, color: '#de4c4f' }, + { code: 'BT', name: 'Bhutan', value: 738267, color: '#eea638' }, + { code: 'BO', name: 'Bolivia', value: 10088108, color: '#86a965' }, + { + code: 'BA', + name: 'Bosnia and Herzegovina', + value: 3752228, + color: '#d8854f' + }, + { code: 'BW', name: 'Botswana', value: 2030738, color: '#de4c4f' }, + { code: 'BR', name: 'Brazil', value: 196655014, color: '#86a965' }, + { code: 'BN', name: 'Brunei', value: 405938, color: '#eea638' }, + { code: 'BG', name: 'Bulgaria', value: 7446135, color: '#d8854f' }, + { code: 'BF', name: 'Burkina Faso', value: 16967845, color: '#de4c4f' }, + { code: 'BI', name: 'Burundi', value: 8575172, color: '#de4c4f' }, + { code: 'KH', name: 'Cambodia', value: 14305183, color: '#eea638' }, + { code: 'CM', name: 'Cameroon', value: 20030362, color: '#de4c4f' }, + { code: 'CA', name: 'Canada', value: 34349561, color: '#a7a737' }, + { code: 'CV', name: 'Cape Verde', value: 500585, color: '#de4c4f' }, + { + code: 'CF', + name: 'Central African Rep.', + value: 4486837, + color: '#de4c4f' + }, + { code: 'TD', name: 'Chad', value: 11525496, color: '#de4c4f' }, + { code: 'CL', name: 'Chile', value: 17269525, color: '#86a965' }, + { code: 'CN', name: 'China', value: 1347565324, color: '#eea638' }, + { code: 'CO', name: 'Colombia', value: 46927125, color: '#86a965' }, + { code: 'KM', name: 'Comoros', value: 753943, color: '#de4c4f' }, + { code: 'CD', name: 'Congo, Dem. Rep.', value: 67757577, color: '#de4c4f' }, + { code: 'CG', name: 'Congo, Rep.', value: 4139748, color: '#de4c4f' }, + { code: 'CR', name: 'Costa Rica', value: 4726575, color: '#a7a737' }, + { code: 'CI', name: "Cote d'Ivoire", value: 20152894, color: '#de4c4f' }, + { code: 'HR', name: 'Croatia', value: 4395560, color: '#d8854f' }, + { code: 'CU', name: 'Cuba', value: 11253665, color: '#a7a737' }, + { code: 'CY', name: 'Cyprus', value: 1116564, color: '#d8854f' }, + { code: 'CZ', name: 'Czech Rep.', value: 10534293, color: '#d8854f' }, + { code: 'DK', name: 'Denmark', value: 5572594, color: '#d8854f' }, + { code: 'DJ', name: 'Djibouti', value: 905564, color: '#de4c4f' }, + { code: 'DO', name: 'Dominican Rep.', value: 10056181, color: '#a7a737' }, + { code: 'EC', name: 'Ecuador', value: 14666055, color: '#86a965' }, + { code: 'EG', name: 'Egypt', value: 82536770, color: '#de4c4f' }, + { code: 'SV', name: 'El Salvador', value: 6227491, color: '#a7a737' }, + { code: 'GQ', name: 'Equatorial Guinea', value: 720213, color: '#de4c4f' }, + { code: 'ER', name: 'Eritrea', value: 5415280, color: '#de4c4f' }, + { code: 'EE', name: 'Estonia', value: 1340537, color: '#d8854f' }, + { code: 'ET', name: 'Ethiopia', value: 84734262, color: '#de4c4f' }, + { code: 'FJ', name: 'Fiji', value: 868406, color: '#8aabb0' }, + { code: 'FI', name: 'Finland', value: 5384770, color: '#d8854f' }, + { code: 'FR', name: 'France', value: 63125894, color: '#d8854f' }, + { code: 'GA', name: 'Gabon', value: 1534262, color: '#de4c4f' }, + { code: 'GM', name: 'Gambia', value: 1776103, color: '#de4c4f' }, + { code: 'GE', name: 'Georgia', value: 4329026, color: '#d8854f' }, + { code: 'DE', name: 'Germany', value: 82162512, color: '#d8854f' }, + { code: 'GH', name: 'Ghana', value: 24965816, color: '#de4c4f' }, + { code: 'GR', name: 'Greece', value: 11390031, color: '#d8854f' }, + { code: 'GT', name: 'Guatemala', value: 14757316, color: '#a7a737' }, + { code: 'GN', name: 'Guinea', value: 10221808, color: '#de4c4f' }, + { code: 'GW', name: 'Guinea-Bissau', value: 1547061, color: '#de4c4f' }, + { code: 'GY', name: 'Guyana', value: 756040, color: '#86a965' }, + { code: 'HT', name: 'Haiti', value: 10123787, color: '#a7a737' }, + { code: 'HN', name: 'Honduras', value: 7754687, color: '#a7a737' }, + { code: 'HK', name: 'Hong Kong, China', value: 7122187, color: '#eea638' }, + { code: 'HU', name: 'Hungary', value: 9966116, color: '#d8854f' }, + { code: 'IS', name: 'Iceland', value: 324366, color: '#d8854f' }, + { code: 'IN', name: 'India', value: 1241491960, color: '#eea638' }, + { code: 'ID', name: 'Indonesia', value: 242325638, color: '#eea638' }, + { code: 'IR', name: 'Iran', value: 74798599, color: '#eea638' }, + { code: 'IQ', name: 'Iraq', value: 32664942, color: '#eea638' }, + { code: 'IE', name: 'Ireland', value: 4525802, color: '#d8854f' }, + { code: 'IL', name: 'Israel', value: 7562194, color: '#eea638' }, + { code: 'IT', name: 'Italy', value: 60788694, color: '#d8854f' }, + { code: 'JM', name: 'Jamaica', value: 2751273, color: '#a7a737' }, + { code: 'JP', name: 'Japan', value: 126497241, color: '#eea638' }, + { code: 'JO', name: 'Jordan', value: 6330169, color: '#eea638' }, + { code: 'KZ', name: 'Kazakhstan', value: 16206750, color: '#eea638' }, + { code: 'KE', name: 'Kenya', value: 41609728, color: '#de4c4f' }, + { code: 'KP', name: 'Korea, Dem. Rep.', value: 24451285, color: '#eea638' }, + { code: 'KR', name: 'Korea, Rep.', value: 48391343, color: '#eea638' }, + { code: 'KW', name: 'Kuwait', value: 2818042, color: '#eea638' }, + { code: 'KG', name: 'Kyrgyzstan', value: 5392580, color: '#eea638' }, + { code: 'LA', name: 'Laos', value: 6288037, color: '#eea638' }, + { code: 'LV', name: 'Latvia', value: 2243142, color: '#d8854f' }, + { code: 'LB', name: 'Lebanon', value: 4259405, color: '#eea638' }, + { code: 'LS', name: 'Lesotho', value: 2193843, color: '#de4c4f' }, + { code: 'LR', name: 'Liberia', value: 4128572, color: '#de4c4f' }, + { code: 'LY', name: 'Libya', value: 6422772, color: '#de4c4f' }, + { code: 'LT', name: 'Lithuania', value: 3307481, color: '#d8854f' }, + { code: 'LU', name: 'Luxembourg', value: 515941, color: '#d8854f' }, + { code: 'MK', name: 'Macedonia, FYR', value: 2063893, color: '#d8854f' }, + { code: 'MG', name: 'Madagascar', value: 21315135, color: '#de4c4f' }, + { code: 'MW', name: 'Malawi', value: 15380888, color: '#de4c4f' }, + { code: 'MY', name: 'Malaysia', value: 28859154, color: '#eea638' }, + { code: 'ML', name: 'Mali', value: 15839538, color: '#de4c4f' }, + { code: 'MR', name: 'Mauritania', value: 3541540, color: '#de4c4f' }, + { code: 'MU', name: 'Mauritius', value: 1306593, color: '#de4c4f' }, + { code: 'MX', name: 'Mexico', value: 114793341, color: '#a7a737' }, + { code: 'MD', name: 'Moldova', value: 3544864, color: '#d8854f' }, + { code: 'MN', name: 'Mongolia', value: 2800114, color: '#eea638' }, + { code: 'ME', name: 'Montenegro', value: 632261, color: '#d8854f' }, + { code: 'MA', name: 'Morocco', value: 32272974, color: '#de4c4f' }, + { code: 'MZ', name: 'Mozambique', value: 23929708, color: '#de4c4f' }, + { code: 'MM', name: 'Myanmar', value: 48336763, color: '#eea638' }, + { code: 'NA', name: 'Namibia', value: 2324004, color: '#de4c4f' }, + { code: 'NP', name: 'Nepal', value: 30485798, color: '#eea638' }, + { code: 'NL', name: 'Netherlands', value: 16664746, color: '#d8854f' }, + { code: 'NZ', name: 'New Zealand', value: 4414509, color: '#8aabb0' }, + { code: 'NI', name: 'Nicaragua', value: 5869859, color: '#a7a737' }, + { code: 'NE', name: 'Niger', value: 16068994, color: '#de4c4f' }, + { code: 'NG', name: 'Nigeria', value: 162470737, color: '#de4c4f' }, + { code: 'NO', name: 'Norway', value: 4924848, color: '#d8854f' }, + { code: 'OM', name: 'Oman', value: 2846145, color: '#eea638' }, + { code: 'PK', name: 'Pakistan', value: 176745364, color: '#eea638' }, + { code: 'PA', name: 'Panama', value: 3571185, color: '#a7a737' }, + { code: 'PG', name: 'Papua New Guinea', value: 7013829, color: '#8aabb0' }, + { code: 'PY', name: 'Paraguay', value: 6568290, color: '#86a965' }, + { code: 'PE', name: 'Peru', value: 29399817, color: '#86a965' }, + { code: 'PH', name: 'Philippines', value: 94852030, color: '#eea638' }, + { code: 'PL', name: 'Poland', value: 38298949, color: '#d8854f' }, + { code: 'PT', name: 'Portugal', value: 10689663, color: '#d8854f' }, + { code: 'PR', name: 'Puerto Rico', value: 3745526, color: '#a7a737' }, + { code: 'QA', name: 'Qatar', value: 1870041, color: '#eea638' }, + { code: 'RO', name: 'Romania', value: 21436495, color: '#d8854f' }, + { code: 'RU', name: 'Russia', value: 142835555, color: '#d8854f' }, + { code: 'RW', name: 'Rwanda', value: 10942950, color: '#de4c4f' }, + { code: 'SA', name: 'Saudi Arabia', value: 28082541, color: '#eea638' }, + { code: 'SN', name: 'Senegal', value: 12767556, color: '#de4c4f' }, + { code: 'RS', name: 'Serbia', value: 9853969, color: '#d8854f' }, + { code: 'SL', name: 'Sierra Leone', value: 5997486, color: '#de4c4f' }, + { code: 'SG', name: 'Singapore', value: 5187933, color: '#eea638' }, + { code: 'SK', name: 'Slovak Republic', value: 5471502, color: '#d8854f' }, + { code: 'SI', name: 'Slovenia', value: 2035012, color: '#d8854f' }, + { code: 'SB', name: 'Solomon Islands', value: 552267, color: '#8aabb0' }, + { code: 'SO', name: 'Somalia', value: 9556873, color: '#de4c4f' }, + { code: 'ZA', name: 'South Africa', value: 50459978, color: '#de4c4f' }, + { code: 'ES', name: 'Spain', value: 46454895, color: '#d8854f' }, + { code: 'LK', name: 'Sri Lanka', value: 21045394, color: '#eea638' }, + { code: 'SD', name: 'Sudan', value: 34735288, color: '#de4c4f' }, + { code: 'SR', name: 'Suriname', value: 529419, color: '#86a965' }, + { code: 'SZ', name: 'Swaziland', value: 1203330, color: '#de4c4f' }, + { code: 'SE', name: 'Sweden', value: 9440747, color: '#d8854f' }, + { code: 'CH', name: 'Switzerland', value: 7701690, color: '#d8854f' }, + { code: 'SY', name: 'Syria', value: 20766037, color: '#eea638' }, + { code: 'TW', name: 'Taiwan', value: 23072000, color: '#eea638' }, + { code: 'TJ', name: 'Tajikistan', value: 6976958, color: '#eea638' }, + { code: 'TZ', name: 'Tanzania', value: 46218486, color: '#de4c4f' }, + { code: 'TH', name: 'Thailand', value: 69518555, color: '#eea638' }, + { code: 'TG', name: 'Togo', value: 6154813, color: '#de4c4f' }, + { code: 'TT', name: 'Trinidad and Tobago', value: 1346350, color: '#a7a737' }, + { code: 'TN', name: 'Tunisia', value: 10594057, color: '#de4c4f' }, + { code: 'TR', name: 'Turkey', value: 73639596, color: '#d8854f' }, + { code: 'TM', name: 'Turkmenistan', value: 5105301, color: '#eea638' }, + { code: 'UG', name: 'Uganda', value: 34509205, color: '#de4c4f' }, + { code: 'UA', name: 'Ukraine', value: 45190180, color: '#d8854f' }, + { + code: 'AE', + name: 'United Arab Emirates', + value: 7890924, + color: '#eea638' + }, + { code: 'GB', name: 'United Kingdom', value: 62417431, color: '#d8854f' }, + { code: 'US', name: 'United States', value: 313085380, color: '#a7a737' }, + { code: 'UY', name: 'Uruguay', value: 3380008, color: '#86a965' }, + { code: 'UZ', name: 'Uzbekistan', value: 27760267, color: '#eea638' }, + { code: 'VE', name: 'Venezuela', value: 29436891, color: '#86a965' }, + { code: 'PS', name: 'West Bank and Gaza', value: 4152369, color: '#eea638' }, + { code: 'VN', name: 'Vietnam', value: 88791996, color: '#eea638' }, + { code: 'YE', name: 'Yemen, Rep.', value: 24799880, color: '#eea638' }, + { code: 'ZM', name: 'Zambia', value: 13474959, color: '#de4c4f' }, + { code: 'ZW', name: 'Zimbabwe', value: 12754378, color: '#de4c4f' } +]; +var max = -Infinity; +var min = Infinity; +mapData.forEach(function (itemOpt) { + if (itemOpt.value > max) { + max = itemOpt.value; + } + if (itemOpt.value < min) { + min = itemOpt.value; + } +}); +option = { + backgroundColor: '#404a59', + title: { + text: 'World Population (2011)', + subtext: 'From Gapminder', + left: 'center', + top: 'top', + textStyle: { + color: '#fff' + } + }, + tooltip: { + trigger: 'item', + formatter: function (params) { + var value = (params.value + '').split('.'); + value = + value[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g, '$1,') + + '.' + + value[1]; + return params.seriesName + '
' + params.name + ' : ' + value; + } + }, + visualMap: { + show: false, + min: 0, + max: max, + inRange: { + symbolSize: [6, 60] + } + }, + geo: { + name: 'World Population (2010)', + type: 'map', + map: 'world', + roam: true, + emphasis: { + label: { + show: false + }, + itemStyle: { + areaColor: '#2a333d' + } + }, + itemStyle: { + areaColor: '#323c48', + borderColor: '#111' + } + }, + series: [ + { + type: 'scatter', + coordinateSystem: 'geo', + data: mapData.map(function (itemOpt) { + return { + name: itemOpt.name, + value: [ + latlong[itemOpt.code].longitude, + latlong[itemOpt.code].latitude, + itemOpt.value + ], + emphasis: { + label: { + position: 'right', + show: true + } + }, + itemStyle: { + color: itemOpt.color + } + }; + }) + } + ] +}; diff --git a/testdata/sunburst-book.js b/testdata/sunburst-book.js new file mode 100644 index 0000000..64ba015 --- /dev/null +++ b/testdata/sunburst-book.js @@ -0,0 +1,436 @@ +/* +title: Book Records +category: sunburst +titleCN: 书籍分布 +shotWidth: 820 +difficulty: 6 +*/ +const colors = ['#FFAE57', '#FF7853', '#EA5151', '#CC3F57', '#9A2555']; +const bgColor = '#2E2733'; +const itemStyle = { + star5: { + color: colors[0] + }, + star4: { + color: colors[1] + }, + star3: { + color: colors[2] + }, + star2: { + color: colors[3] + } +}; +const data = [ + { + name: '虚构', + itemStyle: { + color: colors[1] + }, + children: [ + { + name: '小说', + children: [ + { + name: '5☆', + children: [ + { + name: '疼' + }, + { + name: '慈悲' + }, + { + name: '楼下的房客' + } + ] + }, + { + name: '4☆', + children: [ + { + name: '虚无的十字架' + }, + { + name: '无声告白' + }, + { + name: '童年的终结' + } + ] + }, + { + name: '3☆', + children: [ + { + name: '疯癫老人日记' + } + ] + } + ] + }, + { + name: '其他', + children: [ + { + name: '5☆', + children: [ + { + name: '纳博科夫短篇小说全集' + } + ] + }, + { + name: '4☆', + children: [ + { + name: '安魂曲' + }, + { + name: '人生拼图版' + } + ] + }, + { + name: '3☆', + children: [ + { + name: '比起爱你,我更需要你' + } + ] + } + ] + } + ] + }, + { + name: '非虚构', + itemStyle: { + color: colors[2] + }, + children: [ + { + name: '设计', + children: [ + { + name: '5☆', + children: [ + { + name: '无界面交互' + } + ] + }, + { + name: '4☆', + children: [ + { + name: '数字绘图的光照与渲染技术' + }, + { + name: '日本建筑解剖书' + } + ] + }, + { + name: '3☆', + children: [ + { + name: '奇幻世界艺术\n&RPG地图绘制讲座' + } + ] + } + ] + }, + { + name: '社科', + children: [ + { + name: '5☆', + children: [ + { + name: '痛点' + } + ] + }, + { + name: '4☆', + children: [ + { + name: '卓有成效的管理者' + }, + { + name: '进化' + }, + { + name: '后物欲时代的来临' + } + ] + }, + { + name: '3☆', + children: [ + { + name: '疯癫与文明' + } + ] + } + ] + }, + { + name: '心理', + children: [ + { + name: '5☆', + children: [ + { + name: '我们时代的神经症人格' + } + ] + }, + { + name: '4☆', + children: [ + { + name: '皮格马利翁效应' + }, + { + name: '受伤的人' + } + ] + }, + { + name: '3☆' + }, + { + name: '2☆', + children: [ + { + name: '迷恋' + } + ] + } + ] + }, + { + name: '居家', + children: [ + { + name: '4☆', + children: [ + { + name: '把房子住成家' + }, + { + name: '只过必要生活' + }, + { + name: '北欧简约风格' + } + ] + } + ] + }, + { + name: '绘本', + children: [ + { + name: '5☆', + children: [ + { + name: '设计诗' + } + ] + }, + { + name: '4☆', + children: [ + { + name: '假如生活糊弄了你' + }, + { + name: '博物学家的神秘动物图鉴' + } + ] + }, + { + name: '3☆', + children: [ + { + name: '方向' + } + ] + } + ] + }, + { + name: '哲学', + children: [ + { + name: '4☆', + children: [ + { + name: '人生的智慧' + } + ] + } + ] + }, + { + name: '技术', + children: [ + { + name: '5☆', + children: [ + { + name: '代码整洁之道' + } + ] + }, + { + name: '4☆', + children: [ + { + name: 'Three.js 开发指南' + } + ] + } + ] + } + ] + } +]; +for (let j = 0; j < data.length; ++j) { + let level1 = data[j].children; + for (let i = 0; i < level1.length; ++i) { + let block = level1[i].children; + let bookScore = []; + let bookScoreId; + for (let star = 0; star < block.length; ++star) { + let style = (function (name) { + switch (name) { + case '5☆': + bookScoreId = 0; + return itemStyle.star5; + case '4☆': + bookScoreId = 1; + return itemStyle.star4; + case '3☆': + bookScoreId = 2; + return itemStyle.star3; + case '2☆': + bookScoreId = 3; + return itemStyle.star2; + } + })(block[star].name); + block[star].label = { + color: style.color, + downplay: { + opacity: 0.5 + } + }; + if (block[star].children) { + style = { + opacity: 1, + color: style.color + }; + block[star].children.forEach(function (book) { + book.value = 1; + book.itemStyle = style; + book.label = { + color: style.color + }; + let value = 1; + if (bookScoreId === 0 || bookScoreId === 3) { + value = 5; + } + if (bookScore[bookScoreId]) { + bookScore[bookScoreId].value += value; + } + else { + bookScore[bookScoreId] = { + color: colors[bookScoreId], + value: value + }; + } + }); + } + } + level1[i].itemStyle = { + color: data[j].itemStyle.color + }; + } +} +option = { + backgroundColor: bgColor, + color: colors, + series: [ + { + type: 'sunburst', + center: ['50%', '48%'], + data: data, + sort: function (a, b) { + if (a.depth === 1) { + return b.getValue() - a.getValue(); + } + else { + return a.dataIndex - b.dataIndex; + } + }, + label: { + rotate: 'radial', + color: bgColor + }, + itemStyle: { + borderColor: bgColor, + borderWidth: 2 + }, + levels: [ + {}, + { + r0: 0, + r: 40, + label: { + rotate: 0 + } + }, + { + r0: 40, + r: 105 + }, + { + r0: 115, + r: 140, + itemStyle: { + shadowBlur: 2, + shadowColor: colors[2], + color: 'transparent' + }, + label: { + rotate: 'tangential', + fontSize: 10, + color: colors[0] + } + }, + { + r0: 140, + r: 145, + itemStyle: { + shadowBlur: 80, + shadowColor: colors[0] + }, + label: { + position: 'outside', + textShadowBlur: 5, + textShadowColor: '#333' + }, + downplay: { + label: { + opacity: 0.5 + } + } + } + ] + } + ] +}; +export {}; diff --git a/testdata/sunburst-book.js.svg b/testdata/sunburst-book.js.svg new file mode 100644 index 0000000..be8429f --- /dev/null +++ b/testdata/sunburst-book.js.svg @@ -0,0 +1,871 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +非虚构 +社科 +4☆ +卓有成效的管理者 +进化 +后物欲时代的来临 +5☆ +痛点 +3☆ +疯癫与文明 +设计 +4☆ +数字绘图的光照与渲染技术 +日本建筑解剖书 +5☆ +无界面交互 +3☆ +奇幻世界艺术 +&RPG地图绘制讲座 +心理 +4☆ +皮格马利翁效应 +受伤的人 +5☆ +我们时代的神经症人格 +2☆ +迷恋 +绘本 +4☆ +假如生活糊弄了你 +博物学家的神秘动物图鉴 +5☆ +设计诗 +3☆ +方向 +居家 +4☆ +把房子住成家 +只过必要生活 +北欧简约风格 +技术 +5☆ +代码整洁之道 +4☆ +Three.js 开发指南 +哲学 +4☆ +人生的智慧 +虚构 +小说 +5☆ + +慈悲 +楼下的房客 +4☆ +虚无的十字架 +无声告白 +童年的终结 +3☆ +疯癫老人日记 +其他 +4☆ +安魂曲 +人生拼图版 +5☆ +纳博科夫短篇小说全集 +3☆ +比起爱你,我更需要你 + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/sunburst-borderRadius.js b/testdata/sunburst-borderRadius.js new file mode 100644 index 0000000..8cceeb9 --- /dev/null +++ b/testdata/sunburst-borderRadius.js @@ -0,0 +1,84 @@ +/* +title: Sunburst with Rounded Corner +category: sunburst +titleCN: 圆角旭日图 +difficulty: 2 +*/ +var data = [ + { + name: 'Grandpa', + children: [ + { + name: 'Uncle Leo', + value: 15, + children: [ + { + name: 'Cousin Jack', + value: 2 + }, + { + name: 'Cousin Mary', + value: 5, + children: [ + { + name: 'Jackson', + value: 2 + } + ] + }, + { + name: 'Cousin Ben', + value: 4 + } + ] + }, + { + name: 'Father', + value: 10, + children: [ + { + name: 'Me', + value: 5 + }, + { + name: 'Brother Peter', + value: 1 + } + ] + } + ] + }, + { + name: 'Nancy', + children: [ + { + name: 'Uncle Nike', + children: [ + { + name: 'Cousin Betty', + value: 1 + }, + { + name: 'Cousin Jenny', + value: 2 + } + ] + } + ] + } +]; +option = { + series: { + type: 'sunburst', + data: data, + radius: [60, '90%'], + itemStyle: { + borderRadius: 7, + borderWidth: 2 + }, + label: { + show: false + } + } +}; +export {}; diff --git a/testdata/sunburst-borderRadius.js.svg b/testdata/sunburst-borderRadius.js.svg new file mode 100644 index 0000000..57df2f4 --- /dev/null +++ b/testdata/sunburst-borderRadius.js.svg @@ -0,0 +1,16 @@ + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/sunburst-drink.js b/testdata/sunburst-drink.js new file mode 100644 index 0000000..f0e35c3 --- /dev/null +++ b/testdata/sunburst-drink.js @@ -0,0 +1,860 @@ +/* +title: Drink Flavors +category: sunburst +titleCN: Drink Flavors +shotWidth: 1000 +difficulty: 5 +*/ +var data = [ + { + name: 'Flora', + itemStyle: { + color: '#da0d68' + }, + children: [ + { + name: 'Black Tea', + value: 1, + itemStyle: { + color: '#975e6d' + } + }, + { + name: 'Floral', + itemStyle: { + color: '#e0719c' + }, + children: [ + { + name: 'Chamomile', + value: 1, + itemStyle: { + color: '#f99e1c' + } + }, + { + name: 'Rose', + value: 1, + itemStyle: { + color: '#ef5a78' + } + }, + { + name: 'Jasmine', + value: 1, + itemStyle: { + color: '#f7f1bd' + } + } + ] + } + ] + }, + { + name: 'Fruity', + itemStyle: { + color: '#da1d23' + }, + children: [ + { + name: 'Berry', + itemStyle: { + color: '#dd4c51' + }, + children: [ + { + name: 'Blackberry', + value: 1, + itemStyle: { + color: '#3e0317' + } + }, + { + name: 'Raspberry', + value: 1, + itemStyle: { + color: '#e62969' + } + }, + { + name: 'Blueberry', + value: 1, + itemStyle: { + color: '#6569b0' + } + }, + { + name: 'Strawberry', + value: 1, + itemStyle: { + color: '#ef2d36' + } + } + ] + }, + { + name: 'Dried Fruit', + itemStyle: { + color: '#c94a44' + }, + children: [ + { + name: 'Raisin', + value: 1, + itemStyle: { + color: '#b53b54' + } + }, + { + name: 'Prune', + value: 1, + itemStyle: { + color: '#a5446f' + } + } + ] + }, + { + name: 'Other Fruit', + itemStyle: { + color: '#dd4c51' + }, + children: [ + { + name: 'Coconut', + value: 1, + itemStyle: { + color: '#f2684b' + } + }, + { + name: 'Cherry', + value: 1, + itemStyle: { + color: '#e73451' + } + }, + { + name: 'Pomegranate', + value: 1, + itemStyle: { + color: '#e65656' + } + }, + { + name: 'Pineapple', + value: 1, + itemStyle: { + color: '#f89a1c' + } + }, + { + name: 'Grape', + value: 1, + itemStyle: { + color: '#aeb92c' + } + }, + { + name: 'Apple', + value: 1, + itemStyle: { + color: '#4eb849' + } + }, + { + name: 'Peach', + value: 1, + itemStyle: { + color: '#f68a5c' + } + }, + { + name: 'Pear', + value: 1, + itemStyle: { + color: '#baa635' + } + } + ] + }, + { + name: 'Citrus Fruit', + itemStyle: { + color: '#f7a128' + }, + children: [ + { + name: 'Grapefruit', + value: 1, + itemStyle: { + color: '#f26355' + } + }, + { + name: 'Orange', + value: 1, + itemStyle: { + color: '#e2631e' + } + }, + { + name: 'Lemon', + value: 1, + itemStyle: { + color: '#fde404' + } + }, + { + name: 'Lime', + value: 1, + itemStyle: { + color: '#7eb138' + } + } + ] + } + ] + }, + { + name: 'Sour/\nFermented', + itemStyle: { + color: '#ebb40f' + }, + children: [ + { + name: 'Sour', + itemStyle: { + color: '#e1c315' + }, + children: [ + { + name: 'Sour Aromatics', + value: 1, + itemStyle: { + color: '#9ea718' + } + }, + { + name: 'Acetic Acid', + value: 1, + itemStyle: { + color: '#94a76f' + } + }, + { + name: 'Butyric Acid', + value: 1, + itemStyle: { + color: '#d0b24f' + } + }, + { + name: 'Isovaleric Acid', + value: 1, + itemStyle: { + color: '#8eb646' + } + }, + { + name: 'Citric Acid', + value: 1, + itemStyle: { + color: '#faef07' + } + }, + { + name: 'Malic Acid', + value: 1, + itemStyle: { + color: '#c1ba07' + } + } + ] + }, + { + name: 'Alcohol/\nFremented', + itemStyle: { + color: '#b09733' + }, + children: [ + { + name: 'Winey', + value: 1, + itemStyle: { + color: '#8f1c53' + } + }, + { + name: 'Whiskey', + value: 1, + itemStyle: { + color: '#b34039' + } + }, + { + name: 'Fremented', + value: 1, + itemStyle: { + color: '#ba9232' + } + }, + { + name: 'Overripe', + value: 1, + itemStyle: { + color: '#8b6439' + } + } + ] + } + ] + }, + { + name: 'Green/\nVegetative', + itemStyle: { + color: '#187a2f' + }, + children: [ + { + name: 'Olive Oil', + value: 1, + itemStyle: { + color: '#a2b029' + } + }, + { + name: 'Raw', + value: 1, + itemStyle: { + color: '#718933' + } + }, + { + name: 'Green/\nVegetative', + itemStyle: { + color: '#3aa255' + }, + children: [ + { + name: 'Under-ripe', + value: 1, + itemStyle: { + color: '#a2bb2b' + } + }, + { + name: 'Peapod', + value: 1, + itemStyle: { + color: '#62aa3c' + } + }, + { + name: 'Fresh', + value: 1, + itemStyle: { + color: '#03a653' + } + }, + { + name: 'Dark Green', + value: 1, + itemStyle: { + color: '#038549' + } + }, + { + name: 'Vegetative', + value: 1, + itemStyle: { + color: '#28b44b' + } + }, + { + name: 'Hay-like', + value: 1, + itemStyle: { + color: '#a3a830' + } + }, + { + name: 'Herb-like', + value: 1, + itemStyle: { + color: '#7ac141' + } + } + ] + }, + { + name: 'Beany', + value: 1, + itemStyle: { + color: '#5e9a80' + } + } + ] + }, + { + name: 'Other', + itemStyle: { + color: '#0aa3b5' + }, + children: [ + { + name: 'Papery/Musty', + itemStyle: { + color: '#9db2b7' + }, + children: [ + { + name: 'Stale', + value: 1, + itemStyle: { + color: '#8b8c90' + } + }, + { + name: 'Cardboard', + value: 1, + itemStyle: { + color: '#beb276' + } + }, + { + name: 'Papery', + value: 1, + itemStyle: { + color: '#fefef4' + } + }, + { + name: 'Woody', + value: 1, + itemStyle: { + color: '#744e03' + } + }, + { + name: 'Moldy/Damp', + value: 1, + itemStyle: { + color: '#a3a36f' + } + }, + { + name: 'Musty/Dusty', + value: 1, + itemStyle: { + color: '#c9b583' + } + }, + { + name: 'Musty/Earthy', + value: 1, + itemStyle: { + color: '#978847' + } + }, + { + name: 'Animalic', + value: 1, + itemStyle: { + color: '#9d977f' + } + }, + { + name: 'Meaty Brothy', + value: 1, + itemStyle: { + color: '#cc7b6a' + } + }, + { + name: 'Phenolic', + value: 1, + itemStyle: { + color: '#db646a' + } + } + ] + }, + { + name: 'Chemical', + itemStyle: { + color: '#76c0cb' + }, + children: [ + { + name: 'Bitter', + value: 1, + itemStyle: { + color: '#80a89d' + } + }, + { + name: 'Salty', + value: 1, + itemStyle: { + color: '#def2fd' + } + }, + { + name: 'Medicinal', + value: 1, + itemStyle: { + color: '#7a9bae' + } + }, + { + name: 'Petroleum', + value: 1, + itemStyle: { + color: '#039fb8' + } + }, + { + name: 'Skunky', + value: 1, + itemStyle: { + color: '#5e777b' + } + }, + { + name: 'Rubber', + value: 1, + itemStyle: { + color: '#120c0c' + } + } + ] + } + ] + }, + { + name: 'Roasted', + itemStyle: { + color: '#c94930' + }, + children: [ + { + name: 'Pipe Tobacco', + value: 1, + itemStyle: { + color: '#caa465' + } + }, + { + name: 'Tobacco', + value: 1, + itemStyle: { + color: '#dfbd7e' + } + }, + { + name: 'Burnt', + itemStyle: { + color: '#be8663' + }, + children: [ + { + name: 'Acrid', + value: 1, + itemStyle: { + color: '#b9a449' + } + }, + { + name: 'Ashy', + value: 1, + itemStyle: { + color: '#899893' + } + }, + { + name: 'Smoky', + value: 1, + itemStyle: { + color: '#a1743b' + } + }, + { + name: 'Brown, Roast', + value: 1, + itemStyle: { + color: '#894810' + } + } + ] + }, + { + name: 'Cereal', + itemStyle: { + color: '#ddaf61' + }, + children: [ + { + name: 'Grain', + value: 1, + itemStyle: { + color: '#b7906f' + } + }, + { + name: 'Malt', + value: 1, + itemStyle: { + color: '#eb9d5f' + } + } + ] + } + ] + }, + { + name: 'Spices', + itemStyle: { + color: '#ad213e' + }, + children: [ + { + name: 'Pungent', + value: 1, + itemStyle: { + color: '#794752' + } + }, + { + name: 'Pepper', + value: 1, + itemStyle: { + color: '#cc3d41' + } + }, + { + name: 'Brown Spice', + itemStyle: { + color: '#b14d57' + }, + children: [ + { + name: 'Anise', + value: 1, + itemStyle: { + color: '#c78936' + } + }, + { + name: 'Nutmeg', + value: 1, + itemStyle: { + color: '#8c292c' + } + }, + { + name: 'Cinnamon', + value: 1, + itemStyle: { + color: '#e5762e' + } + }, + { + name: 'Clove', + value: 1, + itemStyle: { + color: '#a16c5a' + } + } + ] + } + ] + }, + { + name: 'Nutty/\nCocoa', + itemStyle: { + color: '#a87b64' + }, + children: [ + { + name: 'Nutty', + itemStyle: { + color: '#c78869' + }, + children: [ + { + name: 'Peanuts', + value: 1, + itemStyle: { + color: '#d4ad12' + } + }, + { + name: 'Hazelnut', + value: 1, + itemStyle: { + color: '#9d5433' + } + }, + { + name: 'Almond', + value: 1, + itemStyle: { + color: '#c89f83' + } + } + ] + }, + { + name: 'Cocoa', + itemStyle: { + color: '#bb764c' + }, + children: [ + { + name: 'Chocolate', + value: 1, + itemStyle: { + color: '#692a19' + } + }, + { + name: 'Dark Chocolate', + value: 1, + itemStyle: { + color: '#470604' + } + } + ] + } + ] + }, + { + name: 'Sweet', + itemStyle: { + color: '#e65832' + }, + children: [ + { + name: 'Brown Sugar', + itemStyle: { + color: '#d45a59' + }, + children: [ + { + name: 'Molasses', + value: 1, + itemStyle: { + color: '#310d0f' + } + }, + { + name: 'Maple Syrup', + value: 1, + itemStyle: { + color: '#ae341f' + } + }, + { + name: 'Caramelized', + value: 1, + itemStyle: { + color: '#d78823' + } + }, + { + name: 'Honey', + value: 1, + itemStyle: { + color: '#da5c1f' + } + } + ] + }, + { + name: 'Vanilla', + value: 1, + itemStyle: { + color: '#f89a80' + } + }, + { + name: 'Vanillin', + value: 1, + itemStyle: { + color: '#f37674' + } + }, + { + name: 'Overall Sweet', + value: 1, + itemStyle: { + color: '#e75b68' + } + }, + { + name: 'Sweet Aromatics', + value: 1, + itemStyle: { + color: '#d0545f' + } + } + ] + } +]; +option = { + title: { + text: 'WORLD COFFEE RESEARCH SENSORY LEXICON', + subtext: 'Source: https://worldcoffeeresearch.org/work/sensory-lexicon/', + textStyle: { + fontSize: 14, + align: 'center' + }, + subtextStyle: { + align: 'center' + }, + sublink: 'https://worldcoffeeresearch.org/work/sensory-lexicon/' + }, + series: { + type: 'sunburst', + data: data, + radius: [0, '95%'], + sort: undefined, + emphasis: { + focus: 'ancestor' + }, + levels: [ + {}, + { + r0: '15%', + r: '35%', + itemStyle: { + borderWidth: 2 + }, + label: { + rotate: 'tangential' + } + }, + { + r0: '35%', + r: '70%', + label: { + align: 'right' + } + }, + { + r0: '70%', + r: '72%', + label: { + position: 'outside', + padding: 3, + silent: false + }, + itemStyle: { + borderWidth: 3 + } + } + ] + } +}; +export {}; diff --git a/testdata/sunburst-drink.js.svg b/testdata/sunburst-drink.js.svg new file mode 100644 index 0000000..d38354b --- /dev/null +++ b/testdata/sunburst-drink.js.svg @@ -0,0 +1,1445 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Fruity +Other Fruit +Coconut +Cherry +Pomegranate +Pineapple +Grape +Apple +Peach +Pear +Berry +Blackberry +Raspberry +Blueberry +Strawberry +Citrus Fruit +Grapefruit +Orange +Lemon +Lime +Dried Fruit +Raisin +Prune +Other +Papery/Musty +Stale +Cardboard +Papery +Woody +Moldy/Damp +Musty/Dusty +Musty/Earthy +Animalic +Meaty Brothy +Phenolic +Chemical +Bitter +Salty +Medicinal +Petroleum +Skunky +Rubber +Sour/ +Fermented +Sour +Sour Aromatics +Acetic Acid +Butyric Acid +Isovaleric Acid +Citric Acid +Malic Acid +Alcohol/ +Fremented +Winey +Whiskey +Fremented +Overripe +Green/ +Vegetative +Green/ +Vegetative +Under-ripe +Peapod +Fresh +Dark Green +Vegetative +Hay-like +Herb-like +Olive Oil +Raw +Beany +Roasted +Burnt +Acrid +Ashy +Smoky +Brown, Roast +Cereal +Grain +Malt +Pipe Tobacco +Tobacco +Sweet +Brown Sugar +Molasses +Maple Syrup +Caramelized +Honey +Vanilla +Vanillin +Overall Sweet +Sweet Aromatics +Spices +Brown Spice +Anise +Nutmeg +Cinnamon +Clove +Pungent +Pepper +Nutty/ +Cocoa +Nutty +Peanuts +Hazelnut +Almond +Cocoa +Chocolate +Dark Chocolate +Flora +Floral +Chamomile +Rose +Jasmine +Black Tea + +WORLD COFFEE RESEARCH SENSORY LEXICON +Source: https://worldcoffeeresearch.org/work/sensory-lexicon/ + + \ No newline at end of file diff --git a/testdata/sunburst-label-rotate.js b/testdata/sunburst-label-rotate.js new file mode 100644 index 0000000..7e887bf --- /dev/null +++ b/testdata/sunburst-label-rotate.js @@ -0,0 +1,128 @@ +/* +title: Sunburst Label Rotate +category: sunburst +titleCN: 旭日图标签旋转 +difficulty: 2 +*/ +option = { + silent: true, + series: [ + { + radius: ['15%', '80%'], + type: 'sunburst', + sort: undefined, + emphasis: { + focus: 'ancestor' + }, + data: [ + { + value: 8, + children: [ + { + value: 4, + children: [ + { + value: 2 + }, + { + value: 1 + }, + { + value: 1 + }, + { + value: 0.5 + } + ] + }, + { + value: 2 + } + ] + }, + { + value: 4, + children: [ + { + children: [ + { + value: 2 + } + ] + } + ] + }, + { + value: 4, + children: [ + { + children: [ + { + value: 2 + } + ] + } + ] + }, + { + value: 3, + children: [ + { + children: [ + { + value: 1 + } + ] + } + ] + } + ], + label: { + color: '#000', + textBorderColor: '#fff', + textBorderWidth: 2, + formatter: function (param) { + var depth = param.treePathInfo.length; + if (depth === 2) { + return 'radial'; + } + else if (depth === 3) { + return 'tangential'; + } + else if (depth === 4) { + return '0'; + } + return ''; + } + }, + levels: [ + {}, + { + itemStyle: { + color: '#CD4949' + }, + label: { + rotate: 'radial' + } + }, + { + itemStyle: { + color: '#F47251' + }, + label: { + rotate: 'tangential' + } + }, + { + itemStyle: { + color: '#FFC75F' + }, + label: { + rotate: 0 + } + } + ] + } + ] +}; +export {}; diff --git a/testdata/sunburst-label-rotate.js.svg b/testdata/sunburst-label-rotate.js.svg new file mode 100644 index 0000000..898d235 --- /dev/null +++ b/testdata/sunburst-label-rotate.js.svg @@ -0,0 +1,199 @@ + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/sunburst-monochrome.js b/testdata/sunburst-monochrome.js new file mode 100644 index 0000000..56993b7 --- /dev/null +++ b/testdata/sunburst-monochrome.js @@ -0,0 +1,242 @@ +/* +title: Monochrome Sunburst +category: sunburst +titleCN: Monochrome Sunburst +difficulty: 3 +*/ +const item1 = { + color: '#F54F4A' +}; +const item2 = { + color: '#FF8C75' +}; +const item3 = { + color: '#FFB499' +}; +const data = [ + { + children: [ + { + value: 5, + children: [ + { + value: 1, + itemStyle: item1 + }, + { + value: 2, + children: [ + { + value: 1, + itemStyle: item2 + } + ] + }, + { + children: [ + { + value: 1 + } + ] + } + ], + itemStyle: item1 + }, + { + value: 10, + children: [ + { + value: 6, + children: [ + { + value: 1, + itemStyle: item1 + }, + { + value: 1 + }, + { + value: 1, + itemStyle: item2 + }, + { + value: 1 + } + ], + itemStyle: item3 + }, + { + value: 2, + children: [ + { + value: 1 + } + ], + itemStyle: item3 + }, + { + children: [ + { + value: 1, + itemStyle: item2 + } + ] + } + ], + itemStyle: item1 + } + ], + itemStyle: item1 + }, + { + value: 9, + children: [ + { + value: 4, + children: [ + { + value: 2, + itemStyle: item2 + }, + { + children: [ + { + value: 1, + itemStyle: item1 + } + ] + } + ], + itemStyle: item1 + }, + { + children: [ + { + value: 3, + children: [ + { + value: 1 + }, + { + value: 1, + itemStyle: item2 + } + ] + } + ], + itemStyle: item3 + } + ], + itemStyle: item2 + }, + { + value: 7, + children: [ + { + children: [ + { + value: 1, + itemStyle: item3 + }, + { + value: 3, + children: [ + { + value: 1, + itemStyle: item2 + }, + { + value: 1 + } + ], + itemStyle: item2 + }, + { + value: 2, + children: [ + { + value: 1 + }, + { + value: 1, + itemStyle: item1 + } + ], + itemStyle: item1 + } + ], + itemStyle: item3 + } + ], + itemStyle: item1 + }, + { + children: [ + { + value: 6, + children: [ + { + value: 1, + itemStyle: item2 + }, + { + value: 2, + children: [ + { + value: 2, + itemStyle: item2 + } + ], + itemStyle: item1 + }, + { + value: 1, + itemStyle: item3 + } + ], + itemStyle: item3 + }, + { + value: 3, + children: [ + { + value: 1 + }, + { + children: [ + { + value: 1, + itemStyle: item2 + } + ] + }, + { + value: 1 + } + ], + itemStyle: item3 + } + ], + itemStyle: item1 + } +]; +option = { + series: { + radius: ['15%', '80%'], + type: 'sunburst', + sort: undefined, + emphasis: { + focus: 'ancestor' + }, + data: data, + label: { + rotate: 'radial' + }, + levels: [], + itemStyle: { + color: '#ddd', + borderWidth: 2 + } + } +}; +export {}; diff --git a/testdata/sunburst-monochrome.js.svg b/testdata/sunburst-monochrome.js.svg new file mode 100644 index 0000000..65133b7 --- /dev/null +++ b/testdata/sunburst-monochrome.js.svg @@ -0,0 +1,559 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/sunburst-simple.js b/testdata/sunburst-simple.js new file mode 100644 index 0000000..ca13f3d --- /dev/null +++ b/testdata/sunburst-simple.js @@ -0,0 +1,83 @@ +/* +title: Basic Sunburst +category: sunburst +titleCN: 基础旭日图 +difficulty: 1 +*/ +var data = [ + { + name: 'Grandpa', + children: [ + { + name: 'Uncle Leo', + value: 15, + children: [ + { + name: 'Cousin Jack', + value: 2 + }, + { + name: 'Cousin Mary', + value: 5, + children: [ + { + name: 'Jackson', + value: 2 + } + ] + }, + { + name: 'Cousin Ben', + value: 4 + } + ] + }, + { + name: 'Father', + value: 10, + children: [ + { + name: 'Me', + value: 5 + }, + { + name: 'Brother Peter', + value: 1 + } + ] + } + ] + }, + { + name: 'Nancy', + children: [ + { + name: 'Uncle Nike', + children: [ + { + name: 'Cousin Betty', + value: 1 + }, + { + name: 'Cousin Jenny', + value: 2 + } + ] + } + ] + } +]; +option = { + series: { + type: 'sunburst', + // emphasis: { + // focus: 'ancestor' + // }, + data: data, + radius: [0, '90%'], + label: { + rotate: 'radial' + } + } +}; +export {}; diff --git a/testdata/sunburst-simple.js.svg b/testdata/sunburst-simple.js.svg new file mode 100644 index 0000000..1cab8ed --- /dev/null +++ b/testdata/sunburst-simple.js.svg @@ -0,0 +1,154 @@ + + + + + + + + + + + + + + + +Grandpa +Uncle Leo +Cousin Mary +Jackson +Cousin Ben +Cousin Jack +Father +Me +Brother Peter +Nancy +Uncle Nike +Cousin Jenny +Cousin Betty + + \ No newline at end of file diff --git a/testdata/sunburst-visualMap.js b/testdata/sunburst-visualMap.js new file mode 100644 index 0000000..59700ad --- /dev/null +++ b/testdata/sunburst-visualMap.js @@ -0,0 +1,124 @@ +/* +title: Sunburst VisualMap +category: sunburst +titleCN: 旭日图使用视觉编码 +difficulty: 4 +*/ +var data = [ + { + name: 'Grandpa', + children: [ + { + name: 'Uncle Leo', + value: 15, + children: [ + { + name: 'Cousin Jack', + value: 2 + }, + { + name: 'Cousin Mary', + value: 5, + children: [ + { + name: 'Jackson', + value: 2 + } + ] + }, + { + name: 'Cousin Ben', + value: 4 + } + ] + }, + { + name: 'Aunt Jane', + children: [ + { + name: 'Cousin Kate', + value: 4 + } + ] + }, + { + name: 'Father', + value: 10, + children: [ + { + name: 'Me', + value: 5, + itemStyle: { + color: 'red' + } + }, + { + name: 'Brother Peter', + value: 1 + } + ] + } + ] + }, + { + name: 'Mike', + children: [ + { + name: 'Uncle Dan', + children: [ + { + name: 'Cousin Lucy', + value: 3 + }, + { + name: 'Cousin Luck', + value: 4, + children: [ + { + name: 'Nephew', + value: 2 + } + ] + } + ] + } + ] + }, + { + name: 'Nancy', + children: [ + { + name: 'Uncle Nike', + children: [ + { + name: 'Cousin Betty', + value: 1 + }, + { + name: 'Cousin Jenny', + value: 2 + } + ] + } + ] + } +]; +option = { + visualMap: { + type: 'continuous', + min: 0, + max: 10, + inRange: { + color: ['#2F93C8', '#AEC48F', '#FFDB5C', '#F98862'] + } + }, + series: { + type: 'sunburst', + data: data, + radius: [0, '90%'], + label: { + rotate: 'radial' + } + } +}; +export {}; diff --git a/testdata/sunburst-visualMap.js.svg b/testdata/sunburst-visualMap.js.svg new file mode 100644 index 0000000..8a232dd --- /dev/null +++ b/testdata/sunburst-visualMap.js.svg @@ -0,0 +1,450 @@ + + + + + + + + + + + + + + + + + + + + + + +Grandpa +Uncle Leo +Cousin Mary +Jackson +Cousin Ben +Cousin Jack +Father +Me +Brother Peter +Aunt Jane +Cousin Kate +Mike +Uncle Dan +Cousin Luck +Nephew +Cousin Lucy +Nancy +Uncle Nike +Cousin Jenny +Cousin Betty + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/themeRiver-basic.js b/testdata/themeRiver-basic.js new file mode 100644 index 0000000..4d55d53 --- /dev/null +++ b/testdata/themeRiver-basic.js @@ -0,0 +1,181 @@ +/* +title: ThemeRiver +category: themeRiver +titleCN: 主题河流图 +*/ +option = { + tooltip: { + trigger: 'axis', + axisPointer: { + type: 'line', + lineStyle: { + color: 'rgba(0,0,0,0.2)', + width: 1, + type: 'solid' + } + } + }, + legend: { + data: ['DQ', 'TY', 'SS', 'QG', 'SY', 'DD'] + }, + singleAxis: { + top: 50, + bottom: 50, + axisTick: {}, + axisLabel: {}, + type: 'time', + axisPointer: { + animation: true, + label: { + show: true + } + }, + splitLine: { + show: true, + lineStyle: { + type: 'dashed', + opacity: 0.2 + } + } + }, + series: [ + { + type: 'themeRiver', + emphasis: { + itemStyle: { + shadowBlur: 20, + shadowColor: 'rgba(0, 0, 0, 0.8)' + } + }, + data: [ + ['2015/11/08', 10, 'DQ'], + ['2015/11/09', 15, 'DQ'], + ['2015/11/10', 35, 'DQ'], + ['2015/11/11', 38, 'DQ'], + ['2015/11/12', 22, 'DQ'], + ['2015/11/13', 16, 'DQ'], + ['2015/11/14', 7, 'DQ'], + ['2015/11/15', 2, 'DQ'], + ['2015/11/16', 17, 'DQ'], + ['2015/11/17', 33, 'DQ'], + ['2015/11/18', 40, 'DQ'], + ['2015/11/19', 32, 'DQ'], + ['2015/11/20', 26, 'DQ'], + ['2015/11/21', 35, 'DQ'], + ['2015/11/22', 40, 'DQ'], + ['2015/11/23', 32, 'DQ'], + ['2015/11/24', 26, 'DQ'], + ['2015/11/25', 22, 'DQ'], + ['2015/11/26', 16, 'DQ'], + ['2015/11/27', 22, 'DQ'], + ['2015/11/28', 10, 'DQ'], + ['2015/11/08', 35, 'TY'], + ['2015/11/09', 36, 'TY'], + ['2015/11/10', 37, 'TY'], + ['2015/11/11', 22, 'TY'], + ['2015/11/12', 24, 'TY'], + ['2015/11/13', 26, 'TY'], + ['2015/11/14', 34, 'TY'], + ['2015/11/15', 21, 'TY'], + ['2015/11/16', 18, 'TY'], + ['2015/11/17', 45, 'TY'], + ['2015/11/18', 32, 'TY'], + ['2015/11/19', 35, 'TY'], + ['2015/11/20', 30, 'TY'], + ['2015/11/21', 28, 'TY'], + ['2015/11/22', 27, 'TY'], + ['2015/11/23', 26, 'TY'], + ['2015/11/24', 15, 'TY'], + ['2015/11/25', 30, 'TY'], + ['2015/11/26', 35, 'TY'], + ['2015/11/27', 42, 'TY'], + ['2015/11/28', 42, 'TY'], + ['2015/11/08', 21, 'SS'], + ['2015/11/09', 25, 'SS'], + ['2015/11/10', 27, 'SS'], + ['2015/11/11', 23, 'SS'], + ['2015/11/12', 24, 'SS'], + ['2015/11/13', 21, 'SS'], + ['2015/11/14', 35, 'SS'], + ['2015/11/15', 39, 'SS'], + ['2015/11/16', 40, 'SS'], + ['2015/11/17', 36, 'SS'], + ['2015/11/18', 33, 'SS'], + ['2015/11/19', 43, 'SS'], + ['2015/11/20', 40, 'SS'], + ['2015/11/21', 34, 'SS'], + ['2015/11/22', 28, 'SS'], + ['2015/11/23', 26, 'SS'], + ['2015/11/24', 37, 'SS'], + ['2015/11/25', 41, 'SS'], + ['2015/11/26', 46, 'SS'], + ['2015/11/27', 47, 'SS'], + ['2015/11/28', 41, 'SS'], + ['2015/11/08', 10, 'QG'], + ['2015/11/09', 15, 'QG'], + ['2015/11/10', 35, 'QG'], + ['2015/11/11', 38, 'QG'], + ['2015/11/12', 22, 'QG'], + ['2015/11/13', 16, 'QG'], + ['2015/11/14', 7, 'QG'], + ['2015/11/15', 2, 'QG'], + ['2015/11/16', 17, 'QG'], + ['2015/11/17', 33, 'QG'], + ['2015/11/18', 40, 'QG'], + ['2015/11/19', 32, 'QG'], + ['2015/11/20', 26, 'QG'], + ['2015/11/21', 35, 'QG'], + ['2015/11/22', 40, 'QG'], + ['2015/11/23', 32, 'QG'], + ['2015/11/24', 26, 'QG'], + ['2015/11/25', 22, 'QG'], + ['2015/11/26', 16, 'QG'], + ['2015/11/27', 22, 'QG'], + ['2015/11/28', 10, 'QG'], + ['2015/11/08', 10, 'SY'], + ['2015/11/09', 15, 'SY'], + ['2015/11/10', 35, 'SY'], + ['2015/11/11', 38, 'SY'], + ['2015/11/12', 22, 'SY'], + ['2015/11/13', 16, 'SY'], + ['2015/11/14', 7, 'SY'], + ['2015/11/15', 2, 'SY'], + ['2015/11/16', 17, 'SY'], + ['2015/11/17', 33, 'SY'], + ['2015/11/18', 40, 'SY'], + ['2015/11/19', 32, 'SY'], + ['2015/11/20', 26, 'SY'], + ['2015/11/21', 35, 'SY'], + ['2015/11/22', 4, 'SY'], + ['2015/11/23', 32, 'SY'], + ['2015/11/24', 26, 'SY'], + ['2015/11/25', 22, 'SY'], + ['2015/11/26', 16, 'SY'], + ['2015/11/27', 22, 'SY'], + ['2015/11/28', 10, 'SY'], + ['2015/11/08', 10, 'DD'], + ['2015/11/09', 15, 'DD'], + ['2015/11/10', 35, 'DD'], + ['2015/11/11', 38, 'DD'], + ['2015/11/12', 22, 'DD'], + ['2015/11/13', 16, 'DD'], + ['2015/11/14', 7, 'DD'], + ['2015/11/15', 2, 'DD'], + ['2015/11/16', 17, 'DD'], + ['2015/11/17', 33, 'DD'], + ['2015/11/18', 4, 'DD'], + ['2015/11/19', 32, 'DD'], + ['2015/11/20', 26, 'DD'], + ['2015/11/21', 35, 'DD'], + ['2015/11/22', 40, 'DD'], + ['2015/11/23', 32, 'DD'], + ['2015/11/24', 26, 'DD'], + ['2015/11/25', 22, 'DD'], + ['2015/11/26', 16, 'DD'], + ['2015/11/27', 22, 'DD'], + ['2015/11/28', 10, 'DD'] + ] + } + ] +}; +export {}; diff --git a/testdata/themeRiver-basic.js.svg b/testdata/themeRiver-basic.js.svg new file mode 100644 index 0000000..9f2d656 --- /dev/null +++ b/testdata/themeRiver-basic.js.svg @@ -0,0 +1,164 @@ + + + + + + + + + + + + + + +9 +11 +13 +15 +17 +19 +21 +23 +25 +27 + + + + + + + + + + + + + + + + + + + +DQ + + +TY + + +SS + + +QG + + +SY + + +DD + + + +DQ + +TY + +SS + +QG + +SY + +DD + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/testdata/themeRiver-lastfm.js b/testdata/themeRiver-lastfm.js new file mode 100644 index 0000000..09d8bb0 --- /dev/null +++ b/testdata/themeRiver-lastfm.js @@ -0,0 +1,76 @@ +/* +title: ThemeRiver Lastfm +category: themeRiver +titleCN: ThemeRiver Lastfm +*/ +// From https://github.com/jsundram/streamgraph.js/blob/master/examples/data/lastfm.js +let rawData = [ + [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], + [0, 49, 67, 16, 0, 19, 19, 0, 0, 1, 10, 5, 6, 1, 1, 0, 25, 0, 0, 0], + [0, 6, 3, 34, 0, 16, 1, 0, 0, 1, 6, 0, 1, 56, 0, 2, 0, 2, 0, 0], + [0, 8, 13, 15, 0, 12, 23, 0, 0, 1, 0, 1, 0, 0, 6, 0, 0, 1, 0, 1], + [0, 9, 28, 0, 91, 6, 1, 0, 0, 0, 7, 18, 0, 9, 16, 0, 1, 0, 0, 0], + [0, 3, 42, 36, 21, 0, 1, 0, 0, 0, 0, 16, 30, 1, 4, 62, 55, 1, 0, 0], + [0, 7, 13, 12, 64, 5, 0, 0, 0, 8, 17, 3, 72, 1, 1, 53, 1, 0, 0, 0], + [1, 14, 13, 7, 8, 8, 7, 0, 1, 1, 14, 6, 44, 8, 7, 17, 21, 1, 0, 0], + [0, 6, 14, 2, 14, 1, 0, 0, 0, 0, 2, 2, 7, 15, 6, 3, 0, 0, 0, 0], + [0, 9, 11, 3, 0, 8, 0, 0, 14, 2, 0, 1, 1, 1, 7, 13, 2, 1, 0, 0], + [0, 7, 5, 10, 8, 21, 0, 0, 130, 1, 2, 18, 6, 1, 5, 1, 4, 1, 0, 7], + [0, 2, 15, 1, 5, 5, 0, 0, 6, 0, 0, 0, 4, 1, 3, 1, 17, 0, 0, 9], + [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], + [6, 27, 26, 1, 0, 11, 1, 0, 0, 0, 1, 1, 2, 0, 0, 9, 1, 0, 0, 0], + [31, 81, 11, 6, 11, 0, 0, 0, 0, 0, 0, 0, 3, 2, 0, 3, 14, 0, 0, 12], + [19, 53, 6, 20, 0, 4, 37, 0, 30, 86, 43, 7, 5, 7, 17, 19, 2, 0, 0, 5], + [0, 22, 14, 6, 10, 24, 18, 0, 13, 21, 5, 2, 13, 35, 7, 1, 8, 0, 0, 1], + [0, 56, 5, 0, 0, 0, 0, 0, 7, 24, 0, 17, 7, 0, 0, 3, 0, 0, 0, 8], + [18, 29, 3, 6, 11, 0, 15, 0, 12, 42, 37, 0, 3, 3, 13, 8, 0, 0, 0, 1], + [32, 39, 37, 3, 33, 21, 6, 0, 4, 17, 0, 11, 8, 2, 3, 0, 23, 0, 0, 17], + [72, 15, 28, 0, 0, 0, 0, 0, 1, 3, 0, 35, 0, 9, 17, 1, 9, 1, 0, 8], + [11, 15, 4, 2, 0, 18, 10, 0, 20, 3, 0, 0, 2, 0, 0, 2, 2, 30, 0, 0], + [14, 29, 19, 3, 2, 17, 13, 0, 7, 12, 2, 0, 6, 0, 0, 1, 1, 34, 0, 1], + [1, 1, 7, 6, 1, 1, 15, 1, 1, 2, 1, 3, 1, 1, 9, 1, 1, 25, 1, 72] +]; +let labels = [ + 'The Sea and Cake', + 'Andrew Bird', + 'Laura Veirs', + 'Brian Eno', + 'Christopher Willits', + 'Wilco', + 'Edgar Meyer', + 'B\xc3\xa9la Fleck', + 'Fleet Foxes', + 'Kings of Convenience', + 'Brett Dennen', + 'Psapp', + 'The Bad Plus', + 'Feist', + 'Battles', + 'Avishai Cohen', + 'Rachael Yamagata', + 'Norah Jones', + 'B\xc3\xa9la Fleck and the Flecktones', + 'Joshua Redman' +]; +let data = []; +for (let i = 0; i < rawData.length; i++) { + for (let j = 0; j < rawData[i].length; j++) { + let label = labels[i]; + data.push([j, rawData[i][j], label]); + } +} +option = { + singleAxis: { + max: 'dataMax' + }, + series: [ + { + type: 'themeRiver', + data: data, + label: { + show: false + } + } + ] +}; +export {}; diff --git a/testdata/tree-basic.js b/testdata/tree-basic.js new file mode 100644 index 0000000..66a486f --- /dev/null +++ b/testdata/tree-basic.js @@ -0,0 +1,49 @@ +/* +title: From Left to Right Tree +category: tree +titleCN: 从左到右树状图 +*/ +myChart.showLoading(); +$.get(ROOT_PATH + '/data/asset/data/flare.json', function (data) { + myChart.hideLoading(); + data.children.forEach(function (datum, index) { + index % 2 === 0 && (datum.collapsed = true); + }); + myChart.setOption((option = { + tooltip: { + trigger: 'item', + triggerOn: 'mousemove' + }, + series: [ + { + type: 'tree', + data: [data], + top: '1%', + left: '7%', + bottom: '1%', + right: '20%', + symbolSize: 7, + label: { + position: 'left', + verticalAlign: 'middle', + align: 'right', + fontSize: 9 + }, + leaves: { + label: { + position: 'right', + verticalAlign: 'middle', + align: 'left' + } + }, + emphasis: { + focus: 'descendant' + }, + expandAndCollapse: true, + animationDuration: 550, + animationDurationUpdate: 750 + } + ] + })); +}); +export {}; diff --git a/testdata/tree-legend.js b/testdata/tree-legend.js new file mode 100644 index 0000000..5a8aa77 --- /dev/null +++ b/testdata/tree-legend.js @@ -0,0 +1,234 @@ +/* +title: Multiple Trees +category: tree +titleCN: 多棵树 +*/ +myChart.showLoading(); +const data = { + name: 'flare', + children: [ + { + name: 'data', + children: [ + { + name: 'converters', + children: [ + { name: 'Converters', value: 721 }, + { name: 'DelimitedTextConverter', value: 4294 } + ] + }, + { + name: 'DataUtil', + value: 3322 + } + ] + }, + { + name: 'display', + children: [ + { name: 'DirtySprite', value: 8833 }, + { name: 'LineSprite', value: 1732 }, + { name: 'RectSprite', value: 3623 } + ] + }, + { + name: 'flex', + children: [{ name: 'FlareVis', value: 4116 }] + }, + { + name: 'query', + children: [ + { name: 'AggregateExpression', value: 1616 }, + { name: 'And', value: 1027 }, + { name: 'Arithmetic', value: 3891 }, + { name: 'Average', value: 891 }, + { name: 'BinaryExpression', value: 2893 }, + { name: 'Comparison', value: 5103 }, + { name: 'CompositeExpression', value: 3677 }, + { name: 'Count', value: 781 }, + { name: 'DateUtil', value: 4141 }, + { name: 'Distinct', value: 933 }, + { name: 'Expression', value: 5130 }, + { name: 'ExpressionIterator', value: 3617 }, + { name: 'Fn', value: 3240 }, + { name: 'If', value: 2732 }, + { name: 'IsA', value: 2039 }, + { name: 'Literal', value: 1214 }, + { name: 'Match', value: 3748 }, + { name: 'Maximum', value: 843 }, + { + name: 'methods', + children: [ + { name: 'add', value: 593 }, + { name: 'and', value: 330 }, + { name: 'average', value: 287 }, + { name: 'count', value: 277 }, + { name: 'distinct', value: 292 }, + { name: 'div', value: 595 }, + { name: 'eq', value: 594 }, + { name: 'fn', value: 460 }, + { name: 'gt', value: 603 }, + { name: 'gte', value: 625 }, + { name: 'iff', value: 748 }, + { name: 'isa', value: 461 }, + { name: 'lt', value: 597 }, + { name: 'lte', value: 619 }, + { name: 'max', value: 283 }, + { name: 'min', value: 283 }, + { name: 'mod', value: 591 }, + { name: 'mul', value: 603 }, + { name: 'neq', value: 599 }, + { name: 'not', value: 386 }, + { name: 'or', value: 323 }, + { name: 'orderby', value: 307 }, + { name: 'range', value: 772 }, + { name: 'select', value: 296 }, + { name: 'stddev', value: 363 }, + { name: 'sub', value: 600 }, + { name: 'sum', value: 280 }, + { name: 'update', value: 307 }, + { name: 'variance', value: 335 }, + { name: 'where', value: 299 }, + { name: 'xor', value: 354 }, + { name: '_', value: 264 } + ] + }, + { name: 'Minimum', value: 843 }, + { name: 'Not', value: 1554 }, + { name: 'Or', value: 970 }, + { name: 'Query', value: 13896 }, + { name: 'Range', value: 1594 }, + { name: 'StringUtil', value: 4130 }, + { name: 'Sum', value: 791 }, + { name: 'Variable', value: 1124 }, + { name: 'Variance', value: 1876 }, + { name: 'Xor', value: 1101 } + ] + }, + { + name: 'scale', + children: [ + { name: 'IScaleMap', value: 2105 }, + { name: 'LinearScale', value: 1316 }, + { name: 'LogScale', value: 3151 }, + { name: 'OrdinalScale', value: 3770 }, + { name: 'QuantileScale', value: 2435 }, + { name: 'QuantitativeScale', value: 4839 }, + { name: 'RootScale', value: 1756 }, + { name: 'Scale', value: 4268 }, + { name: 'ScaleType', value: 1821 }, + { name: 'TimeScale', value: 5833 } + ] + } + ] +}; +var data2 = { + name: 'flare', + children: [ + { + name: 'flex', + children: [{ name: 'FlareVis', value: 4116 }] + }, + { + name: 'scale', + children: [ + { name: 'IScaleMap', value: 2105 }, + { name: 'LinearScale', value: 1316 }, + { name: 'LogScale', value: 3151 }, + { name: 'OrdinalScale', value: 3770 }, + { name: 'QuantileScale', value: 2435 }, + { name: 'QuantitativeScale', value: 4839 }, + { name: 'RootScale', value: 1756 }, + { name: 'Scale', value: 4268 }, + { name: 'ScaleType', value: 1821 }, + { name: 'TimeScale', value: 5833 } + ] + }, + { + name: 'display', + children: [{ name: 'DirtySprite', value: 8833 }] + } + ] +}; +myChart.hideLoading(); +myChart.setOption((option = { + tooltip: { + trigger: 'item', + triggerOn: 'mousemove' + }, + legend: { + top: '2%', + left: '3%', + orient: 'vertical', + data: [ + { + name: 'tree1', + icon: 'rectangle' + }, + { + name: 'tree2', + icon: 'rectangle' + } + ], + borderColor: '#c23531' + }, + series: [ + { + type: 'tree', + name: 'tree1', + data: [data], + top: '5%', + left: '7%', + bottom: '2%', + right: '60%', + symbolSize: 7, + label: { + position: 'left', + verticalAlign: 'middle', + align: 'right' + }, + leaves: { + label: { + position: 'right', + verticalAlign: 'middle', + align: 'left' + } + }, + emphasis: { + focus: 'descendant' + }, + expandAndCollapse: true, + animationDuration: 550, + animationDurationUpdate: 750 + }, + { + type: 'tree', + name: 'tree2', + data: [data2], + top: '20%', + left: '60%', + bottom: '22%', + right: '18%', + symbolSize: 7, + label: { + position: 'left', + verticalAlign: 'middle', + align: 'right' + }, + leaves: { + label: { + position: 'right', + verticalAlign: 'middle', + align: 'left' + } + }, + expandAndCollapse: true, + emphasis: { + focus: 'descendant' + }, + animationDuration: 550, + animationDurationUpdate: 750 + } + ] +})); +export {}; diff --git a/testdata/tree-orient-bottom-top.js b/testdata/tree-orient-bottom-top.js new file mode 100644 index 0000000..9f15d35 --- /dev/null +++ b/testdata/tree-orient-bottom-top.js @@ -0,0 +1,47 @@ +/* +title: From Bottom to Top Tree +category: tree +titleCN: 从下到上树状图 +*/ +myChart.showLoading(); +$.get(ROOT_PATH + '/data/asset/data/flare.json', function (data) { + myChart.hideLoading(); + myChart.setOption((option = { + tooltip: { + trigger: 'item', + triggerOn: 'mousemove' + }, + series: [ + { + type: 'tree', + data: [data], + left: '2%', + right: '2%', + top: '20%', + bottom: '8%', + symbol: 'emptyCircle', + orient: 'BT', + expandAndCollapse: true, + label: { + position: 'bottom', + rotate: 90, + verticalAlign: 'middle', + align: 'right' + }, + leaves: { + label: { + position: 'top', + rotate: 90, + verticalAlign: 'middle', + align: 'left' + } + }, + emphasis: { + focus: 'descendant' + }, + animationDurationUpdate: 750 + } + ] + })); +}); +export {}; diff --git a/testdata/tree-orient-right-left.js b/testdata/tree-orient-right-left.js new file mode 100644 index 0000000..99a7998 --- /dev/null +++ b/testdata/tree-orient-right-left.js @@ -0,0 +1,49 @@ +/* +title: From Right to Left Tree +category: tree +titleCN: 从右到左树状图 +*/ +myChart.showLoading(); +$.get(ROOT_PATH + '/data/asset/data/flare.json', function (data) { + myChart.hideLoading(); + data.children.forEach(function (datum, index) { + index % 2 === 0 && (datum.collapsed = true); + }); + myChart.setOption((option = { + tooltip: { + trigger: 'item', + triggerOn: 'mousemove' + }, + series: [ + { + type: 'tree', + data: [data], + top: '1%', + left: '15%', + bottom: '1%', + right: '7%', + symbolSize: 7, + orient: 'RL', + label: { + position: 'right', + verticalAlign: 'middle', + align: 'left' + }, + leaves: { + label: { + position: 'left', + verticalAlign: 'middle', + align: 'right' + } + }, + emphasis: { + focus: 'descendant' + }, + expandAndCollapse: true, + animationDuration: 550, + animationDurationUpdate: 750 + } + ] + })); +}); +export {}; diff --git a/testdata/tree-polyline.js b/testdata/tree-polyline.js new file mode 100644 index 0000000..bd58857 --- /dev/null +++ b/testdata/tree-polyline.js @@ -0,0 +1,168 @@ +/* +title: Tree with Polyline Edge +category: tree +titleCN: 折线树图 +*/ +const data = { + name: 'flare', + children: [ + { + name: 'data', + children: [ + { + name: 'converters', + children: [ + { name: 'Converters', value: 721 }, + { name: 'DelimitedTextConverter', value: 4294 } + ] + }, + { + name: 'DataUtil', + value: 3322 + } + ] + }, + { + name: 'display', + children: [ + { name: 'DirtySprite', value: 8833 }, + { name: 'LineSprite', value: 1732 }, + { name: 'RectSprite', value: 3623 } + ] + }, + { + name: 'flex', + children: [{ name: 'FlareVis', value: 4116 }] + }, + { + name: 'query', + children: [ + { name: 'AggregateExpression', value: 1616 }, + { name: 'And', value: 1027 }, + { name: 'Arithmetic', value: 3891 }, + { name: 'Average', value: 891 }, + { name: 'BinaryExpression', value: 2893 }, + { name: 'Comparison', value: 5103 }, + { name: 'CompositeExpression', value: 3677 }, + { name: 'Count', value: 781 }, + { name: 'DateUtil', value: 4141 }, + { name: 'Distinct', value: 933 }, + { name: 'Expression', value: 5130 }, + { name: 'ExpressionIterator', value: 3617 }, + { name: 'Fn', value: 3240 }, + { name: 'If', value: 2732 }, + { name: 'IsA', value: 2039 }, + { name: 'Literal', value: 1214 }, + { name: 'Match', value: 3748 }, + { name: 'Maximum', value: 843 }, + { + name: 'methods', + children: [ + { name: 'add', value: 593 }, + { name: 'and', value: 330 }, + { name: 'average', value: 287 }, + { name: 'count', value: 277 }, + { name: 'distinct', value: 292 }, + { name: 'div', value: 595 }, + { name: 'eq', value: 594 }, + { name: 'fn', value: 460 }, + { name: 'gt', value: 603 }, + { name: 'gte', value: 625 }, + { name: 'iff', value: 748 }, + { name: 'isa', value: 461 }, + { name: 'lt', value: 597 }, + { name: 'lte', value: 619 }, + { name: 'max', value: 283 }, + { name: 'min', value: 283 }, + { name: 'mod', value: 591 }, + { name: 'mul', value: 603 }, + { name: 'neq', value: 599 }, + { name: 'not', value: 386 }, + { name: 'or', value: 323 }, + { name: 'orderby', value: 307 }, + { name: 'range', value: 772 }, + { name: 'select', value: 296 }, + { name: 'stddev', value: 363 }, + { name: 'sub', value: 600 }, + { name: 'sum', value: 280 }, + { name: 'update', value: 307 }, + { name: 'variance', value: 335 }, + { name: 'where', value: 299 }, + { name: 'xor', value: 354 }, + { name: 'x_x', value: 264 } + ] + }, + { name: 'Minimum', value: 843 }, + { name: 'Not', value: 1554 }, + { name: 'Or', value: 970 }, + { name: 'Query', value: 13896 }, + { name: 'Range', value: 1594 }, + { name: 'StringUtil', value: 4130 }, + { name: 'Sum', value: 791 }, + { name: 'Variable', value: 1124 }, + { name: 'Variance', value: 1876 }, + { name: 'Xor', value: 1101 } + ] + }, + { + name: 'scale', + children: [ + { name: 'IScaleMap', value: 2105 }, + { name: 'LinearScale', value: 1316 }, + { name: 'LogScale', value: 3151 }, + { name: 'OrdinalScale', value: 3770 }, + { name: 'QuantileScale', value: 2435 }, + { name: 'QuantitativeScale', value: 4839 }, + { name: 'RootScale', value: 1756 }, + { name: 'Scale', value: 4268 }, + { name: 'ScaleType', value: 1821 }, + { name: 'TimeScale', value: 5833 } + ] + } + ] +}; +option = { + tooltip: { + trigger: 'item', + triggerOn: 'mousemove' + }, + series: [ + { + type: 'tree', + id: 0, + name: 'tree1', + data: [data], + top: '10%', + left: '8%', + bottom: '22%', + right: '20%', + symbolSize: 7, + edgeShape: 'polyline', + edgeForkPosition: '63%', + initialTreeDepth: 3, + lineStyle: { + width: 2 + }, + label: { + backgroundColor: '#fff', + position: 'left', + verticalAlign: 'middle', + align: 'right' + }, + leaves: { + label: { + position: 'right', + verticalAlign: 'middle', + align: 'left' + } + }, + emphasis: { + focus: 'descendant' + }, + expandAndCollapse: true, + animationDuration: 550, + animationDurationUpdate: 750 + } + ] +}; +export {}; diff --git a/testdata/tree-polyline.js.svg b/testdata/tree-polyline.js.svg new file mode 100644 index 0000000..f5e0c73 --- /dev/null +++ b/testdata/tree-polyline.js.svg @@ -0,0 +1,1375 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +flare + +data + +converters + +Converters + +DelimitedTextConverter + +DataUtil + +display + +DirtySprite + +LineSprite + +RectSprite + +flex + +FlareVis + +query + +AggregateExpression + +And + +Arithmetic + +Average + +BinaryExpression + +Comparison + +CompositeExpression + +Count + +DateUtil + +Distinct + +Expression + +ExpressionIterator + +Fn + +If + +IsA + +Literal + +Match + +Maximum + +methods + +add + +and + +average + +count + +distinct + +div + +eq + +fn + +gt + +gte + +iff + +isa + +lt + +lte + +max + +min + +mod + +mul + +neq + +not + +or + +orderby + +range + +select + +stddev + +sub + +sum + +update + +variance + +where + +xor + +x_x + +Minimum + +Not + +Or + +Query + +Range + +StringUtil + +Sum + +Variable + +Variance + +Xor + +scale + +IScaleMap + +LinearScale + +LogScale + +OrdinalScale + +QuantileScale + +QuantitativeScale + +RootScale + +Scale + +ScaleType + +TimeScale + + \ No newline at end of file diff --git a/testdata/tree-radial.js b/testdata/tree-radial.js new file mode 100644 index 0000000..c0f110c --- /dev/null +++ b/testdata/tree-radial.js @@ -0,0 +1,32 @@ +/* +title: Radial Tree +category: tree +titleCN: 径向树状图 +*/ +myChart.showLoading(); +$.get(ROOT_PATH + '/data/asset/data/flare.json', function (data) { + myChart.hideLoading(); + myChart.setOption((option = { + tooltip: { + trigger: 'item', + triggerOn: 'mousemove' + }, + series: [ + { + type: 'tree', + data: [data], + top: '18%', + bottom: '14%', + layout: 'radial', + symbol: 'emptyCircle', + symbolSize: 7, + initialTreeDepth: 3, + animationDurationUpdate: 750, + emphasis: { + focus: 'descendant' + } + } + ] + })); +}); +export {}; diff --git a/testdata/tree-vertical.js b/testdata/tree-vertical.js new file mode 100644 index 0000000..b0c1cee --- /dev/null +++ b/testdata/tree-vertical.js @@ -0,0 +1,45 @@ +/* +title: From Top to Bottom Tree +category: tree +titleCN: 从上到下树状图 +*/ +myChart.showLoading(); +$.get(ROOT_PATH + '/data/asset/data/flare.json', function (data) { + myChart.hideLoading(); + myChart.setOption((option = { + tooltip: { + trigger: 'item', + triggerOn: 'mousemove' + }, + series: [ + { + type: 'tree', + data: [data], + left: '2%', + right: '2%', + top: '8%', + bottom: '20%', + symbol: 'emptyCircle', + orient: 'vertical', + expandAndCollapse: true, + label: { + position: 'top', + rotate: -90, + verticalAlign: 'middle', + align: 'right', + fontSize: 9 + }, + leaves: { + label: { + position: 'bottom', + rotate: -90, + verticalAlign: 'middle', + align: 'left' + } + }, + animationDurationUpdate: 750 + } + ] + })); +}); +export {}; diff --git a/testdata/treemap-disk.js b/testdata/treemap-disk.js new file mode 100644 index 0000000..5b594d2 --- /dev/null +++ b/testdata/treemap-disk.js @@ -0,0 +1,71 @@ +/* +title: Disk Usage +category: treemap +titleCN: 磁盘占用 +*/ +myChart.showLoading(); +$.get(ROOT_PATH + '/data/asset/data/disk.tree.json', function (diskData) { + myChart.hideLoading(); + const formatUtil = echarts.format; + function getLevelOption() { + return [ + { + itemStyle: { + borderWidth: 0, + gapWidth: 5 + } + }, + { + itemStyle: { + gapWidth: 1 + } + }, + { + colorSaturation: [0.35, 0.5], + itemStyle: { + gapWidth: 1, + borderColorSaturation: 0.6 + } + } + ]; + } + myChart.setOption((option = { + title: { + text: 'Disk Usage', + left: 'center' + }, + tooltip: { + formatter: function (info) { + var value = info.value; + var treePathInfo = info.treePathInfo; + var treePath = []; + for (var i = 1; i < treePathInfo.length; i++) { + treePath.push(treePathInfo[i].name); + } + return [ + '
' + + formatUtil.encodeHTML(treePath.join('/')) + + '
', + 'Disk Usage: ' + formatUtil.addCommas(value) + ' KB' + ].join(''); + } + }, + series: [ + { + name: 'Disk Usage', + type: 'treemap', + visibleMin: 300, + label: { + show: true, + formatter: '{b}' + }, + itemStyle: { + borderColor: '#fff' + }, + levels: getLevelOption(), + data: diskData + } + ] + })); +}); +export {}; diff --git a/testdata/treemap-drill-down.js b/testdata/treemap-drill-down.js new file mode 100644 index 0000000..555c5ce --- /dev/null +++ b/testdata/treemap-drill-down.js @@ -0,0 +1,81 @@ +/* +title: ECharts Option Query +category: treemap +titleCN: ECharts 配置项查询分布 +*/ +const uploadedDataURL = ROOT_PATH + '/data/asset/data/ec-option-doc-statistics-201604.json'; +myChart.showLoading(); +$.getJSON(uploadedDataURL, function (rawData) { + myChart.hideLoading(); + function convert(source, target, basePath) { + for (let key in source) { + let path = basePath ? basePath + '.' + key : key; + if (!key.match(/^\$/)) { + target.children = target.children || []; + const child = { + name: path + }; + target.children.push(child); + convert(source[key], child, path); + } + } + if (!target.children) { + target.value = source.$count || 1; + } + else { + target.children.push({ + name: basePath, + value: source.$count + }); + } + } + const data = { + children: [] + }; + convert(rawData, data, ''); + myChart.setOption((option = { + title: { + text: 'ECharts Options', + subtext: '2016/04', + left: 'leafDepth' + }, + tooltip: {}, + series: [ + { + name: 'option', + type: 'treemap', + visibleMin: 300, + data: data.children, + leafDepth: 2, + levels: [ + { + itemStyle: { + borderColor: '#555', + borderWidth: 4, + gapWidth: 4 + } + }, + { + colorSaturation: [0.3, 0.6], + itemStyle: { + borderColorSaturation: 0.7, + gapWidth: 2, + borderWidth: 2 + } + }, + { + colorSaturation: [0.3, 0.5], + itemStyle: { + borderColorSaturation: 0.6, + gapWidth: 1 + } + }, + { + colorSaturation: [0.3, 0.5] + } + ] + } + ] + })); +}); +export {}; diff --git a/testdata/treemap-obama.js b/testdata/treemap-obama.js new file mode 100644 index 0000000..d5dd9c5 --- /dev/null +++ b/testdata/treemap-obama.js @@ -0,0 +1,196 @@ +/* +title: How $3.7 Trillion is Spent +category: treemap +titleCN: How $3.7 Trillion is Spent +*/ +myChart.showLoading(); +const household_america_2012 = 113616229; +$.get(ROOT_PATH + '/data/asset/data/obama_budget_proposal_2012.json', function (obama_budget_2012) { + myChart.hideLoading(); + function buildData(mode, originList) { + let out = []; + for (let i = 0; i < originList.length; i++) { + let node = originList[i]; + let newNode = cloneNodeInfo(node); + if (!newNode) { + continue; + } + out[i] = newNode; + let value = newNode.value; + // Calculate amount per household. + value[3] = value[0] / household_america_2012; + // if mode === 0 and mode === 2 do nothing + if (mode === 1) { + // Set 'Change from 2010' to value[0]. + let tmp = value[1]; + value[1] = value[0]; + value[0] = tmp; + } + if (node.children) { + newNode.children = buildData(mode, node.children); + } + } + return out; + } + function cloneNodeInfo(node) { + if (!node) { + return; + } + const newNode = {}; + newNode.name = node.name; + newNode.id = node.id; + newNode.value = (node.value || []).slice(); + return newNode; + } + function getLevelOption(mode) { + return [ + { + color: mode === 2 + ? [ + '#c23531', + '#314656', + '#61a0a8', + '#dd8668', + '#91c7ae', + '#6e7074', + '#61a0a8', + '#bda29a', + '#44525d', + '#c4ccd3' + ] + : undefined, + colorMappingBy: 'id', + itemStyle: { + borderWidth: 3, + gapWidth: 3 + } + }, + { + colorAlpha: mode === 2 ? [0.5, 1] : undefined, + itemStyle: { + gapWidth: 1 + } + } + ]; + } + function isValidNumber(num) { + return num != null && isFinite(num); + } + function getTooltipFormatter(mode) { + let amountIndex = mode === 1 ? 1 : 0; + let amountIndex2011 = mode === 1 ? 0 : 1; + return function (info) { + let value = info.value; + let amount = value[amountIndex]; + amount = isValidNumber(amount) + ? echarts.format.addCommas(amount * 1000) + '$' + : '-'; + let amount2011 = value[amountIndex2011]; + amount2011 = isValidNumber(amount2011) + ? echarts.format.addCommas(amount2011 * 1000) + '$' + : '-'; + let perHousehold = value[3]; + perHousehold = isValidNumber(perHousehold) + ? echarts.format.addCommas(+perHousehold.toFixed(4) * 1000) + '$' + : '-'; + let change = value[2]; + change = isValidNumber(change) ? change.toFixed(2) + '%' : '-'; + return [ + '
' + + echarts.format.encodeHTML(info.name) + + '
', + '2012 Amount:   ' + amount + '
', + 'Per Household:   ' + perHousehold + '
', + '2011 Amount:   ' + amount2011 + '
', + 'Change From 2011:   ' + change + ].join(''); + }; + } + function createSeriesCommon(mode) { + return { + type: 'treemap', + tooltip: { + formatter: getTooltipFormatter(mode) + }, + label: { + position: 'insideTopLeft', + formatter: function (params) { + let arr = [ + '{name|' + params.name + '}', + '{hr|}', + '{budget|$ ' + + echarts.format.addCommas(params.value[0]) + + '} {label|budget}' + ]; + mode !== 1 && + arr.push('{household|$ ' + + echarts.format.addCommas(+params.value[3].toFixed(4) * 1000) + + '} {label|per household}'); + return arr.join('\n'); + }, + rich: { + budget: { + fontSize: 22, + lineHeight: 30, + color: 'yellow' + }, + household: { + fontSize: 14, + color: '#fff' + }, + label: { + fontSize: 9, + backgroundColor: 'rgba(0,0,0,0.3)', + color: '#fff', + borderRadius: 2, + padding: [2, 4], + lineHeight: 25, + align: 'right' + }, + name: { + fontSize: 12, + color: '#fff' + }, + hr: { + width: '100%', + borderColor: 'rgba(255,255,255,0.2)', + borderWidth: 0.5, + height: 0, + lineHeight: 10 + } + } + }, + itemStyle: { + borderColor: 'black' + }, + levels: getLevelOption(0) + }; + } + let modes = ['2012Budget', '2011Budget', 'Growth']; + myChart.setOption((option = { + title: { + top: 5, + left: 'center', + text: 'How $3.7 Trillion is Spent', + subtext: 'Obama’s 2012 Budget Proposal' + }, + legend: { + data: modes, + selectedMode: 'single', + top: 55, + itemGap: 5, + borderRadius: 5 + }, + tooltip: {}, + series: modes.map(function (mode, idx) { + let seriesOpt = createSeriesCommon(idx); + seriesOpt.name = mode; + seriesOpt.top = 80; + seriesOpt.visualDimension = idx === 2 ? 2 : undefined; + seriesOpt.data = buildData(idx, obama_budget_2012); + seriesOpt.levels = getLevelOption(idx); + return seriesOpt; + }) + })); +}); +export {}; diff --git a/testdata/treemap-show-parent.js b/testdata/treemap-show-parent.js new file mode 100644 index 0000000..e817d19 --- /dev/null +++ b/testdata/treemap-show-parent.js @@ -0,0 +1,86 @@ +/* +title: Show Parent Labels +category: treemap +titleCN: 显示父层级标签 +*/ +myChart.showLoading(); +$.get(ROOT_PATH + '/data/asset/data/disk.tree.json', function (diskData) { + myChart.hideLoading(); + function getLevelOption() { + return [ + { + itemStyle: { + borderColor: '#777', + borderWidth: 0, + gapWidth: 1 + }, + upperLabel: { + show: false + } + }, + { + itemStyle: { + borderColor: '#555', + borderWidth: 5, + gapWidth: 1 + }, + emphasis: { + itemStyle: { + borderColor: '#ddd' + } + } + }, + { + colorSaturation: [0.35, 0.5], + itemStyle: { + borderWidth: 5, + gapWidth: 1, + borderColorSaturation: 0.6 + } + } + ]; + } + myChart.setOption((option = { + title: { + text: 'Disk Usage', + left: 'center' + }, + tooltip: { + formatter: function (info) { + var value = info.value; + var treePathInfo = info.treePathInfo; + var treePath = []; + for (var i = 1; i < treePathInfo.length; i++) { + treePath.push(treePathInfo[i].name); + } + return [ + '
' + + echarts.format.encodeHTML(treePath.join('/')) + + '
', + 'Disk Usage: ' + echarts.format.addCommas(value) + ' KB' + ].join(''); + } + }, + series: [ + { + name: 'Disk Usage', + type: 'treemap', + visibleMin: 300, + label: { + show: true, + formatter: '{b}' + }, + upperLabel: { + show: true, + height: 30 + }, + itemStyle: { + borderColor: '#fff' + }, + levels: getLevelOption(), + data: diskData + } + ] + })); +}); +export {}; diff --git a/testdata/treemap-simple.js b/testdata/treemap-simple.js new file mode 100644 index 0000000..584e7c7 --- /dev/null +++ b/testdata/treemap-simple.js @@ -0,0 +1,45 @@ +/* +title: Basic Treemap +category: treemap +titleCN: 基础矩形树图 +*/ +option = { + series: [ + { + type: 'treemap', + data: [ + { + name: 'nodeA', + value: 10, + children: [ + { + name: 'nodeAa', + value: 4 + }, + { + name: 'nodeAb', + value: 6 + } + ] + }, + { + name: 'nodeB', + value: 20, + children: [ + { + name: 'nodeBa', + value: 20, + children: [ + { + name: 'nodeBa1', + value: 20 + } + ] + } + ] + } + ] + } + ] +}; +export {}; diff --git a/testdata/treemap-simple.js.svg b/testdata/treemap-simple.js.svg new file mode 100644 index 0000000..b5f0a29 --- /dev/null +++ b/testdata/treemap-simple.js.svg @@ -0,0 +1,23 @@ + + + + + + + + + + + + +nodeBa1 +nodeAb +nodeAa + + + + +nodeB +nodeBa +nodeBa1 + \ No newline at end of file diff --git a/testdata/treemap-sunburst-transition.js b/testdata/treemap-sunburst-transition.js new file mode 100644 index 0000000..cd9a6d7 --- /dev/null +++ b/testdata/treemap-sunburst-transition.js @@ -0,0 +1,57 @@ +/* +title: Transition between Treemap and Sunburst +category: treemap +titleCN: 矩形树图和旭日图的动画过渡 +difficulty: 4 +videoStart: 3000 +videoEnd: 9000 +*/ +$.getJSON(ROOT_PATH + '/data/asset/data/echarts-package-size.json', function (data) { + const treemapOption = { + series: [ + { + type: 'treemap', + id: 'echarts-package-size', + animationDurationUpdate: 1000, + roam: false, + nodeClick: undefined, + data: data.children, + universalTransition: true, + label: { + show: true + }, + breadcrumb: { + show: false + } + } + ] + }; + const sunburstOption = { + series: [ + { + type: 'sunburst', + id: 'echarts-package-size', + radius: ['20%', '90%'], + animationDurationUpdate: 1000, + nodeClick: undefined, + data: data.children, + universalTransition: true, + itemStyle: { + borderWidth: 1, + borderColor: 'rgba(255,255,255,.5)' + }, + label: { + show: false + } + } + ] + }; + let currentOption = treemapOption; + myChart.setOption(currentOption); + setInterval(function () { + currentOption = + currentOption === treemapOption ? sunburstOption : treemapOption; + myChart.setOption(currentOption); + }, 3000); +}); +export {}; diff --git a/testdata/treemap-visual.js b/testdata/treemap-visual.js new file mode 100644 index 0000000..4a13de2 --- /dev/null +++ b/testdata/treemap-visual.js @@ -0,0 +1,117 @@ +/* +title: Gradient Mapping +category: treemap +titleCN: 映射为渐变色 +*/ +myChart.showLoading(); +const household_america_2012 = 113616229; +$.get(ROOT_PATH + '/data/asset/data/obama_budget_proposal_2012.json', function (obama_budget_2012) { + myChart.hideLoading(); + const visualMin = -100; + const visualMax = 100; + const visualMinBound = -40; + const visualMaxBound = 40; + convertData(obama_budget_2012); + function convertData(originList) { + let min = Infinity; + let max = -Infinity; + for (let i = 0; i < originList.length; i++) { + let node = originList[i]; + if (node) { + let value = node.value; + value[2] != null && value[2] < min && (min = value[2]); + value[2] != null && value[2] > max && (max = value[2]); + } + } + for (let i = 0; i < originList.length; i++) { + let node = originList[i]; + if (node) { + let value = node.value; + // Scale value for visual effect + if (value[2] != null && value[2] > 0) { + value[3] = echarts.number.linearMap(value[2], [0, max], [visualMaxBound, visualMax], true); + } + else if (value[2] != null && value[2] < 0) { + value[3] = echarts.number.linearMap(value[2], [min, 0], [visualMin, visualMinBound], true); + } + else { + value[3] = 0; + } + if (!isFinite(value[3])) { + value[3] = 0; + } + if (node.children) { + convertData(node.children); + } + } + } + } + function isValidNumber(num) { + return num != null && isFinite(num); + } + myChart.setOption((option = { + title: { + left: 'center', + text: 'Gradient Mapping', + subtext: 'Growth > 0: green; Growth < 0: red; Growth = 0: grey' + }, + tooltip: { + formatter: function (info) { + let value = info.value; + let amount = value[0]; + amount = isValidNumber(amount) + ? echarts.format.addCommas(amount * 1000) + '$' + : '-'; + let amount2011 = value[1]; + amount2011 = isValidNumber(amount2011) + ? echarts.format.addCommas(amount2011 * 1000) + '$' + : '-'; + let change = value[2]; + change = isValidNumber(change) ? change.toFixed(2) + '%' : '-'; + return [ + '
' + + echarts.format.encodeHTML(info.name) + + '
', + '2012 Amount:   ' + amount + '
', + '2011 Amount:   ' + amount2011 + '
', + 'Change From 2011:   ' + change + ].join(''); + } + }, + series: [ + { + name: 'ALL', + top: 80, + type: 'treemap', + label: { + show: true, + formatter: '{b}' + }, + itemStyle: { + borderColor: 'black' + }, + visualMin: visualMin, + visualMax: visualMax, + visualDimension: 3, + levels: [ + { + itemStyle: { + borderWidth: 3, + borderColor: '#333', + gapWidth: 3 + } + }, + { + color: ['#942e38', '#aaa', '#269f3c'], + colorMappingBy: 'value', + itemStyle: { + gapWidth: 1 + } + } + ], + data: obama_budget_2012 + } + ] + })); +}); +export {}; diff --git a/testdata/watermark.js b/testdata/watermark.js new file mode 100644 index 0000000..d236563 --- /dev/null +++ b/testdata/watermark.js @@ -0,0 +1,235 @@ +/* +title: Watermark - ECharts Download +category: bar +titleCN: 水印 - ECharts 下载统计 +difficulty: 6 +*/ +const builderJson = { + all: 10887, + charts: { + map: 3237, + lines: 2164, + bar: 7561, + line: 7778, + pie: 7355, + scatter: 2405, + candlestick: 1842, + radar: 2090, + heatmap: 1762, + treemap: 1593, + graph: 2060, + boxplot: 1537, + parallel: 1908, + gauge: 2107, + funnel: 1692, + sankey: 1568 + }, + components: { + geo: 2788, + title: 9575, + legend: 9400, + tooltip: 9466, + grid: 9266, + markPoint: 3419, + markLine: 2984, + timeline: 2739, + dataZoom: 2744, + visualMap: 2466, + toolbox: 3034, + polar: 1945 + }, + ie: 9743 +}; +const downloadJson = { + 'echarts.min.js': 17365, + 'echarts.simple.min.js': 4079, + 'echarts.common.min.js': 6929, + 'echarts.js': 14890 +}; +const themeJson = { + 'dark.js': 1594, + 'infographic.js': 925, + 'shine.js': 1608, + 'roma.js': 721, + 'macarons.js': 2179, + 'vintage.js': 1982 +}; +const waterMarkText = 'ECHARTS'; +const canvas = document.createElement('canvas'); +const ctx = canvas.getContext('2d'); +canvas.width = canvas.height = 100; +ctx.textAlign = 'center'; +ctx.textBaseline = 'middle'; +ctx.globalAlpha = 0.08; +ctx.font = '20px Microsoft Yahei'; +ctx.translate(50, 50); +ctx.rotate(-Math.PI / 4); +ctx.fillText(waterMarkText, 0, 0); +option = { + backgroundColor: { + type: 'pattern', + image: canvas, + repeat: 'repeat' + }, + tooltip: {}, + title: [ + { + text: '在线构建', + subtext: '总计 ' + builderJson.all, + left: '25%', + textAlign: 'center' + }, + { + text: '各版本下载', + subtext: '总计 ' + + Object.keys(downloadJson).reduce(function (all, key) { + return all + downloadJson[key]; + }, 0), + left: '75%', + textAlign: 'center' + }, + { + text: '主题下载', + subtext: '总计 ' + + Object.keys(themeJson).reduce(function (all, key) { + return all + themeJson[key]; + }, 0), + left: '75%', + top: '50%', + textAlign: 'center' + } + ], + grid: [ + { + top: 50, + width: '50%', + bottom: '45%', + left: 10, + containLabel: true + }, + { + top: '55%', + width: '50%', + bottom: 0, + left: 10, + containLabel: true + } + ], + xAxis: [ + { + type: 'value', + max: builderJson.all, + splitLine: { + show: false + } + }, + { + type: 'value', + max: builderJson.all, + gridIndex: 1, + splitLine: { + show: false + } + } + ], + yAxis: [ + { + type: 'category', + data: Object.keys(builderJson.charts), + axisLabel: { + interval: 0, + rotate: 30 + }, + splitLine: { + show: false + } + }, + { + gridIndex: 1, + type: 'category', + data: Object.keys(builderJson.components), + axisLabel: { + interval: 0, + rotate: 30 + }, + splitLine: { + show: false + } + } + ], + series: [ + { + type: 'bar', + stack: 'chart', + z: 3, + label: { + position: 'right', + show: true + }, + data: Object.keys(builderJson.charts).map(function (key) { + return builderJson.charts[key]; + }) + }, + { + type: 'bar', + stack: 'chart', + silent: true, + itemStyle: { + color: '#eee' + }, + data: Object.keys(builderJson.charts).map(function (key) { + return builderJson.all - builderJson.charts[key]; + }) + }, + { + type: 'bar', + stack: 'component', + xAxisIndex: 1, + yAxisIndex: 1, + z: 3, + label: { + position: 'right', + show: true + }, + data: Object.keys(builderJson.components).map(function (key) { + return builderJson.components[key]; + }) + }, + { + type: 'bar', + stack: 'component', + silent: true, + xAxisIndex: 1, + yAxisIndex: 1, + itemStyle: { + color: '#eee' + }, + data: Object.keys(builderJson.components).map(function (key) { + return builderJson.all - builderJson.components[key]; + }) + }, + { + type: 'pie', + radius: [0, '30%'], + center: ['75%', '25%'], + data: Object.keys(downloadJson).map(function (key) { + return { + name: key.replace('.js', ''), + value: downloadJson[key] + }; + }) + }, + { + type: 'pie', + radius: [0, '30%'], + center: ['75%', '75%'], + data: Object.keys(themeJson).map(function (key) { + return { + name: key.replace('.js', ''), + value: themeJson[key] + }; + }) + } + ] +}; +export {}; diff --git a/testdata/wind-barb.js b/testdata/wind-barb.js new file mode 100644 index 0000000..6e69e41 --- /dev/null +++ b/testdata/wind-barb.js @@ -0,0 +1,294 @@ +"use strict"; +/* +title: Wind Barb +category: 'custom, dataZoom' +titleCN: 风向图 +difficulty: 5 +*/ +$.getJSON(ROOT_PATH + '/data/asset/data/wind-barb-hobart.json', function (rawData) { + const weatherIcons = { + Showers: ROOT_PATH + '/data/asset/img/weather/showers_128.png', + Sunny: ROOT_PATH + '/data/asset/img/weather/sunny_128.png', + Cloudy: ROOT_PATH + '/data/asset/img/weather/cloudy_128.png' + }; + const directionMap = {}; + // prettier-ignore + ['W', 'WSW', 'SW', 'SSW', 'S', 'SSE', 'SE', 'ESE', 'E', 'ENE', 'NE', 'NNE', 'N', 'NNW', 'NW', 'WNW'].forEach(function (name, index) { + directionMap[name] = Math.PI / 8 * index; + }); + const data = rawData.data.map(function (entry) { + return [entry.time, entry.windSpeed, entry.R, entry.waveHeight]; + }); + const weatherData = rawData.forecast.map(function (entry) { + return [ + entry.localDate, + 0, + weatherIcons[entry.skyIcon], + entry.minTemp, + entry.maxTemp + ]; + }); + const dims = { + time: 0, + windSpeed: 1, + R: 2, + waveHeight: 3, + weatherIcon: 2, + minTemp: 3, + maxTemp: 4 + }; + const arrowSize = 18; + const weatherIconSize = 45; + const renderArrow = function (param, api) { + const point = api.coord([ + api.value(dims.time), + api.value(dims.windSpeed) + ]); + return { + type: 'path', + shape: { + pathData: 'M31 16l-15-15v9h-26v12h26v9z', + x: -arrowSize / 2, + y: -arrowSize / 2, + width: arrowSize, + height: arrowSize + }, + rotation: directionMap[api.value(dims.R)], + position: point, + style: api.style({ + stroke: '#555', + lineWidth: 1 + }) + }; + }; + const renderWeather = function (param, api) { + const point = api.coord([ + api.value(dims.time) + (3600 * 24 * 1000) / 2, + 0 + ]); + return { + type: 'group', + children: [ + { + type: 'image', + style: { + image: api.value(dims.weatherIcon), + x: -weatherIconSize / 2, + y: -weatherIconSize / 2, + width: weatherIconSize, + height: weatherIconSize + }, + position: [point[0], 110] + }, + { + type: 'text', + style: { + text: api.value(dims.minTemp) + ' - ' + api.value(dims.maxTemp) + '°', + textFont: api.font({ fontSize: 14 }), + textAlign: 'center', + textVerticalAlign: 'bottom' + }, + position: [point[0], 80] + } + ] + }; + }; + option = { + title: { + text: '天气 风向 风速 海浪 预报', + subtext: '示例数据源于 www.seabreeze.com.au', + left: 'center' + }, + tooltip: { + trigger: 'axis', + formatter: function (params) { + return [ + echarts.format.formatTime('yyyy-MM-dd', params[0].value[dims.time]) + + ' ' + + echarts.format.formatTime('hh:mm', params[0].value[dims.time]), + '风速:' + params[0].value[dims.windSpeed], + '风向:' + params[0].value[dims.R], + '浪高:' + params[0].value[dims.waveHeight] + ].join('
'); + } + }, + grid: { + top: 160, + bottom: 125 + }, + xAxis: { + type: 'time', + maxInterval: 3600 * 1000 * 24, + splitLine: { + lineStyle: { + color: '#ddd' + } + } + }, + yAxis: [ + { + name: '风速(节)', + nameLocation: 'middle', + nameGap: 35, + axisLine: { + lineStyle: { + color: '#666' + } + }, + splitLine: { + lineStyle: { + color: '#ddd' + } + } + }, + { + name: '浪高(米)', + nameLocation: 'middle', + nameGap: 35, + max: 6, + axisLine: { + lineStyle: { + color: '#015DD5' + } + }, + splitLine: { show: false } + }, + { + axisLine: { show: false }, + axisTick: { show: false }, + axisLabel: { show: false }, + splitLine: { show: false } + } + ], + visualMap: { + type: 'piecewise', + // show: false, + orient: 'horizontal', + left: 'center', + bottom: 10, + pieces: [ + { + gte: 17, + color: '#18BF12', + label: '大风(>=17节)' + }, + { + gte: 11, + lt: 17, + color: '#f4e9a3', + label: '中风(11 ~ 17 节)' + }, + { + lt: 11, + color: '#D33C3E', + label: '微风(小于 11 节)' + } + ], + seriesIndex: 1, + dimension: 1 + }, + dataZoom: [ + { + type: 'inside', + xAxisIndex: 0, + minSpan: 5 + }, + { + type: 'slider', + xAxisIndex: 0, + minSpan: 5, + bottom: 50 + } + ], + series: [ + { + type: 'line', + yAxisIndex: 1, + showSymbol: false, + emphasis: { + scale: false + }, + symbolSize: 10, + areaStyle: { + color: { + type: 'linear', + x: 0, + y: 0, + x2: 0, + y2: 1, + global: false, + colorStops: [ + { + offset: 0, + color: 'rgba(88,160,253,1)' + }, + { + offset: 0.5, + color: 'rgba(88,160,253,0.7)' + }, + { + offset: 1, + color: 'rgba(88,160,253,0)' + } + ] + } + }, + lineStyle: { + color: 'rgba(88,160,253,1)' + }, + itemStyle: { + color: 'rgba(88,160,253,1)' + }, + encode: { + x: dims.time, + y: dims.waveHeight + }, + data: data, + z: 2 + }, + { + type: 'custom', + renderItem: renderArrow, + encode: { + x: dims.time, + y: dims.windSpeed + }, + data: data, + z: 10 + }, + { + type: 'line', + symbol: 'none', + encode: { + x: dims.time, + y: dims.windSpeed + }, + lineStyle: { + color: '#aaa', + type: 'dotted' + }, + data: data, + z: 1 + }, + { + type: 'custom', + renderItem: renderWeather, + data: weatherData, + tooltip: { + trigger: 'item', + formatter: function (param) { + return (param.value[dims.time] + + ': ' + + param.value[dims.minTemp] + + ' - ' + + param.value[dims.maxTemp] + + '°'); + } + }, + yAxisIndex: 2, + z: 11 + } + ] + }; + myChart.setOption(option); +});