treefit.plot

treefit.plot(*fits)[source]

Plot estimated results to get insight.

Parameters

*fits ([treefit.fit.Fit]) – The estimated results by treefit.treefit() to be visualized.

Examples

>>> import treefit
# Generate a tree data.
>>> tree = treefit.data.generate_2d_n_arms_star_data(200, 3, 0.1)
# Estimate the goodness-of-fit between tree models and the tree data.
>>> fit = treefit.treefit({"expression": tree}, "tree")
# Visualize the estimated result.
>>> treefit.plot(fit)
# You can mix multiple estimated results by adding "name" column.
>>> tree2 = treefit.data.generate_2d_n_arms_star_data(200, 3, 0.9)
>>> fit2 = treefit.treefit({"expression": tree2}, "tree2")
>>> treefit.plot(fit, fit2)