Region feature "heterogeneity"
Can you provide a more detailed explanation of the region feature, Heterogeneity? Can the user adjust the intensity range deviation?
0
Answers
-
Region Heterogeneity is the percentage of pixels in a region for which the monochrome intensity differs by more than +/- IntensityRange (a percentage of full intensity range for the image's pixel type) from the the mean intensity (Intensity, Mean measurement). The IntensityRange default value is 10% of the image RangeMax-RangeMin. Unfortunately, this parameter is not currently exposed in the user-interface. And so far I haven't been able to think up a practical way for a user to change it, but I'll post a solution if I come up with some way to do it.
0 -
Here's a macro that will update the Heterogeneity measurement with a new IntensityRange:
Public Sub SetIntensityRange()<br> Dim imgA As McImage = ThisApplication.ActiveImage<br> Dim mmData As MediaCy.Addins.Measurements.McMMData = imgA.MeasurementsData<br> If ( mmData Is Nothing OrElse mmData.Count = 0 ) Then Exit Sub<br> Dim mcregionsMeas As MediaCy.IQL.Features.McRegions = mmData.SubFeature(0).GetFeatures<br> If (mcregionsMeas Is Nothing) Then Exit Sub<br> Dim hetMeas As MediaCy.IQL.Features.IMcHeterogeneity = mcregionsMeas.mRgnHeterogeneity<br> Dim nIRng As Integer = CInt(hetMeas.IntensityRange)<br> Dim nIRngNew As Integer = InputBox("New Heterogeneity Intensity Range (%): ", "Hetrogeneity Range", CStr(nIRng))<br> hetMeas.IntensityRange = CDbl(nIRngNew)<br> mmData.ShowMeasurements(MediaCy.Addins.Measurements.McMeasurements.enumShowMeasFlags.smfShowAll) 'update results display<br>End Sub 'SetIntensityRange
You will need a reference to Extensibility and MediaCy.Addins.Measurements in your macro references.
Unfortunately, the new IntensityRange will not persist when a new Count is done, so this is only useful for exploring how the parameter affects the measurement result.
0 -
thank you for the code. very helpful0
Categories
- All Categories
- 961 Image-Pro v9 and higher
- 9 Image-Pro FAQs
- 18 Image-Pro Download & Install
- 448 Image-Pro General Discussions
- 486 Image-Pro Automation (Macros, Apps, Reports)
- 20 AutoQuant Deconvolution
- 2 AutoQuant Download & Install
- 18 AutoQuant General Discussions
- 195 Image-Pro Plus v7 and lower
- 3 Image-Pro Plus Download & Install
- 106 Image-Pro Plus General Discussions
- 86 Image-Pro Plus Automation with Macros
- 19 Legacy Products
- 16 Image-Pro Premier 3D General Discussions
- 26 Image-Pro Insight General Discussions