{nodes} is about nodes in {diagrams}.

learn more… | top users | synonyms (1)

12
votes
3answers
3k views

Put a node behind another in a TikZ diagram

I want to place a node, that is kind of a note, behind another node. However, I need to put the reference node before the note, so I can place the note in a relative position to the reference node. ...
12
votes
3answers
3k views

Horizontal row separation line in tikz matrix (like \hline in tabular)

In this question tikz-matrix-as-a-replacement-for-tabular a nice solution was given to let the matrix in tikz behave like tabular. In this solution cell/.style={rectangle} was used to draw lines ...
12
votes
3answers
2k views

How to align text in TikZ nodes by baseline?

I need to draw a graph where some nodes have the same y-coordinate. I want the text within the nodes on the same y-coordinate to be baseline-aligned. However, the text seems to be aligned by the ...
12
votes
1answer
3k views

Bending arrows in Tikz

In Tikz, I would like to bend an arrow like the one between $H_2O$ and $O_2$ in this figure: I'm able to have a bended line between $H_2O$ and $O_2$, but it's not touching the photophosphorylation ...
12
votes
1answer
4k views

TikZ Styles that set Nodepart Styles

In the following, I'm using user-defined macros to set the type style for the nodeparts for class nodes (\texttt{\textbf{#1}}), interfaces (\texttt{\textit{#1}}). Using the \tikzset command I also ...
12
votes
1answer
485 views

Nested node class with pictogram decoration

I'm wondering how can I define custom TikZ node class mynode thats allows my to use following syntax: \node [mynode,fill=yellow!40] {component} \child{ \node [mynode,fill=yellow!40] ...
11
votes
2answers
3k views

Package PGF Math Error: Unknown operator `o' or `of'

I am getting a weird error while trying to place a node above another node using the below= syntax. \documentclass{article} \usepackage{tikz} \begin{document} \begin{tikzpicture} \node[] (node1) at ...
11
votes
2answers
186 views

How to define an environment that begins with a node?

Please see the following definition: \tikzstyle{boxStyle} = [draw=blue!80, fill=blue!9, very thick, rectangle, rounded corners=3mm, inner sep=10pt, inner ysep=15pt] ...
11
votes
2answers
5k views

Path From and To Same Node in tikz Flowchart

I'm working on creating flowcharts directly inside LaTeX documents using tikz. I am admittedly an extreme novice with tikz, although I have quite a bit of experience using LaTeX. My problem is when ...
11
votes
3answers
799 views

pgfplots - Add offset to pins

I'm trying to make a bar plot for an optimization parameter in quantum physics. To be more informative, the graph should display the values of these parameters above the bars. So far I did ...
11
votes
2answers
3k views

How to nest a graph within a node in TikZ and draw edges between the graphs?

I'm trying to draw a graph and have a separate graph within one of the outer nodes. I seen this question, but I don't understand how the matrix nodes will help me. I would also like to draw edges ...
11
votes
2answers
5k views

Cylinder shading with PGF/TikZ

I'm trying to create a cylinder with 3D shading effects. The cylinders in the picture are standing vertically, and have a body and an end. I'd like the body to be shaded so that it varies uniformly ...
11
votes
3answers
782 views

Anchors/coordinates inside a node's text

The plot Using tikz, I have a main node containing several (three) lines of text, and three "legend" nodes that point to them. If I use a rectangle node, then I can't access the positions of the ...
11
votes
3answers
683 views

How to rotate hyperlink with text

How can I rotate the link of a text in a node. Here is my MWE: \documentclass{article} \usepackage{tikz} \usepackage{hyperref} \begin{document} \begin{tikzpicture} \node (rect) [rectangle, ...
11
votes
2answers
1k views

How two connect any arbitrary nodes of tree in tikz

I need to be able to connect any arbitrary nodes in a tree to each other. I am using the tree package in tikz to create my tree. I cannot figure out though how to connect to nodes by let say a draw ...
11
votes
1answer
187 views

Given four nodes forming a quadrilateral, how do I find the node at the intersection of the diagonals [duplicate]

I'm trying to find and name a node at the intersection of the diagonals of a quadrilateral formed by four other nodes. However, I'm not drawing a path. All I can seem to find in the tikz manual are ...
11
votes
2answers
4k views

Tikz - How to connect nodes

\documentclass{article} \usepackage{tikz} \usetikzlibrary{shapes,arrows} \begin{document} \begin{tikzpicture} \draw (0,2.5) node[minimum height=1cm,minimum width=3cm,draw] (A) {A}; \draw (5,0) ...
11
votes
1answer
579 views

Organigram in Latex. Vertical distance between nodes

I want to draw a organizational structure in form of an organigram. I found this solution and tried to adapt it. The code: \documentclass{article} \usepackage{tikz} ...
11
votes
1answer
1k views

TikZ: connecting nodeparts

I'm new to TikZ. Last couple of hours in fact. I was wondering if there was a way of connecting nodeparts from different nodes. Here's an example \documentclass{article} \usepackage{tikz} ...
11
votes
1answer
6k views

How to place label in middle of line (above and below) with TikZ

\fbox{ \begin{tikzpicture}[scale=1,auto=center] \node[circle,fill=gray!20] (n1) at (2,8) {Node A}; \node[circle,fill=gray!20] (n2) at (8,8) {Node B}; \foreach \from/\to in {n1/n2} \draw ...
11
votes
1answer
2k views

pgfplots - Placing Nodes on x Coordinates of a Plot

I want to plot some graphs in pgfplots and want to place nodes on the exact same x coordinate of the plot. The position of the note has to be set in x direction but free in y direction. Here is one ...
10
votes
3answers
3k views

Table with TikZ

I should create a table like the one here as example. I think that the best way to do a table like this one is generate some labels and use them to colorize the nodes in order to make it more ...
10
votes
3answers
5k views

TikZ: Using Loop to Draw Grid of Nodes

I am trying to draw an Ising model (in my case, a grid of nodes with an undirected edge between adjacent nodes on the same row or column) using TikZ. I have the grid of nodes working nicely using a ...
10
votes
2answers
3k views

How to position nodes around another node in TiKZ?

I'd like to position some nodes in TiKZ around a given node. I could do that manually, by setting each node position, but why not looking for an easier way that looks better? I thought about using a ...
10
votes
3answers
1k views

Drawing a proper shadow for overlapping objects

I draw images that are composed of several overlapping nodes. If I add a drop shadow to each node, the shadow of the second node is drawn over the first node, as seen in the picture below (which ...
10
votes
4answers
980 views

How create circle node in Tikz with T from lines inside? T made split node to 3 sectors

I woud like create 3 sector circle node. See the following figure sectors are bounded by lines
10
votes
3answers
483 views

parametric naming of nodes in Tikz

I would like to generate a graph with nodes and edges names by their coordinates in the graph, something like: \foreach \x in {0,1,...,6} \foreach \y in {1,...,4} \draw (1.5*\x,2.5*\y) circle ...
10
votes
2answers
394 views

Why are just-created TikZ shapes “unknown”?

I'm using TikZ's \foreach iterator to create a series of nodes and then draw edges between them. First I iterate to create the nodes; then I iterate through the nodes to link them to each other. ...
10
votes
2answers
1k views

Problem with custom width of nodes in TikZ

I'm in trouble with some nodes, I'd like to get your help. I'm trying to set the text width of a node, but when I declare this parameter, there is something wrong. Maybe there's something missing in ...
10
votes
1answer
7k views

TikZ: text along path as node

I'm using the decorations library to put bended text along a path. That works fine. However, I'd like to have the bended text as a node, so that I can later use it as a reference (for instance to draw ...
10
votes
2answers
135 views

If I have two nodes defined at the end points of a diagonal of a rectangle, how can I define nodes for the other two corners?

I have two nodes which I want to define to be opposite corners of a rectangle. I would like to be able to define nodes at the other pair of opposite corners. I tried the following, but it gives me ...
10
votes
1answer
5k views

Change node distance for particular nodes

How do you change the node distance to the left for a \node[state] (q4) [below left of=q3] {$homing$}; Ok, it's a little bit on the left, but I want it to move it more to the left. How ...
10
votes
2answers
653 views

Hyperlinked nodes in TikZ mindmap

I am trying to make a small mindmap such that some of the child nodes are hyperlinked. I tried to follow the advice given here, about the new node style hyperlink node, but the following MWE compiles ...
10
votes
3answers
8k views

How to draw a node as a filled circle (dot) to indicate a connection using TikZ and LaTeX?

I have some trouble drawing a control system block diagram using TikZ. I want a certain node to be shown as a dot, indicating a connection. However, the dot is not positioned at the center of the node ...
10
votes
1answer
1k views

macro for empty nodes in tikz-qtree

I'm trying to define a macro for writing empty nodes in a binary tree using tikz-qtree. Referring to the code below, I want the string \missing in my code to be replaced by \edge[draw=none]; {} as-is ...
10
votes
1answer
4k views

Size of TikZ ellipse node

When I set the minimum size of an ellipse in a tikzpicture environment, it expands into a circle if the inner content does not grow as large as the ellipse shape itself. Is there any way around it? ...
10
votes
1answer
320 views

Can I calculate the difference between two relatively positioned nodes with TikZ using calc?

I have a chart with relatively positioned nodes. How do I calculate the horizontal distance x, between node "sub3" and node "key" and multiply that value by 2 and use it for the positioning of node ...
10
votes
1answer
3k views

How to rotate a node and text independently in Tikz

How can I rotate the text inside a node independent of the node in tikz? Right now I am using the rotatebox. The other option I tried was to have two overlapping nodes. Is there a better way to do ...
10
votes
1answer
6k views

tikz nodes: centering with small font

I am trying to create tikz nodes with centered text, but changing fontsize. Unfortunately, while normally-sized text is nicely centered inside the nodes, the smaller text is not centered, but shifted ...
10
votes
1answer
564 views

Label automatically positioned so that it doesn't overlap anything

I produce automatically generated LaTeX-files with nodes and links. Is it possible to put the label of the node outside of the node and it is automatically positioned somewhere, such that there is no ...
10
votes
1answer
340 views

Create custom node to draw this

I'm very very new to tikz, I've already done this: With this code: \documentclass{article} \usepackage[spanish,es-noquoting]{babel} \usepackage[latin1]{inputenc} \usepackage[T1]{fontenc} ...
10
votes
1answer
448 views

TikZ- best practice for line starting on a circle's edge?

I'd like to know how I can achieve the best seamless crossover between a node (in this case, a circle) and a line starting on that node. I would like the line to only touch the circle's edge. So far I ...
10
votes
1answer
581 views

TikZ path labels and --cycle

\draw (0,0) -- node{a} (2,0) -- node{b} (2,1) -- node{c} (0,1) -- cycle; I can't find a simple way to make a label on the last edge. What I want is something like \draw (0,0) -- node{a} (2,0) ...
9
votes
2answers
5k views

How to add a node in the middle of the line with tikz?

actually it's an easy question, but I could find an answer with Google or the included search on StackExchange ;) How do I add in the middle of the line a node with Tikz? I want somethink like this: ...
9
votes
3answers
380 views

Sloped Tikz node with rotation and scale

There should be an easy way to place a sloped node along a path. Using sloped works great (as in the black text). However, if there is a rotate= applied then the text is no longer along the path (as ...
9
votes
4answers
449 views

Highlighting equation with arrow

I want to create an equation with highlighting as shown bellow. But using following code: \documentclass[10pt,a4paper]{article} \usepackage[utf8]{inputenc} \usepackage{amsmath} ...
9
votes
1answer
1k views

Cloud with lines as filling in TikZ

I am trying to draw specific portions of a Petri Net with TikZ. For parts of the subnet where the structure does not matter to me I'd like to use a cloud node filled with parallel lines (inspired by ...
9
votes
2answers
298 views

Rounded corners as a tangent in the right direction

I want to split a path into two branches as in the following MWE. \documentclass{article} \usepackage{tikz} \usetikzlibrary{positioning} \begin{document} \begin{tikzpicture} \node (A) [rectangle] ...
9
votes
2answers
2k views

Increase the bending distance of a ``to`` path in TikZ

I have problem with an small graph. The path between the node J and B should to the right of node I. Is there a way to do this? \documentclass[11pt]{article} \pagestyle{empty} \usepackage{tikz} ...
9
votes
2answers
3k views

tikz center node below 2 other nodes

I want to create a node below 2 other node but place it exactly in the middle of the two nodes. Here's what I have so far... \documentclass[12pt]{article} \thispagestyle{empty} ...