-
-
Notifications
You must be signed in to change notification settings - Fork 64
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Traditional statistical weighting #129
Comments
Continuing #131: So the rough plan would be to have struct OnlineWeight <: Weight end
total_weight::Float64
end
function fit!(stat::MyMean{OnlineWeight}, obs, wt)
total_weight = stat.weight.total_weight + wt
μ = stat.μ * (total_weight - wt)/wt + obs * wt/total_weight
stat.μ = μ
stat.weight.total_weight = total_weight
stat.n += 1
end ? |
The biggest hurdle is that an |
I really would like to have this! |
This is still WIP: https://github.com/gdkrmr/WeightedOnlineStats.jl |
I would love this too... @gdkrmr, gonna try and use your WeightedOnlineStats.jl |
Add the option to put in StatsBase-like weights.
The text was updated successfully, but these errors were encountered: