3 ;;; Time-stamp: <2009-09-21 22:53:53 tony>
4 ;;; Creation: <2008-09-08 08:06:30 tony>
6 ;;; Author: AJ Rossini <blindglobe@gmail.com>
7 ;;; Copyright: (c) 2007-2008, AJ Rossini <blindglobe@gmail.com>. BSD.
8 ;;; Purpose: Stuff that needs to be made working sits inside the
9 ;;; progns... This file contains the current challenges to
10 ;;; solve, including a description of the setup and the work
13 ;;; What is this talk of 'release'? Klingons do not make software
14 ;;; 'releases'. Our software 'escapes', leaving a bloody trail of
15 ;;; designers and quality assurance people in its wake.
25 ;;(asdf:oos 'asdf:load-op 'lisp-matrix)
26 ;;(asdf:oos 'asdf:compile-op 'cls :force t)
27 (asdf:oos
'asdf
:load-op
'cls
)
30 (asdf:oos
'asdf
:load-op
'cl-cairo2-x11
)
31 (asdf:oos
'asdf
:load-op
'cl-2d
)
34 (asdf:oos
'asdf
:load-op
'cl-pdf
)
35 (asdf:oos
'asdf
:load-op
'cl-typesetting
))
37 ;; (asdf:oos 'asdf:load-op 'xarray)
38 ;; (asdf:oos 'asdf:load-op 'cl-opengl)
39 ;; (asdf:oos 'asdf:load-op 'tinaa)
43 (in-package :lisp-stat-unittests
)
45 ;; tests = 80, failures = 7, errors = 21
46 (run-tests :suite
'lisp-stat-ut
)
47 (describe (run-tests :suite
'lisp-stat-ut
))
49 (describe 'lisp-stat-ut
)
50 (documentation 'lisp-stat-ut
'type
)
52 ;; FIXME: Example: currently not relevant, yet
53 ;; (describe (lift::run-test :test-case 'lisp-stat-unittests::create-proto
54 ;; :suite 'lisp-stat-unittests::lisp-stat-ut-proto))
56 (describe (lift::run-tests
:suite
'lisp-stat-ut-dataframe
))
57 (lift::run-tests
:suite
'lisp-stat-ut-dataframe
)
59 (describe (lift::run-test
60 :test-case
'lisp-stat-unittests
::create-proto
61 :suite
'lisp-stat-unittests
::lisp-stat-ut-proto
))
65 ;;; Tasks working on...
69 ;; use of extension packages supporting versioning and validation of
71 (asdf:oos
'asdf
:load-op
'versioned-objects
)
72 (asdf:oos
'asdf
:load-op
'validations
))
76 ;; Syntax examples using lexical scope, closures, and bindings to
77 ;; ensure a clean communication of results
78 (with-data dataset
((dsvarname1 [usevarname1])
79 (dsvarname2 [usevarname2]))
82 (defparameter *df-test*
83 (make-instance 'dataframe-array
84 :storage #2A (('a "test0" 0 0d0)
90 :case-labels (list "0" "1" "2" "3" "4")
91 :var-labels (list "symbol" "string" "integer" "double-float")
92 :var-types (list 'symbol 'string 'integer 'double-float)))
94 *df-test* ; but with SBCL, ints become floats?
96 (defun check-var (df colnum)
97 (let ((nobs (xdim df 0)))
99 (check-type (xref df i colnum) (elt (var-types df) i)))))
101 (check-var *df-test* 0)
105 (integerp (xref *df-test* 1 2))
106 (floatp (xref *df-test* 1 2))
107 (integerp (xref *df-test* 1 3))
108 (type-of (xref *df-test* 1 3))
109 (floatp (xref *df-test* 1 3))
111 (type-of (vector 1 1d0))
120 (xref *df-test* 1 '*)
122 ;;; Experiments with cl-variates
124 ;; (asdf:oos 'asdf:compile-op 'cl-variates :force t)
125 ;; (asdf:oos 'asdf:compile-op 'cl-variates-test :force t)
126 ;; (asdf:oos 'asdf:load-op 'lift)
127 ;; (asdf:oos 'asdf:load-op 'cl-variates)
128 (asdf:oos 'asdf:load-op 'cl-variates-test)
130 (in-package :cl-variates-test)
132 (run-tests :suite 'cl-variates-test)
133 (describe (run-tests :suite 'cl-variates-test))
135 (in-package :cl-variates-user)
137 (defparameter state (make-random-number-generator))
138 (setf (random-seed state) 44)
140 (loop for i from 1 to 10 collect
141 (random-range state 0 10))
142 ;; => (1 5 1 0 7 1 2 2 8 10)
143 (setf (random-seed state) 44)
144 (loop for i from 1 to 10 collect
145 (random-range state 0 10))
146 ;; => (1 5 1 0 7 1 2 2 8 10)
148 (setf (random-seed state) 44)
150 (loop for i from 1 to 10 collect
151 (normal-random state 0 1))
153 ;; (-1.2968656102820426 0.40746363934173213 -0.8594712469518473 0.8795681301148328
154 ;; 1.0731526250004264 -0.8161629082481728 0.7001813608754809 0.1078045427044097
155 ;; 0.20750134211656893 -0.14501914108452274)
157 (setf (random-seed state) 44)
158 (loop for i from 1 to 10 collect
159 (normal-random state 0 1))
161 ;; (-1.2968656102820426 0.40746363934173213 -0.8594712469518473 0.8795681301148328
162 ;; 1.0731526250004264 -0.8161629082481728 0.7001813608754809 0.1078045427044097
163 ;; 0.20750134211656893 -0.14501914108452274)
166 ;;; experiments with LLA
167 (in-package :cl-user)
168 (asdf:oos 'asdf:load-op 'lla)
169 (in-package :lla-user)