zoukankan      html  css  js  c++  java
  • echarts-雷达图

    效果图:

    <div style=" 462px; height: 290px;id="propertyRightTop"></div>
     // 自适应字体大小变化
        WidthAdaptive(res) {
          var windth = window.innerWidth;
          let fontSize = windth / 1920;
          return fontSize * res;
        },
        drawLine() {
          // 基于准备好的dom,初始化echarts实例
          let myChart = this.$echarts.init(
            document.getElementById("propertyRightTop")
          );
    
          let option = {
            backgroundColor: "transparent",
            grid: {
              top: "20%",
            },
            radar: {
              splitNumber: 4, // 雷达图圈数设置
    
              splitLine: {
                lineStyle: {
                  color: [
                    "rgba(255,255,255,0.4)",
                    "rgba(255,255,255,0.4)",
                    "rgba(255,255,255,0.4)",
                    "rgba(255,255,255,0.4)",
                    "rgba(255,255,255,0.4)",
                    "rgba(255,255,255,.4)",
                  ],
                },
              },
    
              splitArea: {
                show: false,
              },
              axisLine: {
                lineStyle: {
                  color: "rgba(255,255,255,0.1)",
                },
              },
              indicator: [
                {
                  name: "",
                  max: 100,
                },
                {
                  name: "",
                  max: 100,
                },
                {
                  name: "",
                  max: 100,
                },
                {
                  name: "",
                  max: 100,
                },
              ],
            },
    
            series: [
              {
                type: "radar",
    
                data: [
                  {
                    value: [88, 85, 65, 88],
                    name: "预算分配(Allocated Budget)",
                  },
                ],
                itemStyle: {
                  normal: {
                    color: "#00C9A3",
                  },
                },
                areaStyle: {
                  normal: {
                    opacity: 0.2,
                  },
                },
              },
            ],
          };
          window.onresize = function () {
            myChart.resize();
          };
          myChart.setOption(option);
        },
  • 相关阅读:
    HDU5171 GTY's birthday gift —— 矩阵快速幂
    UVA10870 Recurrences —— 矩阵快速幂
    HDU4965 Fast Matrix Calculation —— 矩阵乘法、快速幂
    UVA11551 Experienced Endeavour —— 矩阵快速幂
    D6 I
    亲和串
    Kmp 算法模板 C
    Buy the Ticket
    寒假D3 A Find the Lost Sock
    寒假 D3 D Modular Inverse
  • 原文地址:https://www.cnblogs.com/a973692898/p/15384658.html
Copyright © 2011-2022 走看看