cosValue = Math.cos(Math.toRadians(angle));
Region tick = ticks.get(index);
if (angle % 30 == 0) {
tick.setPrefWidth(size * majorTickWidthFactor);
tick.setPrefHeight(size * majorTickHeightFactor);
tick.relocate(size * 0.5 + ((size * (radius + majorTickOffset) * sinValue) - (size * (majorTickWidthFactor) * 0.5)),
size * 0.5 + ((size * (radius + majorTickOffset) * cosValue) - (size * (majorTickHeightFactor) * 0.5)));
} else {
tick.setPrefWidth(size * minorTickWidthFactor);
tick.setPrefHeight(size * minorTickHeightFactor);
tick.relocate(size * 0.5 + ((size * (radius + minorTickOffset) * sinValue) - (size * (minorTickWidthFactor) * 0.5)),