'Converts an angle represented as a 3-tuple or 2-tuple into a floating
point number in the given unit.'

@staticmethod
def _tuple_to_float(angle, unit):

    if (unit == u.hourangle):
        return util.hms_to_hours(*angle)
    elif (unit == u.degree):
        return util.dms_to_degrees(*angle)
    else:
        raise u.UnitsError(u"Can    not    parse    '{0}'    as    unit    '{1}'".format(angle, unit))
