简体   繁体   English

高图:更改每个单独的图/标记大小,是否可能?

[英]High Charts: Change each individual plot/marker size, is it possible?

I am trying to change the size of each plot on the following chart , is it possible? 我试图改变下中每个图的大小,是否可能?

I did try to change the line thickness however this made no difference to each individual plot on each line series. 我确实尝试改变线条粗细,但是这对每个线条系列的每个单独的图形没有区别。

series:{ [<%= GraphSeries4 %>],

                marker: {

                enabled: false

            },
                },

Graph series is a variable which collects data from an Sql database. 图形系列是一个从Sql数据库收集数据的变量。

Add lineWidth parameter in series list. series列表中添加lineWidth参数。 See this jsFiddle code. 看到这个jsFiddle代码。 Crucial code: 关键代码:

var chart = new Highcharts.Chart({
    // some other code
    series: [
        {
            name: 'Tokyo',
            data: [7.0, 6.9, 9.5, 14.5, 18.2, 21.5, 23.3, 18.3, 13.9, 9.6],
            lineWidth: 5
        }, {
            name: 'New York',
            data: [-0.2, 0.8, 5.7, 11.3, 17.0, 22.0, 20.1, 14.1, 8.6, 2.5],
            lineWidth: 15
        }
    ]
}

Also see the documentation for possible parameters. 另请参阅文档以获取可能的参数。

//EDIT //编辑

You can also change markers size on whole chart or single points. 您还可以在整个图表或单个点上更改标记大小。 See this jsFiddle . 看到这个jsFiddle And the code: 和代码:

var chart = new Highcharts.Chart({
    // some other code
    series: [
        {
            name: 'Tokyo',
            data: [7.0, 6.9, 9.5, 14.5, 18.2, 21.5, 23.3, 18.3, 13.9, 9.6],
            // marker setting for all points in this series
            marker: {
                radius: 5
            },
            lineWidth: 5
        }, {
            name: 'New York',
            // marker setting for second point only
            data: [-0.2, { y: 0.8, marker: { radius: 15 }}, 5.7, 11.3, 17.0, 22.0, 20.1, 14.1, 8.6, 2.5],
            lineWidth: 15
        }
    ]
}

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM