On Sat, Jun 11, 2011 at 12:54 AM, Henning Thielemann <lemming@henning-thielemann.de> wrote:

On Sat, 11 Jun 2011, Dmitri O.Kondratiev wrote:

That's what I get (see below). What else should I do to install gnuplot?

~/wks/haskell-wks/gnuplot/gnuplot-0.4.2/src>ghc -v Demo.hs

Do you really want to compile the Demo (with ghc)? It is already compiled if 'cabal install -fbuildExamples' was successful. Maybe you want to run 'ghci' for interactive tests. But you need to tell 'ghci' the path to the Paths module. 'make ghci-demo' should call GHCi with the right options on Linux:

$ ghci -Wall -i:src:dist/build/autogen:execute/tmp src/Demo.hs



Did I already advertise the gnuplot mailing list?
 http://projects.haskell.org/cgi-bin/mailman/listinfo/gnuplot/

Yes, you did, thanks. Yet, please allow me to ask a few more questions here, before I subscribe to gnuplot list. I am really short on time - must have some plots for demo next Monday (

1) Can current version of gnuplot draw histograms? I need these first of all.
2) It seems that "$ ghci -Wall -i:src:dist/build/autogen:execute/tmp src/Demo.hs"
works on Mac OSX, yet I can't make it produce any output directly on screen.
How to generate output and display it immediately in an output window?

This is what I get:

~/wks/haskell-wks/gnuplot/gnuplot-0.4.2>ghci -Wall -i:src:dist/build/autogen:execute/tmp src/Demo.hs
GHCi, version 6.12.3: http://www.haskell.org/ghc/  :? for help
Loading package ghc-prim ... linking ... done.
Loading package integer-gmp ... linking ... done.
Loading package base ... linking ... done.
Loading package ffi-1.0 ... linking ... done.
[ 1 of 33] Compiling Paths_gnuplot    ( dist/build/autogen/Paths_gnuplot.hs, interpreted )
[ 2 of 33] Compiling Graphics.Gnuplot.Terminal ( src/Graphics/Gnuplot/Terminal.hs, interpreted )
[ 3 of 33] Compiling Graphics.Gnuplot.Execute ( execute/tmp/Graphics/Gnuplot/Execute.hs, interpreted )
[ 4 of 33] Compiling Graphics.Gnuplot.Utility ( src/Graphics/Gnuplot/Utility.hs, interpreted )
[ 5 of 33] Compiling Graphics.Gnuplot.Private.FrameOption ( src/Graphics/Gnuplot/Private/FrameOption.hs, interpreted )
[ 6 of 33] Compiling Graphics.Gnuplot.Private.FrameOptionSet ( src/Graphics/Gnuplot/Private/FrameOptionSet.hs, interpreted )
[ 7 of 33] Compiling Graphics.Gnuplot.Private.Graph ( src/Graphics/Gnuplot/Private/Graph.hs, interpreted )
[ 8 of 33] Compiling Graphics.Gnuplot.Private.GraphEmpty ( src/Graphics/Gnuplot/Private/GraphEmpty.hs, interpreted )
[ 9 of 33] Compiling Graphics.Gnuplot.Display ( src/Graphics/Gnuplot/Display.hs, interpreted )
[10 of 33] Compiling Graphics.Gnuplot.Private.Plot ( src/Graphics/Gnuplot/Private/Plot.hs, interpreted )
[11 of 33] Compiling Graphics.Gnuplot.Private.Frame ( src/Graphics/Gnuplot/Private/Frame.hs, interpreted )
[12 of 33] Compiling Graphics.Gnuplot.Private.ColorSpecification ( src/Graphics/Gnuplot/Private/ColorSpecification.hs, interpreted )
[13 of 33] Compiling Graphics.Gnuplot.Private.LineSpecification ( src/Graphics/Gnuplot/Private/LineSpecification.hs, interpreted )
[14 of 33] Compiling Graphics.Gnuplot.Value.Tuple ( src/Graphics/Gnuplot/Value/Tuple.hs, interpreted )
[15 of 33] Compiling Graphics.Gnuplot.Value.Atom ( src/Graphics/Gnuplot/Value/Atom.hs, interpreted )
[16 of 33] Compiling Graphics.Gnuplot.Value.ColumnSet ( src/Graphics/Gnuplot/Value/ColumnSet.hs, interpreted )
[17 of 33] Compiling Graphics.Gnuplot.Private.Graph2DType ( src/Graphics/Gnuplot/Private/Graph2DType.hs, interpreted )
[18 of 33] Compiling Graphics.Gnuplot.Private.Graph2D ( src/Graphics/Gnuplot/Private/Graph2D.hs, interpreted )
[19 of 33] Compiling Graphics.Gnuplot.Private.Graph3DType ( src/Graphics/Gnuplot/Private/Graph3DType.hs, interpreted )
[20 of 33] Compiling Graphics.Gnuplot.Private.Graph3D ( src/Graphics/Gnuplot/Private/Graph3D.hs, interpreted )
[21 of 33] Compiling Graphics.Gnuplot.MultiPlot ( src/Graphics/Gnuplot/MultiPlot.hs, interpreted )
[22 of 33] Compiling Graphics.Gnuplot.LineSpecification ( src/Graphics/Gnuplot/LineSpecification.hs, interpreted )
[23 of 33] Compiling Graphics.Gnuplot.Graph.ThreeDimensional ( src/Graphics/Gnuplot/Graph/ThreeDimensional.hs, interpreted )
[24 of 33] Compiling Graphics.Gnuplot.Graph.TwoDimensional ( src/Graphics/Gnuplot/Graph/TwoDimensional.hs, interpreted )
[25 of 33] Compiling Graphics.Gnuplot.Graph ( src/Graphics/Gnuplot/Graph.hs, interpreted )
[26 of 33] Compiling Graphics.Gnuplot.Plot.ThreeDimensional ( src/Graphics/Gnuplot/Plot/ThreeDimensional.hs, interpreted )
[27 of 33] Compiling Graphics.Gnuplot.Plot.TwoDimensional ( src/Graphics/Gnuplot/Plot/TwoDimensional.hs, interpreted )
[28 of 33] Compiling Graphics.Gnuplot.Frame.OptionSet ( src/Graphics/Gnuplot/Frame/OptionSet.hs, interpreted )
[29 of 33] Compiling Graphics.Gnuplot.Frame.Option ( src/Graphics/Gnuplot/Frame/Option.hs, interpreted )
[30 of 33] Compiling Graphics.Gnuplot.Frame ( src/Graphics/Gnuplot/Frame.hs, interpreted )
[31 of 33] Compiling Graphics.Gnuplot.Terminal.X11 ( src/Graphics/Gnuplot/Terminal/X11.hs, interpreted )
[32 of 33] Compiling Graphics.Gnuplot.Advanced ( src/Graphics/Gnuplot/Advanced.hs, interpreted )

src/Graphics/Gnuplot/Advanced.hs:83:0:
    Warning: The import of `Data.Monoid' is redundant
               except perhaps to import instances from `Data.Monoid'
             To import instances alone, use: import Data.Monoid()
[33 of 33] Compiling Main             ( src/Demo.hs, interpreted )
Ok, modules loaded: Graphics.Gnuplot.Advanced, Graphics.Gnuplot.Terminal.X11, Graphics.Gnuplot.Frame, Graphics.Gnuplot.Frame.Option, Graphics.Gnuplot.Frame.OptionSet, Graphics.Gnuplot.Plot.TwoDimensional, Graphics.Gnuplot.Plot.ThreeDimensional, Graphics.Gnuplot.Graph, Graphics.Gnuplot.Graph.TwoDimensional, Graphics.Gnuplot.Graph.ThreeDimensional, Graphics.Gnuplot.LineSpecification, Graphics.Gnuplot.MultiPlot, Graphics.Gnuplot.Value.Atom, Graphics.Gnuplot.Value.Tuple, Graphics.Gnuplot.Value.ColumnSet, Graphics.Gnuplot.Private.LineSpecification, Graphics.Gnuplot.Private.ColorSpecification, Graphics.Gnuplot.Private.Plot, Graphics.Gnuplot.Private.Frame, Graphics.Gnuplot.Private.FrameOption, Graphics.Gnuplot.Private.FrameOptionSet, Graphics.Gnuplot.Private.Graph, Graphics.Gnuplot.Private.Graph2D, Graphics.Gnuplot.Private.Graph3D, Graphics.Gnuplot.Private.Graph2DType, Graphics.Gnuplot.Private.Graph3DType, Graphics.Gnuplot.Private.GraphEmpty, Graphics.Gnuplot.Utility, Graphics.Gnuplot.Execute, Graphics.Gnuplot.Display, Graphics.Gnuplot.Terminal, Main, Paths_gnuplot.
*Main> :t simple2D

<interactive>:1:0: Not in scope: `simple2D'
*Main> main
Loading package filepath-1.1.0.4 ... linking ... done.
Loading package old-locale-1.0.0.2 ... linking ... done.
Loading package old-time-1.0.0.5 ... linking ... done.
Loading package unix-2.4.0.2 ... linking ... done.
Loading package directory-1.0.1.1 ... linking ... done.
Loading package process-1.0.1.3 ... linking ... done.
Loading package time-1.1.4 ... linking ... done.
Loading package array-0.3.0.1 ... linking ... done.
Loading package containers-0.3.0.0 ... linking ... done.
Loading package utility-ht-0.0.7 ... linking ... done.
Loading package monoid-transformer-0.0.2 ... linking ... done.
*Main> :t simple2D

<interactive>:1:0: Not in scope: `simple2D'