stcorp / harp

Data harmonization toolset for scientific earth observation data
http://stcorp.github.io/harp/doc/html/index.html
BSD 3-Clause "New" or "Revised" License
55 stars 18 forks source link

Improve bin() operation when input has count=0 #290

Closed svniemeijer closed 1 year ago

svniemeijer commented 1 year ago

When count=0 and the variable has NaN values, we currently add 0 x NaN to the total sum which makes the sum become NaN. For the case where count=0 we should just skip adding anything to the total sum

svniemeijer commented 1 year ago

Can't reproduce with HARP 1.18. This might have been an artefact of the issue that got fixed with 10760700d54979c904f849d9f69e3bb7fde9460a