Tagged Questions
3
votes
1answer
55 views
How can I display tick marks on only one axis of a pgfplots graph?
How can I display tick marks on only one axis of a pgfplots graph?
Here is some simple code to work with:
\documentclass{article}
\usepackage{tikz}
\usepackage{pgfplots}
\begin{document}
...
32
votes
2answers
538 views
Draw polarized light
I was trying to draw something like that
Searching through the net to see if it already exists in tikz I came accross in texample.net the following image which looks a lot like what I want to draw.
...
2
votes
0answers
47 views
X-Y plot with variable diameter points [duplicate]
I want to draw an X-Y plot where each point has a kind of "third dimensional" value that I want to represent using different points "size" (points are circles with different diameters).
I already ...
4
votes
2answers
99 views
drawing a line in polar coordinates
I have a point in polar coordinates (110:2cm), but from here I want to draw a line straight down.
Doing (110:1cm) is a line towards the center along 110 degrees. Without taking 2*sin(110) and ...
2
votes
1answer
75 views
Multithread integral function executing picture
I need to make a picture that should look like
I saw a similar question here but the red function line appears neither when I use --shell-escape nor when I use --enable-write18. I use TeXstudio, by ...
6
votes
1answer
85 views
Join two function-defined curves in Tikz
I have the following:
\begin{tikzpicture}[line cap=round,line join=round]
\draw[dashed,domain=0:9,samples=20] plot (\x,{1/(\x+.5)+3});
\draw[dashed,domain=0:9,samples=20] plot (\x,-{1/(\x+.5)+2});
...
3
votes
1answer
142 views
Plotting a 2D gaussian sample
Can you please help me with making a 2D Guassian sample with specified means and variances?
I only know how to make a guassian curve :D
\documentclass{article}
\usepackage{paralist,pst-func, ...
6
votes
2answers
250 views
Rindler coordinate chart (family of parametric curves) in TikZ
Is it possible to make a plot like this with TikZ or other drawing packages?
This plot visualizes a two parameter family of curves, given by
T = x Sinh(t)
X = x Cosh(t)
The pink curves are ...
2
votes
5answers
218 views
How to write y = (x / 6) ^ {3 / 7} in TikZ format to plot its graph?
How to write y=(x/6)^{3/7} in TikZ format to plot its graph in the following code?
\documentclass{article}
\usepackage{tikz}
\begin{document}
\begin{tikzpicture}
\draw ...
6
votes
2answers
230 views
How to plot a discontinuous function curve and diagram of Markov chain with TikZ?
Please apologize my ingnorance of tips to use for asking questions.
I would like to realise the plots and the diagram like those shown on page 158,
160
and 161
on this document Chaine de ...
3
votes
1answer
237 views
Bell curve with multiple x-axes and annotations
I've just started working with pgfplots and I'm getting good results, but I'm having difficulties getting this one done in LaTeX:
The curve itself is not a problem, but the multiple x-axes (I don't ...
2
votes
0answers
170 views
Scatterplot with TikZ/pgfplots
I have 7 *.txt files each with 2 columns of data thus:
time(mins) contacts
3.25 8
1.166666667 4
3.2 6
3.2 7
2.25 8
5.466666667 12
2.25 3
2.166666667 7
I'd like to plot them in separate ...
2
votes
1answer
128 views
tikz does not plot correctly
@Jake: this is the whole document
\documentclass[11pt, a4paper]{book}
\usepackage{amssymb}
\usepackage{amsmath}
\usepackage{amsthm}
\usepackage{tikz}
\usepackage{pgfplots}
...
6
votes
4answers
427 views
What is the easiest way to plot a function and its tangent lines at the turning points?
I want to plot graphs like this and embed them as Tikz or Pstricks code in my handouts. I know that there are software such as Ipe, LaTeXDraw etc. But none of them can satisfy me. Because Ipe doesn't ...
7
votes
2answers
267 views
Easy creation of logarithmic grid with TikZ
Is it possible to create a logarithmic grid using the command below with TikZ?
\draw (-0.1,-0.1) grid (4.1,4.1);
It would be great to be able to create a logarithmic grid without having to specify ...
7
votes
2answers
274 views
How to draw two intersecting graphs?
I want to make the following figure.
My efforts are:
\documentclass{standalone}
\usepackage{pgfplots}
\usetikzlibrary{calc,shadings}
\usepackage{pgfplots}
\begin{document}
\begin{tikzpicture}
...
8
votes
1answer
224 views
how to draw plots without data in tikz?
I want to draw this plot. I know how to do it with data. But here I don't have any data. And I want to draw this. How would I do it?
3
votes
1answer
161 views
How to run gnuplot/latex from inside texshop?
I was able to write a piece of code that drew a graph in gnuplot and then
using tikz embedded that into my TeX document and run it via Texshop. I am
not able to do that anymore. I need to run
...
8
votes
1answer
180 views
Tikz plots distorted mark
Consider the following code:
\documentclass{minimal}
\usepackage{tikz}
\usetikzlibrary{plotmarks}
\begin{document}
\tikz{\draw (0,0) -- plot[mark=o] (0.5,0) -- (1,0);}
\end{document}
It seems ...
7
votes
1answer
334 views
Plot functions and their point of intersection
We are plotting three functions as follows
\documentclass{article}
\usepackage{pgfplots}
\begin{document}
\begin{tikzpicture}
\begin{axis}[enlargelimits=false]
\addplot[domain=0:1,blue] {(1-x)/5};
...
5
votes
1answer
173 views
Scaled ticks with ymin and ymax
For a publication I am preparing multiple plots with PGFPlots and would like to have them all look alike, i.e. having the same axis and identical ticks. For this I intended to use ymin and ymax, but ...
20
votes
3answers
925 views
How can I make plots with TikZ which look like the new Mathematica 9 plots
The new Mathematica 9 is out! I would love to know how to make similar plots to the one's advertized, particularly the following:
and
Here is a simple plot to get started.
%& -shell-escape
...
5
votes
2answers
747 views
How to plot data from a CSV file using tikz and csvsimple?
Here is a minimal example :
\begin{filecontents*}{data.csv}
a,b,c,d
1,4,5,1
2,3,1,5
3,5,6,1
4,1,4,9
5,3,4,7
\end{filecontents*}
\documentclass{article}
\usepackage[utf8]{inputenc}
...
10
votes
1answer
300 views
Plot non-continuous function with TikZ
How can I plot a non-continuous function with TikZ (using continuous lines for continous stretches of the function and dashed lines for discontinuities)? Does anybody know an efficient method?
9
votes
2answers
292 views
pgfplots plots function not correct
This code
\documentclass{article}
\usepackage{pgfplots}
\pgfplotsset{compat=newest}
\begin{document}
\begin{tikzpicture}
\begin{axis}
\addplot [domain=15:30, samples=1000] ...
184
votes
2answers
19k views
Create xkcd style diagram in TeX
The unique style of the diagrams at xkcd has an informative but nice hand-drawn touch. I guess they are actually drawn by hand but just recently on our partner site for Mathematica someone asked how ...
3
votes
1answer
192 views
Curve synthesis - Adding many (mostly piecewise linear) curves
It's a follow-up to a previous question. If I could have a macro out of the solution over there, it would have been great but then I couldn't make it.
The following code (to be added to the one in ...
9
votes
1answer
264 views
Curve synthesis - Adding two curves to get another one
Case 1:
Let's say I have a few coordinates (A), (B), (C), (W), (X), (Y), and (Z) (possibily obtained through intersection, rotation, and whatnots).
I draw two piecewise linear curves through (A), ...
5
votes
1answer
376 views
Draw outside axis with pgfplots
I have the following diagram, and would like to extend the red line so it crosses the axes and goes on for a bit at the start and the end like in the second picture, but I would like the red and blue ...
6
votes
1answer
382 views
Making the y-axis range of a plot have more values in some parts
For the MWE below:
\documentclass{report}
\usepackage[left=2.5cm,right=2cm,top=2cm,bottom=2cm]{geometry}
\usepackage[T1]{fontenc}
\usepackage{pgfplots}
\begin{document}
\begin{figure}[H]
...
6
votes
1answer
270 views
Plotting a straight line to the peak point of a graph
For the MWE below:
\documentclass{report}
\usepackage[left=2.5cm,right=2cm,top=2cm,bottom=2cm]{geometry}
\usepackage[T1]{fontenc}
\usepackage{pgfplots}
...
3
votes
1answer
335 views
How to plot coordinate between two xticks?
I want to plot some data using pgfplot. Here is a code I have written:
\documentclass{article}
\usepackage{pgfplots}
\pgfplotsset{compat = 1.3}
\begin{document}
\begin{tikzpicture}
\begin{axis}[
...
12
votes
2answers
780 views
TikZ: How to draw a sine curve in 3D?
I know how to draw a sine curve in TikZ and I know how to rotate it in the plane of the paper. I would now like to draw a sine curve that oscillates in the depth of the paper - to give the impression ...
6
votes
3answers
1k views
draw a plot with point
i try to draw something like this :
to do that i have write some code using tikz,unfortunately i dont get what i want
\documentclass{report}
\usepackage{tikz}
\usetikzlibrary{automata,topaths}
...
8
votes
1answer
285 views
Tikz / pgfplot: plot Alternating Sequence
Is there any possibility to plot an alternating sequence?
Picture: Alternating sequence:
I don't need exacly the same output as above.
I tried the following:
\begin{tikzpicture}
\begin{axis}[
...
5
votes
1answer
600 views
TikZ plot: centering and units on axis
I have the following.
I'm trying to center the plot and putting \begin{center} around the TikZ image does not work.
Also I'm trying to change the units of the x-axis. The x-axis is used to ...
3
votes
1answer
456 views
TikZ: bars width and size of plot
This is a followup on my previous question. I have tried to plot my data and I see the following now.
Would it be possible to define the size of the area that is used for the plot? I have tried to ...
3
votes
1answer
425 views
TikZ: plot datapoints with bars
I'm currently generating data files which have points as follows
5 1
3 2
2 1.4
...
Each line 2 values of which the first is indicating the time and the second some value. I'm currently (as I'm ...
11
votes
1answer
699 views
Floor function plot with TikZ
I can't seem to figure out why, but TikZ isn't properly plotting the floor function. Here is my code:
\begin{tikzpicture}[xscale=1,yscale=1]
\draw[step=.5cm,gray,very thin] (0,0) grid (8,8);
...
2
votes
3answers
464 views
Problems with including a tikz tex file generated by Octave (MatLab clone)
I have plotted a figure in Octave and printed it as a TikZ figure (see the device option) to a tex file called comparison_tikz.tex, and I have imported it into my document with the line
...
3
votes
1answer
327 views
TikZ: plot data files with spaces in path
I tried to plot a data file with spaces is the file path.
\draw[line width=0.4mm] plot[] file{/home/schlumpf/test folder/daten.txt};
My problem is the space in the file path. How can I plot this ...
6
votes
1answer
585 views
How to generate stem plots with TikZ like stem() in Matlab?
Given a set of (x,y) coordinates stored in a file, how could I generate a stem plot from those coordinates? I would like to achieve something similar as the matlab's stem function: ...
2
votes
1answer
806 views
latex code for graphing rational function
I've seen in TikZ and pgf Manual for version 1.18 a code for graphing some functions but it does not provide an example for a rational function.
Can someone help me graph $x+\frac{1}{x}$?
5
votes
1answer
787 views
Define node at relative coordinates of \draw plot
I am not able to fix that simple plot. I think I missed something, but I can't point out what !
Could you tell me why (a) is not at midway of the red line ?
\documentclass{article}
...
2
votes
1answer
674 views
tikz draw plot not correct
I am trying to plot a naca0012 airfoil profile by its analytic function ( cf wikipedia ) using tikz and I can't understand why I get the following results. I precise that I get the same results if I ...
9
votes
3answers
389 views
How can I make circle plots?
I have not idea how to call these things, but I just saw a paper with the following figure
and I was wondering how one would go about doing it in LaTeX. The closest thing I saw on TeXample.net was ...
4
votes
1answer
273 views
Labeling a function's plot generated by “plot function” [duplicate]
Possible Duplicate:
How to label a path drawn using tikz with \draw plot?
Consider plotting a parabola using the following code:
\begin{scope}[domain=-2:2]
...
2
votes
1answer
468 views
Plotting area in the plane where two inequalities in two variables hold
I would like to plot the area in the plane where two inequalities hold, both involving two variables. I would like to do it the way Wolfram Alpha does it, but within a LaTeX document. I have looked ...
4
votes
1answer
1k views
Problem using matlab2tikz
I'm trying to get matlab2tikz to work. I want to use it for prettyfying output of Matlab's image() command.
In Matlab I tried
imagesc(rand(100));
xlabel('X');
ylabel('Y');
title('Random Colors');
...
3
votes
1answer
464 views
Strange behavior in smooth pgfplot with sudden changes in the slope
I'm trying to plot some points with sudden changes in the slope. But I get some strange behavior like this:
as you can see in the peaks, there is no smoothness in there.
However, I think the ...



