-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Attribute forwarding update for Makie 0.21 (#99)
* separate out handling of kwargs forwarded to individual component plots * tests + fix * pull out test setup into own file * compat + version bump
- Loading branch information
Showing
6 changed files
with
88 additions
and
135 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
name = "MixedModelsMakie" | ||
uuid = "b12ae82c-6730-437f-aff9-d2c38332a376" | ||
authors = ["Phillip Alday <[email protected]>", "Douglas Bates <[email protected]>", "contributors"] | ||
version = "0.4.3" | ||
version = "0.4.4" | ||
|
||
[deps] | ||
BSplineKit = "093aae92-e908-43d7-9660-e50ee39d5a0a" | ||
|
@@ -19,7 +19,7 @@ StatsBase = "2913bbd2-ae8a-5f71-8c99-4fb6c76f3a91" | |
[compat] | ||
Aqua = "0.5, 0.6" | ||
BSplineKit = "0.15, 0.16, 0.17" | ||
CairoMakie = "0.11" | ||
CairoMakie = "0.11, 0.12" | ||
DataFrames = "1" | ||
Distributions = "0.25" | ||
KernelDensity = "0.6.3" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
f = ridgeplot(b1) | ||
@test save(joinpath(OUTDIR, "ridge_sleepstudy.png"), f) | ||
|
||
f = ridgeplot(br) | ||
f = ridgeplot(br; color=(:blue, 0.3), errorbars_attributes=(; whiskerwidth=15)) | ||
@test save(joinpath(OUTDIR, "ridge_rankdeficient.png"), f) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
using Aqua | ||
using CairoMakie | ||
using DataFrames | ||
using MixedModels | ||
using MixedModelsMakie | ||
using Random # we don't depend on exact PRNG vals, so no need for StableRNGs | ||
using Statistics | ||
using Suppressor | ||
using Test | ||
using TestSetExtensions | ||
|
||
using MixedModelsMakie: confint_table | ||
|
||
const OUTDIR = joinpath(pkgdir(MixedModelsMakie), "test", "output") | ||
const progress = false | ||
|
||
function save(path, obj, args...; kwargs...) | ||
isfile(path) && rm(path) | ||
Makie.save(path, obj, args...; kwargs...) | ||
return isfile(path) | ||
end | ||
|
||
m1 = fit(MixedModel, | ||
@formula(1000 / reaction ~ 1 + days + (1 + days | subj)), | ||
MixedModels.dataset(:sleepstudy); progress) | ||
|
||
m1zc = fit(MixedModel, | ||
@formula(1000 / reaction ~ 1 + days + zerocorr(1 + days | subj)), | ||
MixedModels.dataset(:sleepstudy); progress) | ||
|
||
m2 = fit(MixedModel, | ||
@formula(rt_trunc ~ 1 + spkr * prec * load + | ||
(1 + spkr + prec + load | subj) + | ||
(1 + spkr | item)), | ||
MixedModels.dataset(:kb07); progress) | ||
|
||
b1 = parametricbootstrap(MersenneTwister(42), 500, m1; progress, | ||
optsum_overrides=(; ftol_rel=1e-6)) | ||
g1 = fit(MixedModel, | ||
@formula(r2 ~ 1 + anger + gender + btype + situ + | ||
(1 | subj) + (1 + gender | item)), | ||
MixedModels.dataset(:verbagg), | ||
Bernoulli(); progress) | ||
|
||
rng = MersenneTwister(0) | ||
x = rand(rng, 100) | ||
a = rand(rng, 100) | ||
data = (; x, x2=1.5 .* x, a, y=rand(rng, [0, 1], 100), g=repeat('A':'T', 5)) | ||
mr = @suppress fit(MixedModel, @formula(y ~ a + x + x2 + (1 | g)), data; progress) | ||
br = @suppress parametricbootstrap(MersenneTwister(42), 500, mr; progress, | ||
optsum_overrides=(; ftol_rel=1e-6)) |
2c412a5
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@JuliaRegistrator register
2c412a5
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Registration pull request created: JuliaRegistries/General/112242
Tip: Release Notes
Did you know you can add release notes too? Just add markdown formatted text underneath the comment after the text
"Release notes:" and it will be added to the registry PR, and if TagBot is installed it will also be added to the
release that TagBot creates. i.e.
To add them here just re-invoke and the PR will be updated.
Tagging
After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.
This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via: