TikZ is a higher-level drawing language built on top of the PGF graphics framework. For questions specifically about the PGF layer use {pgf-core} instead. Both tags are possible on the same question. The tag {diagrams} is also compatible with this tag.

learn more… | top users | synonyms (3)

0
votes
1answer
20 views

Enhancing Booktab Tables containing Tikz picture

I have created a table containing text, equations and a tikz picture [created using Geogebra and scaled using \resizebox]. As a beginner, I found it difficult to center my content and to remove the ...
1
vote
0answers
14 views

How to shade the intersection portion? using tikz?

How to shade the intersection portion? \documentclass[border=2pt]{standalone} \usepackage{pgfplots} \begin{document} \begin{tikzpicture} \begin{axis}[xmax=9,ymax=9, samples=50] \addplot[blue, ...
43
votes
5answers
3k views
+200

How do we Draw a Bird in LaTeX

Yes, it's that time of the month again. It's time for somebody to ask how we can draw X in LaTeX. This time I'm asking the question and X is a bird. The reason why I'm interested in this question is ...
6
votes
1answer
36 views

Trees in context

Excuse me for my english, is not my language. I have a document in LaTeX, the relevant code is \documentclass[a4 paper, 12pt]{article} \usepackage{tikz-qtree} \usepackage{tikz} \usepackage{pgf} \...
5
votes
2answers
40 views

Shading between a circle and two lines

I have drawn the unit circle and some tangent lines to the circle. I now wish to shade the area between the two lines bounded by the circle. Here is the tex that I have already written. \...
1
vote
2answers
18 views

tikz-cd message pgf Error: No shape named tikz@f@2-2-4 is known

The diagram $\begin{tikzcd} & U_0 \ar[dl, "\operatorname{f}_0"] & \ar[dr, "\operatorname{f}'_0"] \\ U_1 \ar[d, "\operatorname{f}_1"] & & V_1 \...
0
votes
2answers
63 views

pgfplot/tikz stacked bar chart

I have the following table with data And I am trying to replicate it in a stacked bar chart. Could anybody help to build this kind of chart? The table is easy to replicate it in latex, but I am ...
5
votes
3answers
61 views

How to retrieve current stroke and fill color in PGF/TikZ

I am defining a shape which can be drawn in normal or inverted mode. In normal mode, the border lines and inner lines are drawn with the current stoke color, while the shape is filled with the current ...
2
votes
2answers
30 views

Multiple outputs in node

I am trying to draw multiple outputs system with TiKz but I'm having several problems to get it right.I have searched for examples, but I could not find anything that looks like to what I want to draw....
1
vote
1answer
40 views

usage of control points twice

I just started learning Tikz from the The TikZ and PGF Packages Manual for version 3.0.1a, and in the curved path construction subtopic I encountered the following piece of code \begin{tikzpicture} \...
11
votes
2answers
2k views

TIKZ drawing vector field from external file

I would like to draw a vector field from a data file. I tried to adapt code from Manual for Package pgfplots but this doesn't work \documentclass{standalone} \usepackage{pgfplots} \pgfplotstableread{...
2
votes
2answers
23 views

Using \hphantom within TikZ nodes

I'm trying to align the following piece of text: *Corresponding author Name Nameson name@mydomain.com such that the two lower lines are horizontally aligned with the C, rather than the * in the ...
4
votes
2answers
137 views

How to draw Block diagram like this in LaTeX?

I like to draw the following diagram: So far i succeed to draw the the following: \begin{tikzpicture}[ block/.style={draw, minimum width=10mm, minimum height=6mm}, sum/.style={circle, draw, ...
2
votes
0answers
20 views

matlab2tikz Invalid Code (13x) [on hold]

I have a question or rather a significant problem with matlab2tikz. When I insert the resulting tikz file into my document and try to compile a get a large number of ! Invalid code (13x), should be ...
2
votes
1answer
225 views

TeX capacity exceeded using pgfplots with/without externalization

The following MWE compiles (for me) \documentclass{article} \usepackage{pgfplots} \pgfplotsset{compat=newest} \usetikzlibrary{external} \tikzexternalize[prefix=figures/externalized/] \begin{...
5
votes
2answers
135 views

Problems with flow chart - decision tree

I am creating a decision tree with flow chart in the using the tikz-package. A MWE is as follow: \documentclass{article} \usepackage[latin1]{inputenc} \usepackage{tikz} \usetikzlibrary{shapes,arrows} ...
1
vote
2answers
66 views

Horizontal bar chart with different colors for each bar

I want to create a horizontal bar chart with different labels on the y-axis for each bar. Also, the value should be displayed on the right-hand side of each bar. Fx: "Test A" ... red bar ... 400 "...
0
votes
0answers
35 views

Exponential numbers on a graph

I'm writing a document and I want know how can I set the X axis numbers using a scientific notation. I have this table: \begin{tikzpicture}[scale = 1] \begin{axis}[ xmode=log, log ticks with ...
0
votes
0answers
21 views

Trying to make a scatter plot for the first time; pgfplots [on hold]

I am trying to make two scatter plots for my physics lab report. I keep getting errors and I keep referring to the pgfplots manual but to no avail. \documentclass[12pt]{article} \usepackage[margin=...
1
vote
1answer
68 views

Question about including tikzpicture in a research paper

I am using \documentclass[conference]{IEEEtran} for writing a paper. I will be using tikz environment for drawing figures. Some figures will occupy only a single column, but I have a couple of figures ...
8
votes
2answers
3k views

How to overbrace / underbrace in text mode (using TikZ?)

I want to create something that somewhat looks like this: I know about \overbrace but that only applies to math mode. I couldn't find an \overbrace for text. And while I probably could use math ...
1
vote
2answers
47 views

how to finish this latex drawing with an angle between two arcs and two pictures and arrows?

I have the following tikz picture that I managed to draw: \documentclass{article} \usepackage{tikz} \begin{document} \begin{tikzpicture} \draw[thick] (0cm,0cm) circle(1cm); \foreach \x in {30,45} { ...
1
vote
4answers
168 views

How to draw a circle in TikZ?

I want to draw a disc using TikZ whose two halves are of different color.
2
votes
1answer
34 views

Alignment of pictures in TikZ

I'm having some trouble with drawing a couple of pictures in TikZ. It puts a different alignment on two adjacent pictures, as follows: Also, how can I get the "and" to be centered vertically? My ...
0
votes
1answer
58 views

Annotate row and column highlighted in one table with different color by Tikzmark in Beamer

I found example for row only here: Annotate the table row highlighted by Tikzmark in Beamer Also found example for column only here: Annotate the table column highlighted by Tikzmark in Beamer but ...
0
votes
0answers
12 views

Tikz error using media9

This is my first attempt to include a video in a PDF file, so basicaly, most of the things I did were just copy-paste from other examples to see how the thing worked. To sum it up, my file looks like ...
1
vote
1answer
35 views

Two tikz figures (with colored areas) next to each other

I would like place to figures/graphs next to each other. So far, I've managed to create the first figure and parts of the second figure. I don't know how to place them next to each other and how to ...
4
votes
1answer
75 views

Fit a title on multiple lines in a header (Friggeri CV)

I'm helping a friend with LaTeX to make her a CV that looks very nice using the Friggeri CV template. I'm experienced with it but not with Tikz, which is used to make the black header at the beginning ...
1
vote
0answers
34 views

TikZ-UML: How to place stereotype next to relation?

is there an easy way to position a stereotype next to a relation instead of "over" it? (or at least to add a white background to the stereotype?) Here is an example of what I mean: \documentclass[]{...
0
votes
0answers
57 views

Position of multiple arrows: Arrows must end at same position

I want to get two vertical sets of flowcharts and join their elements by arrows. MWE is given below. I want to draw two arrows from A1 and B1 to A2 with their heads meet at the same point. I tried ...
2
votes
1answer
21 views

Changing the axis xmax/domain in a step plot

Consider the MWE below. This example is from the PGF Plot galery with added 1 outlier (1000,50) resulting in the first (wrong) screenshot below. I want to limit the domain/axis, so I get something ...
15
votes
1answer
288 views
+50

Customizing \fill and line in TikZ

How I can draw these (flexible) nodes and arrow? (as in this presentation) A MWE: \documentclass{beamer} \usepackage{tikz} \usetheme{CambridgeUS} \usetikzlibrary{calc} \usepackage[T1]{fontenc} \...
1
vote
1answer
61 views

Problems inserting tikzpictures in headlines in slides and titlepage, LaTeX beamer

I am creating a custom beamer theme and I have problems inserting graphics in the headline of the slides. For the graphics I have exported .eps files to TikZ code with Inkscape, which worked fine. ...
0
votes
1answer
37 views

Plot problem with tikz and data from matlab

I extracted data from matlab figures, with the command "dlmwrite('heat.txt',[x',u],'delimiter', '\t')". It gives me a text file with 3 columns of numbers (the first is the abscisse x, and the other ...
1
vote
1answer
25 views

Ylabel too distant from axis

I'd like to insert a tikz picture in a beamer document. When I plot the image the distance from ylabel and the axis is too large, so the picture is too small. \documentclass{beamer} \usepackage{tikz} ...
3
votes
2answers
52 views

Centering tabular-looking nodes in TikZ

I've recently decided to make a formal study of LaTeX so I can upgrade my talents from "copy, paste & hack" TeX user to well, someone who knows how to use the tools. One of the things I'm trying ...
1
vote
2answers
41 views

Tikz: How to better distinguish between arrows to one coordinate?

In my tikz pictures there are several arrows pointing on the same coordinate. The arrows heads look very ugly. I want to see every arrow head separately. How can I improve my picture? Screenshot ...
39
votes
2answers
5k views

“Z-level” in TikZ

This is an idle question, but neverthless, I think it's interesting. Does TikZ have a simple way to implement a "z-level" specification. By this, I don't mean 3D drawing, I mean specifying which ...
2
votes
1answer
48 views

TikZ / PGF : why use \addplot instead of \plot?

I cannot understand the difference between addplot and a simple draw plot. Can someone explain why it is generally preferred on forums to do the second thing on this MWE ? \setuppapersize[A4][A4] \...
0
votes
0answers
58 views

How to draw in tikz with label in radians

I want to draw in TikZ the graph of the next image:
4
votes
1answer
78 views

TikZ-Drawing of Euler-cases (Knickfälle), bended lines

As a novice in TikZ I tried to draw the four so called Euler-cases (Knickfälle/Buckling; https://en.wikipedia.org/wiki/Buckling). I got that far: But it should rather look like this: As you can ...
4
votes
1answer
56 views

Angle in ellipse coordinates

I need an explanation here. Consider the MWE below. If I set X=Y=3 the point (-20:{\X} and \Y) ends up at the -20 angle as expected. If I set Y=1 then the point is on the ellipse, but at a different ...
1
vote
0answers
28 views

PGF Plot: Different Graphs/Plots in one file

I want to plot my benchmark results from Celero (C++ benchmarking library) in latex, via PGF Plot: I get a csv file with all data in the form of (here with example data): Now I want to plot the ...
2
votes
0answers
111 views
+50

Cut off graphs using dot2texi with TikZ

I am creating concept maps using dot2texi and TiKz. However, with more complex maps the current style sometimes causes the map to be cut off. This despite the fact that in theory there is actually ...
1
vote
1answer
48 views

Tikz: shade area between two bezier curves and an intersection

I'm trying to shade the area between two Bezier curves and two lines, but I can't make it work. Here is an example \documentclass[12pts]{beamer} \usepackage{tikz} \begin{document} \begin{frame}{...
2
votes
2answers
75 views

tikzpicture curved arrows

I am trying to make I diagram with two boxes, one above the other, and two arrows: I would like the arrows to be curved (that would be kind of circular flow diagram) and in just one direction. ...
0
votes
1answer
27 views

TikZ: remove side-bearing from text node

I want to horizontally align the first letter of a text node with a shape I've drawn. In my example, I want the F to be horizontally pixel-aligned with the left side of the square. The first step is ...
53
votes
6answers
37k views

Specifying the width and height of a tikzpicture

Is it possible to specify the width and height of a tikzpicture? To scale a tikzpicture I use the option scale, i.e. for instance \begin{tikzpicture}[scale = 2] ... \end{tikzpicture} I tried to ...
0
votes
0answers
34 views

“Missing \endcsname inserted” when using pgfplots

I encountered the problem while trying to export figures from Matlab using matlab2tikz. However, while troubleshooting I discovered that even simple pgfplots examples did not work. For example, the ...
3
votes
2answers
47 views

Further extension needed for game tree (tikz)

I've started making a game tree, but I get stuck after the second level. Suggestions for extending to the desired output or cleaner code are much appreciated. Desired output Current output ...