Skip to content

theresaswayne/stereology

Repository files navigation

stereology

These scripts are designed to assist with performing unbiased stereology using the Fiji distribution of ImageJ.

Credits

These scripts were written or modified, as noted, by Theresa Swayne, Ph.D., Columbia University, New York, NY, USA. This work is licensed under a Creative Commons Attribution-NonCommercial 3.0 Unported License. If you use the material, please read the license and give credit appropriately.

The original Multipurpose Grid macro was written by Aleksandr Mironov.

Installation

For jython scripts (.py):

Use the Fiji distribution of ImageJ. Plain ImageJ does not support Jython.

To run the script from anywhere on your computer, open Fiji, File > Open, select the script, and click Run.

To install so that the command appears in the ImageJ menu, follow instructions here.

For ImageJ1 macros (.ijm):

Use Fiji or plain ImageJ.

To run the macro from anywhere on your computer, open Fiji, File > Open, select the script, and click Run.

To install so that the command appears in the ImageJ menu, follow instructions here.

For Batch commands (.txt):

Use Fiji or plain ImageJ.

Note that batch apply grid.txt requires the macro Multipurpose_gridMod.ijm to be installed in the plugins folder!

  1. Open the Batch Macro command (Process > Macro...).
  2. Set the Input folder to the folder containing the images you want to process. All files in the folder will be processed.
  3. Set the Output folder to a different folder where you would like the results to be saved.
  4. Click Open and select the .txt file.
  5. Click Process.

Sample workflow

Here is one way to use these scripts.

  1. Open a slide scanner image using VSI Reader, and create a grid of ROIs.
  2. Use random_ROI.py to select a subset of the tissue for analysis.
  3. Use batch apply grid.txt to overlay a non-destructive counting grid on the set of images.
  4. During counting, if you have a large area containing many points, use cross_count.ijm to count black crosses within the area.

Limitations

  • To change the number of fields or grid characteristics you need to edit the scripts.
  • Cross counting works only with black crosses, and assumes there is no black in the image.

Disclaimer

I have tested these at the time of uploading. If you find a bug, please contact me.

Contact

Theresa Swayne, Ph.D., Confocal and Specialized Microscopy Shared Resource, Columbia University