Questions tagged [gnuplot]

Gnuplot is a portable command-line driven graphing utility for linux, OS/2, MS Windows, OSX, VMS, and many other platforms. Use this tag for questions about programmatic use of Gnuplot; debugging interactive usage is off-topic.

Gnuplot is a command-line driven plotting engine that runs on all major operating systems (Windows, GNU/Linux, OSX, etc.). Its initial release dates back to 1986 and it is still being actively developed. The program is written in and is released under a custom open source license.

Gnuplot provides a large array of styles to produce different plots including plots popular in mathematics, statistics, or even financial analysis. It can also produce various plot styles for three dimensional data including surface and contour plots. It is capable of plotting user defined functions or specific data and can even generate data through various facilities if needed.

There is no graphical user interface contained in the official release, but several external ones are available (e.g. wgnuplot, xgfe, PlotDrop,...). Additionally there are interfaces available for multiple programming languages such as C, , , and (see more information in links below). There are several software suites that use Gnuplot as plotting device. Amongst them are GNU , and . Mostly however, Gnuplot is used via scripts which automate the task of generating graphics.

Gnuplot produces output using custom output devices called terminals which are available for interactive use, most popular raster formats, various vector formats (including SVG), and both postscript and pdf. Terminals are even available for various LaTeX package formats for direct inclusion into LaTeX documents allowing the document processor to do the typesetting of figure annotations or having the annotations done by gnuplot itself.

Gnuplot is a powerful tool as it allows the customization of nearly every parameter of the plot. Recent versions even support limited but powerful programming features including command line arguments for scripts, conditional and looping statements, and the ability to do smoothing or basic statistical calculations on data.

Gnuplot demos

enter image description here enter image description here

Links

Gnuplot Blogs

Gnuplot Books

6701 questions
2
votes
1 answer

gnuplot replot not plotting

The short version: gnuplot's "replot" command is not seeming to plot anything. Only the original plot ("plot ...") is displayed in the output. The long version: I have a shell script cycling through a database of files, some of which need to be…
sn8ze
  • 27
  • 1
  • 6
2
votes
0 answers

Contour plot on triangular domain

I have to plot a data file which is in a triangular domain. To make it clearer, my data file possess 3 value, two frequencies f1 and f2 with a sum lower or equal to 100 (i.e. f1 + f2 <= 100) and a metric m. My data file is structured as follow: f1 …
Missu
  • 505
  • 3
  • 15
2
votes
2 answers

gnuplot with broken x axis in v5.2 using nonlinear

Version 5.2 contains set nonlinear. One can use it to construct broken axes as suggested in the demo here. I am trying to follow the steps for x axis also logarithmic.The current code is below as well as the data. The problem that I cannot figure…
atapaka
  • 1,172
  • 4
  • 14
  • 30
2
votes
1 answer

How to smooth every plot in GNUplot?

I have a script where I do a lot of plots of a couple of data files. Now, I want to smoothen the curves with smooth csplines. Unfortunately, I would have to manually add this to every single plot command, which is neither beautiful, nor very elegant…
BUFU
  • 127
  • 11
2
votes
1 answer

Gnuplot fitting method

"Fit" in Gnuplot uses which method (Algorithm) for fitting any curve? How does it calculate the error in fitting parameters? A rough idea about the method or the algorithm would be enough.
Kartik Chhajed
  • 183
  • 2
  • 10
2
votes
1 answer

Gnuplot macros, do for, and arrays

I am using gnuplot 5.2.4. I am doing a for-loop, to analyse in each cycle a different column (or combination of columns) of a file. The column to be used is written in an array and is passed to the commands as a macro. The code is written in a .plt…
BaBuZ87
  • 23
  • 2
2
votes
1 answer

Plotting 1D profile in GNU PLOT

I have collected data at eight different point along a profile of 5000km long. The data consist of velocity value at different depth. I am able to plot velocity vs depth with X axis as velocity and y axis downward as depth. But I want to plot…
rehman
  • 101
  • 7
2
votes
2 answers

Installing gnuplot on jupyter

I want to plot my bar chart by gnuplot. But I have problem with installing. I am using jupyter anaconda and the following codes don't work for installing. !conda install gnuplot-py !pip install gnuplot-py !pip install gnuplot Do you have any idea?
Elham
  • 272
  • 2
  • 11
2
votes
1 answer

Is possible to change the points in a plot by numbers in GNUPLOT?

i would like to know if there is some way for customize the point symbols in a plot generated in gnuplot? I want to change the symbols in a plot by numbers, for example, change all '+' symbol by the number '1'. Every help will be appreciated.
2
votes
0 answers

How do I do to make enhanced fonts and bold lines using gnuplot-py?

I'm trying to plot my data with labels (x and y) and font enhanced (bold) using gnuplot-py (on ubuntu python 2.7). What I did until now is: g.xlabel("Wavelength (nm)") g.ylabel("Elipicity (mdegree)") g('set xrange [190:260]') g('set xtics font ",…
2
votes
1 answer

How to keep PyQt5 responsive when calling gnuplot?

I am trying to create plots with a Python GUI and gnuplot. I am generating the code in Python and send it to gnuplot. This basically works with piping data to gnuplot, but: Disadvantages: the Python program is blocked until you close gnuplot you…
theozh
  • 22,244
  • 5
  • 28
  • 72
2
votes
1 answer

Batch definition of functions, or how to plot spectra

I have a calculated spectrum stored in a file containing two columns: The first is the x-position (wavenumber), the second is the height (intensity). In order to simulate a real spectrum I'd like to place a Gaussian for each of these lines (around…
Eldrad
  • 733
  • 3
  • 15
2
votes
1 answer

WiFi networks as clustered bar charts

I'm using my Airport utility to get all available WiFi networks around me and I want to display them as a clustered bar chart using gnuplot. I can't figure out, how to transform the data into a form that gnuplot can work with. My neighbours.dat…
Mike
  • 21
  • 3
2
votes
3 answers

Gnuplot filledcurves flip axes

There is a style to fill the space between two functions of x. Examples of such plots can be found e.g. at http://gnuplot.sourceforge.net/demo/fillbetween.html Is there any way to make similar plot, but with flipped x and y axes? Here is the desired…
Roux
  • 435
  • 3
  • 12
2
votes
1 answer

How do I draw a cube/rectangle with GnuPlot?

I am trying to draw a series of cubes like so: What is the simplest way to define a cube in GnuPlot?
lbenedetto
  • 2,022
  • 1
  • 21
  • 39
1 2 3
99
100