Har*_*ish 1 ios swift ios-charts
在iOS Chart Framework中,图表中的y值是重复的.如下图所示,图表中有多个0和1.
无论如何我可以自定义此图表,因此没有任何重复的y值.因此,在这种情况下,理想情况下,y值应为1,2,3,4,5.我只是不希望y值重复出现.
你也可以尝试:
/// When true, axis labels are controlled by the `granularity` property.
/// When false, axis values could possibly be repeated.
/// This could happen if two adjacent axis values are rounded to same value.
/// If using granularity this could be avoided by having fewer axis values visible.
public var granularityEnabled = false
Run Code Online (Sandbox Code Playgroud)
并设置yAxis.granularity=某个值