Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/javascript/463.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Javascript 散点图:如何将序列名称放入函数中_Javascript_Jquery_Highcharts_Scatter Plot - Fatal编程技术网

Javascript 散点图:如何将序列名称放入函数中

Javascript 散点图:如何将序列名称放入函数中,javascript,jquery,highcharts,scatter-plot,Javascript,Jquery,Highcharts,Scatter Plot,因此,我想调用这组数据中的“名称”,以便在脚本另一部分的函数中使用 我可以通过使用调用ticker、x、info和hover变量 event.point.ticker,event.point.info 但我还不知道怎么知道这部剧的名字。我试过很多东西,比如 series.name、this.series.name和event.point.name、this.chart.name 都没有用。这是数据 series: [{ name: 'Weak Outlook',color: 'red'

因此,我想调用这组数据中的“名称”,以便在脚本另一部分的函数中使用

我可以通过使用调用ticker、x、info和hover变量

event.point.ticker,event.point.info

但我还不知道怎么知道这部剧的名字。我试过很多东西,比如

series.name、this.series.name和event.point.name、this.chart.name

都没有用。这是数据

series: 
[{
    name: 'Weak Outlook',color: 'red',data: 
    [{
        x: 40,
        y:10,
        ticker:'Michael Kors: (KORS)',
        info: 'Outlook roughly inline<br>1Q Revenue below street expectations', hover:'Guidance slightly below consensus<br>1Q Revenue to disappoint<br><a href="">read more</a>'
    },
    {
        x: 20,
        y:50,
        ticker:'Shares to sell off on earnings',
        info:'Data implies that shares, after management releases Q1 guidance, will...<br><br><a href="">read more</a>'
    },
    {
        x:0,y:0,ticker:'Zynga: (ZNGA)'
    },
    {
        x:3,y:4,ticker:'Avid: (AVID)'
    },
    {
        x:4,y:10,ticker:'JCPenny: (JCP)'
    },
    {
        x:6,y:25,ticker:'Deckers Outdoor: (DECK)'},
    {
        x:0,y:100,ticker:'Nutrisystem Corp: (NTRI)'
    },
]}],

您需要
event.point.series.name
每个点都包含对其父系列的引用

应触发哪个事件和元素(点/系列)以显示其他信息?
click: function(event,series) 
{
    xmlhttp.open("GET","/s.php?o="+event.point.ticker+"&q="+event.point.y+"&r="+event.point.x+"&s="+event.point.info+"&t="+series.name+"&u="+event.point.str5+"&v="+event.point.str6,true);