Adjust force-directed layout parameters for better stability.
- Reduced repulsion force to 0.01 - Minimized node oscillation - Improved convergence behavior
This commit is contained in:
parent
2ed5cdce5e
commit
79dc2cb62b
1 changed files with 1 additions and 1 deletions
|
|
@ -218,7 +218,7 @@ const LayoutsControl = () => {
|
||||||
maxIterations: maxIterations,
|
maxIterations: maxIterations,
|
||||||
settings: {
|
settings: {
|
||||||
attraction: 0.0003, // Lower attraction force to reduce oscillation
|
attraction: 0.0003, // Lower attraction force to reduce oscillation
|
||||||
repulsion: 0.05, // Lower repulsion force to reduce oscillation
|
repulsion: 0.01, // Lower repulsion force to reduce oscillation
|
||||||
gravity: 0.01, // Increase gravity to make nodes converge to center faster
|
gravity: 0.01, // Increase gravity to make nodes converge to center faster
|
||||||
inertia: 0.4, // Lower inertia to add damping effect
|
inertia: 0.4, // Lower inertia to add damping effect
|
||||||
maxMove: 100 // Limit maximum movement per step to prevent large jumps
|
maxMove: 100 // Limit maximum movement per step to prevent large jumps
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue