def is_empty(data):
    """
    Checks if an object, particularly :class:`Series` and :class:`DataFrame`,
    contains any values.

    .. note:: 
        ``DataFrame`` objects have an ``empty`` attribute, but ``Series`` don't.
        This function allows you to check both data structures using only one 
        function.
    """
    try:
        return not bool(data)
    except ValueError:
        pass
    try:
        return data.empty
    except AttributeError:
        if data.tolist():
            return False
        return True
