GraphMakie with scale

I am using the GraphMakie to make graphs, it is working very well, but I wanted to know if there is a way to add scale to the graphs, similar to a scatter plot.
I tryed the documentation but did’t find anything about it.
Anyone have any idea how or if there is an alternative?
Thanks!

What do you mean with scale?

The only thing I can think of is a colorbar… in that case use

f, ax, p = graphplot(…)
pn = get_node_plot(p)

To extract the scatter plot object from the graph plot pn. You may then proceed as with every other scatter plot.

Hi,
Thanks for the answer, I migth not be explaining well so I’ll try to use will use an example table.
I have the following graph to make:

from to
1 2
2 3
3 1

Each node have the following coordinate :

node x y
1 1 1
2 1 5
3 5 1
When I plot the graph it does not take in account the position of each node, so the final result is a circle (my data has 20 around nodes). I would like to have each node in it’s respective coordinate and have the final obtained graph ploted.
I hope it makes more sense now, as I’m not sure if graphs is the best option for this.
Hhanks!

just do

graphplot(ax, g; layout = _ -> positions)

a more complicated here: Combine Makie with GMT.jl - #6 by lazarusA shows this in action.

1 Like