From 945e5d678373eabf225b9c01ab59c5820879e891 Mon Sep 17 00:00:00 2001 From: Ayush Patnaik Date: Mon, 8 Apr 2024 11:00:07 +0530 Subject: [PATCH 1/7] Update ci.yml --- .github/workflows/ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 12287c4..763c8fa 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -17,9 +17,9 @@ jobs: - uses: actions/checkout@v2 - uses: julia-actions/setup-julia@latest with: - version: '1.7.2' + version: '1.7.3' arch: x64 - name: Install test dependencies run: julia --project=test/ -e 'using Pkg; Pkg.instantiate()' - name: Run tests - run: julia --project=. -e 'using Pkg; Pkg.test()' \ No newline at end of file + run: julia --project=. -e 'using Pkg; Pkg.test()' From df43edb0567e30b6d7d23cf3cfea3c3148b8e9bc Mon Sep 17 00:00:00 2001 From: CompatHelper Julia Date: Sat, 20 Apr 2024 00:42:16 +0000 Subject: [PATCH 2/7] CompatHelper: bump compat for Documenter to 1, (keep existing compat) --- Project.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Project.toml b/Project.toml index 651b150..434c4f7 100644 --- a/Project.toml +++ b/Project.toml @@ -21,7 +21,7 @@ Turing = "fce5fe82-541a-59a6-adf8-730c64b5f9a0" [compat] DataFrames = "1" Distributions = "0.25" -Documenter = "0.27" +Documenter = "0.27, 1" GLM = "1" NLSolversBase = "7" Optim = "1" From a1d0ffa1eadec57ebfd9c345bcba79c939c5343e Mon Sep 17 00:00:00 2001 From: CompatHelper Julia Date: Sat, 20 Apr 2024 00:42:20 +0000 Subject: [PATCH 3/7] CompatHelper: add new compat entry for HypothesisTests at version 0.11, (keep existing compat) --- Project.toml | 1 + 1 file changed, 1 insertion(+) diff --git a/Project.toml b/Project.toml index 651b150..bc5a852 100644 --- a/Project.toml +++ b/Project.toml @@ -23,6 +23,7 @@ DataFrames = "1" Distributions = "0.25" Documenter = "0.27" GLM = "1" +HypothesisTests = "0.11" NLSolversBase = "7" Optim = "1" StatsAPI = "1" From 9bf73ac9c29eb249d853244051695eb3f5d3d211 Mon Sep 17 00:00:00 2001 From: CompatHelper Julia Date: Sat, 20 Apr 2024 00:42:27 +0000 Subject: [PATCH 4/7] CompatHelper: bump compat for StatsBase to 0.34, (keep existing compat) --- Project.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Project.toml b/Project.toml index 651b150..35c0711 100644 --- a/Project.toml +++ b/Project.toml @@ -26,7 +26,7 @@ GLM = "1" NLSolversBase = "7" Optim = "1" StatsAPI = "1" -StatsBase = "0.33" +StatsBase = "0.33, 0.34" StatsModels = "0.6" Turing = "0.23.2, 0.24" julia = "1" From f237be8de528a16bf9cf905815b5e3a7e32b5f85 Mon Sep 17 00:00:00 2001 From: Shouvik Ghosh Date: Mon, 6 May 2024 11:46:30 +0530 Subject: [PATCH 5/7] Updated tests to use standard deviation --- test/numerical/bayesian/LinearRegression.jl | 8 ++++---- test/numerical/bayesian/LogisticRegression.jl | 4 ++-- test/numerical/bayesian/NegBinomialRegression.jl | 4 ++-- test/numerical/bayesian/PoissonRegression.jl | 4 ++-- 4 files changed, 10 insertions(+), 10 deletions(-) diff --git a/test/numerical/bayesian/LinearRegression.jl b/test/numerical/bayesian/LinearRegression.jl index 8758c25..3930434 100644 --- a/test/numerical/bayesian/LinearRegression.jl +++ b/test/numerical/bayesian/LinearRegression.jl @@ -11,13 +11,13 @@ tests = [ for (prior, test_mean) in tests CRRao.set_rng(StableRNG(123)) model = fit(@formula(MPG ~ HP + WT + Gear), mtcars, LinearRegression(), prior) - - @test mean(predict(model, mtcars)) ≈ test_mean + prediction = predict(model, mtcars) + @test mean(prediction) - 2 * std(prediction) <= test_mean && test_mean <= mean(prediction) + 2 * std(prediction) end gauss_test = 20.0796026428345 CRRao.set_rng(StableRNG(123)) model = fit(@formula(MPG ~ HP + WT + Gear), mtcars, LinearRegression(), Prior_Gauss(), 30.0, [0.0,-3.0,1.0], 1000) - -@test mean(predict(model, mtcars)) ≈ gauss_test \ No newline at end of file +prediction = predict(model, mtcars) +@test mean(prediction) - 2 * std(prediction) <= gauss_test && gauss_test <= mean(prediction) + 2 * std(prediction) diff --git a/test/numerical/bayesian/LogisticRegression.jl b/test/numerical/bayesian/LogisticRegression.jl index 2708cfa..07aa246 100644 --- a/test/numerical/bayesian/LogisticRegression.jl +++ b/test/numerical/bayesian/LogisticRegression.jl @@ -52,7 +52,7 @@ for (prior, prior_testcases) in tests for (link, test_mean) in prior_testcases CRRao.set_rng(StableRNG(123)) model = fit(@formula(Vote ~ Age + Race + Income + Educate), turnout, LogisticRegression(), link, prior) - - @test mean(predict(model, turnout)) ≈ test_mean + prediction = predict(model, turnout) + @test mean(prediction) - 2 * std(prediction) <= test_mean && test_mean <= mean(prediction) + 2 * std(prediction) end end \ No newline at end of file diff --git a/test/numerical/bayesian/NegBinomialRegression.jl b/test/numerical/bayesian/NegBinomialRegression.jl index 0d75a20..165d2cf 100644 --- a/test/numerical/bayesian/NegBinomialRegression.jl +++ b/test/numerical/bayesian/NegBinomialRegression.jl @@ -11,6 +11,6 @@ tests = [ for (prior, test_mean) in tests CRRao.set_rng(StableRNG(123)) model = fit(@formula(Num ~ Target + Coop + NCost), sanction, NegBinomRegression(), prior) - - @test mean(predict(model, sanction)) ≈ test_mean + prediction = predict(model, sanction) + @test mean(prediction) - 2 * std(prediction) <= test_mean && test_mean <= mean(prediction) + 2 * std(prediction) end \ No newline at end of file diff --git a/test/numerical/bayesian/PoissonRegression.jl b/test/numerical/bayesian/PoissonRegression.jl index d80b490..5ba4457 100644 --- a/test/numerical/bayesian/PoissonRegression.jl +++ b/test/numerical/bayesian/PoissonRegression.jl @@ -11,6 +11,6 @@ tests = [ for (prior, test_mean) in tests CRRao.set_rng(StableRNG(123)) model = fit(@formula(Num ~ Target + Coop + NCost), sanction, PoissonRegression(), prior) - - @test mean(predict(model, sanction)) ≈ test_mean + prediction = predict(model, sanction) + @test mean(prediction) - 2 * std(prediction) <= test_mean && test_mean <= mean(prediction) + 2 * std(prediction) end \ No newline at end of file From 3999415f22bd923569787d0349aa93bffddabbfa Mon Sep 17 00:00:00 2001 From: CompatHelper Julia Date: Sun, 19 May 2024 00:47:43 +0000 Subject: [PATCH 6/7] CompatHelper: bump compat for Turing to 0.32, (keep existing compat) --- Project.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Project.toml b/Project.toml index 651b150..602c809 100644 --- a/Project.toml +++ b/Project.toml @@ -28,7 +28,7 @@ Optim = "1" StatsAPI = "1" StatsBase = "0.33" StatsModels = "0.6" -Turing = "0.23.2, 0.24" +Turing = "0.23.2, 0.24, 0.32" julia = "1" [extras] From 559ee17d6f29e52e11e65ca5fc9a9611e5b25635 Mon Sep 17 00:00:00 2001 From: CompatHelper Julia Date: Sat, 31 Aug 2024 00:51:11 +0000 Subject: [PATCH 7/7] CompatHelper: bump compat for Turing to 0.34, (keep existing compat) --- Project.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Project.toml b/Project.toml index 1a4f94e..efd45cf 100644 --- a/Project.toml +++ b/Project.toml @@ -29,7 +29,7 @@ Optim = "1" StatsAPI = "1" StatsBase = "0.33, 0.34" StatsModels = "0.6" -Turing = "0.23.2, 0.24, 0.32" +Turing = "0.23.2, 0.24, 0.32, 0.34" julia = "1" [extras]