Skip to content

Unclear interaction between MixedModels & CategoricalArrays #606

Answered by palday
DarioSarra asked this question in Q&A
Discussion options

You must be logged in to vote

Thanks for providing an MWE. 😄

I suspect that this is mostly an issue of the weird ways that contrast coding plays out (especially since there are multiple interactions and a three-level variable), because all the deviances are quite similar and well within numerical tolerance:

julia> deviance(m_v1)
136481.16714620416

julia> deviance(m_v2)
136481.16714408842

julia> deviance(m_v3)
136481.16714728964

Setting your contrasts (including their reference level) explicitly is a good idea so that you remember to report them:

julia> contrasts = Dict(:Protocol => EffectsCoding(; base="90/90"), 
                        :Gen => EffectsCoding(; base="WT"),
                        :Stim => DummyCoding(…

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@DarioSarra
Comment options

@kleinschmidt
Comment options

Answer selected by DarioSarra
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants