Write in dotfile a graph equivalent to those depicted in bubble file

    See http://graphviz.readthedocs.io/en/latest/examples.html#cluster-py
    for graphviz API

def tree_to_dot(tree:BubbleTree, dotfile:str=None, render:bool=False):
    """Write in dotfile a graph equivalent to those depicted in bubble file

    See http://graphviz.readthedocs.io/en/latest/examples.html#cluster-py
    for graphviz API

    """
    graph = tree_to_graph(tree)
    path = None
    if dotfile:  # first save the dot file.
        path = graph.save(dotfile)
    if render:  # secondly, show it.
        # As the dot file is known by the Graph object,
        # it will be placed around the dot file.
        graph.view()
    return path