option = { "grid": { "top": 10, "bottom": 10, "right": -50, "left": 80 }, "tooltip": { "padding": 10, }, "yAxis": [{ "nameTextStyle": { "color": "#97d2ff", "padding": [0, 20, 10, 0], // "fontSize": 26 }, "axisLabel": { "color": "#333", // "fontSize": 26, "interval": 0, "align": "left", "padding": [0, 60, 0, 0] }, "axisTick": { "show": false }, "splitLine": { "show": false }, "axisLine": { "show": false }, "type": "category", "data": ["1 珠海", "2 珠海", "3 珠海", "4 珠海", "5 珠海", "6 珠海", "7 珠海", "8 珠海", "9 珠海", "10 珠海"], "inverse": true, "offset": 60 }, { "nameTextStyle": { "color": "#97d2ff", "padding": [0, 20, 10, 0], "fontSize": 26 }, "axisLabel": { "show": false }, "axisTick": { "show": false }, "splitLine": { "show": false }, "axisLine": { "show": false }, "data": ["1 珠海", "2 珠海", "3 珠海", "4 珠海", "5 珠海", "6 珠海", "7 珠海", "8 珠海", "9 珠海", "10 珠海"], "inverse": true }], "xAxis": { "nameTextStyle": { "color": "#BBC5D9", "padding": [0, 20, 10, 0], // "fontSize": 26 }, "axisLabel": { "show": false }, "axisTick": { "show": false }, "splitLine": { "show": false }, "axisLine": { "show": false } }, "series": [{ "type": "bar", "barWidth": 20, "barGap": "-100%", "yAxisIndex": 1, "data": [-6, -6, -6, -6, -6, -6, -6, -6, -6, -6], "itemStyle": { "normal": { "barBorderRadius": [20, 0, 0, 20], "borderColor": "#43B2FD", // "borderWidth": 2, "color": "#FAFAFA" } }, "silent": true }, { "type": "bar", "barWidth": 20, "barGap": "-100%", "data": [5, 5, 5, 5, 5, 5, 5, 5, 5, 5], "yAxisIndex": 1, "itemStyle": { "normal": { "barBorderRadius": [0, 20, 20, 0], "borderColor": "#43B2FD", // "borderWidth": 2, "color": "#FAFAFA" } }, "label": { "show": true, "position": "insideRight", "color": "#333", // "fontSize": 26, "padding": [0, 10, 0, 0] }, "silent": true }, { "type": "bar", "barGap": "-100%", "barWidth": 18, "data": [{ "value": -5.5, "itemStyle": { "normal": { "barBorderRadius": [20, 0, 0, 20], "color": { "x": 0, "y": 0, "x2": 1, "y2": 0, "type": "linear", "global": false, "colorStops": [{ "offset": 0, "color": "#25C250" }, { "offset": 1, "color": "#01BAA9" }] } } } }, { "value": -4.2, "itemStyle": { "normal": { "barBorderRadius": [20, 0, 0, 20], "color": { "x": 0, "y": 0, "x2": 1, "y2": 0, "type": "linear", "global": false, "colorStops": [{ "offset": 0, "color": "#25C250" }, { "offset": 1, "color": "#01BAA9" }] } } } }, { "value": -4, "itemStyle": { "normal": { "barBorderRadius": [20, 0, 0, 20], "color": { "x": 0, "y": 0, "x2": 1, "y2": 0, "type": "linear", "global": false, "colorStops": [{ "offset": 0, "color": "#25C250" }, { "offset": 1, "color": "#01BAA9" }] } } } }, { "value": -3.5, "itemStyle": { "normal": { "barBorderRadius": [20, 0, 0, 20], "color": { "x": 0, "y": 0, "x2": 1, "y2": 0, "type": "linear", "global": false, "colorStops": [{ "offset": 0, "color": "#25C250" }, { "offset": 1, "color": "#01BAA9" }] } } } }, { "value": -2, "itemStyle": { "normal": { "barBorderRadius": [20, 0, 0, 20], "color": { "x": 0, "y": 0, "x2": 1, "y2": 0, "type": "linear", "global": false, "colorStops": [{ "offset": 0, "color": "#25C250" }, { "offset": 1, "color": "#01BAA9" }] } } } }, { "value": -1, "itemStyle": { "normal": { "barBorderRadius": [20, 0, 0, 20], "color": { "x": 0, "y": 0, "x2": 1, "y2": 0, "type": "linear", "global": false, "colorStops": [{ "offset": 0, "color": "#25C250" }, { "offset": 1, "color": "#01BAA9" }] } } } }, { "value": 1.5, "itemStyle": { "normal": { "barBorderRadius": [0, 20, 20, 0], "color": { "x": 0, "y": 0, "x2": 1, "y2": 0, "type": "linear", "global": false, "colorStops": [{ "offset": 0, "color": "#FF6602" }, { "offset": 1, "color": "#FF6058" }] } } } }, { "value": 2, "itemStyle": { "normal": { "barBorderRadius": [0, 20, 20, 0], "color": { "x": 0, "y": 0, "x2": 1, "y2": 0, "type": "linear", "global": false, "colorStops": [{ "offset": 0, "color": "#FF6602" }, { "offset": 1, "color": "#FF6058" }] } } } }, { "value": 3.4, "itemStyle": { "normal": { "barBorderRadius": [0, 20, 20, 0], "color": { "x": 0, "y": 0, "x2": 1, "y2": 0, "type": "linear", "global": false, "colorStops": [{ "offset": 0, "color": "#FF6602" }, { "offset": 1, "color": "#FF6058" }] } } } }, { "value": 4, "itemStyle": { "normal": { "barBorderRadius": [0, 20, 20, 0], "color": { "x": 0, "y": 0, "x2": 1, "y2": 0, "type": "linear", "global": false, "colorStops": [{ "offset": 0, "color": "#FF6602" }, { "offset": 1, "color": "#FF6058" }] } } } }] }] }