成人国产在线小视频_日韩寡妇人妻调教在线播放_色成人www永久在线观看_2018国产精品久久_亚洲欧美高清在线30p_亚洲少妇综合一区_黄色在线播放国产_亚洲另类技巧小说校园_国产主播xx日韩_a级毛片在线免费

資訊專欄INFORMATION COLUMN

常用echarts圖表

wapeyang / 2630人閱讀

摘要:李達(dá)康漢東省省委常委,京州市市委書(shū)記。程度漢東省京州市公安局光明區(qū)分局局長(zhǎng),因犯錯(cuò)誤,被李達(dá)康書(shū)記和趙東來(lái)局長(zhǎng)點(diǎn)名要清除公安隊(duì)伍。盡管程度逃避了所有罪責(zé),上面也有人保他,但最終還是在反貪局局長(zhǎng)侯亮平的縝密偵查下被繩之于法。

//本文代碼基于ehcarts4.0開(kāi)發(fā)
//https://cdn.bootcss.com/echarts/4.0.0/echarts.min.js
堆疊區(qū)域圖

option = {
    title: {
        text: "堆疊區(qū)域圖"
    },
    tooltip : {
        trigger: "axis",
        axisPointer: {
            type: "cross",
            label: {
                backgroundColor: "#6a7985"
            }
        }
    },
    legend: {
        top:0,
        right:0
    },
    grid: {
        left: "3%",
        right: "4%",
        bottom: "3%",
        containLabel: true
    },
    xAxis : [
        {
            type : "category",
            boundaryGap : false,
            data : ["周一","周二","周三","周四","周五","周六","周日"],
            
        }
    ],
    yAxis : [
        {
            type : "value",
            axisTick: { 
                show: true 
            },
            
        }
    ],
    series : [
        {
            name:"郵件營(yíng)銷",
            type:"line",
            smooth:true,
            symbolSize:2,
            showSymbol:false,
            symbol: "emptyCircle",
            stack: "總量",
            lineStyle:{
                color:"#9CDD47"
            },
            itemStyle:{
                color:"#9CDD47",
                borderWidth:2
            },
            areaStyle: {
                color:{
                    type: "linear",
                    x: 0,
                    y: 0,
                    x2: 0,
                    y2: 1,
                    colorStops: [{
                        offset: 0, color: "rgba(156, 221, 71,0.2)" // 0% 處的顏色
                    }, {
                        offset: 1, color:"rgba(156, 221, 71, 0)"http:// 100% 處的顏色
                    }],
                }
            },
            data:[120, 132, 101, 134, 90, 230, 210]
        },
        {
            name:"聯(lián)盟廣告",
            type:"line",
            stack: "總量",
            smooth:true,
            symbolSize:2,
            showSymbol:false,
            symbol: "emptyCircle",
            lineStyle:{
                color:"#07FFFF"
            },
            itemStyle:{
                color:"#07FFFF",
                borderWidth:2
            },
            areaStyle: {
                color:{
                    type: "linear",
                    x: 0,
                    y: 0,
                    x2: 0,
                    y2: 1,
                    colorStops: [{
                        offset: 0, color: "rgba(7, 255, 255, 0.2)" // 0% 處的顏色
                    }, {
                        offset: 1, color:"rgba(7, 255, 255, 0)"http:// 100% 處的顏色
                    }],
                }
            },
            data:[220, 182, 191, 234, 290, 330, 310]
        }
    ]
};
餅圖

// 餅圖配置項(xiàng)
    var option = {
        series: [
            {
                name:"風(fēng)險(xiǎn)預(yù)警占比",
                type: "pie",
                radius: ["25%", "40%"],
                center: ["50%", "50%"],
                roseType: false,
                data: [
                    {
                        value: 40,
                        name: "紅色預(yù)警"
                    }, {
                        value: 30,
                        name: "橙色預(yù)警"
                    }, {
                        value: 10,
                        name: "黃色預(yù)警"
                    }, {
                        value: 50,
                        name: "藍(lán)色預(yù)警"
                    }
                ],
                label: {
                    fontSize: 12,
                    color:"#545454",
                    formatter: function (param) {
                        return param.name + "(" + Math.round(param.percent) + "%" + ")" 
                            + "
" + param.value +  "個(gè)";
                    }
                },
                labelLine: {
                    smooth: false,
                    lineStyle: {
                        width: 2
                    }
                },
                itemStyle: {
                    color:function(params){
                        switch (params.name) {
                            case "紅色預(yù)警":
                                return "#D70002";
                            case "橙色預(yù)警":
                                return "#FF9309";
                            case "黃色預(yù)警":
                                return "#FFFB09";
                            case "藍(lán)色預(yù)警":
                                return "#035EF7";
                            default:
                                break;
                        }
                    }
                },
            }
        ]
    }
堆疊柱狀圖

//堆疊柱狀圖配置項(xiàng)
  var option = {
      backgroundColor: "#fff",
      tooltip: {
          trigger: "axis",
          axisPointer: {
              type: "shadow"
          }
      },
      legend: {
          bottom: "10",
          itemGap: 30,
          data: ["一級(jí)", "二級(jí)", "三級(jí)", "四級(jí)"]
      },
      grid: { //圖表的位置
          top: 30,
          left: 10,
          right: 80,
          bottom: 60,
          containLabel: true
      },
      dataZoom: [
          {
              type: "inside"
          }, {
              type: "slider",
              start: 0,
              bottom: 40,
              height: "15px",
              fillerColor:"rgba(202,223,255,.8)",
              borderColor:"#b6d2fc",
              handleStyle:{
                  color:"#b6d2fc"
              },
              dataBackground:{
                  lineStyle:{
                      color:"#b6d2fc"
                  },
                  areaStyle:{
                      color:"rgba(202,223,255,.8)"
                  }
              }
          }
      ],
      yAxis: [
          {
              type: "value",
              name: "備案?jìng)€(gè)數(shù)",
              nameTextStyle: {
                  fontSize: 12,
                  fontWeight: "bold",
                  color: "#454545"
              },
              splitLine: {
                  show: false
              },
              axisLine: {
                  lineStyle: {
                      color: "#B3B3B3"
                  }
              },
              axisLabel: {
                  color: "#454545"
              }
          }
      ],
      xAxis: [
          {
              type: "category",
              name: "區(qū)縣名稱",
              nameTextStyle: {
                  fontSize: 12,
                  fontWeight: "bold",
                  color: "#454545"
              },
              axisLine: {
                  lineStyle: {
                      color: "#B3B3B3"
                  }
              },
              axisLabel: {
                  color: "#454545"
              },
              data: ["鼓樓區(qū)","玄武區(qū)","秦淮區(qū)"]
          }
      ],
      series: [
          {
              name: "一級(jí)",
              type: "bar",
              stack: "總量",
              barWidth: "10px",
              itemStyle:{
                  color:"#D70002"
              },
              data: [2,4,6]
          },
          {
              name: "二級(jí)",
              type: "bar",
              stack: "總量",
              barWidth: "10px",
              data: [2,4,1]
          },
          {
              name: "三級(jí)",
              type: "bar",
              stack: "總量",
              barWidth: "10px",
              itemStyle:{
                  color:"#FFFB09"
              },
              data: [1,5,7]
          },
          {
              name: "四級(jí)",
              type: "bar",
              stack: "總量",
              barWidth: "10px",
              itemStyle:{
                  color:"#FF9309"
              },
              data: [1]
          }
      ]
    }
漸變柱狀圖

//配置項(xiàng)
var option = {
      backgroundColor: "#fff",
      color: [
          new echarts.graphic.LinearGradient(
              0, 0, 0, 1,
              [
                  { offset: 0, color: "#23E9EE" },
                  { offset: 1, color: "#0460F7" }
              ]
          )
      ],
      tooltip: {
          trigger: "axis",
          axisPointer: {
              type: "shadow"
          }
      },
      legend: {
          bottom: "10",
          itemGap: 30,
          data: ["一級(jí)", "二級(jí)", "三級(jí)", "四級(jí)"]
      },
      grid: { //圖表的位置
          top: 30,
          left: 10,
          right: 80,
          bottom: 60,
          containLabel: true
      },
      dataZoom: [
          {
              type: "inside"
          }, {
              type: "slider",
              start: 0,
              bottom: 40,
              height: "15px",
              fillerColor:"rgba(202,223,255,.8)",
              borderColor:"#b6d2fc",
              handleStyle:{
                  color:"#b6d2fc"
              },
              dataBackground:{
                  lineStyle:{
                      color:"#b6d2fc"
                  },
                  areaStyle:{
                      color:"rgba(202,223,255,.8)"
                  }
              }
          }
      ],
      yAxis: [
          {
              type: "value",
              name: "備案?jìng)€(gè)數(shù)",
              nameTextStyle: {
                  fontSize: 12,
                  fontWeight: "bold",
                  color: "#454545"
              },
              splitLine: {
                  show: false
              },
              axisLine: {
                  lineStyle: {
                      color: "#B3B3B3"
                  }
              },
              axisLabel: {
                  color: "#454545"
              }
          }
      ],
      xAxis: [
          {
              type: "category",
              name: "區(qū)縣名稱",
              nameTextStyle: {
                  fontSize: 12,
                  fontWeight: "bold",
                  color: "#454545"
              },
              axisLine: {
                  lineStyle: {
                      color: "#B3B3B3"
                  }
              },
              axisLabel: {
                  color: "#454545"
              },
              data: ["鼓樓區(qū)","玄武區(qū)","秦淮區(qū)"]
          }
      ],
      series: [
          {
              name: "報(bào)警",
              type: "bar",
              stack: "總量",
              barWidth: "10px",
              data: [1,2,4]
          }
      ]
  };
線圖

//線圖配置項(xiàng)
var option = {
      tooltip: {
          trigger: "axis"
      },
      color: [
          new echarts.graphic.LinearGradient(
              0, 0, 0, 1,
              [
                  {offset: 0, color: "#23E9EE"},
                  {offset: 1, color: "#0460F7"}
              ]
          )
      ],
      grid: {
          top: 30,
          left: 10,
          right: 30,
          bottom: 50,
          containLabel: true
      },
      dataZoom: [
          {
              type: "inside"
          }, {
              type: "slider",
              start: 0,
              bottom: 30,
              height: "15px",
              fillerColor:"rgba(202,223,255,.8)",
              borderColor:"#b6d2fc",
              handleStyle:{
                  color:"#b6d2fc"
              },
              dataBackground:{
                  lineStyle:{
                      color:"#b6d2fc"
                  },
                  areaStyle:{
                      color:"rgba(202,223,255,.8)"
                  }
              }
          }
      ],
      yAxis: [
          {
              type: "value",
              splitLine: {
                  show: false
              },
              axisLine: {
                  lineStyle: {
                      color: "#B3B3B3"
                  }
              },
              axisLabel: {
                  color: "#454545"
              }
          }
      ],
      xAxis: {
          type: "category",
          boundaryGap:false,
          axisLine: {
              lineStyle: {
                  color: "#B3B3B3"
              }
          },
          axisLabel: {
              color: "#454545"
          },
          data: ["周一", "周二", "周三", "周四", "周五", "周六", "周日"]
      },
      series: [
          {
              name: "報(bào)警個(gè)數(shù)",
              type: "line",
              symbol: "emptyCircle",
              symbolSize: 2,
              showSymbol: false,
              smooth: true,
              areaStyle: {
                  color: new echarts.graphic.LinearGradient(
                      0, 0, 0, 1,
                      [
                          {offset: 0, color: "rgba(35,233,238,.4)"},
                          {offset: 1, color: "rgba(4,96,247,.4)"}
                      ]
                  )
              },
              lineStyle: {
                  width: 1,
                  color: "#59cef5"
              },
              itemStyle: {
                  borderColor: "#59cef5",
                  borderWidth: 2
              },
              data:[2,4,3,2,1,4,2]
          }
      ]
  }
雷達(dá)圖

option = {
                tooltip: {},
                radar: {
                    tooltip: {
                        trigger: "item",
                    },
                    radius:"70%",
                    center: ["50%", "55%"],
                   indicator: [
                         { name: "人", max: 50 },
                         { name: "管", max: 50 },
                         { name: "物", max: 50 },
                         { name: "環(huán)", max: 50 },
                         { name: "機(jī)", max: 200 },
                     ],
                    shape: "circle",
                    splitNumber: 4,
                   triggerEvent: true,
                    name: {
                        textStyle: {
                            color: "#3EB9F9",
                        },
                    },
                    splitLine: {
                        lineStyle: {
                            color: [],
                        },
                    },
                    splitArea: {
                        show: true,
                        areaStyle: {
                            color: [
                                "rgba(38, 117, 222, 0.2)",
                                "rgba(38, 117, 222, 0.4)",
                                "rgba(38, 117, 222, 0.6)",
                                "rgba(38, 117, 222, 0.8)",
                            ].reverse(),
                        },
                    },
                    axisLine: {
                        lineStyle: {
                            color: "#2675DE",
                        },
                    },
                },
                series: [
                    {
                        type: "radar",
                        tooltip: {
                            trigger: "item",
                        },
                        data: [
                            {
                               name: "",
                                value: [14, 19, 46, 46, 18],
                                label: {
                                    normal: {
                                       show: true,
                                    },
                                },
                           },
                      ],
                        lineStyle: {
                            normal: {
                                width: 1,
                                opacity: 1,
                            },
                        },
                        symbol: "none",
                        itemStyle: {
                            normal: {
                                color: "#07FFFF",
                            },
                        },
                        areaStyle: {
                            normal: {
                                opacity: 0.1,
                            },
                        },
                    },
                ],
            };
分段折線圖

{
                tooltip: {
                    trigger: "axis",
                    formatter:function(params){
                        const p = params[0];
                        const n = p.name;
                        const v = p.data;
                        const s = n + "
風(fēng)險(xiǎn)值:" + v; return s; } }, backgroundColor: "#161627", grid:{ bottom:90, }, dataZoom: [ { type: "inside", }, { type: "slider", start: 0, bottom: 35, height: "10px", fillerColor: "rgba(38, 117, 222, 0.1)", borderColor: "#2675DE", handleStyle: { color: "#2675DE", }, textStyle:{ color:"#fff" }, dataBackground: { lineStyle: { color: "#2675DE", }, areaStyle: { color: "rgba(38, 117, 222, 0.1)", }, }, left:80, right:80, }, ], xAxis: { data: ["2019-03-18", "2019-03-19", "2019-03-20", "2019-03-21"], axisLine:{ lineStyle:{ color:"#86AFE5" } }, axisLabel: { interval: 0, rotate: 20 } }, yAxis: { splitLine: { show: true, interval:"0.2", lineStyle:{ color:"rgba(184, 184, 184, 0.2)" } }, axisLine:{ lineStyle:{ color:"#86AFE5" } }, interval: 1, }, visualMap: { orient:"horizontal", bottom: 0, left: "center", textStyle:{ color:"#fff" }, pieces: [ { label:"一般風(fēng)險(xiǎn)", gt:0, lte:0.45, color:"#035EF7", }, { label:"高風(fēng)險(xiǎn)", gt:0.45, lte:0.7, color:"#FFFB09", }, { label:"較高風(fēng)險(xiǎn)", gt:0.7, lte:0.86, color:"#FF9309", }, { label:"極高風(fēng)險(xiǎn)", gt:0.86, lte:1, color:"#D70002", }], outOfRange: { color: "#999", }, }, series: { name: "風(fēng)險(xiǎn)值", type: "line", smooth: true, symbolSize: 6, symbol:"circle", data:[0.2, 0.4, 0.8, 1], markLine: { symbol: ["none", "none"], data: [ { yAxis: 0.45, lineStyle: { color: "#FFFB09", type: "dotted", }, label: { position: "start", } }, { yAxis: 0.7, lineStyle: { color: "#FF9309", type: "dotted", }, label: { position: "start", } }, { yAxis: 0.86, lineStyle: { color: "#FF9309", type: "dotted", }, label: { position: "start", } } ], }, }, }
關(guān)系圖

var links = [
    {
        source: "人",
        target: "現(xiàn)實(shí)風(fēng)險(xiǎn)",
        des: "侯亮平是高育良的得意門生"
    }, {
        source: "人",
        target: "管",
    }, {
        source: "安全管理",
        target: "人",
    }, {
        source: "趙立春",
        target: "趙瑞龍",
    }, {
        source: "趙立春",
        target: "劉新建",
    }, {
        source: "李達(dá)康",
        target: "趙立春",
    }, {
        source: "管",
        target: "高小琴",
    }, {
        source: "陳巖石",
        target: "機(jī)",
    }, {
        source: "陸亦可",
        target: "機(jī)",
    }, {
        source: "沙瑞金",
        target: "陳巖石",
    }, {
        source: "管",
        target: "機(jī)",
    }, {
        source: "管",
        target: "現(xiàn)實(shí)風(fēng)險(xiǎn)",
    }, {
        source: "現(xiàn)實(shí)風(fēng)險(xiǎn)",
        target: "機(jī)",
    }, {
        source: "人",
        target: "吳惠芬",
    }, {
        source: "機(jī)",
        target: "趙東來(lái)",
    }, {
        source: "高小琴",
        target: "高小鳳",
        symbolSize: "1"
    }, {
        source: "趙東來(lái)",
        target: "陸亦可",
        //name: "愛(ài)慕"
    }, {
        source: "管",
        target: "程度",
        //name: "領(lǐng)導(dǎo)"
    }, {
        source: "人",
        target: "高小鳳",
        //name: "情人"
    }, {
        source: "趙瑞龍",
        target: "管",
        symbolSize: "1",
    }, {
        source: "李達(dá)康",
        target: "趙東來(lái)",
    }, {
        source: "趙瑞龍",
        target: "程度",
        //name: "領(lǐng)導(dǎo)"
    }, {
        source: "沙瑞金",
        target: "李達(dá)康",
    }, {
        source: "沙瑞金",
        target: "人",
    }, {
        source: "管",
        target: "梁璐",
    }, {
        source: "吳惠芬",
        target: "梁璐",
    }, {
        source: "李達(dá)康",
        target: "歐陽(yáng)菁",
    }, {
        source: "趙瑞龍",
        target: "劉新建",
    }, {
        source: "趙瑞龍",
        target: "高小琴",
        symbolSize: "1"
    }, {
        source: "趙瑞龍",
        target: "高小鳳",
    }, {
        source: "吳心怡",
        target: "陸亦可",
    }, {
        source: "吳心怡",
        target: "吳惠芬",
        //name: "姐妹"
    }, {
        source: "物",
        target: "現(xiàn)實(shí)風(fēng)險(xiǎn)",
        //name: "發(fā)小"
    }, {
        source: "物",
        target: "歐陽(yáng)菁",
        //name: "舉報(bào)",
    }, {
        source: "歐陽(yáng)菁",
        target: "劉新建",
        //name: "舉報(bào)",
        
    }, {
        source: "劉新建",
        target: "趙瑞龍",
        //name: "舉報(bào)",
        
    }, {
        source: "李達(dá)康",
        target: "丁義珍",
        //name: "領(lǐng)導(dǎo)"
    }, {
        source: "高小琴",
        target: "丁義珍",
        //name: "策劃出逃"
    }, {
        source: "管",
        target: "丁義珍",
        //name: "勾結(jié)"
    }, {
        source: "趙瑞龍",
        target: "丁義珍",
        //name: "勾結(jié)"
    }];

    links.forEach(function(v) {
        v.name="";
        v.lineStyle = {
            color: "#ccc"
        };
    })

option = {
    title: { text: "關(guān)系圖譜" },
    tooltip: {
        formatter: function (x) {
            return x.data.des;
        }
    },
    series: [
        {
            type: "graph",
            layout: "force",
            symbolSize: 40,
            roam: true,
            // edgeSymbol: ["circle", "arrow"],
            focusNodeAdjacency: true,
            edgeSymbolSize: [4, 10],
            edgeLabel: {
                normal: {
                    textStyle: {
                        fontSize: 20
                    }
                }
            },
            force: {
                repulsion: 2500,
                edgeLength: [10, 50]
            },
            draggable: true,
            itemStyle: {
                normal: {
                    borderWidth: 2,
                    color: "#6696FF",
                    shadowColor: "#6696FF",
                    shadowBlur: 10,
                    borderColor: "#fff"
                }
            },
            lineStyle: {
                normal: {
                    width: 2,
                    color: "#6696FF"
                }
            },
            edgeLabel: {
                normal: {
                    show: true,
                    formatter: function (x) {
                        return x.data.name;
                    }
                }
            },
            label: {
                normal: {
                    show: true,
                    textStyle: {
                    }
                }
            },
            data: [
                {
                    name: "現(xiàn)實(shí)風(fēng)險(xiǎn)",
                    des: "最高檢反貪局偵查處處長(zhǎng),漢東省人民檢察院副檢察長(zhǎng)兼反貪局局長(zhǎng)。
經(jīng)過(guò)與腐敗違法分子的斗爭(zhēng),最終將一批腐敗分子送上了審判臺(tái),
正義戰(zhàn)勝邪惡,自己也迎來(lái)了成長(zhǎng)。", symbolSize: 100, itemStyle: { normal: { color: "#6696FF" } } }, { name: "李達(dá)康", des: "漢東省省委常委,京州市市委書(shū)記。是一個(gè)正義無(wú)私的好官。
但為人過(guò)于愛(ài)惜自己的羽毛,對(duì)待身邊的親人和朋友顯得有些無(wú)情。", label: { position: "right", formatter: "" }, itemStyle: { normal: { color: "#6696FF" } } }, { name: "管", des: "漢東省公安廳廳長(zhǎng)", symbolSize: 80 }, { name: "陳巖石", des: "離休干部、漢東省檢察院前常務(wù)副檢察長(zhǎng)。充滿正義,平凡而普通的共 產(chǎn) 黨人。
對(duì)大老虎趙立春,以各種形式執(zhí)著舉報(bào)了十二年。
在這場(chǎng)關(guān)系黨和國(guó)家生死存亡的斗爭(zhēng)中,老人家以耄耋高齡,
義無(wú)反顧地背起了炸 藥包,在反腐勝利前夕因病去世。", itemStyle: { normal: { color: "#6696FF" } }, label: { position: "right", formatter: "" }, }, { name: "陸亦可", des: "漢東省檢察院反貪局一處處長(zhǎng)", itemStyle: { normal: { color: "#6696FF" } }, label: { position: "right", formatter: "" }, }, { name: "人", des: "漢東省省委副書(shū)記兼政法委書(shū)記。年近六十,是一個(gè)擅長(zhǎng)太極功夫的官場(chǎng)老手。侯亮平、陳海和祁同偉是其學(xué)生。", symbolSize: 80 }, { name: "沙瑞金", des: "漢東省省委書(shū)記", itemStyle: { normal: { color: "#6696FF" } }, label: { position: "right", formatter: "" }, }, { name: "高小琴", label: { position: "right", formatter: "" }, des: "山水集團(tuán)董事長(zhǎng),是一位叱咤于政界和商界的風(fēng)云人物,處事圓滑、精明干練。" }, { name: "高小鳳", label: { position: "right", formatter: "" }, }, { name: "安全管理", des: "漢東省京州市公安局局長(zhǎng),充滿正義,整治惡勢(shì)力,
在與檢察部門的合作中從最初的質(zhì)疑到之后的通力配合。", label: { position: "right", formatter: "" }, itemStyle: { normal: { color: "#6696FF" } } }, { name: "程度", label: { position: "right", formatter: "" }, des: "漢東省京州市公安局光明區(qū)分局局長(zhǎng),因犯錯(cuò)誤,被李達(dá)康書(shū)記和趙東來(lái)局長(zhǎng)點(diǎn)名要清除公安隊(duì)伍。
但在高小琴的幫助下,祁同偉調(diào)他當(dāng)上了省公安廳辦公室副主任。
盡管程度逃避了所有罪責(zé),上面也有人保他,
但最終還是在反貪局局長(zhǎng)侯亮平的縝密偵查下被繩之于法。", }, { name: "吳惠芬", label: { position: "right", formatter: "" }, des: "漢東省省委副書(shū)記高育良的妻子,漢東大學(xué)明史教授。", itemStyle: { normal: { color: "#6696FF" } } }, { name: "趙瑞龍", label: { position: "right", formatter: "" }, des: "副國(guó)級(jí)人物趙立春的公子哥,官二代,打著老子的旗子,
黑白兩道通吃,可謂呼風(fēng)喚雨,權(quán)傾一時(shí)。", }, { name: "趙立春", label: { position: "right", formatter: "" }, des: "副國(guó)級(jí)領(lǐng)導(dǎo)人,曾經(jīng)的改革闖將,在權(quán)利面前,顯得極其渺小。", }, { name: "機(jī)", itemStyle: { normal: { color: "#6696FF" } }, symbolSize: 80 }, { name: "梁璐", label: { position: "right", formatter: "" }, itemStyle: { normal: { color: "#6696FF" } } }, { name: "劉新建", label: { position: "right", formatter: "" }, }, { name: "歐陽(yáng)菁", label: { position: "right", formatter: "" }, }, { name: "吳心怡", label: { position: "right", formatter: "" }, itemStyle: { normal: { color: "#6696FF" } } }, { name: "物", symbolSize: 80 }, { name: "丁義珍", label: { position: "right", formatter: "" }, } ], links: links } ] };
區(qū)域折線圖

option = {
                tooltip: {
                    trigger: "axis",
                    formatter:function(params){
                        const p = params[0];
                        const n = p.name;
                        const v = p.data;
                        const s = n + "
風(fēng)險(xiǎn)值:" + v; return s; } }, backgroundColor: "#161627", color:"#000", grid:{ bottom:90, }, legend:{ show:true, data:[ { name:"一般風(fēng)險(xiǎn)", icon:"circle", textStyle:{ color:"#fff" } } ] }, visualMap: { orient:"horizontal", bottom: 0, left: "center", textStyle:{ color:"#fff" }, pieces: [{ label:"一般風(fēng)險(xiǎn)", gt:0, lte:0.45, color:"#035EF7" }, { label:"高風(fēng)險(xiǎn)", gt:0.45, lte:0.7, color:"#FEEA45" },{ label:"較高風(fēng)險(xiǎn)", gt:0.7, lte:0.86, color:"#FF9309" },{ label:"極高風(fēng)險(xiǎn)", gt:0.86, lte:1, color:"#D70002" }], outOfRange: { color: "#999", }, }, dataZoom: [ { type: "inside", }, { type: "slider", start: 0, bottom: 35, height: "10px", fillerColor: "rgba(38, 117, 222, 0.1)", borderColor: "#2675DE", handleStyle: { color: "#2675DE", }, textStyle:{ color:"#fff" }, dataBackground: { lineStyle: { color: "#2675DE", }, areaStyle: { color: "rgba(38, 117, 222, 0.1)", }, }, left:80, right:80, }, ], xAxis: { data: ["2019-03-18", "2019-03-19", "2019-03-20", "2019-03-21"], axisLine:{ lineStyle:{ color:"#86AFE5" } }, axisLabel: { interval: 0, rotate: 20 } }, yAxis: { splitLine: { show: true, interval:"0.2", lineStyle:{ color:"rgba(184, 184, 184, 0.2)" } }, axisLine:{ lineStyle:{ color:"#86AFE5" } }, interval: 1, }, series: { name: "風(fēng)險(xiǎn)值", type: "line", smooth: true, symbolSize:8, symbol: "circle", lineStyle:{ color:"#000" }, itemStyle:{ borderWidth:2, borderColor:"#000" }, data:[0.2, 0.4, 0.8, 1], markLine: { symbol: ["none", "none"], data: [ { yAxis: 0.45, lineStyle: { color: "#035EF7", type: "solid", }, label: { position: "start", } }, { yAxis: 0.7, lineStyle: { color: "#FEEA45", type: "solid", }, label: { position: "start", } }, { yAxis: 0.86, lineStyle: { color: "#FF9309", type: "solid", }, label: { position: "start", } } ], }, markArea: { data: [ [{ name: "", yAxis: 0, itemStyle: { color: "#035EF7" }, }, { yAxis: 0.45 }], [{ name: "", yAxis: 0.45, itemStyle: { color: "#FEEA45" }, }, { yAxis: 0.7, }], [{ name: "", yAxis: 0.7, itemStyle: { color: "#FF9309" }, }, { yAxis: 0.9, }], [{ name: "", yAxis: 0.9, itemStyle: { color: "#D70002" }, }, { yAxis: 1, }] ] }, }, };
創(chuàng)建實(shí)例
var chart = echarts.init(document.getElementById("chartBox"));
設(shè)置圖表實(shí)例的配置項(xiàng)
設(shè)置圖表實(shí)例的配置項(xiàng)以及數(shù)據(jù),萬(wàn)能接口,所有參數(shù)和數(shù)據(jù)的修改都可以通過(guò)setOption完成,ECharts 會(huì)合并新的參數(shù)和數(shù)據(jù),然后刷新圖表
chart.setOption(option);

文章版權(quán)歸作者所有,未經(jīng)允許請(qǐng)勿轉(zhuǎn)載,若此文章存在違規(guī)行為,您可以聯(lián)系管理員刪除。

轉(zhuǎn)載請(qǐng)注明本文地址:http://systransis.cn/yun/98084.html

相關(guān)文章

  • 前端開(kāi)發(fā)者常用的9個(gè)JavaScript圖表庫(kù)

    摘要:使用來(lái)呈現(xiàn)圖表。允許用戶在應(yīng)用程序中創(chuàng)建美觀的可復(fù)用的圖表。它是基于創(chuàng)建的,是一個(gè)以數(shù)據(jù)為中心的圖表庫(kù),可以改進(jìn)數(shù)據(jù)可視化的效果。非常輕巧,并使用元素來(lái)創(chuàng)建很奇特的圖表。是庫(kù)中較為古老的圖表庫(kù)之一??偨Y(jié)以上介紹的庫(kù)都是高質(zhì)量的圖表庫(kù)。 當(dāng)前,數(shù)據(jù)可視化已經(jīng)成為數(shù)據(jù)科學(xué)領(lǐng)域非常重要的一部分。不同網(wǎng)絡(luò)系統(tǒng)中產(chǎn)生的數(shù)據(jù),都需要經(jīng)過(guò)適當(dāng)?shù)目梢暬幚恚员愀玫某尸F(xiàn)給用戶讀取和分析。 對(duì)任何一個(gè)...

    luck 評(píng)論0 收藏0
  • 每周前端開(kāi)源推薦第六期

    摘要:每周前端開(kāi)源推薦第六期從名字就可以很容易的看出該項(xiàng)目的作用,解壓縮。同時(shí)支持瀏覽器和。是任務(wù)調(diào)度的項(xiàng)目。初始化定義人物每三分鐘觸發(fā)一次觸發(fā)一個(gè)交互式學(xué)習(xí)的方式。強(qiáng)烈建議大家先去體驗(yàn)一下的介紹是由百度團(tuán)隊(duì)開(kāi)發(fā)的一款開(kāi)源圖表項(xiàng)目。 每周前端開(kāi)源推薦第六期 43081j / rar.js Pure-JavaScript RAR reader using AJAX, File API...

    Salamander 評(píng)論0 收藏0
  • 每周前端開(kāi)源推薦第六期

    摘要:每周前端開(kāi)源推薦第六期從名字就可以很容易的看出該項(xiàng)目的作用,解壓縮。同時(shí)支持瀏覽器和。是任務(wù)調(diào)度的項(xiàng)目。初始化定義人物每三分鐘觸發(fā)一次觸發(fā)一個(gè)交互式學(xué)習(xí)的方式。強(qiáng)烈建議大家先去體驗(yàn)一下的介紹是由百度團(tuán)隊(duì)開(kāi)發(fā)的一款開(kāi)源圖表項(xiàng)目。 每周前端開(kāi)源推薦第六期 43081j / rar.js Pure-JavaScript RAR reader using AJAX, File API...

    channg 評(píng)論0 收藏0
  • 每周前端開(kāi)源推薦第六期

    摘要:每周前端開(kāi)源推薦第六期從名字就可以很容易的看出該項(xiàng)目的作用,解壓縮。同時(shí)支持瀏覽器和。是任務(wù)調(diào)度的項(xiàng)目。初始化定義人物每三分鐘觸發(fā)一次觸發(fā)一個(gè)交互式學(xué)習(xí)的方式。強(qiáng)烈建議大家先去體驗(yàn)一下的介紹是由百度團(tuán)隊(duì)開(kāi)發(fā)的一款開(kāi)源圖表項(xiàng)目。 每周前端開(kāi)源推薦第六期 43081j / rar.js Pure-JavaScript RAR reader using AJAX, File API...

    worldligang 評(píng)論0 收藏0
  • vue.js使用echarts一分鐘簡(jiǎn)單入門

    摘要:圖表的使用在企業(yè)級(jí)軟件中使用越來(lái)越普遍,前端開(kāi)發(fā)人員可以使用常用的開(kāi)源庫(kù)來(lái)進(jìn)行圖表展示的開(kāi)發(fā),公司最近提出需要豐富系統(tǒng)首頁(yè)的內(nèi)容,趁此機(jī)會(huì)分享一下如何在使用框架下使用確定你需要引入的版本官網(wǎng)地址或者安裝按需引入。 圖表的使用在企業(yè)級(jí)軟件中使用越來(lái)越普遍,前端開(kāi)發(fā)人員可以使用常用的echarts開(kāi)源庫(kù)來(lái)進(jìn)行圖表展示的開(kāi)發(fā),公司最近提出需要豐富系統(tǒng)首頁(yè)的內(nèi)容,趁此機(jī)會(huì)分享一下如何在使用vu...

    venmos 評(píng)論0 收藏0
  • vue.js使用echarts一分鐘簡(jiǎn)單入門

    摘要:圖表的使用在企業(yè)級(jí)軟件中使用越來(lái)越普遍,前端開(kāi)發(fā)人員可以使用常用的開(kāi)源庫(kù)來(lái)進(jìn)行圖表展示的開(kāi)發(fā),公司最近提出需要豐富系統(tǒng)首頁(yè)的內(nèi)容,趁此機(jī)會(huì)分享一下如何在使用框架下使用確定你需要引入的版本官網(wǎng)地址或者安裝按需引入。 圖表的使用在企業(yè)級(jí)軟件中使用越來(lái)越普遍,前端開(kāi)發(fā)人員可以使用常用的echarts開(kāi)源庫(kù)來(lái)進(jìn)行圖表展示的開(kāi)發(fā),公司最近提出需要豐富系統(tǒng)首頁(yè)的內(nèi)容,趁此機(jī)會(huì)分享一下如何在使用vu...

    chengtao1633 評(píng)論0 收藏0

發(fā)表評(píng)論

0條評(píng)論

最新活動(dòng)
閱讀需要支付1元查看
<