mirror of
https://gitee.com/antv/g6.git
synced 2024-12-15 18:11:08 +08:00
17 lines
793 B
Markdown
17 lines
793 B
Markdown
|
---
|
||
|
title: Circular Layout
|
||
|
order: 4
|
||
|
---
|
||
|
|
||
|
Circular layout orders the nodes according to the configuration, and then places the nodes on a circle.
|
||
|
|
||
|
## Usage
|
||
|
|
||
|
As the demo below, you can deploy it in `layout` while instantiating Graph. it can also be used for [Subgraph Layout](/en/docs/manual/middle/layout/sub-layout). By tuning the configurations, you can adjust the radius, start angle, end angle, nodes' order method, divisions, spiral style, and so on.
|
||
|
|
||
|
- Example 1 : Basic Circular Layout, the nodes are placed on the circle clockwise in the data order.
|
||
|
- Example 2 : The nodes are placed on the circle clockwise according to their degrees.
|
||
|
- Example 3 : Spiral layout.
|
||
|
- Example 4 : Divide the nodes into several divisions on the circle.
|
||
|
- Example 5 : Translate the parameters in dynamic.
|