finish(self)
Return value is a list of subdiagrams represented with the following fields:
=============== =================================================== Field Description =============== =================================================== patch Sankey outline (an instance of
~matplotlib.patches.PathPatch
) flows values of the flows (positive for input, negative for output) angles list of angles of the arrows [deg/90] For example, if the diagram has not been rotated, an input to the top side will have an angle of 3 (DOWN), and an output from the top side will have an angle of 1 (UP). If a flow has been skipped (because its magnitude is less than tolerance), then its angle will be None. tips array in which each row is an [x, y] pair indicating the positions of the tips (or "dips") of the flow paths If the magnitude of a flow is less the tolerance for the instance ofSankey
, the flow is skipped and its tip will be at the center of the diagram. text~matplotlib.text.Text
instance for the label of the diagram texts list of~matplotlib.text.Text
instances for the labels of flows =============== ===================================================
Adjust the axes and return a list of information about the Sankey subdiagram(s).
The following pages refer to to this document either explicitly or contain code examples using this.
matplotlib.sankey.Sankey.__init__
matplotlib.sankey.Sankey.add
Hover to see nodes names; edges to Self not shown, Caped at 50 nodes.
Using a canvas is more power efficient and can get hundred of nodes ; but does not allow hyperlinks; , arrows or text (beyond on hover)
SVG is more flexible but power hungry; and does not scale well to 50 + nodes.
All aboves nodes referred to, (or are referred from) current nodes; Edges from Self to other have been omitted (or all nodes would be connected to the central node "self" which is not useful). Nodes are colored by the library they belong to, and scaled with the number of references pointing them