Dear list,

I am trying to render a *directed* graph with LaTeX and tikz. I'ts a 
Bayesian network based on some causal reasoning (hence the necessity for a 
directed graph), but I'll reduce my problem to a simple test case.

The following code :

var("a", latex_name="\mathrm{a}")
var("b", latex_name="\mathrm{b}")
var("c", latex_name="\mathrm{c}")
var("d", latex_name="\mathrm{d}")
var("e", latex_name="\mathrm{e}")
H=DiGraph({a:{b:'$\\beta_{a,b}$',c:'$\\beta_{a,c}$',d:'$\\beta_{a,d}$'}, 
c:{e:'$\\beta_{c,e}$'}})
H.set_pos(H.layout_acyclic())
H.set_latex_options(tkz_style="Custom", graphic_size=(4,4), 
vertex_size=0.5, vertex_labels=True, edge_labels=True, 
edge_label_sloped=False)
view(H)

gives me *almost* what I want (drag-and-drop from a notebook] :


The graph has the desired layout, the markup (vertices and edges) is 
correct. But, for reasons I haven't be able to fathom,  edges are rendered 
as circle arcs (about pi/6). It is not especially good in my test case, and 
makes my full graph positively awful...

Trying to use another style of graph makes me lose [a) edge markup and/or 
b) vertex markup], and c) arrow heads. Looking in the documentation about 
arrow heads gave no clue. Trying to specify latex parameters for edges and 
vertices has no point, since these setups are forgotten by the new style 
(and yes, I tried to use two set_latex_options instructions : same results 
in both orders...).

Any hint ?

                                                Emmanuel Charpentier

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To post to this group, send email to sage-support@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to