diff --git a/Project.toml b/Project.toml index 3649e2bc..1282df2c 100644 --- a/Project.toml +++ b/Project.toml @@ -3,7 +3,7 @@ uuid = "c7f686f2-ff18-58e9-bc7b-31028e88f75d" keywords = ["markov chain monte carlo", "probablistic programming"] license = "MIT" desc = "Chain types and utility functions for MCMC simulations." -version = "4.2.4" +version = "4.3.0" [deps] AbstractFFTs = "621f4979-c628-5d54-868e-fcf4e3e8185c" @@ -36,7 +36,7 @@ Formatting = "0.4" IteratorInterfaceExtensions = "0.1.1, 1" MLJModelInterface = "0.3.5" NaturalSort = "1" -PrettyTables = "0.9" +PrettyTables = "0.9, 0.10" RecipesBase = "0.7, 0.8, 1.0" SpecialFunctions = "^0.8, 0.9, 0.10" StatsBase = "0.32, 0.33" @@ -49,11 +49,10 @@ DataFrames = "a93c6f00-e57d-5684-b7b6-d8193f3e46c0" FFTW = "7a1cc6ca-52ef-59f5-83cd-3a7055c09341" KernelDensity = "5ab0869b-81aa-558d-bb23-cbf5423bbe9b" Logging = "56ddb016-857b-54e1-b83d-db4d58db5568" -MLJModels = "d491faf4-2d78-11e9-2867-c94bc002c0b7" +Pkg = "44cfe95a-1eb2-52ea-b672-e2afdf69b78f" StatsPlots = "f3b207a7-027a-5e70-b257-86293d7955fd" Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40" UnicodePlots = "b8865327-cd53-5732-bb35-84acbb429228" -XGBoost = "009559a3-9522-5dbb-924b-0b6ed2b22bb9" [targets] -test = ["DataFrames", "FFTW", "KernelDensity", "Logging", "StatsPlots", "Test", "UnicodePlots", "MLJModels", "XGBoost"] +test = ["DataFrames", "FFTW", "KernelDensity", "Logging", "StatsPlots", "Test", "UnicodePlots", "Pkg"] diff --git a/test/rstar_tests.jl b/test/rstar_tests.jl index 562f1ea2..e046e7e8 100644 --- a/test/rstar_tests.jl +++ b/test/rstar_tests.jl @@ -1,6 +1,6 @@ using MCMCChains -using Tables using MLJModels +using MLJXGBoostInterface using Test N = 1000 @@ -12,7 +12,6 @@ chn = Chains(val, colnames, Dict(:internals => internal_colnames)) classif = @load XGBoostClassifier() @testset "R star test" begin - # Compute R* statistic for a mixed chain. R = rstar(classif, randn(N,2), rand(1:3,N)) diff --git a/test/runtests.jl b/test/runtests.jl index 277ecd9e..b4331a22 100644 --- a/test/runtests.jl +++ b/test/runtests.jl @@ -1,3 +1,4 @@ +using Pkg using Test using Random @@ -5,10 +6,14 @@ using Random Random.seed!(0) @testset "MCMCChains" begin - - # run tests related to rstar statistic - println("Rstar") - @time include("rstar_tests.jl") + # MLJXGBoostInterface requires Julia >= 1.3 + if VERSION >= v"1.3" + # run tests related to rstar statistic + println("Rstar") + Pkg.add("MLJModels") + Pkg.add("MLJXGBoostInterface") + @time include("rstar_tests.jl") + end # run tests for effective sample size println("ESS")