Programming

When I worked in IT, I didn't do much programming (HTML and CSS are markup, not code), but prior to that, when I was a biologist, I did a fair amount. A lot of what I did involved either modifications to programs others had written (species/releve sorting of plant communities, harmonic mean determination of animal home ranges) or small utilities. There were two areas, however, where I did some major programming, creating what I would now call "production-quality applications".

Labels for plant specimens

Labels for museum specimens of plants (usually called "herbarium specimens", or, by the real old-timers, "exsiccatae") often contain repetitive information, and are sometimes prepared in multiple copies. Sounds like a job for a computer, right? And indeed, some of the earliest examples were written for mainframe computers as far back as the 1970s.

Mainframe programs

My first attempt, created for BOT 343 at Cal Poly Pomona, was written in Fortran for the CDC Cyber mainframe in the early 1980s. If you have any familiarity with Fortran, you're probably wondering, "WTF? It's horrible at strings, and that's most of what a label is." But at the time, Fortran was the only language I knew well (I had taken a class in it as an undergraduate, and implemented a community ecology program written in it a year or so before I began this project). (Un)fortunately, I no longer have the code for that version.

The next version was written in Cyber Basic, a language that made other Basics seem elegant, but that had robust string handling. I imbedded it in a Cyber Command Language routine to send the output to a text formatting program and thence to a special line printer that was loaded with white paper rather than greenbar. This passed through several revisions, and I even presented a poster about it at a Botanical Society of America meeting:

Clark, Curtis. 1983. Herbarium label-writing on a main-frame computer. Amer. J. Bot. 70(5), Part 2, p. 102. [pdf, 199 kb]

Here is the Basic source code for what I believe was the last version, and here is the Cyber Command Language wrapper.

Microcomputer programs

It was never easy for students to use mainframes, and as microcomputers became more common, it became harder still. My next viable attempt was a program called Scheda that I wrote in Turbo Pascal for MS-DOS, using the Turbo Pascal Database Toolbox.The program and a reasonable size data file could live on a single 3.5" diskette. Students in BOT 343 used it, and I sent copies to a number of botanists around the world Even if I had the source code still, I couldn't distribute it, because of the licensing of the toolbox, but here is the documentation file and here is the .zip archive with the executable and all the associated files.

With the advent of Windows, I had considered porting the program, but that never happened. Instead, I created an Access database and a Word merge file, which I may post here at some point.

Corn genetics

A common introductory genetics lab involves corn ears with grains that can be purple or yellow, and independently starchy (smooth) or sweet (wrinkled). Students count the number of each of the four possible combinations and compare the results against theory.

In the 1980s, graduate teaching associates in BIO 115 developed a device they called a "gametotron" that randomly revealed pink or blue beads in a clear test tube attached to a squeeze restaurant-style mustard or ketchup container. The bead colors were recorded as genotypes, and the data used for an exercise with the same outcome as the classical corn exercise.

In the 1980s, Dan Curran, at the time a graduate student, wrote a Basic program for the Cyber that performed a dihybrid cross using randomly generated gametes, and populated a Punnett Square, the common graphical device for analyzing such crosses. I rewrote the core algorithm, and then the program languished as students kept shaking their gametotrons.

I rewrote the program in Turbo Pascal, in both English and Spanish versions (I didn't know anything about localization back then; now I'd use string tables). These still run well (and blindingly fast) in a command window in Windows. I never did much to distribute them.

In 2001, as an exercise for learning Javascript, I rewrote parts of the program for the web.