neat.MorphTree.color_x_axis¶
- MorphTree.color_x_axis(ax, cmap, add_scalebar=1)[source]¶
Color the x-axis of a plot according to the morphology.
!!! Has to be called after all lines are plotted !!!
Furthermor, node colors have to be set first. This can be done with MorphTree.set_node_colors() or manually by adding a ‘color’ entry to the
MorphNode.contentdictionary- Parameters:
ax (matplotlib.axes.Axes instance) – the ax object of which the x-axis will be colored
cmap (matplotlib.colors.Colormap instance) – Colormap that determines the color of each branch
sizex (float) – Size of scalebar (in micron). If set to None, no scalebar is plotted.