Skip to content

Commit 8471dcb

Browse files
author
mahdis-z
committed
minor revisions
1 parent a97dee1 commit 8471dcb

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

python/sankey-diagram.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ fig.show()
134134

135135
### Define Node Position
136136

137-
The following axample sets [node.x](https://plot.ly/python/reference/#sankey-node-x) and [node.y](https://plot.ly/python/reference/#sankey-node-y) to place nodes in the specified locations, except in the [snap arrangement](https://plot.ly/python/reference/#sankey-arrangement) to avoid overlapping of the nodes, therefore, an automatic snapping of elements will be set to define the padding between nodes via [nodepad](https://plot.ly/python/reference/#sankey-node-pad). The other possible arrangements are:<font color='blue'> 1)</font> perpendicular <font color='blue'>2)</font> freeform <font color='blue'>3)</font> fixed
137+
The following example sets [node.x](https://plot.ly/python/reference/#sankey-node-x) and `node.y` to place nodes in the specified locations, except in the `snap arrangement` (default behaviour when `node.x` and `node.y` are not defined) to avoid overlapping of the nodes, therefore, an automatic snapping of elements will be set to define the padding between nodes via [nodepad](https://plot.ly/python/reference/#sankey-node-pad). The other possible arrangements are:<font color='blue'> 1)</font> perpendicular <font color='blue'>2)</font> freeform <font color='blue'>3)</font> fixed
138138

139139
```python
140140
import plotly.graph_objects as go
@@ -145,7 +145,7 @@ fig = go.Figure(go.Sankey(
145145
"label": ["A", "B", "C", "D", "E", "F"],
146146
"x": [0.2, 0.1, 0.5, 0.7, 0.3, 0.5],
147147
"y": [0.7, 0.5, 0.2, 0.4, 0.2, 0.3],
148-
'pad':10},
148+
'pad':10}, # 10 Pixels
149149
link = {
150150
"source": [0, 0, 1, 2, 5, 4, 3, 5],
151151
"target": [5, 3, 4, 3, 0, 2, 2, 3],

0 commit comments

Comments
 (0)