Skip to content

Commit b61999b

Browse files
committed
Update PosteriorStats tests
1 parent 35493f3 commit b61999b

File tree

1 file changed

+14
-14
lines changed

1 file changed

+14
-14
lines changed

test/posteriorstats.jl

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -53,11 +53,11 @@ _as_array(x::AbstractArray) = x
5353
if length(sz) == 2
5454
@test issetequal(
5555
keys(loo_result1.pointwise),
56-
(:elpd, :elpd_mcse, :p, :reff, :pareto_shape),
56+
(:elpd, :se_elpd, :p, :reff, :pareto_shape),
5757
)
5858
else
5959
@test loo_result1.pointwise.elpd == loo_result.pointwise.elpd
60-
@test loo_result1.pointwise.elpd_mcse == loo_result.pointwise.elpd_mcse
60+
@test loo_result1.pointwise.se_elpd == loo_result.pointwise.se_elpd
6161
@test loo_result1.pointwise.p == loo_result.pointwise.p
6262
@test loo_result1.pointwise.reff == loo_result.pointwise.reff
6363
@test loo_result1.pointwise.pareto_shape ==
@@ -71,21 +71,21 @@ _as_array(x::AbstractArray) = x
7171
loo_result2 = loo(idata2)
7272
@test loo_result2.estimates.elpd loo_result1.estimates.elpd atol = atol_perm
7373
@test isapprox(
74-
loo_result2.estimates.elpd_mcse,
75-
loo_result1.estimates.elpd_mcse;
74+
loo_result2.estimates.se_elpd,
75+
loo_result1.estimates.se_elpd;
7676
nans=true,
7777
atol=atol_perm,
7878
)
7979
@test loo_result2.estimates.p loo_result1.estimates.p atol = atol_perm
8080
@test isapprox(
81-
loo_result2.estimates.p_mcse,
82-
loo_result1.estimates.p_mcse;
81+
loo_result2.estimates.se_p,
82+
loo_result1.estimates.se_p;
8383
nans=true,
8484
atol=atol_perm,
8585
)
8686
@test isapprox(
87-
loo_result2.pointwise.elpd_mcse,
88-
loo_result1.pointwise.elpd_mcse;
87+
loo_result2.pointwise.se_elpd,
88+
loo_result1.pointwise.se_elpd;
8989
nans=true,
9090
atol=atol_perm,
9191
)
@@ -205,15 +205,15 @@ _as_array(x::AbstractArray) = x
205205
waic_result2 = waic(idata2)
206206
@test waic_result2.estimates.elpd waic_result1.estimates.elpd atol = atol_perm
207207
@test isapprox(
208-
waic_result2.estimates.elpd_mcse,
209-
waic_result1.estimates.elpd_mcse;
208+
waic_result2.estimates.se_elpd,
209+
waic_result1.estimates.se_elpd;
210210
nans=true,
211211
atol=atol_perm,
212212
)
213213
@test waic_result2.estimates.p waic_result1.estimates.p atol = atol_perm
214214
@test isapprox(
215-
waic_result2.estimates.p_mcse,
216-
waic_result1.estimates.p_mcse;
215+
waic_result2.estimates.se_p,
216+
waic_result1.estimates.se_p;
217217
nans=true,
218218
atol=atol_perm,
219219
)
@@ -228,7 +228,7 @@ _as_array(x::AbstractArray) = x
228228
)
229229
result1 = compare(eight_schools_data)
230230
result2 = compare(map(loo, eight_schools_data))
231-
@testset for k in (:name, :rank, :elpd_diff, :elpd_diff_mcse, :weight)
231+
@testset for k in (:name, :rank, :elpd_diff, :se_elpd_diff, :weight)
232232
@test getproperty(result1, k) == getproperty(result2, k)
233233
end
234234
end
@@ -267,7 +267,7 @@ _as_array(x::AbstractArray) = x
267267

268268
stats = @inferred SummaryStats summarize(data, mean, std; name="Stats")
269269
@test stats.name == "Stats"
270-
@test stats[:parameter] == var_names
270+
@test stats[:label] == var_names
271271
@test stats[:mean] map(mean, slices)
272272
@test stats[:std] map(std, slices)
273273

0 commit comments

Comments
 (0)