Skip to content

Commit 4990041

Browse files
0-1-0 Release Candidate (#26)
* expand description * have gee_fit be internal function * update license year * fix urls * seed readme to avoid changes * fix doi link * update parsnip vesions * Increment version number to 0.1.0 * typo in readme * CoC link forwarding Co-authored-by: Max Kuhn <mxkuhn@gmail.com>
1 parent 9898845 commit 4990041

8 files changed

Lines changed: 43 additions & 30 deletions

File tree

DESCRIPTION

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,18 @@
11
Package: multilevelmod
22
Title: Model Wrappers for Multi-Level Models
3-
Version: 0.0.0.9000
3+
Version: 0.1.0
44
Authors@R: c(
55
person("Max", "Kuhn", , "max@rstudio.com", role = c("aut", "cre"),
66
comment = c(ORCID = "0000-0003-2402-136X")),
77
person("RStudio", role = "cph")
88
)
99
Description: Bindings for hierarchical regression models for use with the
10-
'parsnip' package.
10+
'parsnip' package. Models include longitudinal generalized linear models
11+
(Liang and Zeger, 1986) <doi:10.1093/biomet/73.1.13>, and mixed-effect
12+
models (Pinheiro and Bates) <doi:10.1007/978-1-4419-0318-1_1>.
1113
License: MIT + file LICENSE
1214
Depends:
13-
parsnip (>= 0.1.7),
15+
parsnip (>= 0.2.0),
1416
R (>= 2.10)
1517
Imports:
1618
dplyr,
@@ -31,14 +33,13 @@ Suggests:
3133
tidymodels
3234
VignetteBuilder:
3335
knitr
34-
Remotes:
35-
tidymodels/parsnip#631
3636
Config/Needs/website:
37+
tidymodels/tidymodels
3738
tidyverse/tidytemplate
3839
Encoding: UTF-8
3940
Language: en-US
4041
LazyData: true
4142
Roxygen: list(markdown = TRUE)
4243
RoxygenNote: 7.1.2
43-
URL: ttps://github.com/tidymodels/multilevelmod,
44+
URL: https://github.com/tidymodels/multilevelmod,
4445
http://multilevelmod.tidymodels.org/

LICENSE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
YEAR: 2020
1+
YEAR: 2022
22
COPYRIGHT HOLDER: RStudio

R/gee.R

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,8 @@ gee_formula <- function(f) {
7070
#' Also, because of issues with the `gee()` function, a supplementary call to
7171
#' `glm()` is needed to get the rank and QR decomposition objects so that
7272
#' `predict()` can be used.
73+
#' @return A gee object
74+
#' @keywords internal
7375
#' @export
7476
gee_fit <- function(formula, data, family = gaussian, ...) {
7577
f <- gee_formula(formula)

README.Rmd

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,8 @@ knitr::opts_chunk$set(
1616
# multilevelmod
1717

1818
<!-- badges: start -->
19-
[![Lifecycle: experimental](https://img.shields.io/badge/lifecycle-experimental-orange.svg)](https://www.tidyverse.org/lifecycle/#experimental)
20-
[![CRAN status](https://www.r-pkg.org/badges/version/multilevelmod)](https://CRAN.R-project.org/package=multilevelmod)
21-
[![Codecov test coverage](https://codecov.io/gh/topepo/multilevelmod/branch/main/graph/badge.svg)](https://codecov.io/gh/topepo/multilevelmod?branch=main)
19+
[![Lifecycle: experimental](https://img.shields.io/badge/lifecycle-experimental-orange.svg)](https://lifecycle.r-lib.org/articles/stages.html)
20+
[![Codecov test coverage](https://codecov.io/gh/topepo/multilevelmod/branch/main/graph/badge.svg)](https://app.codecov.io/gh/topepo/multilevelmod?branch=main)
2221
[![R-CMD-check](https://github.com/tidymodels/multilevelmod/workflows/R-CMD-check/badge.svg)](https://github.com/tidymodels/multilevelmod/actions)
2322
<!-- badges: end -->
2423

@@ -33,7 +32,6 @@ multilevelmod enables the use of multi-level models (a.k.a mixed-effects models,
3332
You can install the released version of multilevelmod from [CRAN](https://CRAN.R-project.org) with:
3433

3534
``` r
36-
# not yet
3735
install.packages("multilevelmod")
3836
```
3937

@@ -43,7 +41,7 @@ For the development version:
4341
devtools::install_github("tidymodels/multilevelmod")
4442
```
4543

46-
## Avaliable Engines
44+
## Available Engines
4745

4846
The multilevelmod package provides engines for the models in the following table.
4947

@@ -77,6 +75,7 @@ The `sleepstudy` data is used as an example:
7775

7876
```{r sleep-lme}
7977
library(multilevelmod)
78+
set.seed(1234)
8079
data(sleepstudy, package = "lme4")
8180
8281
mixed_model_spec <- linear_reg() %>% set_engine("lmer")
@@ -103,13 +102,13 @@ hier_model_fit
103102

104103
## Contributing
105104

106-
This project is released with a [Contributor Code of Conduct](https://contributor-covenant.org/version/2/0/CODE_OF_CONDUCT.html). By contributing to this project, you agree to abide by its terms.
105+
This project is released with a [Contributor Code of Conduct](https://www.contributor-covenant.org/version/2/0/CODE_OF_CONDUCT.html). By contributing to this project, you agree to abide by its terms.
107106

108-
- For questions and discussions about tidymodels packages, modeling, and machine learning, please [post on RStudio Community](https://rstd.io/tidymodels-community).
107+
- For questions and discussions about tidymodels packages, modeling, and machine learning, please [post on RStudio Community](https://community.rstudio.com/new-topic?category_id=15&tags=tidymodels,question).
109108

110109
- If you think you have encountered a bug, please [submit an issue](https://github.com/tidymodels/multilevelmod/issues).
111110

112-
- Either way, learn how to create and share a [reprex](https://rstd.io/reprex) (a minimal, reproducible example), to clearly communicate about your code.
111+
- Either way, learn how to create and share a [reprex](https://community.rstudio.com/new-topic?category_id=15&tags=tidymodels,question) (a minimal, reproducible example), to clearly communicate about your code.
113112

114113
- Check out further details on [contributing guidelines for tidymodels packages](https://www.tidymodels.org/contribute/) and [how to get help](https://www.tidymodels.org/help/).
115114

README.md

Lines changed: 13 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,9 @@
66
<!-- badges: start -->
77

88
[![Lifecycle:
9-
experimental](https://img.shields.io/badge/lifecycle-experimental-orange.svg)](https://www.tidyverse.org/lifecycle/#experimental)
10-
[![CRAN
11-
status](https://www.r-pkg.org/badges/version/multilevelmod)](https://CRAN.R-project.org/package=multilevelmod)
9+
experimental](https://img.shields.io/badge/lifecycle-experimental-orange.svg)](https://lifecycle.r-lib.org/articles/stages.html)
1210
[![Codecov test
13-
coverage](https://codecov.io/gh/topepo/multilevelmod/branch/main/graph/badge.svg)](https://codecov.io/gh/topepo/multilevelmod?branch=main)
11+
coverage](https://codecov.io/gh/topepo/multilevelmod/branch/main/graph/badge.svg)](https://app.codecov.io/gh/topepo/multilevelmod?branch=main)
1412
[![R-CMD-check](https://github.com/tidymodels/multilevelmod/workflows/R-CMD-check/badge.svg)](https://github.com/tidymodels/multilevelmod/actions)
1513
<!-- badges: end -->
1614

@@ -28,7 +26,6 @@ You can install the released version of multilevelmod from
2826
[CRAN](https://CRAN.R-project.org) with:
2927

3028
``` r
31-
# not yet
3229
install.packages("multilevelmod")
3330
```
3431

@@ -38,7 +35,7 @@ For the development version:
3835
devtools::install_github("tidymodels/multilevelmod")
3936
```
4037

41-
## Avaliable Engines
38+
## Available Engines
4239

4340
The multilevelmod package provides engines for the models in the
4441
following table.
@@ -72,6 +69,7 @@ The `sleepstudy` data is used as an example:
7269

7370
``` r
7471
library(multilevelmod)
72+
set.seed(1234)
7573
data(sleepstudy, package = "lme4")
7674

7775
mixed_model_spec <- linear_reg() %>% set_engine("lmer")
@@ -116,7 +114,7 @@ hier_model_fit
116114
#> observations: 180
117115
#> ------
118116
#> Median MAD_SD
119-
#> (Intercept) 251.5 6.4
117+
#> (Intercept) 251.3 6.5
120118
#> Days 10.5 1.7
121119
#>
122120
#> Auxiliary parameter(s):
@@ -125,9 +123,9 @@ hier_model_fit
125123
#>
126124
#> Error terms:
127125
#> Groups Name Std.Dev. Corr
128-
#> Subject (Intercept) 24
129-
#> Days 7 0.06
130-
#> Residual 26
126+
#> Subject (Intercept) 24.1
127+
#> Days 6.9 0.09
128+
#> Residual 26.0
131129
#> Num. levels: Subject 18
132130
#>
133131
#> ------
@@ -138,19 +136,20 @@ hier_model_fit
138136
## Contributing
139137

140138
This project is released with a [Contributor Code of
141-
Conduct](https://contributor-covenant.org/version/2/0/CODE_OF_CONDUCT.html).
139+
Conduct](https://www.contributor-covenant.org/version/2/0/CODE_OF_CONDUCT.html).
142140
By contributing to this project, you agree to abide by its terms.
143141

144142
- For questions and discussions about tidymodels packages, modeling,
145143
and machine learning, please [post on RStudio
146-
Community](https://rstd.io/tidymodels-community).
144+
Community](https://community.rstudio.com/new-topic?category_id=15&tags=tidymodels,question).
147145

148146
- If you think you have encountered a bug, please [submit an
149147
issue](https://github.com/tidymodels/multilevelmod/issues).
150148

151149
- Either way, learn how to create and share a
152-
[reprex](https://rstd.io/reprex) (a minimal, reproducible example),
153-
to clearly communicate about your code.
150+
[reprex](https://community.rstudio.com/new-topic?category_id=15&tags=tidymodels,question)
151+
(a minimal, reproducible example), to clearly communicate about your
152+
code.
154153

155154
- Check out further details on [contributing guidelines for tidymodels
156155
packages](https://www.tidymodels.org/contribute/) and [how to get

man/gee_fit.Rd

Lines changed: 4 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

man/multilevelmod-package.Rd

Lines changed: 8 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

vignettes/multilevelmod.Rmd

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@ predict(lme_fit, two_factor_incompl %>% filter(subject == "donor1"))
143143

144144
## Models using lmer, glmer, and stan_glmer
145145

146-
The `"lmer"`, `"glmer"`, and `"stan_glmer"` engines all use the same formula syntax for fitting multilevel models. See [Section 2.1 of _Linear Mixed Models with lme4_](https://cran.r-project.org/web/packages/lme4/vignettes/lmer.pdf) for details. In this section, we'll demonstrate using the `"lmer"` engine.
146+
The `"lmer"`, `"glmer"`, and `"stan_glmer"` engines all use the same formula syntax for fitting multilevel models. See [Section 2.1 of _Linear Mixed Models with lme4_](https://cran.r-project.org/package=lme4/vignettes/lmer.pdf) for details. In this section, we'll demonstrate using the `"lmer"` engine.
147147

148148
All of the model specification occurs in the formula; no models terms are specified via `set_engine()` (although other arguments can be passed there, as usual). To fit the same random intercept model, the syntax is:
149149

0 commit comments

Comments
 (0)