'Adjust the text angle and text alignment of ticklabels
according to the matplotlib convention.
The *label_direction* must be one of [left, right, bottom,
top].
property                 left       bottom    right      top
ticklabels angle         90         0         -90        180
ticklabel va             center     baseline  center     baseline
ticklabel ha             right      center    right      center
Note that the text angles are actually relative to (90 + angle
of the direction to the ticklabel), which gives 0 for bottom
axis.'

def set_axis_direction(self, label_direction):

    if (label_direction not in [u'left', u'right', u'top', u'bottom']):
        raise ValueError(u'direction    must    be    one    of    "left",    "right",    "top",    "bottom"')
    self._axis_direction = label_direction
    self.set_default_alignment(label_direction)
    self.set_default_angle(label_direction)
