Closed ablaom closed 1 year ago
Seeing this too. Causing failure in this PR: https://github.com/MilesCranmer/SymbolicRegression.jl/pull/195
@juliohm
I think we should get rid of WeightedMean in future releases to avoid confusion. Most people are interested in WeightedSum. You can compare the two implementations here:
So basically, WeightedMean = WeightedSum / nobs, the same way Mean = Sum / nobs
I will mark the issue as invalid, and we can work on a next breaking release that removes the AggMode submodule and also removes these specific cases with AggMode.WeightedMean and AggMode.None
Trying out 0.9.
What am I missing here?
But the absolute value of the differences of prediction and ground truth are
[1, 2, 4]
, so weighted mean =(4*1 + 2*2 + 1*4)/(4 + 2 + 1) = 12/7
, no?Also, I don't understand the
normalize
option? Isn't a weighted mean invariant to rescaling of the weights?If I do change
normalize=true
I still don't get12/7≈1.71
:which is
4/7
, the mean of the weighted sum.