Line in a flowchart in the tikz of XeLaTeX

5

Below is the code and the result of the flowchart I'm building:

\documentclass{article}

\usepackage{tikz}
\usetikzlibrary{shapes,backgrounds}

\begin{document}

\begin{figure}[!ht]

\centering

% Define block styles
\tikzstyle{block} = [rectangle, draw, fill=white, 
    text width=6em, text centered, rounded corners, node distance=2cm, minimum height=2em]
\tikzstyle{line} = [draw, -latex]
\tikzstyle{cloud} = [draw, ellipse,fill=white, node distance=2cm,
    minimum height=2em]

\begin{tikzpicture}[node distance = 3cm, auto]
    % Place nodes
    \node [block]                         (observacoes) {Fazer Observações};
    \node [block, below of = observacoes] (perguntas) {Formular Perguntas Interessantes};
    \node [block, below of = perguntas]   (hipoteses) {Levantar Hipóteses};
    \node [block, below of = hipoteses]   (predicoes) {Realizar Predições};
    \node [block, below of = predicoes]   (testar)  {Testar Predições};
    \node [block, below of = testar]      (coletar) {Coletar Dados Para Predições};
    \node [block, right of = testar, xshift=2cm, yshift=-1cm]      (refinar) {Refinar as Hipóteses};
    \node [block, below of = coletar]     (teorias) {Desenvolver Teorias};
    % Draw edges
    \path [line] (observacoes) -- (perguntas);
    \path [line] (perguntas)   -- (hipoteses);
    \path [line] (hipoteses)   -- (predicoes);
    \path [line] (predicoes)   -- (testar);
    \path [line] (testar)      -- (coletar);
    \path [line] (coletar)     -- (teorias);
    \path [line] (coletar)     -- (refinar);
    \path [line] (refinar)     -- (testar);
\end{tikzpicture}

\caption{\label{metodoestatisto.fluxograma} Fluxograma mostrando os passos do Método Científico.}

\end{figure}

\end{document}

Iwouldliketocreatealinefromthe"Develop Theories" node to the "Make Remarks" node, similar to the line I drew in red in the figure below:

How do I do this?

    
asked by anonymous 26.01.2017 / 19:11

1 answer

3

Before the end of the figure, add another path :

\path [line,rounded corners=7ex] 
          (teorias.west) -- ++(-1.5cm,0) |- (observacoes.west);

(remove rounded corners=7ex for connections with straight lines)

    
26.01.2017 / 20:23