# GraphMakie with scale

**URL:** https://discourse.julialang.org/t/graphmakie-with-scale/79961
**Category:** General Usage
**Tags:** question
**Created:** [April 24, 2022, 9:45pm UTC](https://discourse.julialang.org/t/graphmakie-with-scale/79961 "2022-04-24T21:45:40Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![Yuri\_Mizusawa](https://avatars.discourse-cdn.com/v4/letter/y/e480ec/32.png) [@Yuri\_Mizusawa](https://discourse.julialang.org/u/Yuri_Mizusawa)
#### Post date: [April 24, 2022, 9:45pm UTC](https://discourse.julialang.org/t/graphmakie-with-scale/79961/1 "2022-04-24T21:45:40Z")

</div>

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!

---

<div class="post-metadata">

### Author: ![hexaeder](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/hexaeder/32/24403_2.png) [@hexaeder](https://discourse.julialang.org/u/hexaeder)
#### Post date: [April 26, 2022, 4:52am UTC](https://discourse.julialang.org/t/graphmakie-with-scale/79961/2 "2022-04-26T04:52:13Z")

</div>

What do you mean with scale?

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

```julia
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.

---

<div class="post-metadata">

### Author: ![Yuri\_Mizusawa](https://avatars.discourse-cdn.com/v4/letter/y/e480ec/32.png) [@Yuri\_Mizusawa](https://discourse.julialang.org/u/Yuri_Mizusawa)
#### Post date: [April 26, 2022, 10:05pm UTC](https://discourse.julialang.org/t/graphmakie-with-scale/79961/3 "2022-04-26T22:05:02Z")

</div>

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! | | |

---

<div class="post-metadata">

### Author: ![lazarusA](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/lazarusa/32/6571_2.png) [@lazarusA](https://discourse.julialang.org/u/lazarusA)
#### Post date: [April 26, 2022, 10:18pm UTC](https://discourse.julialang.org/t/graphmakie-with-scale/79961/4 "2022-04-26T22:18:58Z")

</div>

just do

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

```

a more complicated here: [Combine Makie with GMT.jl - #6 by lazarusA](https://discourse.julialang.org/t/combine-makie-with-gmt-jl/74347/6) shows this in action.
