We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
坐标轴显示精度保留了是几位数的精度,但这应该并不是我们预期的效果,请问这个问题该如何解决? 坐标配置如下: const battery = new Chart({ container: 'Battery', width: 1328, height: 400, }); battery.data(this.ctempData) battery.scale({ time: { tickCount: 20 }, ctemp: { // nice: true, tickCount: 12 } }); battery.axis('ctemp', { line:{ }, tickLine:{ }, title:{ text:'温度' }, grid:null
} )
效果图如下: 实际的坐标数据如下:
The text was updated successfully, but these errors were encountered:
试试tickInterval:0.1调整刻度间距,或者自定义刻度格式
tickInterval:0.1
formatter:(val)=>`${Number.parseFloat(val).toFixed(1)}`
tickInterval示例代码
Sorry, something went wrong.
rainy-25Ghz
No branches or pull requests
Reproduction link
Steps to reproduce
坐标轴显示精度保留了是几位数的精度,但这应该并不是我们预期的效果,请问这个问题该如何解决?
坐标配置如下:
const battery = new Chart({
container: 'Battery',
width: 1328,
height: 400,
});
battery.data(this.ctempData)
battery.scale({
time: {
tickCount: 20
},
ctemp: {
// nice: true,
tickCount: 12
}
});
battery.axis('ctemp',
{
line:{
},
tickLine:{
},
title:{
text:'温度'
},
grid:null
效果图如下:
实际的坐标数据如下:
The text was updated successfully, but these errors were encountered: