Here is how my graph looks like:
I wan't the y axis to have an interval of 50 so i try doing this:
var axisSet: CPTXYAxisSet = CPTXYAxisSet(layer: graph.axisSet)
var y = axisSet.yAxis
y.majorIntervalLength = 50
But majorIntervalLength doesn't seems to exist
Swift doesn't support NSDecimal
values. We've made some changes to the Core Plot API, replacing NSDecimal
with NSDecimalNumber
. The changes are on the release-2.0
branch and not in a release package yet. See Core Plot issue #96 for more discussion of the issue.
来源:https://stackoverflow.com/questions/27204557/coreplot-with-swift-there-is-no-yaxis-majorintervallength