plottting graphs in C++

U

uccdx01

hi all, i'm fairly new to programming. i was writing a C++ program and
found out that at some point i need to plot a graph from the data in
some arrays i created. my compiler DEV-C++ seems to have no library
for graphics so i'm stuck. i would really appreciate any help on
writing a C++ program which can plot data into graphical form. thank
you
 
A

Alf P. Steinbach

* uccdx01:
hi all, i'm fairly new to programming. i was writing a C++ program and
found out that at some point i need to plot a graph from the data in
some arrays i created. my compiler DEV-C++ seems to have no library
for graphics so i'm stuck. i would really appreciate any help on
writing a C++ program which can plot data into graphical form. thank
you

One easy solution is to produce a text file with comma-separated values
(or semicolon-separated), and then import that into any spreadsheet program.
 
D

Divick

1. You can plot your data in OpenGL which is a 3D graphics API. To many
it may seem an overkill but it will be fast and efficient. And since
your requirements are not very special (as it seems to me), thus
writing a simple OpenGL program should not be tough for graph plotting.

2. Other option is to use some platform specific library for drawing
for example using Win32 library on Windows and Xlib on Linux.

3. You can generate comma-separated values in a file and then use
gnuplot to plot those values. You can invoke gnuplot from your C++
program itself.

Hope that helps,
Divick
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,483
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top