def map_to_linear(self, with_stocks: bool=False):
result = []<EOL>for ac in self.model.classes:<EOL><INDENT>rows = self.__get_ac_tree(ac, with_stocks)<EOL>result += rows<EOL><DEDENT>return result<EOL>
Maps the tree to a linear representation suitable for display