我正在 Wijmo 折线图中显示数据,其 X 值是一天中的某个时间。例如,8:00、8:05、8:10 等等。尽管我的数据点每 5 分钟一次,但我希望我的 X 轴标签仅显示整个小时。例如,8:00、9:00、10:00 等等。
目前,我只能获取 X 轴标签来反射(reflect)数据点的实际值。例如,每 5 分钟一次。
有人能引导我走向正确的方向吗?谢谢。
最佳答案
您是否将数据绑定(bind)到标签而不是系列。看起来您正在返回您的值并将其放入标签中。
seriesList: [{
legendEntry: true,
label: "timeData",
data: { x: { bind: "Date" }, y: { bind: "Count"} }
}]
Note: I was going to answer your question, but I realized I was pulling the answer from the wijmo forums and it was to your question.
关于linechart - 韦伊莫折线图 : Controlling X-Axis labels for Dates/Strings,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/12688433/