Skip to content

Commit

Permalink
Use median instead of mean in a test to lower the variance of the
Browse files Browse the repository at this point in the history
estimate a bit
  • Loading branch information
torfjelde committed Sep 26, 2024
1 parent 4088a9f commit 03e84b3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion test/abstractmcmc.jl
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@

# Check that means are roughly okay.
params_resolved = map(first MCMCTempering.getparams, transitions_resolved_inner)
@test vec(mean(params_resolved; dims=2)) [5.0, 5.0] atol = 0.4
@test vec(median(params_resolved; dims=2)) [5.0, 5.0] atol = 0.4

# A composition of `SwapSampler` and `MultiSampler` has special `AbstractMCMC.bundle_samples`.
@testset "bundle_samples with Vector" begin
Expand Down

0 comments on commit 03e84b3

Please sign in to comment.