Page MenuHomePhabricator

No statistics is calculated for the "line profile"
Closed, ResolvedPublic


No statistics such as mean, stdDev, max, min etc. is calculated for the "line profile", while the histogram works fine.

How to reproduce:

  • Open an image and the measurement tool
  • draw a line
  • go to the statistics view, select the image and the line profile and see what happens: histogram works fine, statistics shows only NA

Error messages
-> GUI: "Error calculating statistics!"
-> Console: "ERROR: Runtime Exception: Masking not possible for non-closed figures"
-> Logging: "Runtime Exception: Masking not possible for non-closed figures"

It should be possible to calculate the statistics for a line, although it is a non-closed figure.

Event Timeline

The following error is thrown:

if ( !m_PlanarFigure->IsClosed() )

throw std::runtime_error( "Masking not possible for non-closed figures" );


In mitkImageStatisticsCalculator.cpp line 608

There seems to be no implementation for non-closed planar figures in the ImageStatisticsCalculator. A separate treatment of non-closed planar figures has to be implemented from scratch.

The misleading error messages in the GUI have been removed in T15359. The remaining issue of this bug is to decide if the calculation of the statistic along the intensity profile is a requested feature. Therefore, I set this bug to RFD.

This bug could not be fixed within the 2013-06 release and has medium severity. Setting target milestone to unspecified.

This bug could not be fixed within the release 2013-06. Setting its target milestone to unspecified

This bug is equivalent to T14605 and has been addressed there.