0

I would like to ask how to plot a decision tree in python. The functionality which I mean is similar to one in this question, but a picture is needed, not just text format.

For example, having this dictionary structure

MyNodeStructure = {'main': {'load': {'regA': None},
                            'comupute': {'loop': {'regA': None,
                                                  'regB': None}},
                            'store': None}}

I would like to get something like this as an output: Example of desired tree.

Do you know any module/easy way how to achieve this result in Python3?

Tomato
  • 9
  • 3
  • Most likely pydot is what you're after. See this question + answer for discussion of making a pydot pic from a dict: https://stackoverflow.com/questions/24657384/plotting-a-decision-tree-with-pydot – greg_data Apr 11 '18 at 15:14
  • 1
    @greg_data Oh, pretty much what I wanted, except few insignificant details. I must have overlooked that question, thank you! – Tomato Apr 12 '18 at 13:27

0 Answers0