function positionLabels(s, angle) {
        s.each(function(d) {
            var thisLabel = d3.select(this);
            var mathjaxGroup = thisLabel.select('.text-math-group');
            var anchor = labelFns.anchorFn(d, angle);

            var transform = opts.transFn.call(thisLabel.node(), d) +
                ((isNumeric(angle) && +angle !== 0) ?
                (' rotate(' + angle + ',' + labelFns.xFn(d) + ',' +
                    (labelFns.yFn(d) - d.fontSize / 2) + ')') :
                '');

            // how much to shift a multi-line label to center it vertically.
            var nLines = svgTextUtils.lineCount(thisLabel);
            var lineHeight = LINE_SPACING * d.fontSize;
            var anchorHeight = labelFns.heightFn(d, isNumeric(angle) ? +angle : 0, (nLines - 1) * lineHeight);

            if(anchorHeight) {
                transform += strTranslate(0, anchorHeight);
            }

            if(mathjaxGroup.empty()) {
                var thisText = thisLabel.select('text');
                thisText.attr({
                    transform: transform,
                    'text-anchor': anchor
                });

                thisText.style('opacity', 1); // visible

                if(ax._adjustTickLabelsOverflow) {
                    ax._adjustTickLabelsOverflow();
                }
            } else {
                var mjWidth = Drawing.bBox(mathjaxGroup.node()).width;
                var mjShift = mjWidth * {end: -0.5, start: 0.5}[anchor];
                mathjaxGroup.attr('transform', transform + strTranslate(mjShift, 0));
            }
        });
    }
Draw axis tick labels

@param {DOM element} gd
@param {object} ax (full) axis object
 - {string} _id
 - {boolean} showticklabels
 - {number} tickangle
 - {object (optional)} _selections
 - {object} (optional)} _tickAngles
 - {object} (optional)} _prevTickAngles
@param {object} opts
- {array of object} vals (calcTicks output-like)
- {d3 selection} layer
- {string (optional)} cls (node className)
- {boolean} repositionOnUpdate (set to true to reposition update selection)
- {boolean} secondary
- {fn} transFn
- {object} labelFns
 + {fn} xFn
 + {fn} yFn
 + {fn} anchorFn
 + {fn} heightFn