B
Blah
I'm trying to use the system() in a C++ program to execute gnuplot on
a file of data on OSX and have the graph pop up but so far the only
thing I've managed to do is get gnuplot to open.
as I minor test I did (unrelated stuff excised)
#include <stdlib.h>
int system(const char *string);
system("gnuplot");
system("plot sin(x)");
and the only thing that happened was gnuplot opening in terminal. For
that matter typing
plot sin(x) doesn't do anything even if it is typed manually into
terminal with gnuplot started. The graph only pops up if I enter it
directly into the console that opens when clicking on gnuplot in
finder. Anyway to fix this or more easily load a file to gnuplot from
the other program?
a file of data on OSX and have the graph pop up but so far the only
thing I've managed to do is get gnuplot to open.
as I minor test I did (unrelated stuff excised)
#include <stdlib.h>
int system(const char *string);
system("gnuplot");
system("plot sin(x)");
and the only thing that happened was gnuplot opening in terminal. For
that matter typing
plot sin(x) doesn't do anything even if it is typed manually into
terminal with gnuplot started. The graph only pops up if I enter it
directly into the console that opens when clicking on gnuplot in
finder. Anyway to fix this or more easily load a file to gnuplot from
the other program?