Plotting a weighted tree graph

As other people mentioned, you can also use GraphMakie.jl

Bucheim breaks with your graph because it assumes double edges and a node cannot have multiple parent nodes.
If this is not a deal breaker you can work it around with SimpleWeightedDiGraph:

using GraphMakie

g = SimpleWeightedDiGraph(5)    
add_edge!(g, 1, 2, 0.5)    
add_edge!(g, 1, 3, 2.0)    
add_edge!(g, 1, 4, 3.5)    
add_edge!(g, 1, 5, 5.0)    
     
edws = [get_weight(g, e.src, e.dst) for e in edges(g)]    
            
graphplot(g, layout=NetworkLayout.Buchheim(), edge_width=edws, arrow_size=5 .+ 5 .* edws)                

1 Like