{"id":27966188,"url":"https://github.com/anestistouloumis/multgee","last_synced_at":"2025-05-07T20:17:17.064Z","repository":{"id":56934955,"uuid":"94203902","full_name":"AnestisTouloumis/multgee","owner":"AnestisTouloumis","description":"GEE solver for correlated nominal or ordinal multinomial responses using a local odds ratios parameterization.","archived":false,"fork":false,"pushed_at":"2024-03-18T21:17:47.000Z","size":4628,"stargazers_count":9,"open_issues_count":4,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-05-07T20:17:11.434Z","etag":null,"topics":["gee","multinomial","r"],"latest_commit_sha":null,"homepage":"https://CRAN.R-project.org/package=multgee","language":"R","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/AnestisTouloumis.png","metadata":{"files":{"readme":"README.Rmd","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2017-06-13T11:06:01.000Z","updated_at":"2024-01-04T23:37:22.000Z","dependencies_parsed_at":"2023-10-20T17:27:13.233Z","dependency_job_id":null,"html_url":"https://github.com/AnestisTouloumis/multgee","commit_stats":{"total_commits":108,"total_committers":3,"mean_commits":36.0,"dds":0.05555555555555558,"last_synced_commit":"20572af2db2182b4652b3254605ca57e12a36a2c"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AnestisTouloumis%2Fmultgee","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AnestisTouloumis%2Fmultgee/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AnestisTouloumis%2Fmultgee/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AnestisTouloumis%2Fmultgee/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/AnestisTouloumis","download_url":"https://codeload.github.com/AnestisTouloumis/multgee/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252949246,"owners_count":21830154,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["gee","multinomial","r"],"created_at":"2025-05-07T20:17:16.266Z","updated_at":"2025-05-07T20:17:17.050Z","avatar_url":"https://github.com/AnestisTouloumis.png","language":"R","funding_links":[],"categories":[],"sub_categories":[],"readme":"---\noutput: github_document\nreferences:\n- id: Touloumis2015\n  title: \"R Package multgee: A Generalized Estimating Equations Solver for Multinomial Responses\"\n  author:\n  - family: Touloumis\n    given: Anestis\n  container-title: Journal of Statistical Software\n  volume: 64\n  URL: 'https://www.jstatsoft.org/v064/i08'\n  issue: 8\n  page: 1-14\n  type: article-journal\n  issued:\n    year: 2015\n- id: Touloumis2013\n  title: \"GEE for Multinomial Responses Using a Local Odds Ratios Parameterization\"\n  author:\n  - family: Touloumis\n    given: Anestis\n  - family: Agresti\n    given: Alan\n  - family: Kateri\n    given: Maria\n  container-title: Biometrics\n  volume: 69\n  URL: 'https://onlinelibrary.wiley.com/doi/10.1111/biom.12054/full'\n  issue: 3\n  page: 633--640\n  type: article-journal\n  issued:\n    year: 2013\ncsl: biometrics.csl    \n---\n\n\u003c!-- README.md is generated from README.Rmd. Please edit that file --\u003e\n\n```{r setup, include=FALSE}\nknitr::opts_chunk$set(\n  tidy = TRUE,\n  collapse = TRUE,\n  comment = \"#\u003e\",\n  fig.path = \"README-\"\n)\n```\n\n\n\n\n# multgee: GEE Solver for Correlated Nominal or Ordinal Multinomial Responses\n[![Github version](`r paste0(\"https://img.shields.io/badge/GitHub%20-\", as.vector(read.dcf('DESCRIPTION')[, 'Version']),\"-orange.svg\")`)](\"commits/master\")\n[![R-CMD-check](https://github.com/AnestisTouloumis/multgee/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/AnestisTouloumis/multgee/actions/workflows/R-CMD-check.yaml)\n[![Project Status: Active The project has reached a stable, usable state and is being actively developed.](http://www.repostatus.org/badges/latest/active.svg)](http://www.repostatus.org/#active) \n\n\n\n[![CRAN Version](https://www.r-pkg.org/badges/version/multgee?color=blue)](https://cran.r-project.org/package=multgee)\n[![CRAN Downloads](https://cranlogs.r-pkg.org/badges/grand-total/multgee?color=blue)](https://cranlogs.r-pkg.org/badges/grand-total/multgee)\n[![CRAN Downloads](https://cranlogs.r-pkg.org/badges/multgee)](https://cran.r-project.org/package=multgee)\n\n\n\n\n## Installation\nYou can install the release version of `multgee`:\n\n```{r eval=FALSE}\ninstall.packages(\"multgee\")\n```\n\nThe source code for the release version of `multgee` is available on CRAN at:\n\n- https://CRAN.R-project.org/package=multgee\n\nOr you can install the development version of `multgee`:\n\n```{r eval=FALSE}\n# install.packages(\"devtools\")\ndevtools::install_github(\"AnestisTouloumis/multgee\")\n```\n\nThe source code for the development version of `multgee` is available on github at:\n\n- https://github.com/AnestisTouloumis/multgee\n\nTo use `multgee`, you should load the package as follows:\n\n```{r}\nlibrary(\"multgee\")\n```\n\n\n\n\n## Usage\nThis package provides a generalized estimating equations (GEE) solver for fitting marginal regression models with correlated nominal or ordinal multinomial responses based on a local odds ratios parameterization for the association structure [see @Touloumis2013].\n\n\nThere are two core functions to fit GEE models for correlated multinomial responses:\n\n- `ordLORgee` for an ordinal response scale. Options for the marginal model include cumulative link models or an adjacent categories logit model,\n- `nomLORgee` for a nominal response scale. Currently, the only option is a marginal baseline category logit model.\n\nThe main arguments in both functions are: \n\n- an optional data frame (`data`),\n- a model formula (`formula`),\n- a cluster identifier variable (`id`),\n- an optional vector that identifies the order of the observations within each cluster (`repeated`).\n\n\nThe association structure among the correlated multinomial responses is expressed via marginalized local odds ratios [@Touloumis2013]. The estimating procedure for the local odds ratios can be summarized as follows: For each level pair of the `repeated` variable, the available responses are aggregated across clusters to form a square marginalized contingency table. Treating these tables as independent, an RC-G(1) type model is fitted in order to estimate the marginalized local odds ratios. The `LORstr` argument determines the form of the marginalized local odds ratios structure. Since the general RC-G(1) model is closely related to the family of association models, one can instead fit an association model to each of the marginalized contingency tables by setting `LORem = \"2way\"` in the core functions. \n\n\nThere are also five useful utility functions:\n\n- `confint` for obtaining Wald--type confidence intervals for the regression parameters using the standard errors of the sandwich (`method = \"robust\"`) or of the model--based (`method = \"naive\"`) covariance matrix. The default option is the sandwich covariance matrix (`method = \"robust\"`),\n- `waldts` for assessing the goodness-of-fit of two nested GEE models based on a Wald test statistic,\n- `vcov` for obtaining the sandwich (`method = \"robust\"`) or model--based (`method = \"naive\"`) covariance matrix of the regression parameters,\n- `intrinsic.pars` for assessing whether the underlying association structure does not change dramatically across the level pairs of `repeated`,\n- `gee_criteria` for reporting commonly used criteria to select variables and/or association structure for GEE models.  \n\n\n\n## Example\nThe following R code replicates the GEE analysis presented in @Touloumis2013.\n```{r}\ndata(\"arthritis\")\nintrinsic.pars(y, arthritis, id, time, rscale = \"ordinal\")\n```\n\nThe intrinsic parameters do not differ much. This suggests that the uniform local odds ratios structure might be a good approximation for the association pattern.\n\n```{r}\nfitord \u003c- ordLORgee(formula = y ~ factor(time) + factor(trt) + factor(baseline),\n                    data = arthritis, id = id, repeated = time)\nsummary(fitord)\n```\n\n\nThe 95\\% Wald confidence intervals for the regression parameters are\n```{r}\nconfint(fitord) \n```\n\nTo illustrate model comparison, consider another model with `age` and `sex` as additional covariates:\n```{r}\nfitord1 \u003c- update(fitord, formula = . ~ . + age + factor(sex))\nwaldts(fitord, fitord1)\ngee_criteria(fitord, fitord1) \n```\nAccording to the Wald test, there is no evidence of no difference between the two models. The QICu criterion suggest that `fitord` should be preferred over `fitord1`.\n\n\n## Getting help\nThe statistical methods implemented in `multgee` are described in @Touloumis2013. A detailed description of the functionality of `multgee` can be found in @Touloumis2015. Note that an updated version of this paper also serves as a vignette: \n\n```{r eval=FALSE}\nbrowseVignettes(\"multgee\")\n```\n\n\n\n\n## How to cite\n```{r echo=FALSE, comment=\"\"}\nprint(citation(\"multgee\"), bibtex = TRUE)\n```\n\n\n\n\n# References\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fanestistouloumis%2Fmultgee","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fanestistouloumis%2Fmultgee","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fanestistouloumis%2Fmultgee/lists"}