Haskell Charts

A library for rendering 2D charts from haskell.

Features

News

11 August 2008

Haddock lives! I've updated the public API documentation to match v 0.8.

6 July 2008

New features in the just released v 0.8 include:

Apologies that the API docs on this ste are still a bit out of date. Having upgraded to ghc 6.8.3, it seems there's no haddock yet to support it.

8 May 2008

Another version, tagged "CHART_0_7", and uploaded to hackage. New we have:

Note that the haddock API documentation linked to below is a little out of date. This new version makes user of the newtype deriving ghc extension, which isn't parsed by my ailing haddock 0.8. Time to upgrade it...

10 Mar 2008

I've tagged the current version "CHART_0_6", and uploaded the package to hackage. New features include:

25 Feb 2008

I've pushed David Roundy's patches implementing the "simple" interface. This makes usage from within ghci feasible. A tag and release to hackage will follow. See the comments at the the start of Simple.hs for information and examples.

/OldNews

Examples

Simple API

The "simple" API is straightforward to use directly from the ghci REPL. For example:

$ ghci -package Chart
...
Prelude> :m Graphics.Rendering.Chart.Simple
Prelude Graphics.Rendering.Chart.Simple> plotWindow [0,0.1..2.9] sin

will produce a chart in a window:

HaskellCharts/Example0

Standard API

(Click on the example to enlarge and view it's haskell source)

HaskellCharts/Example1 HaskellCharts/Example2
HaskellCharts/Example3 HaskellCharts/Example6
HaskellCharts/Example8

Documentation

The documentation automatically generated by haddock is available here. This corresponds to the repo state tagged CHART_0_6'

To-Do

(too long to list!)

Dependencies

Download

via darcs, with the command: darcs get http://www.dockerz.net/repos/chart or get a (maybe more) stable version from hackage.

To build

Follow the usual cabal routine. If you fetched from darcs:

cd chart
runghc Setup.hs configure
runghc Setup.hs build
sudo runghc Setup.hs install

or from hackage:

tar -xzf Chart-2007.8.8.tar.gz
cd Chart-2007.8.8
runghc Setup.hs configure
runghc Setup.hs build
sudo runghc Setup.hs install

(Cabal note: the sudo is required to install into a system wide ghc package database. If you want to install only for the current user, then add something like "--user --prefix ~/ghc_local" to the configure line, and drop the sudo)

Finally, to build the set of test charts into a single executable:

cd tests; ghc --make test.hs
./test

Credits

Thanks to David Roundy, Francisco Jerez, and Russell O'Connor for contributing patches.

Contact

Tim Docker

Patches welcome!

HaskellCharts (last edited 2008-08-11 20:46:56 by TimDocker)