def compressing_itemset_tree(root, endswith):
    """
    compressing itemset with tree

    Parameters
    ----------
    root : tree.Node
        tree that has been fulled by itemset.
            for example : 
                apple
               //   \\
             banana
             //  \\
           mango

    endswith : str
        compress with endswith in column.
            for example : 
                = "mango"

    Returns
    -------
    dictionary of itemset and counts.
        for example :
            {"mango": 1}

    """

    return root.find_set(endswith)