"RunMacro.java" is an an example program that shows how to run an 
ImageJ macro  from the command line with no GUI. It requires the 
1.33c ij.jar, which is in this folder.

To compile:
  javac -classpath ij.jar RunMacro.java

To run:
  java -cp ij.jar:. RunMacro analyze.txt Blobs.tif (Unix)
  java -cp ij.jar;. RunMacro analyze.txt Blobs.tif (Windows)

Four example command line macros are in this folder:

  table.txt: Generates a sine/cosine table
  analyze.txt: Runs the particle analyzer on an image
  process.txt: Analyzes all the tiff images in a folder
  count.txt: Counts the number of lines in a text file