These are examples files to accompany the Ripon Good Math
implementation of xlispstat.
The file all.lsp contains a dialog to allow one to load these
simply. Start up xlispstat, load file all.lsp, and then you have a menu which
allows quick loading of most of these (the interesting ones, although not all
do something upon loading!).
Also included here are the original Data files that come with
xlispstat. Some of them are used in the examples of Luke's book. I've
duplicated files that have filenames longer than 8 characters, to appease
the DOS monster.... They are as follows:
Section A:
- abe.lsp
- contains my dad's abe data (taken from a bust of Abe Lincoln -
we represent abe as a matrix.
- adji.lsp
- is file adji.lsp, created to play one version of mancala and beat
the old men of Cotonou. I created this file for Rock, when we got to talking
about how the old men like to sit around and play. I told him that it would be
fun to program a computer to beat them (I wondered what they'd say to that!).
I can only beat them at the easy version - they beat me at the harder
version. So, for the moment, I'm leaving them their pride! (And pretending to
myself that I could actually beat them if I only worked harder, which is not at
all certain!)
- adjust.lsp
- concerns adjustment: Trying to follow the exposition in Statistical
Methods in Epidemiology, by Kahn and Sempos, p. 138:
- africa.lsp
- Working a problem from Cliff and Ord's "Spatial Processes", involving Moran's I calculations.
- ai3
- contains files for the ai book of Patrick H. Winston:
;;;; This software is licensed by Patrick H. Winston (licensor) for
;;;; instructional use with the textbooks ``Artificial Intelligence,'' by
;;;; Patrick H. Winston, and ``Lisp,'' by Patrick H. Winston and Berthold
;;;; K. P. Horn. You are free to make copies of this software and
;;;; modify it for such instructional use as long as:
;;;; 1. You keep this notice intact.
;;;; 2. You cause any modified files to carry a prominent notice stating
;;;; that you modified the files and the date of your modifications.
- agresti.lsp
- will hopefully one day be used to input most of Agresti's
examples, based on someone else's hard work of entering the data:
This document contains tables from the Appendix of "An Introduction to
Categorical Data Analysis," by Alan Agresti, published by John Wiley
and Sons, Inc., January 1996. The tables show SAS code for the analyses
conducted in that text, and contain the major data sets from that text.
See the text for further information about the datasets.
- all.lsp
- contains a dialog allowing quick loading of any of several
of these (more interesting) example files.
- autodiff.lsp
- does automatic differentiation.
This is Dan Kalman's latest code. He's also got a test routine at the
end which he called testf, but which I've renamed kalmans-test.
kalman@email.cas.american.edu: "I found a newer version of the lisp that
goes with the paper I handed out in San Diego. This version really
implements everything just as in the talk. I have not worked with it very
much, and suspect it may perform worse than the other version. But the code
should be more understandable. Hope you have fun with it."
Section B:
- barchart.lsp
- is Dom Early's bar-chart.
- bayes.lsp
- Data from the book Bayes and Empirical Bayes... by
Carlin, et al.
- bele.lsp
- This is file bele.lsp, created to play one version of mancala
and beat the old men of Cotonou. I created this file for Rock, when we got to
talking about how the old men like to sit around and play. I told him that it
would be fun to program a computer to beat them (I wondered what they'd say to
that!).
- benford.lsp
- concern's benford's distribution of digits.
- bithell.lsp
- creating data sets and showing the functions Bithell used in his
relative risk testing from epidemiology.
- bos.lsp
-
This is work on a paper by L. P. Bos, J. E. Grabenstetter, and K.
Salkauskas, Pseudo-tensor product interpolation and blending with families
of univariate schemes, Computer-Aided Geometric Design, 13 (1996) 429-440.
- buttafly.lsp
- is just for fun, try it!
(load-calc buttafly)
(butterfly)
Section C:
- calculator.lsp
- emulates a ti-30-calculator:
(load-calc calculator)
- calculat.lsp
- same calculator thing, for the Dos afflicted.
(load-calc calculat)
- californ.lsp
- a file that is useful for verifying the score test, defined in file
spatial.lsp. This is a cluster test.
(load-calc californ)
- chars.lsp
- demonstrates some character/string functions.
(load-calc chars examples t)
- convhull.lsp
- returns a list of points forming the convex hull of a two-dimensional
data set.
Section D:
- dad.lsp
- documents that our flesh technique can be used to match a
grid of functions (a function grid).
- dad2.lsp
- produces pictures related to dad.lsp (see that file first!)
- dad3.lsp
- realized that, in fact, the whole thing boils down to something
that doesn't even require all the SVD gyrations: we could just proceed directly
to the inverse of the matrix. So I do!
- dad4.lsp -> dad5.lsp -> dad6.lsp
-
Here's a kludgy way to get an m x n case to work out (in the sense of
getting curve interpolation with as much differentiability as existed in the
original curves):
Assume m < n: step over the n dimension m curves at a time, and do an
mxm case (n-m+1 times). You now have n-m+1 patch functions, which you can
multiply by bump functions (infinitely differentiable, finitely supported) and
add together to maintain interpolation and differentiability.
Run dad6.lsp for the best of the lot. It also seems to be the
culmination.
- daniel.lsp
- contains work from Wayne W. Daniel's "Biostatistics: a
Foundation for Analysis in the Health Sciences."
- densdemo.lsp
- This file contains programs to run demonstrations of plots of density
and probability functions.
- domutils.lsp - by Dom Early
- is needed by other files, e.g. barchart.lsp.
- drapedat.lsp
- is needed by draper.lsp.
- draper.lsp
- is most of the examples and exercises from the book "Applied
Regression Analysis", by N. R. Draper and H. Smith., second edition.
- dynload.lsp
- demonstrates dynamic loading, call-cfun, call-fsub
- dynload2.lsp
- also demonstrates dynamic loading, call-cfun, call-fsub
Section E:
- eig-show.lsp
- shows how to create simple functions for calculating eigenvalues
of general matrices using the determinant. (These are pedogogical, rather than
work-horse!)
Section F:
- f2cl.lsp
- represents a lot of work trying to adapt and improve f2cl. It
works pretty well now, at turning fortran codes into xlispstat codes.
- f2cltest.lsp
- tests f2cl, using files which are found all over my directory
structure. So this won't be very useful in general! On the other hand, it
should show you how to test....
- farouki.lsp
- skins the farouki matroid, and looks at surface curvature of the
skin.
- flesh.lsp
- For fleshing out the zero matrix, creating a skin. I've got a method
for interpolating the grid without forcing the boundary to zero, and I want
to use in the general case of interpolating a matrix.
- formal.lsp
- defines some formal operations (e.g. simplifies - in infix
notation - the sum of two matrices).
- francais.lsp
- shows how I use xlispstat to improve my french!
Section G:
- gabor.lsp
- Gabor Filters: Joel Hounsou has me thinking about Gabor filters. He
want to duplicate some results he's seen in a few papers, with the unltimate
goal of signature discrimination.
- gart.lsp
- This is from a paper by John J. Gart, The comparison of proportions: a
review of significance tests, confidence intervals, and adjustments for
stratification, Review of the International Statistical Institute, V. 79, #2,
1971.
- graph.lsp
- is, at the moment, just chapter 9 from the Luke Book. I've had
thoughts of doing something with this sort of plot...
- grays.lsp
- "I attach my hack for gray-level plots, it do not fully does what you
need but it's close..."
Frederic Udina
- grrisk.lsp
- This is to look at the effect of integrating various functions over the
"relative risk". Jay did this, plotting relative risk for a function.
Section H:
- hash101.lsp
- is basics of hash tables.
- high-d.lsp
- is demonstrates another way of visualizing high dimensional
data.
- hosmer.lsp
- is stuff from hosmer/lemeshow, Logistic Regression.
Section I:
- ill.lsp
- fleshing out a rank-one (ill-conditioned) matrix
- infect.lsp
- The idea here is to create a simulation of an infectious process. I'm
going to follow the idea of the book "Spatial Processes", by Cliff and Ord, and
use one poisson process followed by a second. I.e., the first poisson process
distributes the disease based on the weighted underlying population structure,
while the second reflects the choice of a second poisson process that reflects
infections from the primary infecteds.
In other words, the infecteds always spread out from the infected in a
poisson fashion.
Section J:
- jacobi.lsp
- is a demonstration of a couple of iterative techniques for
solving Ax=b, including jacobi-iteration and gauss-seidel-iteration.
- jay.lsp
- helped result in
Kaufman, J. S., M. C. Asuzu, J. Mufunda, T. Forrester, R. Wilks, A. Luke,
A. E. Long, and R. S. Cooper. {\em Relationship Between Blood Pressure
and Body Mass Index in Lean Populations}. Hypertension, Vol. 30, \#6,
December, 1997:1511-1516.
- john-fox.lsp
- includes some xlispstat tips on various topics.
Section K:
- kalman.lsp
- is kalman's old code: the update is in autodiff.lsp.
- kishore.lsp
- Kishore Karamshandani of Pulmonary came to me with plots of
lung function for seven lung-transplant patients whose lung function was
declining. At 20% decline, they are said to show BOS, a lung syndrome.
- knot.lsp
- is some knot plotting stuff from Dad....
Section L:
- lisp3
- contains files for the lisp book of Patrick H. Winston:
;;;; This software is licensed by Patrick H. Winston (licensor) for
;;;; instructional use with the textbooks ``Artificial Intelligence,'' by
;;;; Patrick H. Winston, and ``Lisp,'' by Patrick H. Winston and Berthold
;;;; K. P. Horn. Your are free to make copies of this software and
;;;; modify it for such instructional use as long as:
;;;; 1. You keep this notice intact.
;;;; 2. You cause any modified files to carry a prominent notice stating
;;;; that you modified the files and the date of your modifications.
- logistic.lsp
- is a demonstration that I rigged up for Jay, to show him the
effect of varying the parameters in a logistic model.
- loglin
- is a set of files created by
Brendan Halpin |E-mail: brendan@essex.ac.uk
ESRC Research Centre on Micro-Social Change |PGP key on servers, finger
University of Essex, Colchester CO4 3SQ, UK |Work: +44-1206-873790
http://www.irc.essex.ac.uk/~brendan |Home: +44-1206-825250
for doing loglinear modelling.
- lorenz.lsp
- is a collection of examples and exercises to look at different
aspects of the Lorenz equations.
- ls2html.lsp
- shows how to format a directory as an html file.
Section M:
- mancala.lsp
- was created to play one version of mancala and
beat the old men of Cotonou. I created this file for Rock, when we got to
talking about how the old men like to sit around and play. I told him that it
would be fun to program a computer to beat them (I wondered what they'd say to
that!).
- maple.lsp
- Maple didn't seem to have an easy way to turn a text file into
a worksheet, so I kludged this one up.
- matroid.lsp
- is a trio of matroids, which together constitute the sphere with
three holes in it. It's called matroid.gif, and it's in my home directory, in
the dad subdirectory. Have a look.
It's fleshed out (doubled) from six sections per matroid.
I made it using circles in the plane that have their derivatives
perpendicular to the equator (so that when they are projected onto the sphere
there will be derivative continuity). I see that I need to do some geometry: I
should really use the orthogonal family of these circles to define the points
in the other direction, so as to assure continuity of derivatives in the other
direction (or something like that!).
- meshnick.lsp
- For a project I'm involved in with Steve Meshnick, concerning resistant
malaria.
- mswstat.lsp
- is a file containing examples from the second edition of the
book "Mathematical Statistics with Applications" by William Mendenhall, Richard
L. Scheaffer, and Dennis D. Wackerly.
- myeloma.lsp
- is
Myeloma Data, from p. 9 of "Modelling Survival Data in Medical Research",
D. Collett.
Section N:
- neural.lsp
- is file neural.lsp, created to test out back-propogation and
neural nets. This work was undertaken at the Institut de Mathematiques et de
Sciences Physiques, Porto Novo, Benin, in collaboration with Dr. Joel Hounsou.
- neural2.lsp
- I want to discriminate letters as seen in a demo of the software
"Cortex-Pro" that Joel gave me.
- newstart.lsp
- is a new start on an environment which is general enough to work
under all three platforms, and work well.
- nonnewt.lsp
- is a file containing a function that solves for zeros of systems
using newton's method.
- nonnewt1.lsp
- calculates the svd of a matrix using a modified form of the
function in nonnewt.lsp.
- nreg.lsp
- there are two: one is a simple little example for nreg-model;
the other is in the loyola directory now, along with its big data file,
which is gzipped.
Section O:
- obj-dist.lsp
- contains further work, based on the file obj-func.lsp, in the
realm of distributions. It contains some trials of re-parenting, and
multiple-parenting.
- obj-func.lsp
- is a start on a function object, which contains plotting,
domain, etc. information about a lambda expression.
- OOP.lsp
- is a "fun" demo file for Object-Oriented Programming, involving
a tool inventory system.
- ord.lsp
- some spatial statistics from a paper by Keith Ord.
Section P:
- packages.lsp
- is a first look at packages: why they work, why they don't.
- perko.lsp
- is a collection of examples and exercises from the book
"Differential Equations and Dynamical Systems", by Lawrence Perko,
Springer-Verlag, New York, 1991.
- pie-chart.lsp
- is for making - of all things - pie-charts! Tchapo was doing pie
charts in school, so I made a pie chart maker. Initially based on the one in
the ucla archive (pie-chart.lsp, by Jan de Leeuw, 02-23-95), but much modified.
- power.lsp
- is useful for carrying out statistical power
calculations. Functions start-power and test-start-power are now implemented as
macros which load this file as needed.
Section Q:
- quotes.lsp
- are some nice quotes!
Section R:
- ripley.lsp
- implements the Ripley's K function.
- rubout.lsp
- is supposed to take care of a mac problem dealing with the
#\Rubout character.
Section S:
- sheet.lsp
- "The previous spreadsheet data-editor I made had some
disadvantages...."
;; Version 0.5 -- Jan de Leeuw -- 07-23-95
;; Version 0.6 ------------------ added save and revert
- simplex.lsp
- is an implementation of Gil Strang's simplex method. It's
sloppy, not pretty and optimized the way he would want it to be, but it gets
the job done.
- snedecor.lsp
- is exercises from Snedecor and Cochrane, 6th edition.
- steve.lsp
- is more tips from xlispstat folks.
- strang.lsp
- will ultimately be many of the examples and exercises from the
book "Introduction to Applied Mathematics", by Gilbert Strang, first edition.
- survive.lsp
- is a repackaged version of a file that Thomas Lumley shipped out
to do some survival analysis. I changed pieces here and there.
- svd-reg.lsp
- attempts to address the relationship between svd and regression.
Section T:
- teach
- is a directory containing demonstrations by the R folks, to show
some simple ideas in statistics.
- tensor.lsp
- contains my tensor definitions, methods, etc., toward a
generalization of the SVD to the TSVD.
- tic-tac.lsp
- I read in a book that Joel gave me to read ("Neural Computing: An
Introduction", by R. Beale and T. Jackson, Adam Hilger, Bristol) about MENACE
(Matchbox Educable Noughts and Crosses Engine), which learns to play the game
of "naughts and crosses" (i.e., tic-tac-toe) by the simple addition and
deletion of match sticks from matchboxes.
- tic-tac1.lsp
- is data for tic-tac.lsp
- tic-tac2.lsp
- contains a list of all possible moves, which was fairly
computation intensive so I wanted to save it.
- trial.lsp
- demonstrates how to use require.
- trial1.lsp
- is a file containing a function needed to make the trial
require...
- typing.lsp
- is a program I wrote to help our librarian Therese learn to
type while I was at IMSP. It contains a function (lettres) which tells Therese
how well she's doing at typing made up words.
- tsvd.lsp
- is based on nonnewt1.lsp, only to find the tsvd of a tensor.
Section U:
- unonldyn.lsp
- is examples from Kaplan and Glass, Understanding Non-Linear
Dynamics.
Section V:
Section W:
- waller.lsp
- a file that is useful for verifying several cluster tests, defined in
file spatial.lsp.
(load-calc waller)
- webster.lsp
- Kriging the local risk of a rare disease from a register of
diagnoses.
Section X:
- xgobips.lsp
- is for creating postscript plots of point data using the template of
xgobi - these are much nicer than my native postscript function output.
- xgobips2.lsp
- is for creating postscript plots of line data using the template of
xgobi. I really need to combine the two so that I can do all of my plotting
in one convenient place....
Section Y:
Section Z: