-
Notifications
You must be signed in to change notification settings - Fork 18
Installation
First things first, you have to have a working Common Lisp implementation and all the libraries required by the components you wish to use.
If you're on GNU/Linux, chances are SBCL will do fine; I use it for my own data analysis. (Especially nice is the Emacs + SLIME combo as a front-end to the Lisp REPL.) If you're on Windows or Mac or want to see more options, try this.
NOTE: As of now (2021-10-16), the CFFI groveler does not correctly compile HDF5 (1.12.1) related files with at least one version of GCC (11.1.0). Due to this, if you use new versions of GCC and/or HDF5, you might need to use the "newcffi" branch of cl-ana along with my fork of CFFI until upstream accepts my pull request or fixes this on their own.
First install the following:
Then all you have to do is run this in your favorite Lisp implementation:
(ql:quickload "cl-ana")
and quicklisp automatically downloads cl-ana and all its Lisp dependencies.
It may be that the quicklisp version is not up to date with the lastest version of cl-ana; in this case, one can use quicklisp to install cl-ana the first time, and as long as there are no new dependencies you can just download the newest source and place it somewhere ASDF knows about on your system, possibly removing the quicklisp version of cl-ana if necessary.
If you start getting strange errors while loading GSLL or CFFI for the first time about 'ffi.h/ffitarget.h not found', then you probably need to create symbolic links to the libffi headers in /usr/include. But have no fear, my libcffi-compat project has a script which will create these for you.
cl-ana depends on the following libraries on top of whatever implementation of Lisp you decide:
The Lisp library dependencies GSLL, Alexandria, iterate, antik, and cl-csv can all be easily installed via quicklisp. The order of dependency installation should be (along with Lisp commands for installing via quicklisp):
- HDF5
- GSL
- gnuplot
- external-program
(ql:quickload "external-program")
- CFFI
(ql:quickload "cffi")
- Alexandria
(ql:quickload "alexandria")
- GSLL
(ql:quickload "gsll")
- iterate
(ql:quickload "iterate")
- antik
(ql:quickload "antik")
- cl-csv
(ql:quickload "cl-csv")
- cl-fad
(ql:quickload "cl-fad")
Installation of cl-ana is most easily done by placing the source code in a directory where ASDF will look for it. If you don't know what I'm talking about, read this first. Once you've placed it somewhere ASDF knows about, all you have to do is tell your Lisp implementation to load it:
(require 'cl-ana)
This loads all the modules that make up cl-ana. Also provided is a package for playing around:
(in-package :cl-ana)
Each time you want to use cl-ana, all you have to do is fire up the Lisp implementation of your choice and type the above commands into the REPL.