#4750 closed defect (fixed)
Histogram calculation should ignore no data values
Reported by: | Sam Gillingham | Owned by: | warmerdam |
---|---|---|---|
Priority: | normal | Milestone: | 1.11.0 |
Component: | GDAL_Raster | Version: | 1.9.1 |
Severity: | normal | Keywords: | histogram nodata |
Cc: |
Description
Currently GDALRasterBand::ComputeStatistics ignores no data values but GDALRasterBand::GetHistogram does not. This is inconsistent and confusing. It impacts applications that estimate median/mode etc from the histogram. Attached proposed patch uses the same mechanism as ComputeStatistics to ignore no data values.
Attachments (2)
Change History (6)
by , 12 years ago
Attachment: | gdalrasterband.cpp.histignore.1.9.1.patch added |
---|
by , 11 years ago
Attachment: | gdalrasterband.cpp.patch added |
---|
Patch for GetHistogram that ignores no data values. Updated against trunk
comment:2 by , 11 years ago
Just updated this patch against trunk. Any chance this could be included in GDAL 2.0? Seems this might be a suitable time to fix this inconsistency with ComputeStatistics()...
comment:3 by , 11 years ago
Milestone: | → 2.0 |
---|---|
Resolution: | → fixed |
Status: | new → closed |
Committed in trunk in r26192. Thanks
comment:4 by , 10 years ago
Milestone: | 2.0 → 1.11.0 |
---|
Note:
See TracTickets
for help on using tickets.
Patch for GetHistogram that ignores no data values