Questions tagged [gnuplot-iostream]

It is an interface that allows gnuplot to be controlled from C++. Its similar to gnu plot.

Gnuplot-iostream is an interface that allows gnuplot to be controlled from C++. Its similar to gnu plot. it is a iostream pipe to gnuplot with some additional functions for pushing data arrays and getting mouse clicks. source code include STL containers (eg. vector), Blitz++, and armadillo. it is a low level interface, and usage involves manually sending commands to gnuplot using the "<<" operator

48 questions
1
vote
1 answer

plotting again on the last plot using gnuplot-iostream

i am using gnuplot-iostream to plot datapoints. So, I have two sets. I can successfully plot the first set, but it fails at the second set. first_pts = {....}; second_pts = {....}; Gnuplot gp2d; …
infoclogged
  • 3,641
  • 5
  • 32
  • 53
1
vote
1 answer

using gnuplot-iostream.h in C++

I am trying to plot data using gnuplot through a C++ program. I followed the steps from http://www.stahlke.org/dan/gnuplot-iostream/ and added the headers: #include "gnuplot-iostream.h" #include when I compile I use …
nlsphys
  • 23
  • 1
  • 1
  • 5
0
votes
1 answer

Inconsistent Dot Output on Gnuplot: Extra Dot Appearing

I currently use gnuplot to make graph. I tried to put 5 dot in it which I stored the coordinate on txt file txt file : 5 2 2 4 3 6 1 8 5 10 but the output on png file there's 6 dot?? where's that 1 addition dot came from?? code: #include…
Anoky
  • 39
  • 1
  • 6
0
votes
0 answers

Issue with "set terminal png" Command with GNUPlot C++ (C++ 14, VS 22)

I'm attempting to save a GNUPlot plot as a PNG file. I'm using C++ 14 and Visual Studio 2022. I have the following minimal example code: #include #include #include #include "gnuplot-iostream.h" using namespace std; int…
Runsva
  • 365
  • 1
  • 7
0
votes
0 answers

Issues when attempting to save Plot as PNG with GNUPlot C++ (C++ 14, VS 22)

I'm attempting to save a generated plot into a PNG image with GNUPlot in the C++ implemenation. I'm using C++ 14 with Visual Studio 2022. I have the following minimal example code, designed to produce a simple grid 3D graph and save it as a…
Runsva
  • 365
  • 1
  • 7
0
votes
1 answer

Plot Contour with Gaps in GNUPlot C++? (C++ 14, VS 22)

I'm attempting to plot a contour plot in the GNUPlot C++ library, however I want to be able to plot with holes in the data (without interpolation where there's no data). I'm using C++ 14, with Visual Studio 2022. I have the following example…
Runsva
  • 365
  • 1
  • 7
0
votes
1 answer

Provide Separate Colormap Values to 3D Plot in GNUPlot C++? (C++ 14, VS 22)

I have a 3D grid plot consisting of 3D points (0, 0, 0), (1, 1, 1) and (2, 2, 2). I'm graphing it using the GNUPlot implementation in C++ 14, and I'm using Visual Studio 2022. The following code: #include #include #include…
Runsva
  • 365
  • 1
  • 7
0
votes
1 answer

Graphing 3D Plot with C++ GNUPlot? (C++ 14, VS 22)

I'm attempting to plot a set of 3D points in C++ using the GNUPlot library implementation. I'm using C++ 14 with Visual Studio 2022. I understand how to plot 2D points with this library, however I'm quite confused as to how I'm supposed to plot a…
Runsva
  • 365
  • 1
  • 7
0
votes
1 answer

Proper Way to Plot with GNUPlot? (C++ 14, VS 22)

I'm attempting to graph some data with the GNUPlot library in C++. I'm using Visual Studio 2022 with C++ 14. I also installed the boost libraries and am using the gnuplot-iostream.h file from dsthalke's GitHib repository. As far as I understand,…
Runsva
  • 365
  • 1
  • 7
0
votes
2 answers

How to fix a contour color of a 2D cut with gnuplot

Please I would like to have unique black lines for my 2D contour. set terminal png size 800,800 font 'Times New Roman, 12' set output 'TH1.png' set view map set pm3d map unset surface set cont base set cntrparam levels 50 set isosamples 10 unset…
Herve
  • 11
  • 5
0
votes
0 answers

Using gnu-iostream.h header

I am trying to plot directly in my C program to Gnuplot, so I am using the header #include "gnuplot-iostream.h" But it is missing a dependency of file_descriptor.hpp. I've already copied the entire directory of Gnuplot into my current directory.…
destroyer806
  • 23
  • 1
  • 1
  • 5
0
votes
1 answer

Is there any error variable for gnuplot fit?

I'm making a c++ code which prints commands for gnuplot, in order to plot different things faster. The code plots the data already as the data fit as well, but now I'm adding some labels, and I want to print the fit equation, I mean something with…
0
votes
1 answer

gnuplot-iostream header file has errors

I downloaded gnuplot and am using it with https://github.com/dstahlke/gnuplot-iostream. I have copied all the code from gnuplot-iostream into my own header file but I am getting the following error: Error (active) E2783 expected a comma (the…
Richard
  • 23
  • 6
0
votes
1 answer

Gnuplot invalid command "set output"

I have been trying to solve the problem for more than a day, but whatever api (C++, python) and gnuplot version would not be, the problem is the same. Let's look at several different examples of python code that works fine without an API in the…
Vernadsky
  • 3
  • 3
0
votes
1 answer

gnuplot every command with different lines color and legend

Lets say I have this sample data file 1 2 2 3 3 4 1 5 2 6 3 7 1 8 2 9 3 10 Now in gnuplot if I run this command pl 'test.dat' u 1:2 every :::0::2 w l It plots three lines for each of the block in the data file, but there's no way to distinguish…
Eular
  • 1,707
  • 4
  • 26
  • 50