$phi$
对于此网络,我想要一个无向虚线链接,而不是和之间的虚线箭头$\sigma_y$
。我不知道该怎么做。
谢谢
\documentclass[11pt]{report}
\usepackage{tikz}
\usetikzlibrary{bayesnet}
\begin{document}
\begin{figure}
\centering
\tikz{ %
\node[latent] (phi) {$\phi$};
\node[latent, above=of phi] (f) {$f$};
\node[obs, left=of f] (y) {$\bf{y}$};
\node[latent, below =of y] (sigma) {$\sigma_y$};
\edge {phi} {f};
\edge {f, sigma} {y};
\plate[inner sep=0.25cm, xshift=-0.12cm, yshift=0.12cm] {plate3} {(phi) (f) (y) (sigma)} {W}; %
\edge [dashed] {phi} {sigma};
}
\end{figure}
\end{document}
答案1
只需将选项-
(无箭头的箭头)添加到相关边缘即可。这将覆盖默认设置。
\documentclass[11pt]{report}
\usepackage{tikz}
\usetikzlibrary{bayesnet}
\begin{document}
\begin{figure}
\centering
\tikz{ %
\node[latent] (phi) {$\phi$};
\node[latent, above=of phi] (f) {$f$};
\node[obs, left=of f] (y) {$\bf{y}$};
\node[latent, below =of y] (sigma) {$\sigma_y$};
\edge {phi} {f};
\edge {f, sigma} {y};
\plate[inner sep=0.25cm, xshift=-0.12cm, yshift=0.12cm] {plate3} {(phi) (f) (y) (sigma)} {W}; %
\edge [dashed,-] {phi} {sigma};
% add here ---^
}
\end{figure}
\end{document}