class_docstr: A line axis.
  
  A line axis is the visual representation of a **numerical** or **date scale**.
  
  Attributes
  ----------
  icon: string (class-level attribute)
      The font-awesome icon name for this object.
  axis_types: dict (class-level attribute)
      A registry of existing axis types.
  orientation: {'horizontal', 'vertical'}
      The orientation of the axis, either vertical or horizontal
  side: {'bottom', 'top', 'left', 'right'} or None (default: None)
      The side of the axis, either bottom, top, left or right.
  label: string (default: '')
      The axis label
  tick_format: string or None (default: '')
      The tick format for the axis, for dates use d3 string formatting.
  scale: Scale
      The scale represented by the axis
  num_ticks: int or None (default: None)
      If tick_values is None, number of ticks
  tick_values: numpy.ndarray or None (default: None)
      Tick values for the axis
  tick_labels: dict (default: None)
      Override the tick labels with a dictionary of {value: label}.
      Entries are optional, and if not provided, the default tick labels
      will be used.
  offset: dict (default: {})
      Contains a scale and a value {'scale': scale or None,
      'value': value of the offset}
      If offset['scale'] is None, the corresponding figure scale is used
      instead.
  label_location: {'middle', 'start', 'end'}
      The location of the label along the axis, one of 'start', 'end' or
      'middle'
  label_color: Color or None (default: None)
      The color of the axis label
  grid_lines: {'none', 'solid', 'dashed'}
      The display of the grid lines
  grid_color: Color or None (default: None)
      The color of the grid lines
  color: Color or None (default: None)
      The color of the line
  label_offset: string or None (default: None)
      Label displacement from the axis line. Units allowed are 'em', 'px'
      and 'ex'. Positive values are away from the figure and negative
      values are towards the figure with respect to the axis line.
  visible: bool (default: True)
      A visibility toggle for the axis
  tick_style: Dict (default: {})
      Dictionary containing the CSS-style of the text for the ticks.
      For example: font-size of the text can be changed by passing
      `{'font-size': 14}`
  tick_rotate: int (default: 0)
      Degrees to rotate tick labels by.
class_docstr_tok: ["A","line","axis",".","A","line","axis","is","the","visual","representation","of","a","*","*","numerical","*","*","or","*","*","date","scale","*","*",".","Attributes","--","--","--","--","--","icon",":","string","(","class-level","attribute",")","The","font-awesome","icon","name","for","this","object",".","axis_types",":","dict","(","class-level","attribute",")","A","registry","of","existing","axis","types",".","orientation",":","{","'horizontal","'",",","'vertical","'","}","The","orientation","of","the","axis",",","either","vertical","or","horizontal","side",":","{","'bottom","'",",","'top","'",",","'left","'",",","'right","'","}","or","None","(","default",":","None",")","The","side","of","the","axis",",","either","bottom",",","top",",","left","or","right",".","label",":","string","(","default",":","``",")","The","axis","label","tick_format",":","string","or","None","(","default",":","``",")","The","tick","format","for","the","axis",",","for","dates","use","d3","string","formatting",".","scale",":","Scale","The","scale","represented","by","the","axis","num_ticks",":","int","or","None","(","default",":","None",")","If","tick_values","is","None",",","number","of","ticks","tick_values",":","numpy.ndarray","or","None","(","default",":","None",")","Tick","values","for","the","axis","tick_labels",":","dict","(","default",":","None",")","Override","the","tick","labels","with","a","dictionary","of","{","value",":","label","}",".","Entries","are","optional",",","and","if","not","provided",",","the","default","tick","labels","will","be","used",".","offset",":","dict","(","default",":","{","}",")","Contains","a","scale","and","a","value","{","'scale","'",":","scale","or","None",",","'value","'",":","value","of","the","offset","}","If","offset","[","'scale","'","]","is","None",",","the","corresponding","figure","scale","is","used","instead",".","label_location",":","{","'middle","'",",","'start","'",",","'end","'","}","The","location","of","the","label","along","the","axis",",","one","of","'start","'",",","'end","'","or","'middle'","label_color",":","Color","or","None","(","default",":","None",")","The","color","of","the","axis","label","grid_lines",":","{","'none","'",",","'solid","'",",","'dashed","'","}","The","display","of","the","grid","lines","grid_color",":","Color","or","None","(","default",":","None",")","The","color","of","the","grid","lines","color",":","Color","or","None","(","default",":","None",")","The","color","of","the","line","label_offset",":","string","or","None","(","default",":","None",")","Label","displacement","from","the","axis","line",".","Units","allowed","are","'em","'",",","'px'","and","'ex","'",".","Positive","values","are","away","from","the","figure","and","negative","values","are","towards","the","figure","with","respect","to","the","axis","line",".","visible",":","bool","(","default",":","True",")","A","visibility","toggle","for","the","axis","tick_style",":","Dict","(","default",":","{","}",")","Dictionary","containing","the","CSS-style","of","the","text","for","the","ticks",".","For","example",":","font-size","of","the","text","can","be","changed","by","passing","`","{","'font-size","'",":","14","}","`","tick_rotate",":","int","(","default",":","0",")","Degrees","to","rotate","tick","labels","by","."]
code: def _observe_side(self, change):
      side = change["new"]
  
      if side in ["left", "right"] and self.orientation != "vertical":
          self.orientation = "vertical"
  
      if side in ["bottom", "top"] and self.orientation != "horizontal":
          self.orientation = "horizontal"
  
file_path: bqplot/bqplot/axes.py
imports: from traitlets import observe, Int, Unicode, Instance, Enum, Dict, Bool
  from traittypes import Array
  from ipywidgets import Widget, Color, widget_serialization
  from bqscales import Scale, ColorScale
  from .traits import array_serialization, array_dimension_bounds
  from ._version import __frontend_version__
label_desc: Use image node_id 4 for calling the Axis obj's underlying member method code with example usage: obj._observe_side(change) without return types