TikZ 树中的箭头

TikZ 树中的箭头

我一直在尝试创建一棵由父节点和节点组成的树,节点之间用箭头连接。我几乎创建出了我想要的东西,只是箭头指向了错误的方向。

有人可以帮忙吗?

\begin{tikzpicture}[ 
label distance=3mm,
every label/.style={blue},
event/.style={rectangle,thick,draw,text width=3cm,text centered,anchor=north},
edge from parent/.style={very thick,draw=black!70,-latex},
edge from parent path={(\tikzparentnode.south) -- ++(0,-0.50cm)-| (\tikzchildnode.north)},
level 1/.style={sibling distance=4cm,level distance=1cm,growth parent anchor=south,nodes=event},
level 2/.style={sibling distance=4cm},
]
\node [event] {result}
    child {node {cause1}}
    child {node {cause2}}
    child {node {cause3}
        child{ node {subcause31}}
        child{ node {subcause32}}
        child{ node {subcause33}}
        };\end{tikzpicture}]

答案1

用替换-latex样式。edge from parentlatex-

相关内容