Unlocking Various Technical Skills in ImageJ

Unlocking Various Technical Skills in ImageJ

Reprint with permission: Spiral – Clinical Doctor Research Growth Platform

Unlocking Various Technical Skills in ImageJ

ImageJ (Official website: https://imagej.nih.gov/ij/) is a public image processing software based on Java, developed by the National Institutes of Health (NIH). It is a powerful free software that plays a very important role in biological and medical image analysis.

The image below is the interface of the ImageJ official website. Download the corresponding software according to your system under Download. ImageJ is compatible with Mac OS X, Linux, and Windows systems (not limited by computer system). Counting is very common in biomedical fields, let’s explore counting with ImageJ together.

1

Manual Counting

Unlocking Various Technical Skills in ImageJ

Counting with the Multi-Point Tool

Open the ImageJ software, go to File, Open to open the image to be analyzed:

Unlocking Various Technical Skills in ImageJ

Click the Unlocking Various Technical Skills in ImageJ point tool, right-click, and select Unlocking Various Technical Skills in ImageJ Multi-Point Tool, manually click to count:

Unlocking Various Technical Skills in ImageJ

Click Analyze –> Measure, and you can see that the current count is 23. Save the image.

Cell Counter for Cell Counting

Click Plugins –> Analyze –> Cell Counter, the interface is as follows:

Unlocking Various Technical Skills in ImageJUnlocking Various Technical Skills in ImageJ

Click Initialize to count different types of cells:

Unlocking Various Technical Skills in ImageJ

You can see that the counts for Type1, Type2, and Type3 are 2, 1, and 2 respectively. This method can count different types of cells simultaneously. Click Results in Cell Counter to see the number of different cell types. Compared to the Multi-Point manual counting method, Cell Counter can count different cell types.

Unlocking Various Technical Skills in ImageJ

2

Regular Automatic Counting Process

Open ImageJ software, go to File –> Open to open the image that needs to be analyzed:

Unlocking Various Technical Skills in ImageJUnlocking Various Technical Skills in ImageJ

Image –> Type -> 8-bit (change to grayscale image)

Unlocking Various Technical Skills in ImageJ

Image -> Adjust -> Threshold to adjust the threshold, red represents selected, so that all cell nuclei are selected. In the Dapi image, the threshold is 11-255 –> Apply

Unlocking Various Technical Skills in ImageJ

Note: The background of the fluorescence image is black, so the option below for Dark background needs to be checked, indicating that the background is black.

After Apply, the image is:

Unlocking Various Technical Skills in ImageJ

For the bean image, the threshold range is 37-255->Apply

Unlocking Various Technical Skills in ImageJ

After Apply, the image is:

Unlocking Various Technical Skills in ImageJ

From the image after Apply, it can be seen that many cells are connected together, and during cell counting, they need to be separated.

Unlocking Various Technical Skills in ImageJ

Process -> Binary -> watershed (the watershed segmentation method, separates connected cells)

The segmentation effect is as follows:

Unlocking Various Technical Skills in ImageJ

Analyze -> Analyze particles, the interface is as follows:

Unlocking Various Technical Skills in ImageJ

Size(pixel^2): By default 0-Infinity (infinity), meaning that the size of the cells to be counted falls within which range. For this Dapi image, the cell size is selected as 500-Infinity, filtering out non-target spots. Here we need to try a few minimum values based on the target cell size to get accurate cell counting results.

Circularity: Represents circularity, the closer to 1, the closer to circular, we do not need to change this.

Show: I habitually choose outlines to show the counted cell contours and the numbered counted cells, there are other options. Nothing means that the image and overlay will not display; Bare outlines show only the cell outlines without numbering.

Ellipses: Makes the result contours match the best elliptical shape.

Masks: Fills particles as an 8-bit black and white image.

Count Masks: Fills particle contours as a 16-bit image.

Overlay Outlines: Displays measurement particle contours in the overlay image.

Overlay Masks: Displays measurement particle contours in the overlay image, generally outlines are sufficient for cell counting.

The following option is Display results, to show results.

Clear Results:Repeated measurements of previously measured results will be cleared;

Summarize:Summarizes results;

Exclude on edges:Excludes cells touching the edges from counting;

Include holes: Internal holes will be included;

Add to Manager:Measures particles added to the ROI manager;

Record Starts:Allows plugins and macro functions to recreate particle contours;

In Situ Show:In situ display, the original image will be replaced by the binary image specified in the drop-down menu (black or white).

The results obtained are as follows:

Unlocking Various Technical Skills in ImageJ

Unlocking Various Technical Skills in ImageJ

The bean results are as follows:

Unlocking Various Technical Skills in ImageJUnlocking Various Technical Skills in ImageJ

Application Example:Unlocking Various Technical Skills in ImageJ

Open the image: Unlocking Various Technical Skills in ImageJ

Convert RGB image to grayscale: Image –> Type –> 8-bit.

Unlocking Various Technical Skills in ImageJ

Select threshold: Image–>Adjust–>Threshold–>threshold selection–>red represents selected. The highlighted area at the edge of the dish affects the selection of colonies, use the elliptical Unlocking Various Technical Skills in ImageJ box to roughly select the area where the colony is located.

Analyze–>Analyze particles, select as follows, click OK to get the counting result:

Unlocking Various Technical Skills in ImageJ

3

Automatic Counting of Multi-Porous Materials with ImageJ

Open ImageJ software, go to File–>Open to open the image that needs to be analyzed:

Unlocking Various Technical Skills in ImageJ

Process–>FFT–>Bandpass Filter–>OK:

Unlocking Various Technical Skills in ImageJUnlocking Various Technical Skills in ImageJ

Process–>Find Maxiam–>Output type select Count to get counting data:

Unlocking Various Technical Skills in ImageJ

Unlocking Various Technical Skills in ImageJ

4

RetFM-J Automatic Counting

Open ImageJ software, go to File–>Open to open the image that needs to be analyzed:

Unlocking Various Technical Skills in ImageJ

Plugins–>CLAHE Enhance Contrast–>click OK

Unlocking Various Technical Skills in ImageJUnlocking Various Technical Skills in ImageJ

Plugins–>RetFM-J–>OK

Unlocking Various Technical Skills in ImageJUnlocking Various Technical Skills in ImageJ

The total number of cells is 834, along with Area, coordinates (X,Y), Perim and other indicators.

Unlocking Various Technical Skills in ImageJ

5

DAB Staining for Counting

Open ImageJ software, go to File–>Open to open the image that needs to be analyzed:

Unlocking Various Technical Skills in ImageJ

Click Plugins–>IHC tools

Unlocking Various Technical Skills in ImageJ

Select H-DAB–>Nuclei, the result is 34.

Unlocking Various Technical Skills in ImageJUnlocking Various Technical Skills in ImageJ

6

Quick Dendritic Spine Density Analysis Method and Cell Counting

Crop the dendrites to be analyzed from Golgi-stained images:

Unlocking Various Technical Skills in ImageJ

Open Fiji, go to File–>Open the dendritic spine image to be analyzed (using DG as an example)

Unlocking Various Technical Skills in ImageJ

Change the image from RGB to grayscale: Image–>Type–>8-bit;

Unlocking Various Technical Skills in ImageJ

Convert the image to a binary image: Image–>Adjust–>Threshold (adjust the threshold until the dendrites and dendritic spines are fully selected), click Apply to complete binarization. The binary image is as follows (black or white, grayscale values are 0 or 255):

Unlocking Various Technical Skills in ImageJ

Calibrate the scale: click the Straight tool Unlocking Various Technical Skills in ImageJ and draw a straight line on the scale while holding Shift.

Unlocking Various Technical Skills in ImageJ

Analyze–>Set Scale–>fill in 10 μm in the known distance–>select Global so that the scale correction is valid for all images opened this time. At this point, the step 1 measurement of 226 x 61 pixels changes to 40.36 x 10.89 μm in the image below.

Unlocking Various Technical Skills in ImageJUnlocking Various Technical Skills in ImageJ

Skeletonizing the binarized image: Process–>Binary–>Skeletonize, to obtain the skeletonized image;

Unlocking Various Technical Skills in ImageJ

Clear the scale to avoid interference with dendritic spine counting: Select the rectangular selection in the File menu to select the scale position as shown below.

Unlocking Various Technical Skills in ImageJ

Edit–>Clear (clear the content within the selection):

Unlocking Various Technical Skills in ImageJ

Analyze from the skeleton image to count the number of dendritic spines: Analyze–>Skeleton–>select as follows–>click OK.

Unlocking Various Technical Skills in ImageJ

The results obtained are:

Unlocking Various Technical Skills in ImageJ

There are 25 end-point voxels, which means there are 25 dendritic spines (blue points in the image above).

The longest path to the right can be seen to be 45.31 μm (length of the dendrite), thus the spine density for this image is 25/45.31=0.55 /μm. Generally, when counting, the vertical coordinate is Spine density (Spines /10 μm), for this image it is 5.5 /10 μm.

7

Automatic Counting of Different Shapes

Open ImageJ software, go to File–>Open to open the image that needs to be analyzed, the example image contains two different shapes, 3 triangles and 4 circles:

Unlocking Various Technical Skills in ImageJ

Image –> Type -> 8-bit (change to grayscale image)

Image -> Adjust -> Threshold to adjust the threshold, red represents selected, so that all shapes are selected:

Unlocking Various Technical Skills in ImageJ

Analyze -> Analyze particles, the interface is as follows:

Unlocking Various Technical Skills in ImageJ

As mentioned before, Circularity represents circularity, the closer to 1, the closer to circular, we can count the two shapes based on the difference in shape circularity.

For circular shapes, set Circularity to 0.8-1, Show select Outline, and the result specifically counts 4 circular shapes:

Unlocking Various Technical Skills in ImageJ

For triangular shapes, set Circularity to 0-0.5, Show select Outline, and the result specifically counts 3 triangular shapes:

Unlocking Various Technical Skills in ImageJ

Today’s sharing on ImageJ counting ends here, hope it helps everyone. Wish you all the best in publishing articles, with the left hand CNS and the right hand, and the right hand National Natural Science Foundation!

Submission email: [email protected]

Unlocking Various Technical Skills in ImageJ

Leave a Comment