Graph 在图表上隐藏highcharts系列名称

Graph 在图表上隐藏highcharts系列名称,graph,highcharts,legend,series,display,Graph,Highcharts,Legend,Series,Display,我正在摆弄一个公司项目的高图,我的名字/数字从计算(总数)显示在图例中。问题是它们也会显示在图表上。我一辈子都想不出如何在图表上关闭它们,而在传奇中保留它们。我已经通读了API,也许我错过了它,但如果大家不介意的话,我可能需要一些帮助 代码: Highcharts.chart('high\u charts\u admin'{ 标题:{ 文本:“Adset ID:”+结果[1]。数据[0]。Adset\U ID, }, 副标题:{ 文本:“活动名称:”+结果[1]。数据[0]。活动名称, }, 亚

我正在摆弄一个公司项目的高图,我的名字/数字从计算(总数)显示在图例中。问题是它们也会显示在图表上。我一辈子都想不出如何在图表上关闭它们,而在传奇中保留它们。我已经通读了API,也许我错过了它,但如果大家不介意的话,我可能需要一些帮助

代码:

Highcharts.chart('high\u charts\u admin'{
标题:{
文本:“Adset ID:”+结果[1]。数据[0]。Adset\U ID,
},
副标题:{
文本:“活动名称:”+结果[1]。数据[0]。活动名称,
},
亚克斯:{
标题:{
文本:“”
}
},
xAxis:{
标题:{
文字:“活动日”,
}, 
//键入:“日期时间”,
类别:结果[0][8]
},
图例:{
//labelFormatter:function(){
//返回“”+this.name+“”;
//  },
布局:“垂直”,
对齐:“右”,
垂直排列:'中间',
项目宽度:250,
项目样式:{
fontSize:'16px',
颜色:“黑色”
},
项目编号:12,
项目MarginBottom:12,
是的,
符号高度:25,
符号宽度:30,
符号半径:100,
},
图表:{
marginRight:300,
},
打印选项:{
系列:{
标签:{
允许的连接器:false
},
起点:0,
类型:'系列',
//showInLegend:false,
}
},        
系列:[{
名称:“结果:”+结果[2][0],
数据:结果[0][0],
类型:“样条线”,
标记:{
半径:2
},
}, {
名称:'Reach:'+结果[2][1],
资料:结果[0][1],,
类型:“样条线”,
标记:{
半径:2
},
}, {
名称:'印象:'+结果[2][2],
资料:结果[0][2],,
类型:“样条线”,
标记:{
半径:2
},
}, { 
名称:“每潜在客户成本:”+结果[2][3],
资料:结果[0][3],,
类型:“样条线”,
标记:{
半径:2
},
}, {
名称:“花费:”+结果[2][4],
资料:结果[0][4],,
类型:“样条线”,
标记:{
半径:2
},
}, {
名称:'CTR(全部):'+结果[2][5],
资料:结果[0][5],,
类型:“样条线”,
标记:{
半径:2
},
}, {
名称:'CPC(全部):+结果[2][6],
资料:结果[0][6],,
类型:“样条线”,
标记:{
半径:2
},
}, {
名称:“点击次数:”+结果[2][7],
资料:结果[0][7],,
类型:“样条线”,
标记:{
半径:2
},
}],
响应:{
规则:[{
条件:{
最大宽度:500
},
图表选项:{
图例:{
布局:“水平”,
对齐:'居中',
垂直排列:“底部”
}
}
}]
}
});

这是我的密码:

    Highcharts.chart('high_charts_admin', {
    title: {
        text: 'Adset ID: '+results[1].data[0].adset_id,
    },

    subtitle: {
        text: 'Campaign Name: '+results[1].data[0].campaign_name, 
    },

    yAxis: {
        title: {
            text: ''
        }
    },
    xAxis: {
        title: {
            text: 'Day of the Campaign',
        }, 
        //type: 'datetime', 
        categories: results[0][8]
    },
    legend: {
        //labelFormatter: function() {
        //    return '<span style="color: '+this.color+'">'+ this.name + '</span>';
        //  },
        layout: 'vertical',
        align: 'right',
        verticalAlign: 'middle',
        itemWidth: 250,
        itemStyle: {
            fontSize: '16px',
            color: 'black'
         },
         itemMarginTop: 12,
         itemMarginBottom: 12,
         squareSymbol: true,
         symbolHeight: 25,
         symbolWidth: 30,
         symbolRadius: 100,
    },
    chart: {
        marginRight: 300,
    },

    plotOptions: {
        series: {
            label: {
                connectorAllowed: false
            },
            pointStart: 0,
            type: 'series',
            //showInLegend: false,
        }
    },        
    series: [{
        name: 'Results: '+results[2][0],
        data: results[0][0],
        type: 'spline',
        marker: {
            radius: 2
        },
    }, {
        name: 'Reach: '+results[2][1],
        data: results[0][1],
        type: 'spline',
        marker: {
            radius: 2
        },
    }, {
        name: 'Impressions: '+results[2][2],
        data: results[0][2],
        type: 'spline',
        marker: {
            radius: 2
        },
    }, { 
        name: 'Cost Per Lead: '+results[2][3],
        data: results[0][3],
        type: 'spline',
        marker: {
            radius: 2
        },
    }, {
        name: 'Spend: '+results[2][4],
        data: results[0][4],
        type: 'spline',
        marker: {
            radius: 2
        },
    }, {
        name: 'CTR (All): '+results[2][5],
        data: results[0][5],
        type: 'spline',
        marker: {
            radius: 2
        },
    }, {
        name: 'CPC (All): '+results[2][6],
        data: results[0][6],
        type: 'spline',
        marker: {
            radius: 2
        },
    }, {
        name: 'Clicks: '+results[2][7],
        data: results[0][7],
        type: 'spline',
        marker: {
            radius: 2
        },
    }],
    responsive: {
        rules: [{
            condition: {
                maxWidth: 500
            },
            chartOptions: {
                 legend: {
                 layout: 'horizontal',
                     align: 'center',
                     verticalAlign: 'bottom'
                 }
            }
        }]
    }
});
Highcharts.chart('high\u charts\u admin'{
标题:{
文本:“Adset ID:”+结果[1]。数据[0]。Adset\U ID,
},
副标题:{
文本:“活动名称:”+结果[1]。数据[0]。活动名称,
},
亚克斯:{
标题:{
文本:“”
}
},
xAxis:{
标题:{
文字:“活动日”,
}, 
//键入:“日期时间”,
类别:结果[0][8]
},
图例:{
//labelFormatter:function(){
//返回“”+this.name+“”;
//  },
布局:“垂直”,
对齐:“右”,
垂直排列:'中间',
项目宽度:250,
项目样式:{
fontSize:'16px',
颜色:“黑色”
},
项目编号:12,
项目MarginBottom:12,
是的,
符号高度:25,
符号宽度:30,
符号半径:100,
},
图表:{
marginRight:300,
},
打印选项:{
系列:{
标签:{
允许的连接器:false
},
起点:0,
类型:'系列',
//showInLegend:false,
}
},        
系列:[{
名称:“结果:”+结果[2][0],
数据:结果[0][0],
类型:“样条线”,
标记:{
半径:2
},
}, {
名称:'Reach:'+结果[2][1],
资料:结果[0][1],,
类型:“样条线”,
标记:{
半径:2
},
}, {
名称:'印象:'+结果[2][2],
资料:结果[0][2],,
类型:“样条线”,
标记:{
半径:2
},
}, { 
名称:“每潜在客户成本:”+结果[2][3],
资料:结果[0][3],,
类型:“样条线”,
标记:{
半径:2
},
}, {
名称:“花费:”+结果[2][4],
资料:结果[0][4],,
类型:“样条线”,
标记:{
半径:2
},
}, {
名称:'CTR(全部):'+结果[2][5],
资料:结果[0][5],,
类型:“样条线”,
标记:{
半径:2
},
}, {
名称:'CPC(全部):+结果[2][6],
资料:结果[0][6],,
类型:“样条线”,
标记:{
半径:2
},
}, {
名称:“点击次数:”+结果[2][7],
资料:结果[0][7],,
类型:“样条线”,
标记:{
半径:2
},
}],
响应:{
规则:[{
条件:{
最大宽度:500
},
图表选项:{
图例:{
布局:“水平”,
对齐:'居中',
眩晕
    Highcharts.chart('high_charts_admin', {
    title: {
        text: 'Adset ID: '+results[1].data[0].adset_id,
    },

    subtitle: {
        text: 'Campaign Name: '+results[1].data[0].campaign_name, 
    },

    yAxis: {
        title: {
            text: ''
        }
    },
    xAxis: {
        title: {
            text: 'Day of the Campaign',
        }, 
        //type: 'datetime', 
        categories: results[0][8]
    },
    legend: {
        //labelFormatter: function() {
        //    return '<span style="color: '+this.color+'">'+ this.name + '</span>';
        //  },
        layout: 'vertical',
        align: 'right',
        verticalAlign: 'middle',
        itemWidth: 250,
        itemStyle: {
            fontSize: '16px',
            color: 'black'
         },
         itemMarginTop: 12,
         itemMarginBottom: 12,
         squareSymbol: true,
         symbolHeight: 25,
         symbolWidth: 30,
         symbolRadius: 100,
    },
    chart: {
        marginRight: 300,
    },

    plotOptions: {
        series: {
            label: {
                connectorAllowed: false
            },
            pointStart: 0,
            type: 'series',
            //showInLegend: false,
        }
    },        
    series: [{
        name: 'Results: '+results[2][0],
        data: results[0][0],
        type: 'spline',
        marker: {
            radius: 2
        },
    }, {
        name: 'Reach: '+results[2][1],
        data: results[0][1],
        type: 'spline',
        marker: {
            radius: 2
        },
    }, {
        name: 'Impressions: '+results[2][2],
        data: results[0][2],
        type: 'spline',
        marker: {
            radius: 2
        },
    }, { 
        name: 'Cost Per Lead: '+results[2][3],
        data: results[0][3],
        type: 'spline',
        marker: {
            radius: 2
        },
    }, {
        name: 'Spend: '+results[2][4],
        data: results[0][4],
        type: 'spline',
        marker: {
            radius: 2
        },
    }, {
        name: 'CTR (All): '+results[2][5],
        data: results[0][5],
        type: 'spline',
        marker: {
            radius: 2
        },
    }, {
        name: 'CPC (All): '+results[2][6],
        data: results[0][6],
        type: 'spline',
        marker: {
            radius: 2
        },
    }, {
        name: 'Clicks: '+results[2][7],
        data: results[0][7],
        type: 'spline',
        marker: {
            radius: 2
        },
    }],
    responsive: {
        rules: [{
            condition: {
                maxWidth: 500
            },
            chartOptions: {
                 legend: {
                 layout: 'horizontal',
                     align: 'center',
                     verticalAlign: 'bottom'
                 }
            }
        }]
    }
});
name: 'Results: '+results[2][0],
  series: [{
    name: 'Results1',
    data: [29.9, 71.5, 106.4, 129.2, 144.0, 176.0, 135.6, 148.5, 216.4, 194.1, 95.6, 54.4],
    total: [29.9, 71.5, 106.4, 129.2, 144.0, 176.0, 135.6, 148.5, 216.4, 194.1, 95.6, 54.4].reduce((tot,num)=>{return tot+num}),
    type: 'spline',
    marker: {
      radius: 5
    }
  }]
  legend: {
    labelFormatter: function() {
      return this.userOptions.name + ': ' + this.userOptions.total
    },
  },
<script src="https://code.highcharts.com/highcharts.js"></script>
<script src="https://code.highcharts.com/modules/exporting.js"></script>
<script src="https://code.highcharts.com/modules/export-data.js"></script>
<script src="https://code.highcharts.com/modules/accessibility.js"></script>

<div id="container"></div>