Skip to content

Commit 49daafa

Browse files
authored
Update README.md
add dev docs batch
1 parent 3cfeeef commit 49daafa

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

README.md

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
Layout algorithms for graphs and trees in pure Julia.
33

44
[![Stable](https://img.shields.io/badge/docs-stable-blue.svg)](https://juliagraphs.org/NetworkLayout.jl/stable)
5+
[![Dev](https://img.shields.io/badge/docs-dev-blue.svg)](https://juliagraphs.org/NetworkLayout.jl/dev/)
56
[![Build Status](https://github.com/JuliaGraphs/NetworkLayout.jl/workflows/CI/badge.svg)](https://github.com/JuliaGraphs/NetworkLayout.jl/actions)
67
[![Coverage](https://codecov.io/gh/JuliaGraphs/NetworkLayout.jl/branch/master/graph/badge.svg)](https://codecov.io/gh/JuliaGraphs/NetworkLayout.jl)
78

@@ -13,7 +14,6 @@ pkg> add NetworkLayout.jl
1314
The available algorithms and their parameters can be found in the
1415
[docs](https://juliagraphs.org/NetworkLayout.jl/stable).
1516

16-
1717
All of the algorithms represent mappings `adjacency matrix ↦ vector of
1818
positions` where the positions are represented by the `Point` datatype from
1919
[`GeometryBasics.jl](https://github.com/JuliaGeometry/GeometryBasics.jl)
@@ -24,6 +24,12 @@ using LightGraphs
2424

2525
adj_matrix = adjacency_matrix(wheel_graph(10))
2626

27-
algorithm = NetworkLayout.Spring(; iterations=20)
27+
pos = spring(adj_matrix; iterations=20)
2828
pos = algorithm(adj_matrix)
2929
```
30+
There is also a "delayed" functor version of each algorithm:
31+
```julia
32+
layout = Spring(; iterations=20)
33+
pos = layout(adj_matrix)
34+
```
35+
Instead of passing a adjacency matrix on can also pass `LightGraphs.jl` graphs directly.

0 commit comments

Comments
 (0)