Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

折线图中最大最小值显示不正确 #3646

Closed
swbuild1988 opened this issue Jul 15, 2016 · 3 comments
Closed

折线图中最大最小值显示不正确 #3646

swbuild1988 opened this issue Jul 15, 2016 · 3 comments
Labels
pending We are not sure about whether this is a bug/new feature. stale Inactive for a long time. Will be closed in 7 days.

Comments

@swbuild1988
Copy link

swbuild1988 commented Jul 15, 2016

问题简述 (One-line summary)

折线图中加载了大概超过7,8k的数据,当添加markPoint的时候,直接调用了'max'和'min',现在折线图中标记的最大点最小点,在原数据中就没有这个值,感觉是经过拟合计算出来的一个极值。

ps:加载的数值都是2位小数的

求教怎样才能显示真实的最大最小值

版本及环境 (Version & Environment)

  • ECharts 版本 (ECharts version):3.2.2
  • 浏览器类型和版本 (Browser version):Chrome
  • 操作系统类型和版本 (OS Version):win7/win10

期望结果 (Expected behaviour)

极值显示为正常的值

可能哪里有问题 (What went wrong)

图上的并没有加载所有的数据,而是经过计算拟合的部分数据

ECharts配置项 (ECharts option)

option = {
            xAxis: {
                data: labels
            },
            yAxis: {
                min: avg - 10,
                max: avg + 10
            },
            series: [{
                name: '数据',
                data: datas,
                markPoint: {
                    symbolSize: 80,
                    data: [
                        { type: 'min', name: '最小值' },
                        { type: 'max', name: '最大值'}
                    ]
                },
                markLine: {
                    data: [
                        { type: 'average', name: '平均值' }
                    ]
                }
            }]
}

其他信息 (Other comments)

echartbug

@shaohualiang
Copy link

根据数据显示的样式,数据进行呈现的时候,最好只保留2到3位小数。

@pissang pissang closed this as completed Jul 21, 2016
@pissang pissang reopened this Jul 21, 2016
@swbuild1988
Copy link
Author

1.所有的数据都是两位的了
2.是否在markPoint中有特殊的样式设定(2位小数),在文档中没有找到对应的说明

@pissang pissang added the pending We are not sure about whether this is a bug/new feature. label Jul 31, 2016
@zhangming8691
Copy link

请问最大最小值这个倒水滴的样式可以改吗,想设置程横条样式,方便显示数据。 @shaohualiang ,谢谢。

@Ovilia Ovilia added the stale Inactive for a long time. Will be closed in 7 days. label Jul 8, 2019
@stale stale bot closed this as completed Jul 15, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pending We are not sure about whether this is a bug/new feature. stale Inactive for a long time. Will be closed in 7 days.
Projects
None yet
Development

No branches or pull requests

5 participants