TUNEL Cell Counter

Redirect page


Please visit http://imagej.net/RETINA_Analysis_Toolkit to download this macro.

TUNEL Cell Counter is a free, open source macro created for ImageJ 1.49v developed by Daniel E. Maidana, M.D. and Demetrios G. Vavvas, M.D., Ph.D. at the Angiogenesis Laboratory, Massachusetts Eye and Ear Infirmary, Harvard Medical School. TUNEL Cell Counter has been validated for TUNEL assay quantitation in retinal cryo-sections using ImageJ 1.49v. This macro is able to analyze digital images obtained from fluorescence microscopes, segment the outer nuclear (ONL) and inner nuclear layer (INL), and count TUNEL-positive (TUNEL+) cells in each retinal layer. After analysis, TUNEL Cell Counter generates an array with several output variables. Additionally, the macro generates a merged image with segmented layers and quantitated cells for qualitative performance assessment.

Overview

TUNEL Cell Counter is a custom-built and validated ImageJ macro that processes digital images from retinal TUNEL assay. It segments retinal outer nuclear (ONL) and inner nuclear layers (INL) and quantitates TUNEL+ cells in these layers. The detailed validation process of this macro can be found in our Investigative Ophthalmology & Visual Science (IOVS) paper.

Before You Start

Please read carefully before using this macro.



Microscope Calibration

Replace the value 3095.975 in the source code with your microscope spatial scale.

To convert pixels to mm2, the image spatial scale is required. This can be found in the image metadata or in the microscope's bundled software.

For validation purposes, we acquired images with Axio Imager M2 fluorescence microscope (Carl Zeiss Inc., NY) using a 20x/0.8 air objective. The spatial scale was: 3095.975 pixels/mm.
  run("Set Scale...", "distance=3095.975 known=1 pixel=1 unit=mm global");
Replace the value 3095.975 in code line 32 with your microscope spatial scale.

Image Acquisition

This macro was designed for TIFF images acquired with fluorescence microscopes using a 20x/0.8 air objective. We considered this magnification the most suitable to assess a reasonably large area without missing out on details in cell morphology.

Image Processing

We suggest using consistent post-processing for all images. Regarding the blue channel, avoid saturating pixels, as this will interfere with nuclei identification. As for the green channel, reduce background as much as possible and increase exposure without saturating fragments.

Validated Dataset

The original ONL and INL image datasets used for validation purposes are available to download. These images have been accurately segmented and quantitated, and their values were validated by observers.



Important Links

Download & Install

TUNEL Cell Counter Setup

  1. Download and install ImageJ 1.49v. [1]
  2. Go to Plugins  › Macros  › Install and select the downloaded .ijm file.

TUNEL Cell Counter

Representative animation of Macro Mode. Processing time is ~5 seconds/image.
Representative animation of Batch Mode. Processing time is ~2.7 seconds/image.

Segmentation

The following processes are executed by the macro:

  • ONL Segmentation
  1. Blue channel extracted from the RGB native image.
  2. Gaussian blur filter to reduce noise and detail.
  3. Contrast enhancement.
  4. Tsai moment-preserving thresholding.
  5. Erosion iteration to achieve a fitted segmentation.
  6. Outlier pixels removed to a specific radius.
  7. Fill holes function to consolidate a solid area.
  8. Analyze particles function to measure the ONL area.
  • INL Segmentation
  1. ONL ROI subtracted from the Gaussian filtered blue channel.
  2. Tsai moment-preserving thresholding.
  3. Erosion iterations to achieve a fitted segmentation.
  4. Outlier pixels removed to a specific radius.
  5. Fill holes function used to consolidate a solid area.
  6. Analyze particles function to measure the ONL area.

Total Cells Quantitation

Find Maxima function to detect nuclei located in the ONL and INL ROIs.

TUNEL Cells Quantitation

  1. Green channel extracted from the RGB native image.
  2. Tsai moment-preserving thresholding.
  3. Watershed function to separate contiguous cells.
  4. Analyze particles function to count cells.

Macro Mode vs. Batch Mode

TUNEL Cell Counter can be executed either as a macro or as batch process, with the same results. We strongly recommend Batch Mode processing.

To execute in Macro Mode:

  1. Open an image or drag-and-drop to the application window.
  2. Go to Process  › Macro  › TUNEL Cell Counter.
  3. After processing, select "Results" window and go to File  › Save as, and save results as .xls file.

To execute in Batch Mode:

  1. Inspect the macro source code from the GitHub link.
  2. Copy the whole code to the clipboard.
  3. Go to Process  › Batch  › Macro and paste the content in the macro box.
  4. Correct microscope spatial scale in line 32 of the code, if necessary.
  5. Select Input as the folder were original images are located.
  6. Select Output as the folder were processed images will be saved.
  7. Choose JPEG as "Output Format" (recommended).
  8. Click on "Process".
  9. After processing, select "Summary" window and go to File  › Save as, and save summary as .xls file.

Macro Output

Qualitative

Example of an original TUNEL assay image (top) after macro processing (bottom).
A JPEG image is created to visualize ONL and INL segmentation and TUNEL+ cell count, as an overlay.

Quantitative

When executed in Macro Mode, the output variables are:

Outer Nuclear Layer
  • ONL Area (mm2)
  • ONL Total Cells (count)
  • ONL TUNEL+ Cells (count)
  • Ratio TUNEL+ Cells/ONL Area (count/mm2)
  • Percentage TUNEL+ Cells/ONL Total Cells (%)
Inner Nuclear Layer
  • INL Area (mm2)
  • INL Total Cells (count)
  • INL TUNEL+ Cells (count)
  • Ratio TUNEL+ Cells/INL Area (count/mm2)
  • Percentage TUNEL+ Cells/INL Total Cells (%)
A new window is generated with the output variables.

When executed in Batch Mode, ONL Area, INL Area, ONL TUNEL+ cells, and INL TUNEL+ cells are reported. These values were used for macro validation.
Ratio of TUNEL+ Cells can be calculated by any spreadsheet or statistics package.

Limitations

  1. Acquisition: The macro was designed for images acquired with a 20x/0.8 air objective. Images with higher or lower magnification will not be successfully segmented. We considered this magnification the most suitable to assess a reasonably large area without missing out cell morphology details.
  2. TUNEL staining quality: Images need to have an intense cell staining and low background noise.
  3. Image Focus: Uneven image focus will render incomplete layer segmentation.
  4. Indistinguishable Retinal Layers: The macro cannot distinguish between the ONL and INL if you can't either!
  5. Uncentered Image: For best results, acquire images centered in frame.
  6. Significant Shadowing: Shadowing will render incomplete layer segmentation.

FAQs

  1. Q: Can I modify the source code?
    • A: Yes, you can modify the code to develop new macros or plugins. Please acknowledge previous work that helped or inspired you, and share your contribution with the scientific community!
  2. Q: I used this tool for my research. How should I acknowledge it?
    • A: Please cite or reference this work as follows: Maidana DE, Tsoka P, Tian B, Dib B, Matsumoto H, Kataoka K, Lin H, Miller JW, Vavvas DG. A Novel ImageJ Macro for Automated Cell Death Quantitation in the Retina. Invest Ophthalmol Vis Sci. 2015;56:6701–6708. DOI:10.1167/ iovs.15-17599.
  3. Q: I cannot get accurate segmentation or counting. Any advice?
    • A: Check your acquisition and post-processing parameters. First, try to keep background at minimum to remove any fragments. Next, adjust saturation until cells are easily identifiable.

Future Development

Yes, we know there is a lot to improve!
We are currently working on the following issues:

  • Image acquisition: Images obtained with 10x air objective.
  • Variables in Batch Processing mode: We are modifying the code to report a complete variable list.

In case you have any comments, suggestions, or any difficulties with your images, just send us a message!

Version History

v1.1: In progress.
v1.0: First and validated working version.

External Links

  1. Massachusetts Eye and Ear Infirmary
  2. IOVS Paper

References

  1. Maidana DE, Tsoka P, Tian B, Dib B, Matsumoto H, Kataoka K, Lin H, Miller JW, Vavvas DG. A Novel ImageJ Macro for Automated Cell Death Quantitation in the Retina. Invest Ophthalmol Vis Sci. 2015;56:6701–6708. DOI:10.1167/ iovs.15-17599.