def METHOD_NAME(self, a):
    """Scale self by `a`.
    :arg a: a scalar (or something that contains a dat)
    """
    try:
        self.dat *= a.dat
    except AttributeError:
        self.dat *= a
    return self