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)

1
vote
2answers
19 views

Adding text above a node in Tikzpicture tree diagram

I'm trying to add text above the lines coming from a chance node in a Tikzpicture decision tree. It seems easy to add text at the end of a line, or above the parent node's lines, but I can't figure ...
4
votes
1answer
26 views

tikz overlay pictures horizontal positioning

I think I have a problem about how the box created by tikzpicture is positioned with respect the rest of the text. I have read Positioning TikZ pictures and I think I have understood how the vertical ...
0
votes
0answers
13 views

Tikz-uml create nesting relation

I am using tikz-uml, but it seems there is not UML nesting relationship. I am not very good with tikz could you help me how I can implement it. You can see how it should look here at the end under ...
7
votes
1answer
83 views

Fill in between polar curves

I am trying to fill in space between a pair of spiral curves in tikz. I have tried using the fillbetween library but it just shades in the whole spiral. Does anyone have a hint they could offer? ...
1
vote
0answers
31 views

Package TikZ Error: Problem Compiling in Ubuntu

I get the following error Package tikz Error: Giving up on this path. Did you forget a semicolon?. when compiling this TikZ code: \documentclass{standalone} \usepackage{tikz} \begin{document} ...
2
votes
1answer
42 views

tikz/pgf upgrade and decorations

Since a major upgrade in pgf, my code does not compile any more. I am trying to make "decorated" source listing, where the decorations can be like highlighting some lines (see the MWE), balls on some ...
0
votes
0answers
10 views

pgfmathsetmacro increases border size [duplicate]

Upon creating some graphs with TikZ, I noticed that the border at one side was much larger than it needed to be. The cause seems to be the \pgfmathsetmacro command: \documentclass{standalone} ...
1
vote
1answer
27 views

How to use Umlauts (äüö) in axis label with knitr, LuaTex and tikz?

When compiling pdf documents with complex tikz figures using knitr, the pdftex engine would sometimes run out of memory. Thus, I used the luatex engine to compile these Rnw files. However, I am not ...
2
votes
2answers
53 views

add vertical line of equation x=2 and shade a region in graph by pgfplots

I would like to plot these four equations : $$y=\dfrac{3}{2x+1}, y=3x-2, x=2 y=0$$ and i don't know how to draw vertical line of equation x=2 and shade a region like the picture below ...
0
votes
0answers
22 views

Different row separator for multiple rows in tikz dependency

I want row space for the four rows differently in the below mentioned example. For example 1ex for first 2 rows, 4ex for 2 and 3 rows and 1ex for last 2 rows. Setting row sep gives equal spacing for ...
6
votes
2answers
2k views

Isomorphisms in commutative diagrams in TikZ

Sorry for the basic question. I am trying to get commutative diagrams like \usepackage{tikz} \usetikzlibrary{matrix,arrows} $$\begin{tikzpicture}[description/.style={fill=white,inner sep=2pt}] ...
2
votes
1answer
34 views

drawing snake decoration in a box tikz

I am trying to draw some snake decorations in a box using tikz library but couldn't achieve what I want. Why there is mis-alignment between the actual markings and the snakes. I am using the following ...
0
votes
1answer
79 views

Adding a rectangular box with tikz to table (beamer)

I would like to add a rectangular box to my table to highlight some rows. I'm trying to use tikz with the second lot of code from Harish Kumar's answer to a similar question. However, unlike the ...
2
votes
1answer
46 views

add a little arrow at the end of a function

I have the following code of a segment of tikz: \begin{tikzpicture}[line cap=round,line join=round,>=triangle 45,x=3cm,y=2cm] \draw[->,color=black] (-0.9,0.) -- (1.9,0.); ...
1
vote
1answer
24 views

Set node distance between borders in tikz

From \documentclass[tikz,border=10pt]{standalone} \usetikzlibrary{shapes,arrows,positioning} \begin{document} \tikzstyle{block} = [draw, rectangle, minimum height=3em, minimum width=6em] ...
2
votes
1answer
44 views

how to achieve and draw the final rotation of a frame with Euler angles.

I would like to do the final rotation using Euler angles. In this link Euler Angles, the final rotation undergoes three successive rotations, starting from frame (x,y,z), going through (x',y',z') and ...
6
votes
3answers
388 views

TikZ/PGF linguistics vowel chart

I'm including a vowel chart in a linguistics document of mine, similar to this, and while I'm aware that there are a couple of packages (TIPA, pst-vowel) that can do the job, I'm interested in trying ...
32
votes
1answer
745 views

Making cards for Magic: The Gathering and similar card games

I'm creating cards for a card game. They will be similar to cards in Magic: The Gathering (left-hand image below). What I have is in the right-hand image below. The problem is that the code ...
0
votes
0answers
48 views

Commutative diagram with tikz [on hold]

I write \usepackage{tikz} \usetikzlibrary{matrix,arrows,decorations.pathmorphing} but this gives the error Environment tickzcd undefined.
1
vote
1answer
38 views

Aligning edge labels horizontally with tikz package

I have the following figure: \documentclass{standalone} \usepackage{tikz} \usepackage{pgfplots} \usepackage[active,float]{preview} \usetikzlibrary{calc} ...
1
vote
2answers
64 views

Plotting Floating point number when changes are very small in data

I want to plot the following data, i am using the CSV file, and pgfplotstable package. (0,2.42130785530195E-02), (113.8,2.42130785530195E-02), (227.6,2.42130781357695E-02), ...
87
votes
3answers
6k views

Fundamental differences : PSTricks, TikZ/PGF and others

OK, since this is a pretty vague and subjective question. I need to set up some borders around the discussion that I intend to benefit from. But before anything, I certainly do NOT want to excite the ...
2
votes
3answers
210 views

Using loops with chains?

Is there a smarter way to achieve the same result as the one from the following MWE: 1) by using some kind of loop instead of hand typing every node, 2) by drawing the arrows with tikz instead of ...
1
vote
1answer
33 views

Naming Externalized Images via MD5 Sum

I have a large presentation with over 200 figures (mainly created through stepping through each image). I'm using the external library to cache the results to great effect. Each figure is cached in ...
2
votes
0answers
45 views

Tikz axis border on top, grids below

Is there an easy way to place the border box of a tikz graph on top, while keeping the grid lines behind data lines? \begin{axis}[axis on top] The above puts the border, x grid lines, and y grid ...
3
votes
1answer
47 views

Centering group plot figure

Can anyone show me how to center this group plot? I've tried every trick in the tex.stackexchange book of similar posts (e.g., How to center large figures in LaTeX and how to fix short justified ...
1
vote
2answers
38 views

Remove clk signal from wave environment

How do I remove the clk signal in the wave environment? I still want to keep alle the help lines (i.e. the t0, t1, etc.) Here's the code: \documentclass[11pt]{minimal} \usepackage{tikz} ...
8
votes
1answer
1k views

How do I get \pgfmathparse to create value rounded to one decimal place?

I'm trying to place a grid over an image to help me place other object where I want on the image. But, I'm having difficulty getting tikz to show coordinates as I wish. Here's my MWE: ...
5
votes
1answer
108 views

TikZ/pgfplots: how can I generate a figure like this one?

What's the easiest way to produce a figure like this one? The curve is meant to look wiggly and random, and always non-increasing, except for the jumps up. I have tried using decorations with random ...
1
vote
1answer
110 views

How to draw some targets like this?

I would like to show some stimators properties in statistics. I'm very beginner in LaTeX, so I need some help.
4
votes
3answers
142 views

Shading inside a triangle when the coordinates of one vertex are calculated by TikZ

The following code instructs TikZ to draw a right triangle and to put a grid on the Cartesian plane. I would like to make two modifications to it. I want the inside of the triangle to be "colored" ...
8
votes
1answer
101 views

TikZ decoration to draw a winding or twisting ribbon

I enjoy TikZ styles and decorations a lot, but I still dabble with them. I know how to draw ribbons with a style, if they aren't meant to twist. But I'd like to define a style that has a twist of the ...
9
votes
1answer
453 views

Labeling non axis parallel braces in tikz

Given two points, the following code draws a brace connecting them and labels it. \documentclass{standalone} \usepackage{tikz} \usetikzlibrary{calc,decorations.pathreplacing} \begin{document} ...
3
votes
2answers
110 views

plotting a function with smooth curves

I am trying to plot the following function The issue is I do not know what is the best setting for the coordinates. I tried different coordinates with no success. Here is my code: ...
7
votes
2answers
721 views

TikZ: Labeling objects and referencing them

According to the TikZ manual I can use name= to assign a label to the drawings, but when I do the following: \begin{tikzpicture} \draw [ blue, thick, name=e1] (10pt,10pt) ellipse (50pt and 30pt); ...
0
votes
0answers
66 views

Simple beam deflection tikz

I'm beginner user of Tikz, so can somebody help me to draw this? I would be very thankful.
0
votes
0answers
36 views

Error by creating normal distribution in tikz

Hello I wanna create a Normal distributed figure. with sigma = 10 and mu =185; I have the following code based on Bi-variate Normal distribution \usepackage{tikz} \usepackage{pgfplots} ...
5
votes
2answers
445 views

Plotting R boxplots with pgfplots

I use quite a number of boxplots in my writing, and have chosen pgfplots as my plotting solution for a number of reasons (one of which is the benefit of having the data to build the plot in the tex ...
1
vote
1answer
72 views

Simple TikZ Diagram - curved line with multiple controls

I am trying to draw the following diagram in TikZ: I have written the following code but I am not sure how to do the two curved lines for P1 and P3: \documentclass[11pt,a4paper]{report} ...
3
votes
1answer
71 views

Tikz functions and coordinate system: Adding points and labels

I managed to adjust some of the existing code a little bit to fit my needs. I can plot simple functions. (1) I want to add labels to the coordinate system, for example e (~ 2.71) to the x-axes and ...
0
votes
0answers
30 views

TikZ and other figures in documents meant for multiple paper sizes

Sometimes scientific papers are sent to multiple journals with very varying paper sizes. Usually, changing from one to another, I simply cross my fingers that TikZ figures still fit, and rescale PDF ...
3
votes
2answers
54 views

Placing nodes which vary in length harmoniously

The code \documentclass{article} \usepackage{tikz} \begin{document} \begin{tikzpicture}[font=\footnotesize, very thick] \def\r{3} \foreach \a/\n in {-2/{p-2}, -1/{p-1}, 0/0, 1/1, 2/2, 3/3, 4/4} ...
1
vote
0answers
33 views

\pic: undefined control sequence

I am using Texmaker on Macbook but I have a problem with my code. When I run my code it always shows this message: "undefined control sequence \pic". \documentclass{article} \usepackage{tikz} ...
4
votes
3answers
65 views

TikZ: Get Position/Node of an Arrow Head

Following LaTeX code produces a small image with directions. \documentclass{standalone} \usepackage{tikz} \usetikzlibrary{quotes,angles} \begin{document} \begin{tikzpicture}[thick] % X',Y',Z' in ...
10
votes
3answers
185 views

Accuracy of calculations in TikZ with fixed point arithmetic

I want to build a tree which satisfies the following: It grows to the right. The first child grows at 0 degrees (subsequent children growing clockwise). All children nodes are in the same ...
15
votes
5answers
481 views

Drawing a block diagram with TiKz

I need some help drawing a block diagram using TiKz. I want draw something similar to this: However, I'm struggling to go further than this so far: using the code below: ...
3
votes
1answer
63 views

Drawing Sinusoids with Phase difference

My first goal was to draw sinusoid plots similar whit these images: This is what I've done (similar to one code in this forum): What I'd like to know is (if possible) how to change integral ...
5
votes
1answer
2k views

TikZ: How to encapsulate shade in node?

I have this shaded circle: \shade [ball color=black!80!white] (0,0) circle (1); Is it possible to encapsulate it with node style and fixing the circle radius?
6
votes
1answer
1k views

Automagically externalising PSTricks and TikZ pictures

My thesis currently has a few PSTricks and TikZ pictures. It takes a while to compile over here Scott says he has some scripts to automate externalising TikZ pictures. I'm looking ideally for ...
3
votes
2answers
114 views

TikZ: Drawing an arc from an intersection to an intersection

I want to draw an arc with a given radius from the point the arc intersects with a given circle to the point where the arc intersects with another circle. I have been reading through a lot of the TikZ ...