unofficial mirror of guile-user@gnu.org 
 help / color / mirror / Atom feed
* ANN: Guile-Charting 0.1.0 released
@ 2007-06-08 16:16 Andy Wingo
  2007-06-11  2:40 ` steve tell
  0 siblings, 1 reply; 3+ messages in thread
From: Andy Wingo @ 2007-06-08 16:16 UTC (permalink / raw)
  To: guile-user

[-- Attachment #1: Type: text/plain, Size: 1652 bytes --]

Hey all,

While doing benchmarking and profiling on Guile, I wanted to make bar
graphs with standard-deviation tickers. I couldn't get Gnumeric or
Openoffice to do it, for various reasons. I then realized that it
wouldn't be too bad to do it all in Guile, using Guile-Cairo, and a day
and a half later here we are!

Guile-Charting currently only makes bar charts, but it's something of a
toolkit so you can use the pieces to make other kinds of charts. A
simple invocation would be:

(make-bar-chart "Average Height at Iihenda JSS"
                 '(("Grade 9" (150 "Boys") (140 "Girls"))
                   ("Grade 10" (153 "Boys") (147 "Girls")))
                 :write-to-png "/tmp/graph.png")

A slightly more involved invocation would be:

(define *data*
  '(("Initialization"
     (0.0737 "Python 2.5.1c1" (:y-bracket 0.00264764045897))
     (0.0822 "Guile 1.6.8" (:y-bracket 0.00208806130178))
     (0.1444 "Guile 1.8 CVS" (:y-bracket 0.00645290632196)))
    ("(use-modules (oop goops))"
     (0.1357 "Guile 1.6.8" (:y-bracket 0.00651579278028))
     (0.2766 "Guile 1.8 CVS" (:y-bracket 0.02164973697556)))))

(make-bar-chart "Guile Benchmarks" *data*
                :write-to-png "/tmp/guile-benchmarks.png"
                :bar-width 40 :group-spacing 40 :chart-height 240
                :chart-params
                '(:y-axis-label "Wall-clock execution time (s)"))

Guile-Charting has a web site:
   http://wingolog.org/software/guile-charting/
There's even documentation! See the web site for more. Download the
tarball at:
   http://wingolog.org/pub/guile-charting/guile-charting-0.1.0.tar.gz

Cheers,

Andy.
-- 
http://wingolog.org/

[-- Attachment #2: guile-benchmarks.png --]
[-- Type: image/png, Size: 14869 bytes --]

[-- Attachment #3: Type: text/plain, Size: 140 bytes --]

_______________________________________________
Guile-user mailing list
Guile-user@gnu.org
http://lists.gnu.org/mailman/listinfo/guile-user

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: ANN: Guile-Charting 0.1.0 released
  2007-06-08 16:16 ANN: Guile-Charting 0.1.0 released Andy Wingo
@ 2007-06-11  2:40 ` steve tell
  2007-06-12 21:51   ` Andy Wingo
  0 siblings, 1 reply; 3+ messages in thread
From: steve tell @ 2007-06-11  2:40 UTC (permalink / raw)
  To: Andy Wingo; +Cc: guile-user

On Fri, 8 Jun 2007, Andy Wingo wrote:

> ... using Guile-Cairo, and a day and a half later here we are!
>
> (make-bar-chart "Average Height at Iihenda JSS"
>                 '(("Grade 9" (150 "Boys") (140 "Girls"))
>                   ("Grade 10" (153 "Boys") (147 "Girls")))
>                 :write-to-png "/tmp/graph.png")


I was looking for a guile-cairo example, so I gave gave this a try, by 
adding a "(use-modules (charting))" to those four 
lines, and running from the guile-charting-0.1.0
build directory with "env guile -s ../examples/height.scm".

It fails with
ERROR: Unbound variable: :write-to-png


Changing only ":write-to-png" to "#:write-to-png" changes the session to:


$ cat ../examples/height.scm
(use-modules (charting))

(make-bar-chart "Average Height at Iihenda JSS"
                  '(("Grade 9" (150 "Boys") (140 "Girls"))
                    ("Grade 10" (153 "Boys") (147 "Girls")))
                  #:write-to-png "/tmp/graph.png")
$ env guile -s ../examples/height.scm
ERROR: Unbound variable: :y-axis-ticks
$


This looks like a problem of the #: vs. : style of keyword-arguments,
but adding "(read-set! keywords 'prefix)" to the
example doesn't fix things, but simply changes the error to
ERROR: Unbound variable: #{:y-axis-ticks}#


All this using guile-cairo-1.3.91, cario-1.2.6, and fedora core's 
guile-1.8.0-8.20060831cvs


Steve


_______________________________________________
Guile-user mailing list
Guile-user@gnu.org
http://lists.gnu.org/mailman/listinfo/guile-user


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: ANN: Guile-Charting 0.1.0 released
  2007-06-11  2:40 ` steve tell
@ 2007-06-12 21:51   ` Andy Wingo
  0 siblings, 0 replies; 3+ messages in thread
From: Andy Wingo @ 2007-06-12 21:51 UTC (permalink / raw)
  To: steve tell; +Cc: guile-user

Hey Steve,

On Sun, 2007-06-10 at 22:40 -0400, steve tell wrote:
> ERROR: Unbound variable: :write-to-png

Try again please! Note that probably this would have worked with a
(read-enable! keywords 'prefix) before anything. But whatever, your
point is valid.

Cheers,

Andy.
-- 
http://wingolog.org/


_______________________________________________
Guile-user mailing list
Guile-user@gnu.org
http://lists.gnu.org/mailman/listinfo/guile-user


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2007-06-12 21:51 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-06-08 16:16 ANN: Guile-Charting 0.1.0 released Andy Wingo
2007-06-11  2:40 ` steve tell
2007-06-12 21:51   ` Andy Wingo

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).