-
Notifications
You must be signed in to change notification settings - Fork 4
Closed
Description
I am using NaNStatistics v0.6.52 and encountered a bug with nanmean. See the minimal working example below.
using NaNStatistics
using Test
# Expected
small_data = fill(NaN, 2, 3, 4)
nan_mean_small_data = nanmean(small_data, dims = 2)
@test isequal(nan_mean_small_data, fill(NaN, 2, 1, 4)) # pass
# Not expected
large_data = fill(NaN, 180, 10, 360)
nan_mean_large_data = nanmean(large_data, dims = 2)
@test isequal(nan_mean_large_data, fill(NaN, 180, 1, 360)) # failThe values in nan_mean_large_data are all zeros instead of NaNs.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels