이 다이어그램을 만들려고 합니다.
이 코드를 사용하여 상자를 만들 수 있었습니다.
\begin{tikzpicture}[node distance=1cm, auto,]
\node[punkt] (market) {Update tree};
\node[ above=of market] (dummy) {};
\node[punkt, above=of dummy] (dummy3) {Draw $\Delta t$};
\node[punkt, right=of dummy] (t) {Draw $\rho | \Delta t, y$};
\node[punkt, left=of dummy] (comparison) {Compare with observed tree};
\end{tikzpicture}
dia에 화살표를 생성하면 생성된 매우 복잡한 코드로 화살표에 대한 라텍스 코드를 얻을 수도 있습니다(결국 추가해야 할지 모르겠습니다).
하지만 두 코드를 결합하면 오류가 발생하고 플롯을 만들 수 없습니다. 도움을 주시면 감사하겠습니다.
\ifx\du\undefined
\newlength{\du}
\fi
\setlength{\du}{15\unitlength}
\begin{tikzpicture}
\pgftransformxscale{1.000000}
\pgftransformyscale{-1.000000}
\definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000}
\pgfsetstrokecolor{dialinecolor}
\definecolor{dialinecolor}{rgb}{1.000000, 1.000000, 1.000000}
\pgfsetfillcolor{dialinecolor}
% image rendering not supported\pgfsetlinewidth{0.100000\du}
\pgfsetdash{}{0pt}
\pgfsetdash{}{0pt}
\pgfsetbuttcap
{
\definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000}
\pgfsetfillcolor{dialinecolor}
% was here!!!
\pgfsetarrowsend{stealth}
\definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000}
\pgfsetstrokecolor{dialinecolor}
\draw (-403.700000\du,42.500000\du)--(-403.700000\du,42.500000\du);
}
\pgfsetlinewidth{0.100000\du}
\pgfsetdash{}{0pt}
\pgfsetdash{}{0pt}
\pgfsetbuttcap
{
\definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000}
\pgfsetfillcolor{dialinecolor}
% was here!!!
\pgfsetarrowsend{stealth}
\definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000}
\pgfsetstrokecolor{dialinecolor}
\pgfpathmoveto{\pgfpoint{-417.949962\du}{9.949999\du}}
\pgfpatharc{269}{143}{1.429551\du and 1.429551\du}
\pgfusepath{stroke}
}
\pgfsetlinewidth{0.100000\du}
\pgfsetdash{}{0pt}
\pgfsetdash{}{0pt}
\pgfsetbuttcap
{
\definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000}
\pgfsetfillcolor{dialinecolor}
% was here!!!
\pgfsetarrowsend{stealth}
\definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000}
\pgfsetstrokecolor{dialinecolor}
\pgfpathmoveto{\pgfpoint{-411.049840\du}{13.600048\du}}
\pgfpatharc{287}{251}{7.759989\du and 7.759989\du}
\pgfusepath{stroke}
}
\pgfsetlinewidth{0.100000\du}
\pgfsetdash{}{0pt}
\pgfsetdash{}{0pt}
\pgfsetbuttcap
{
\definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000}
\pgfsetfillcolor{dialinecolor}
% was here!!!
\pgfsetarrowsend{stealth}
\definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000}
\pgfsetstrokecolor{dialinecolor}
\pgfpathmoveto{\pgfpoint{-415.650500\du}{14.649839\du}}
\pgfpatharc{108}{70}{7.125443\du and 7.125443\du}
\pgfusepath{stroke}
}
\pgfsetlinewidth{0.100000\du}
\pgfsetdash{}{0pt}
\pgfsetdash{}{0pt}
\pgfsetbuttcap
{
\definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000}
\pgfsetfillcolor{dialinecolor}
% was here!!!
\pgfsetarrowsend{stealth}
\definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000}
\pgfsetstrokecolor{dialinecolor}
\pgfpathmoveto{\pgfpoint{-419.057248\du}{15.891588\du}}
\pgfpatharc{196}{113}{1.974003\du and 1.974003\du}
\pgfusepath{stroke}
}
\pgfsetlinewidth{0.100000\du}
\pgfsetdash{}{0pt}
\pgfsetdash{}{0pt}
\pgfsetbuttcap
{
\definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000}
\pgfsetfillcolor{dialinecolor}
% was here!!!
\pgfsetarrowsend{stealth}
\definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000}
\pgfsetstrokecolor{dialinecolor}
\pgfpathmoveto{\pgfpoint{-416.112627\du}{12.991865\du}}
\pgfpatharc{115}{2}{1.629642\du and 1.629642\du}
\pgfusepath{stroke}
}
\pgfsetlinewidth{0.100000\du}
\pgfsetdash{}{0pt}
\pgfsetdash{}{0pt}
\pgfsetbuttcap
{
\definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000}
\pgfsetfillcolor{dialinecolor}
% was here!!!
\pgfsetarrowsend{stealth}
\definecolor{dialinecolor}{rgb}{0.000000, 0.000000, 0.000000}
\pgfsetstrokecolor{dialinecolor}
\pgfpathmoveto{\pgfpoint{-408.800310\du}{18.349868\du}}
\pgfpatharc{114}{-118}{4.669774\du and 4.669774\du}
\pgfusepath{stroke}
}
답변1
Tikz 전용:
\documentclass{article}
\usepackage{tikz}
\usetikzlibrary{positioning}
\tikzset{
punkt/.style={
draw,
rounded corners = 2pt,
align=center,
text width=2.5cm
},
%
myarrows/.style={
->,
shorten <=2pt,
shorten >=2pt
}
}
\begin{document}
\begin{tikzpicture}[node distance=1cm, auto,]
\node[punkt] (market) {Update tree};
\node[above=of market] (dummy) {};
\node[punkt, above=of dummy] (dummy3) {Draw $\Delta t$};
\node[punkt, right=of dummy] (t) {Draw $\rho | \Delta t, y$};
\node[punkt, left=of dummy] (comparison) {Compare with observed tree};
\draw[myarrows] (market.east) arc (225:495:2);
\draw[myarrows] (comparison.east) to [bend right] (t.west);
\draw[myarrows] (t.west) to [bend right] (comparison.east);
\draw[myarrows] (comparison.north east) to [bend right] (dummy3.south);
\draw[myarrows] (dummy3.west) to [bend right] (comparison.north) ;
\end{tikzpicture}
\end{document}