I've stumbled to a need to visualize some graph data. Any library that
do things like pies, histograms, box & whiskers .. ? The only thing
I found is PLOT-2D which looks nice but I'm little worried about how
it will work under windows.
Any recommendation ?
thanks
bobi
On Jul 20, 10:01 pm, Slobodan Blazeski <·················@gmail.com>
wrote:
> I've stumbled to a need to visualize some graph data. Any library that
> do things like pies, histograms, box & whiskers .. ? The only thing
> I found is PLOT-2D which looks nice but I'm little worried about how
> it will work under windows.
>
> Any recommendation ?
>
> thanks
> bobi
And http://common-lisp.net/project/cl-plplot/ . Anybody used them ?
On Jul 20, 4:14 pm, Slobodan Blazeski <·················@gmail.com>
wrote:
> On Jul 20, 10:01 pm, Slobodan Blazeski <·················@gmail.com>
> wrote:
>
> > I've stumbled to a need to visualize some graph data. Any library that
> > do things like pies, histograms, box & whiskers .. ? The only thing
> > I found is PLOT-2D which looks nice but I'm little worried about how
> > it will work under windows.
>
> > Any recommendation ?
>
> > thanks
> > bobi
>
> Andhttp://common-lisp.net/project/cl-plplot/. Anybody used them ?
See the recent thread "Generate plots with lisp" for suggestions.
There were several interesting suggestions. I have tried to implement
cl-pdf, but I am having some trouble
running the examples. I have emailed the author of the package, and
if you are interested, I can keep you
posted.
(I am running clisp via cygwin on windows)
Mirko
On Fri, 20 Jul 2007 13:01:12 -0700, <·················@gmail.com> wrote:
> I've stumbled to a need to visualize some graph data. Any library that
> do things like pies, histograms, box & whiskers .. ? The only thing
box & whiskers? If that is 'candlesticks' from the stock-charting
world, then gnuplot 4.2 includes candlesticks and histograms. 'Pies'
might exist too, but they can be created from the toolset in any case.
--
There are no average Common Lisp programmers
Reply-To: email is ignored.
--
Posted via a free Usenet account from http://www.teranews.com
Hi Slobodan,
Slobodan Blazeski wrote:
> I've stumbled to a need to visualize some graph data. Any library that
> do things like pies, histograms, box & whiskers .. ? The only thing
> I found is PLOT-2D which looks nice but I'm little worried about how
> it will work under windows.
I haven't known or used either of the two libraries you mentioned.
Instead, I use (Windows) (C)Lisp to create scripts for the R statistical
package, then call out to R and run the scripts to produce my box and
whisker and bar plots.
R has a horrible syntax but apparently is Scheme based underneath (they
hide it well, if that's the case -- I wish they would provide a real
Scheme syntax!). However, it is quite capable once you bend your mind to
what to me feels like a very quirky way of doing things.
Doing the above is obviously not a "pure lisp" solution, but practically
speaking, it *is* a solution, and I have in fact deployed it to a
"production" Windows environment (although in an experimental, prototype
sort of way -- it's not the main app, only a relatively unimportant
supporting tool).
To create a box plot and bar plot, I did something like the following,
which looks really ugly, but gets the job done:
;; Box Plot
(format stream
(concatenate 'string
"~&png(filename = \"~A\", "
"width = ~A, height = ~A, pointsize = 12, "
"bg = \"white\", res = NA, "
"restoreConsole = TRUE)~%")
box-png png-width png-height)
(format stream
(concatenate 'string
"~&boxplot(hourly, names=c(1:length(hourly)), "
"ylim=c(0,max(hourly)), main=\"~A\", "
"sub=\"~A\", ylab=\"~A\")~%")
nice-title-string report-month box-y-label)
(format stream "axis(side=4)~%")
(format stream "dev.off()~%")
;; Bar Plot
(format stream
(concatenate 'string
"~&png(filename = \"~A\", "
"width = ~A, height = ~A, pointsize = 12, "
"bg = \"white\", res = NA, "
"restoreConsole = TRUE)~%")
bar-png png-width png-height)
(format stream
(concatenate 'string
"~&x <- barplot(height=as.matrix(hourly), "
"names=c(1:length(hourly)), "
"main=\"~A\", sub=\"~A\", "
"ylab=\"~A\", col=\"PaleGoldenRod\")~%")
nice-title-string report-month bar-y-label)
(format stream "~&axis(side=4)~%")
(format stream "~&dev.off()~%")
To call the script, something like the following does the job:
(ext:run-program "c:/path/to/r.exe"
:arguments '("--silent" "--no-save")
:input script-name
:output nil)
"ext:run-program" is a CLISP thing. Most lisps have an equivalent, I think.
One may not like this approach, but at least it's another way to solve
the problem. (By the way, the above method takes only a second or three
to generate a couple of dozen charts in PNG image format.)
Cheers,
David
On Fri, 20 Jul 2007 13:01:12 -0700, Slobodan Blazeski wrote:
> I've stumbled to a need to visualize some graph data. Any library that
> do things like pies, histograms, box & whiskers .. ? The only thing
> I found is PLOT-2D which looks nice but I'm little worried about how
> it will work under windows.
>
> Any recommendation ?
>
> thanks
> bobi
I've been using Edi Weitz's cl-gd:
http://weitz.de/cl-gd/
Its easy to extend and works very well.
--Jeff