3 ;;; Time-stamp: <2009-12-08 07:54:05 tony>
4 ;;; Creation: <2009-03-12 17:14:56 tony>
5 ;;; File: template.lisp
6 ;;; Author: AJ Rossini <blindglobe@gmail.com>
7 ;;; Copyright: (c)2009--, AJ Rossini. BSD, LLGPL, or GPLv2, depending
9 ;;; Purpose: Template header file
11 ;;; What is this talk of 'release'? Klingons do not make software
12 ;;; 'releases'. Our software 'escapes', leaving a bloody trail of
13 ;;; designers and quality assurance people in its wake.
16 ;; start within the common-lisp-stat-user
19 ;; we'll be loading from directories in the CLS homedir, so we want to
20 ;; make it easier to reach.
21 (defparameter *my-cls-homedir
*
22 "/home/tony/sandbox/CLS.git/" ; <- value with trailing directory separator
23 "documentation: change this to localize") ; <- doc
25 (concatenate 'string
*my-cls-homedir
* "Data/example.csv")
27 (defun localized-pathto (x)
28 "return a string denoting the complete path.
29 FIXME: UNIX-centric (though might work on Mac OSX). Might want to
30 return a pathspec, not a string/namespec"
32 (concatenate 'string
*my-cls-homedir
* x
))
37 ;; FIXME: Need to clean up data examples, licenses, attributions, etc.
38 ;; The following breaks because we should use a package to hold
39 ;; configuration details, and this would be the only package outside
40 ;; of packages.lisp, as it holds the overall defsystem structure.
41 (load-data "iris.lsp") ;; (the above partially fixed).
49 ;; Importing data from DSV text files.
51 (asdf:oos
'asdf
:load-op
'rsm-string
)
52 (rsm.string
:file-
>string-table
53 (localized-pathto "Data/example-mixed.csv"))
55 (rsm.string
:file-
>number-table
56 (localized-pathto "Data/example-numeric.csv"))
58 (defparameter *my-df-2
*
59 (make-instance 'dataframe-array
63 (rsm.string
:file-
>string-table
64 (localized-pathto "Data/example-mixed.csv"))))
65 :doc
"This is an interesting dataframe-array"))
68 (defparameter *my-df-3
*
69 (make-instance 'dataframe-array
73 (rsm.string
:file-
>number-table
74 (localized-pathto "Data/example-numeric.csv"))))
75 :doc
"This is an interesting dataframe-array"))
78 ;; Need to the this using the make-dataframe example, or write a
79 ;; dsvfile->dataframe command.