Layouts
EcologicalNetworksPlots.BipartiteInitialLayout
— TypeBipartiteInitialLayout
This type is used to generate an initial bipartite layout, where the nodes are placed on two levels, but their horizontal position is random.
EcologicalNetworksPlots.NestedBipartiteLayout
— TypeNestedBipartiteLayout
Parameters are
align
(whether the two levels should be centered together)relative
(whether the two levels should occupy a length equal to their relative richness)spread
(the distance between the two)
Note that to see the effect of spread
, you may have to use aspectratio=1
; if not, the spacing between levels will be determined by the dimensions of the plot.
Example
Unes = web_of_life("M_SD_033")
I = initial(BipartiteInitialLayout, Unes)
position!(NestedBipartiteLayout(0.4), I, Unes)
plot(I, Unes, aspectratio=1)
scatter!(I, Unes, bipartite=true)