code: def rotate(obj, axis, angle, origin=None):
      '''
      Rotation around unit vector following the right hand rule
  
      Parameters:
          obj : obj to be rotated (e.g. neurite, neuron).
              Must implement a transform method.
          axis : unit vector for the axis of rotation
          angle : rotation angle in rads
  
      Returns:
          A copy of the object with the applied translation.
      '''
      R = _rodrigues_to_dcm(axis, angle)
  
      try:
          return obj.transform(PivotRotation(R, origin))
      except AttributeError:
          raise NotImplementedErrof rotate(obj, axis, angle, origin=None):
      '''
      Rotation around unit vector following the right hand rule
  
      Parameters:
          obj : obj to be rotated (e.g. neurite, neuron).
              Must implement a transform method.
          axis : unit vector for the axis of rotation
          angle : rotation angle in rads
  
      Returns:
          A copy of the object with the applied translation.
      '''
      R = _rodrigues_to_dcm(axis, angle)
  
      try:
          return obj.transform(PivotRotation(R, origin))
      except AttributeError:
          raise NotImplementedError
docs: Rotation around unit vector following the right hand rule
  
      Parameters:
          obj : obj to be rotated (e.g. neurite, neuron).
              Must implement a transform method.
          axis : unit vector for the axis of rotation
          angle : rotation angle in rads
  
      Returns:
          A copy of the object with the applied translation.