-
Notifications
You must be signed in to change notification settings - Fork 176
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
当数值过小时,macd图 只显示一条横线 #6
Comments
这个主要是为了底部的macd图视觉上看起来比较方便,因为当最小值和最大值都小于0.01时,基本上都是比较接近的,在视觉上呈现出来可能就不好看。所以手动设置最大值为1,视觉上就呈现出一条直线。产品需求如此,当然,你可以按照自己的需求来修改 |
怎么说,如果目的是想用在虚拟币上,有得币种兑换时,比例确实会 非常小,所以 个人感觉如果是以仿火币为 主题,这块是不能做限制的 |
的确是这样,将这段代码注释掉,展示的基本上是充满macd绘图区间的,只能看运营方面想要什么效果 |
所以咋解决的现在?我就是用在虚拟币上面,很多小数值的数据,看起来都就是一条线了 |
求解 |
求解,虚拟币很多小币种,运行起来就是线连着一起看不清楚了 |
动态计算最大最小差值 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
当数值过小时,macd图 只显示一条横线,但是他们基本都相差 大约 0.000001。
现在 解决办法是 将
if (Math.abs(mChildMaxValue) < 0.01 && Math.abs(mChildMinValue) < 0.01) {
mChildMaxValue = 1f;
}
注释掉,请问这 个判断的作用是什么?不处理过小的数吗?
The text was updated successfully, but these errors were encountered: