EasyPlot on Windows

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

EasyPlot on Windows

Gregory Guthrie

A very simple test program with Graphics.EasyPlot, flashes up a window, but too fast to see it. There are several old posts on this issue with gnuplot, but I haven’t seen any current solutions.

 

Example:

import Graphics.EasyPlot

 

tData = [ (1,2), (2,3), (3,1), (4,5), (5,3), (6,1) ]

 

main = do plot Windows $ Data2D [Title "Demo Title"] [] tData

 


_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners
Reply | Threaded
Open this post in threaded view
|

Re: EasyPlot on Windows

Theodore Lief Gannon
My first hunch was that, since the program ends right after plotting, it cleans up the plot window and exits. But trying it on an X11 system, I got a persistent window despite the program exiting. That may be a difference between Unix and Windows child process handling; I don't have a Windows machine handy right now to test, but you could try this:

main = do
  plot Windows $ Data2D [Title "Demo Title"] [] tData
  _ <- getLine
  return ()

If that doesn't fix it, my only guess is there's either a difference between the Unix and Windows versions of gnuplot, or a bug in easyplot's Windows handling.

On Thu, May 10, 2018 at 9:24 AM, Gregory Guthrie <[hidden email]> wrote:

A very simple test program with Graphics.EasyPlot, flashes up a window, but too fast to see it. There are several old posts on this issue with gnuplot, but I haven’t seen any current solutions.

 

Example:

import Graphics.EasyPlot

 

tData = [ (1,2), (2,3), (3,1), (4,5), (5,3), (6,1) ]

 

main = do plot Windows $ Data2D [Title "Demo Title"] [] tData

 


_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners



_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners
Reply | Threaded
Open this post in threaded view
|

Re: EasyPlot on Windows

Gregory Guthrie
In reply to this post by Gregory Guthrie
Thanks; good idea - but nope.

I'd file a report to EasyPlot, but not sure where to do that.

Older discussions on this issue note that there is a "persist" option for gnuplot, but I didn't yet see how to pass that to try it.

-----Original Message-----


My first hunch was that, since the program ends right after plotting, it cleans up the plot window and exits. But trying it on an X11 system, I got a persistent window despite the program exiting. That may be a difference between Unix and Windows child process handling; I don't have a Windows machine handy right now to test, but you could try this:

main = do
  plot Windows $ Data2D [Title "Demo Title"] [] tData
  _ <- getLine
  return ()

If that doesn't fix it, my only guess is there's either a difference between the Unix and Windows versions of gnuplot, or a bug in easyplot's Windows handling.
_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners
Reply | Threaded
Open this post in threaded view
|

Re: EasyPlot on Windows

Ut Primum
Maybe you could try with plot'

Il ven 11 mag 2018, 15:11 Gregory Guthrie <[hidden email]> ha scritto:
Thanks; good idea - but nope.

I'd file a report to EasyPlot, but not sure where to do that.

Older discussions on this issue note that there is a "persist" option for gnuplot, but I didn't yet see how to pass that to try it.

-----Original Message-----


My first hunch was that, since the program ends right after plotting, it cleans up the plot window and exits. But trying it on an X11 system, I got a persistent window despite the program exiting. That may be a difference between Unix and Windows child process handling; I don't have a Windows machine handy right now to test, but you could try this:

main = do
  plot Windows $ Data2D [Title "Demo Title"] [] tData
  _ <- getLine
  return ()

If that doesn't fix it, my only guess is there's either a difference between the Unix and Windows versions of gnuplot, or a bug in easyplot's Windows handling.
_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners

_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners
Reply | Threaded
Open this post in threaded view
|

Re: EasyPlot on Windows

Ut Primum
What I meant was:

import Graphics.EasyPlot
tData = [ (1,2), (2,3), (3,1), (4,5), (5,3), (6,1) ]
main = do plot' [Interactive]  Windows $ Data2D [Title "Demo Title"] [] tData

this should work, but it keeps gnuplot open (so you have to type "quit" on the terminal).
(I think there is a difference between the Unix and Windows versions for Gnuplot; I had the same problem when I used gnuplot in C programs)

2018-05-11 15:42 GMT+02:00 Ut Primum <[hidden email]>:
Maybe you could try with plot'

Il ven 11 mag 2018, 15:11 Gregory Guthrie <[hidden email]> ha scritto:
Thanks; good idea - but nope.

I'd file a report to EasyPlot, but not sure where to do that.

Older discussions on this issue note that there is a "persist" option for gnuplot, but I didn't yet see how to pass that to try it.

-----Original Message-----


My first hunch was that, since the program ends right after plotting, it cleans up the plot window and exits. But trying it on an X11 system, I got a persistent window despite the program exiting. That may be a difference between Unix and Windows child process handling; I don't have a Windows machine handy right now to test, but you could try this:

main = do
  plot Windows $ Data2D [Title "Demo Title"] [] tData
  _ <- getLine
  return ()

If that doesn't fix it, my only guess is there's either a difference between the Unix and Windows versions of gnuplot, or a bug in easyplot's Windows handling.
_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners


_______________________________________________
Beginners mailing list
[hidden email]
http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners