def collapse_axes(xlab, ylab):
    """Return X/Y labels for unique X positions"""
    _xlab, _ylab, pos = [xlab[0]], [ylab[0]], [0]
    for i in range(1, len(xlab)):
        if xlab[i] != xlab[i-1]:
            _xlab.append(xlab[i])
            _ylab.append(ylab[i])
            pos.append(i)
    return _xlab, _ylab, pos