easystats / easystats/performance
test_performance for GAMMs
Open
Nobody has claimed this yet.
Enhancement :boom:
- Dominant language
- R
- Stars
- 1.2k
- Forks
- 109
- Avg merge
- 6h 34m
- Merged PRs (30d)
- 8
Description
Will try to look into this when I have time:
model1 <- mgcv::gamm(Sepal.Length ~ s(Petal.Width), random=list(Species = ~1), data=iris, family=inverse.gaussian(link = "identity"))
#>
#> Maximum number of PQL iterations: 20
#> iteration 1
#> iteration 2
#> iteration 3
model2 <- lme4::glmer(Sepal.Length ~ poly(Sepal.Width, 2) + (1|Species), data=iris, family=inverse.gaussian(link = "identity"))
model3 <- gamm4::gamm4(Sepal.Length ~ s(Petal.Width), random=~(1|Species), data=iris, family=inverse.gaussian(link = "identity"))
performance::test_performance(model1, model2)
#> Name | Model.model1 | Model.model2
#> ------------------------------------
#> model1 | lme | glmerMod
#> model2 | gam | glmerMod
#> Models were detected as nested and are compared in sequential order.
performance::test_performance(model1, model3)
#> Warning: Unable to extract terms from the following models:
#> model3
#> Name | Model.model1 | Model.model3
#> ------------------------------------
#> model1 | lme | glmerMod
#> model3 | gam | gam
#> Models were detected as nested and are compared in sequential order.
performance::test_performance(model2, model3)
#> Warning: Unable to extract terms from the following models:
#> model3
#> Name | Model.model2 | Model.model3
#> ------------------------------------
#> model2 | glmerMod | glmerMod
#> model3 | glmerMod | gam
#> Each model is compared to model2.
Created on 2021-02-20 by the reprex package (v0.3.0)
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the three test_performance(model1, model2), test_performance(model1, model3), and test_performance(model2, model3) examples from the issue. Compare the warnings and model tables for the mgcv::gamm, lme4::glmer, and gamm4::gamm4 cases; done requires a clearly documented or corrected outcome for GAMM comparisons.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- r
- Domain
- data, testing-qa
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100