Skip to content

Negative line calculate stack  #9141

@mexvod

Description

@mexvod

option = {

grid: {
    left: '3%',
    right: '4%',
    bottom: '3%',
    containLabel: true
},
xAxis : [
    {
        type : 'category',
        boundaryGap : false,
        data : [1,2,3,4,5]
    }
],
yAxis : [
    {
        type : 'value'
    }
],
series : [
    {
        type:'line',
        stack: '1',
        data:[110,120, 120, 101,115]
    },
    {
        type:'line',
        stack: '1',
        label: {
            normal: {
                show: true,
                position: 'top'
            }
        },
        areaStyle: {normal: {}},
        data:[134,200, -20, 181,143]
    }
]

};

default
Negative areaStyle badly !!
Next:
option = {

grid: {
    left: '3%',
    right: '4%',
    bottom: '3%',
    containLabel: true
},
xAxis : [
    {
        type : 'category',
        boundaryGap : false,
        data : [1,2,3,4,5]
    }
],
yAxis : [
    {
        type : 'value'
    }
],
series : [
    {
        type:'line',
       
        data:[110,120, 120, 101,115]
    },
    {
        type:'line',
       
        label: {
            normal: {
                show: true,
                position: 'top'
            }
        },
        data:[134,200, 80, 181,143]
    }
]

};
default
How to make:
default
how to paint over these areas?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions