Content-Length: 262601 | pFad | http://github.com/UlrichBecker/gnu-plotstream

B6 GitHub - UlrichBecker/gnu-plotstream: Simple C++ interface for Gnuplot with stream ability like std::cout and so on.
Skip to content

UlrichBecker/gnu-plotstream

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

29 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

gnu-plotstream

Simple C++ interface for Gnuplot with stream ability like std::cout and so on.

Small but it supports the full functionality of Gnuplot.

For Linux only! Sorry.

Example:

#include <gnuplotstream.hpp>

using namespace std;
using namespace gpstr; // Namespace for Gnu-Plot-STReam

int main( void )
{
   cout << "Minimal test-program plotting the function si(x)" << endl;
   try
   {
      PlotStream plot( "--persist" );
      plot << "plot sin(x)/x" << endl;
   }
   catch( exception& e )
   {
      cerr << e.what() << endl;
      return EXIT_FAILURE;
   }
   return EXIT_SUCCESS;
}

Result:

Result of example above

If PlotStream has to invoke Gnuplot with additional command line options, then these options are the first parameter of the constructor of PlotStream.

Example:

PlotStream plot( "-noraise --persist" );

Alternatively you can define the macro GPSTR_DEFAULT_OPTIONS in your makefile.

By default the class PlotStream expect the executable of Gnuplot in /usr/bin/gnuplot. If Gnuplot has been installed in a other directory, then the executable file has to be the second parameter of the Constructor:

PlotStream plot( GPSTR_DEFAULT_OPTIONS, "/path/to/my/gnuplot" );

or:

PlotStream plot( "-noraise --persist", "/path/to/my/gnuplot" );

Alternatively you can define the macro GPSTR_DEFAULT_GNUPLOT_EXE in your makefile which will overwrite the default.

For detailed information about Gnuplot look in to the PDF documentation of Gnuplot.

Or visit the homepage of Gnuplot.

About

Simple C++ interface for Gnuplot with stream ability like std::cout and so on.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages









ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: http://github.com/UlrichBecker/gnu-plotstream

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy