Skip to content

Commit 954f6cf

Browse files
committed
add: extra data images and roi properties table
1 parent 1d306a7 commit 954f6cf

File tree

3 files changed

+30
-2
lines changed

3 files changed

+30
-2
lines changed

docs/Tutorials/ROI analysis.md

Lines changed: 30 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
In this tutorial we will talk about regions of interest, how to extract them and how to analyse them on an actual example.
22

3+
## Synopsis
4+
5+
## Regions' analysis
6+
37
As a reminder, to get ROIs, first you need to find ROI map. To do so, you can either use `threshold` method:
48

59
```ts
@@ -116,6 +120,29 @@ for (const roi of biggestRois) {
116120
}
117121
```
118122

123+
An image above highlights the ROIs that we found. Dark blue regions represent the particles that were above the average that we calculated. The light blue particles are the particles with an above average size and roundness above 0.9.
124+
This is just a fraction of tools that ImageJS possesses. There are multiple properties that you can discover more about in our [API features](../Features/Regions%20of%20interest/Regions%20of%20interest.md) section. Here is an example of the properties that you can use with each region of interest.
125+
126+
| Feature | Type | Value |
127+
| --------------- | ------------ | -------------------------------------------------------- |
128+
| `id` | `number` | -128 |
129+
| `origin` | `Point` | `{ row: 1547, column: 1602 }` |
130+
| `height` | `number` | 48 |
131+
| `width` | `number` | 50 |
132+
| `surface` | `number` | 1814 |
133+
| `eqpc` | `number` | 48.05888611016266 |
134+
| `ped` | `number` | 50.64165599181419 |
135+
| `feret` | `Feret` | |
136+
| `fillRatio` | `number` | 1 |
137+
| `sphericity` | `number` | 0.9489991029900559 |
138+
| `roundness` | `number` | 0.8948688625143686, |
139+
| `solidity` | `number` | 0.9674666666666667 |
140+
| `perimeter` | `number` | 159.095454429505 |
141+
| `convexHull` | `ConvexHull` | |
142+
| `mbr` | `Mbr` | |
143+
| `filledSurface` | `number` | 1814 |
144+
| `centroid` | `Point` | `{ column: 1626.577177508269, row: 1570.2546857772877 }` |
145+
119146
## Getting metadata from TIFF files
120147

121148
Another aspect worth inspecting is extracting image metadata. If an image is of TIFF format, you can extract some metadata tags that can provide additional information about an image. For instance, you can get data such as image length and width or learn about image quality through bit depth(`bitsPerSample`) or X and Y Resolutions.
@@ -173,7 +200,7 @@ DPI resolution represents the number of dots per inch. To calculate it we need t
173200
X and Y resolutions are the number of dots per inch on X and Y axes. So, if they are equal, then DPI resolution equals to one of these values. However, this value might not be measured in inches. To check that we need to look at the value of `ResolutionUnit`.
174201
If its value equals to 2 then the X and Y resolutions are measured in inches.If it's 3 then it's in centimeters and has to be converted.
175202

176-
**image of three extra data fields**
203+
![Resolution data](./images/roiAnalysis/resolutionData.png)
177204

178205
```ts
179206
const DPIResolution = 0;
@@ -193,7 +220,8 @@ if (metaTags.XResolution == metaTags.YResolution && metaTags.XResolution) {
193220
```
194221
195222
After that we need to get the magnification. In our case it is already known.
196-
**get magnification image**
223+
224+
![Magnification](./images/roiAnalysis/magnification.png)
197225
198226
All is left is to calculate it through the formula.
199227
Loading
Loading

0 commit comments

Comments
 (0)