1
vote
0answers
38 views

Displaying two plots side by side not displaying titles correctly [duplicate]

I’m writing a report and using the following code to display a bode-diagram. To save some space (I have several of these figures), I’ve displayed them side by side, but the title of the right plots’s ...
2
votes
0answers
66 views

using gnuplot to plot data from a file

I am trying to plot some data using pgfplots, but the data are so extensive that the maximum capacity is reached. I get the error: TeX capacity exceeded, sorry [main memory size=3000000]. What can I ...
1
vote
2answers
85 views

Non-linear plot looks linear

I am plotting a non-linear function -2/3 x^ 3 + x^2-3x+4/3 in the interval [0,1/2], I tried to change the scales to make it look less linear but still looks like a straight line. Any suggestions? ...
4
votes
1answer
78 views

Stack figures in horizontal plane in 3D rectangular shape without loss of quality

I am plotting figures on GMT but it does not support some features in gridview. So I want stack each figure on different platforms below each other. E.g. I want to add each image like the following
3
votes
1answer
41 views

Showing all the decimal numbers on the y axis clearly in a given chart

I would like to show my y axis as follows: Here is my code: \documentclass[english,12pt]{standalone} \usepackage{tikz} \usetikzlibrary{patterns} \usepackage{pgfplots} \pgfplotsset{compat=1.10} ...
4
votes
1answer
83 views

How to skip ticks in pgfplots plot?

I have frequently the problem that too many data points are available for the x axis, I want to show them all in the actual plot, but I would like to show only a subset of the ticks. For instance, if ...
4
votes
0answers
64 views

Pgfplots : Shadow in bar chart with restricted domain

I have a following code which plots a pgf bar plot for me. I am able to add shadow to one of the bar plot. However, the other plot which has a broken y bars, I am unable to add the shadow, because ...
0
votes
0answers
7 views

Skipping ticks in pgfplots plot [duplicate]

I have frequently the problem that too many data points are available for the x axis, I want to show them all in the actual plot, but I would like to show only a subset of the ticks. For instance, if ...
3
votes
0answers
35 views

Function not plotted between 0 and 1 [duplicate]

When I am trying to plot the function x^0.5 / ( x^0.5 + 10^0.5 ), the plot will only start at x=1 but not at x=0. See the following MWE: \documentclass{article} \usepackage{tikz} ...
1
vote
1answer
106 views

Plotting an arbitrary function in latex [closed]

I would like to know how I can replicate the diagram below in latex. thanks. Edit: I can plot a function using tikz/pgfplots if I know how the function is defined. Unfortunately, I don't know how ...
5
votes
1answer
93 views

How do I create a combined figure with two imported curves and draw around it with Tikz?

This is a two part question that I'd really appreciate any help with, I couldn't find previous posts about this so I apologize if this is a repeat question. It all stems from attempting to create this ...
8
votes
1answer
118 views

pgfplots: How to add the origin to the axis in a robust way?

Question I add the origin to my graph with after end axis/.code={\path (axis cs:0,0) node [anchor=north west,yshift=-0.075cm] {0} node [anchor=south east,xshift=-0.075cm] {0};} (code found here). ...
6
votes
2answers
128 views

pgfplots: how to display a label next to my plot when the option clip = true cuts out a part of the graph?

Question I want to attach a label to the curves I draw. My current solution is to add a node after the plot of my function (see the code below). But, when I explicitly cut out a part of my graph, ...
8
votes
1answer
109 views

pgfplots: wrong domain, wrong axis, uncentered graph… is it a bug?

Question I get a very strange graph with pgfplots, see the picture below. What is going wrong? Code and picture \documentclass{article} \usepackage{pgfplots} \begin{document} \begin{tikzpicture} ...
2
votes
1answer
53 views

pgfplots: how to add a label to a graph with the option clip=true?

Question I would like to add a label to my graph, on the right of it or at any other place, for instance somewhere above my graph. Is it possible? I want to use the option clip=true, because of the ...
7
votes
1answer
84 views

pgfplots: the margins “eat” some parts of my graph

Question I use pgfplots with the ultra thick option ans without explicitly giving the domain for the y-axis. It seems that in this case, some part of my graph is "eaten" by the margin: see the ...
4
votes
1answer
148 views

Drawing phase line for differential equations

How can one draw one of this pictures in latex with the simplest way and good looking output?
0
votes
0answers
37 views

Varying Error Bar Length In Timeplot Graph

I have a quick question about the Error Bars functionality in LaTeX, specifically - I am using pgfplots and tikzpicture packages. I was wondering if it is possible to vary the length of the Error bar ...
10
votes
2answers
96 views

Convert from physical dimensions to axis cs coordinate values

In answering PGFPlots: Howto draw a label at a zero of a function?, I got stuck on converting a length in pt to the actual coordinate value in the axis cs system. Here I only need the x value, but ...
9
votes
1answer
92 views

How to make an inline pgfplot

I have the following code to graph a function with a height of 2em, and in line with some text, but it gives an error. \documentclass{article} \usepackage{pgfplots} \newcommand\quadratic{ ...
3
votes
0answers
60 views

How to automatically optimize the PDF output of TiKZ externalize?

I use pgfplots with externalization for generating plots in my document. For heavy plots the output PDF for a figure can grow to few hundred KB. I used Adobe Acrobat to optimize the PDFs which ...
1
vote
1answer
60 views

pgfplot tikz single plot with 2 y axis

I have 5 columns of data in a txt. file as nxI Bfield1 magmoment1 Bfield2 magmoment2. I am attempting to implement nXI - x axis, Bfield1 and Bfield 2 as my y axis and magmoment1 and magmoment 2 as ...
6
votes
1answer
105 views

Simple Characteristic Function or Step Function in pgfplots

How would I go about creating a simple characteristic function plot such as this in pgfplots? It is not necessary for my Latex processor to generate the plot based on a function, manually drawing the ...
3
votes
1answer
92 views

Area restricted by three functions

I am trying to shade the area restricted by the functions y \sin x, x = \sin y and y = 2pi + x. Now my problem is that I do not have access to Pgfplots 1.10so the libary fillbetween is not accessible ...
2
votes
1answer
60 views

Using \foreach to manage ticks in axis, Tikz

I want to add minor distance between y ticks. The default distance is 0.5, I need to set for 0.2. It seems easy to set different space for ticks according to pgfplots, in 4.15, page 271. I add the ...
3
votes
0answers
80 views

pgfplots: unable to affect cycle list name while using \pgfplotsinvokeforeach

I am unable to use custom colors from cycle list name with pgfplotsinvokeforeach. Some pointers could be gauged from this post, which discusses execution of various steps in a plot function. In the ...
2
votes
3answers
78 views

Different xlabels for same x values on different plots

I have two tables that hold different values for the same x values. To compare them, I want to plot both of them in the same plot but with different xlabels. The tables should remain the same, i.e. I ...
3
votes
1answer
52 views

ybar overlaps axis line (and xtick removal)

When I use the MWE below my bar plots are overlapping partly the black x-axis How is it possible that the bar graph starts exactly above the x-axis and not on top of it? And is there a way to ...
9
votes
2answers
108 views

pgfplots 3d cylindrical coordinate system

I am trying to plot a cylindrical coordinate system using pgfplots. The idea would be to plot the r,theta plane similar to what polaraxis provides, see here. I don't know how to translate something ...
7
votes
1answer
173 views

How to retrieve color from a specific location and use it?

Please save your time and energy on this question, this is not an important one. What's the color in the middle (or anywhere else) in these pictures? How to retrieve/compute that color to be ...
3
votes
2answers
134 views

TikZ, PGFPlots, or GNUplot: plotting a curve without the known function

I would like to make a plot of a function that has an overshoot of 25% and then settles with subtle oscillations at 100%. I would like to create it in one of the listed packages or in gnus case add ...
9
votes
2answers
165 views

create a stacked histogram with tikz

I try to create a stacked histogram. Like this: My data consists of classes (0-4) and a float value for each class. I already have a histogram for all mean values. But I would like to color the ...
2
votes
1answer
104 views

How to plot a normal curve with proper y-values

Follow-up question to Plotting bell shaped curve in TikZ-PGF I'm new to LaTeX, and I'm typesetting a document for my stats class, and trying to use LaTeX to produce a normal probability distribution. ...
1
vote
0answers
21 views

Adding legends to tikzpicture [duplicate]

I have tikzpicture (with 3 graphs from my data files. I want to add legends to data1, data2 and data3 to my picture, is it possible? \documentclass[english]{article} \usepackage{tikz} ...
0
votes
0answers
44 views

PGFPLOT Externalization not working

I am trying to externalize PGF Plot to be saved as EPS file using latex and enabled shell-escape. \documentclass[a4paper]{article} \usepackage{lipsum} \usepackage{tikz} ...
2
votes
1answer
61 views

Exclude certain plot points from smoothing

How do I exclude certain coordinates from being smoothed by the "smooth" option in a PGF plot? How do I avoid that \closedcycle jumps to zero? Here is my example: \documentclass{minimal} ...
4
votes
3answers
121 views

Positioning pgfplots axis in tikzpicture

I want to put a pgfplots plot beside several other pdf images that I import into my document, but I can't figure out how to position the pgfplots axis in the larger tikzpicture: ...
5
votes
1answer
63 views

Nested ifnum conditional groupplots with pgfplots?

I want to use groupplots, and set a variable to conditionally plot the plots. Here is the minimal non-working example: \documentclass{article} \usepackage{pgfplots} \usetikzlibrary{calc} ...
2
votes
1answer
84 views

Uniform appearance of tick marks in 3d pgfplot?

In the default configuration the tick marks in a 3d plot from pgfplots are looking nicely when using a box but in my opinion not really uniform when the axis lines are in the center. Is there any ...
3
votes
1answer
107 views

Draw a surface from scattered curves

I have a few curves determined by some points. I need to plot the surface that they determine. That is, I have this \begin{tikzpicture}[scale=0.8] \begin{axis}[% width=12cm,height=12cm, xmin=0, ...
7
votes
1answer
127 views

Color and legend for 3d surface

I'm trying to plot a 3d surface using pgfplots and this is what I have done so far: \usepgfplotslibrary{patchplots} \begin{tikzpicture} \begin{axis}[% width=12cm,height=12cm, xlabel={$J_1$}, ...
10
votes
2answers
288 views

How can I produce such a graph of my piecewise function?

I am writing my thesis in behavioural economics and have to draw individual discount functions, I did the following graph with stata, but would love to have it with tikz. I played around in tikz ...
4
votes
3answers
175 views

pgfplots: Plot inverse function (function of y)

I am trying to plot the Ramberg-Osgood-relationship for a specific material with pgfplots. The relationship describes the stress-strain-curve, that is the stress as a function of the strain. The ...
4
votes
1answer
76 views

Preserving styles while changing axis y line in pgfplots

The code for the MWE generating this image is given below (click for full-size): Basically, I had some graphs like on the left, until I realized I need to shift the x axis - this also forces me to ...
1
vote
1answer
70 views

Overlapping transparent impulses (ycomb) with pgfplots?

Consider the following MWE: \documentclass[% 12pt, journal, twoside, draftcls, letterpaper, ]{IEEEtran} \usepackage{pgfplots} \usepackage{pgfplotstable} \usepackage{tikz} ...
0
votes
1answer
107 views

Aligning .tikz pgfplots with semi custom styles

Previously I was helped with how to align and position graphs in a table with optional subplots in this question: Overlay two .tikz files from input It worked great, but I was not happy using scaling ...
2
votes
1answer
54 views

Custom style just for width and height?

I have some pgfplot graphs in .tikz files and I want to define a custom style to them that only overrides some entries, and uses whats in the .tikz files for the rest. Example: In my .tikz file I ...
5
votes
1answer
84 views

Why doesn't a \foreach variable work in \draw in an \axis?

I'm finding some weird behavior with TikZ's \foreach within an \begin{axis} environment. This works: \foreach \x in {-2,-1,...,2} { \addplot[thick, domain=0.05+(\x*2-1)*pi/2:+(\x*2+1)*pi/2-0.05] ...
2
votes
1answer
79 views

Simple Line-Plot with date on x-axis

I need to do a really simple line plot and my data is looking like this: Date Value Apr2013 0.06 Mai2013 0.08 Jun2013 0.1 Jul2013 0.2 Aug2013 0.4 Sep2013 1.5 Okt2013 2.0 Nov2013 4.1 Dez2013 8.1 ...
2
votes
1answer
101 views

Adjusting pgfplots

I am having trouble controlling the axes in pgfplots. I have defined an evironment for graphs \newenvironment{graph}[3][]{\begin{figure}[htp] \def\tempa{#1} %Saves caption since \end cannot take ...