{"id":20801874,"url":"https://github.com/philips-software/latrend","last_synced_at":"2025-04-13T11:07:47.217Z","repository":{"id":40683142,"uuid":"284682175","full_name":"philips-software/latrend","owner":"philips-software","description":"An R package for clustering longitudinal datasets in a standardized way, providing interfaces to various R packages for longitudinal clustering, and facilitating the rapid implementation and evaluation of new methods","archived":false,"fork":false,"pushed_at":"2025-01-06T18:21:49.000Z","size":65905,"stargazers_count":30,"open_issues_count":19,"forks_count":5,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-04-13T11:07:45.095Z","etag":null,"topics":["cluster-analysis","clustering-evaluation","clustering-methods","data-science","longitudinal-clustering","longitudinal-data","mixture-models","r","r-package","time-series-analysis"],"latest_commit_sha":null,"homepage":"https://philips-software.github.io/latrend/","language":"R","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/philips-software.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":"CITATION.cff","codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2020-08-03T11:29:01.000Z","updated_at":"2025-02-19T17:15:14.000Z","dependencies_parsed_at":"2025-04-12T09:33:41.903Z","dependency_job_id":null,"html_url":"https://github.com/philips-software/latrend","commit_stats":{"total_commits":1304,"total_committers":3,"mean_commits":434.6666666666667,"dds":"0.31288343558282206","last_synced_commit":"42616286688219a7fff8edc02326b50ae18628b2"},"previous_names":[],"tags_count":23,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/philips-software%2Flatrend","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/philips-software%2Flatrend/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/philips-software%2Flatrend/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/philips-software%2Flatrend/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/philips-software","download_url":"https://codeload.github.com/philips-software/latrend/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248703198,"owners_count":21148118,"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":["cluster-analysis","clustering-evaluation","clustering-methods","data-science","longitudinal-clustering","longitudinal-data","mixture-models","r","r-package","time-series-analysis"],"created_at":"2024-11-17T18:24:54.453Z","updated_at":"2025-04-13T11:07:47.183Z","avatar_url":"https://github.com/philips-software.png","language":"R","funding_links":[],"categories":[],"sub_categories":[],"readme":"# latrend\n\u003c!-- badges: start --\u003e\n  [![R-CMD-check](https://github.com/philips-software/latrend/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/philips-software/latrend/actions/workflows/R-CMD-check.yaml)\n  [![CRAN](https://www.r-pkg.org/badges/version/latrend)](https://cran.r-project.org/package=latrend)\n  [![Lifecycle: maturing](https://img.shields.io/badge/lifecycle-maturing-blue.svg)](https://lifecycle.r-lib.org/articles/stages.html#maturing)\n  [![Codecov test coverage](https://codecov.io/gh/philips-software/latrend/branch/master/graph/badge.svg)](https://codecov.io/gh/philips-software/latrend?branch=master)\n  [![Downloads](https://cranlogs.r-pkg.org/badges/grand-total/latrend)](https://www.r-pkg.org/pkg/latrend)\n\u003c!-- badges: end --\u003e\nThe `latrend` package provides a framework for clustering longitudinal datasets in a standardized way. The name is short for _latent-class trend (analysis)_, referring to the discovery of hidden trends in the data. The package provides interfaces to various R packages for conducting this type of analysis.\n\nThe package is described in detail in the pre-print available at https://arxiv.org/abs/2402.14621\n\n# Features\n* **Unified cluster analysis**, independent of the underlying algorithms used. Enabling users to compare the performance of various longitudinal cluster methods on the case study at hand.\n* Supports many different methods for longitudinal clustering out of the box (see the list of supported packages below).\n* The framework consists of extensible `S4` methods based on an abstract model class, enabling **rapid prototyping** of new cluster methods or model specifications.\n* Standard **plotting** tools for model evaluation across methods (e.g., trajectories, cluster trajectories, model fit, metrics)\n* Support for many **cluster metrics** through the packages [clusterCrit](https://CRAN.R-project.org/package=clusterCrit), [mclustcomp](https://CRAN.R-project.org/package=mclustcomp), and [igraph](https://CRAN.R-project.org/package=igraph).\n* The structured and unified analysis approach enables **simulation studies** for comparing methods.\n* Standardized **model validation** for all methods through bootstrapping or k-fold cross-validation.\n\nSee the [release notes page](https://github.com/philips-software/latrend/blob/master/cran-comments.md) for the latest updates.\n\n# Installation\nThe latest release of _latrend_ can be installed from CRAN by running:\n```R\ninstall.packages(\"latrend\")\n```\n\nIt can also be installed from Github directly using:\n```R\nremotes::install_github('philips-software/latrend', ref = remotes::github_release())\n# include vignettes\nremotes::install_github('philips-software/latrend', ref = remotes::github_release(), build_vignettes = TRUE)\n```\n\n# Usage\n```R\nlibrary(latrend)\n```\nLoad and view example data.\n```R\ndata(latrendData)\nhead(latrendData)\noptions(latrend.id = \"Id\", latrend.time = \"Time\")\nplotTrajectories(latrendData, response = \"Y\")\n```\n![image](https://user-images.githubusercontent.com/8193083/226573946-70ceb35e-1f31-4c50-b707-2363909c264f.png)\n\nCluster the trajectories and plot the results.\n```R\nkmlMethod \u003c- lcMethodKML(\"Y\", nClusters = 3)\nmodel \u003c- latrend(kmlMethod, data = latrendData)\nsummary(model)\nplot(model)\n```\n![image](https://user-images.githubusercontent.com/8193083/226574139-e41a90f6-c713-4745-980f-b014a42d4aa8.png)\n\n\nIdentify solutions for 1 to 5 clusters.\n```R\nkmlMethods \u003c- lcMethods(kmlMethod, nClusters = 1:5)\nmodels \u003c- latrendBatch(kmlMethods, data = latrendData)\n```\n\nDetermine the number of clusters through one or more internal cluser metrics.\n```R\nmetric(models, c(\"WMAE\", \"BIC\"))\nplotMetric(models, c(\"Dunn\", \"ASW\", \"WMAE\", \"WRSS\", \"BIC\", \"estimationTime\"))\n```\n![image](https://user-images.githubusercontent.com/8193083/226574529-befeb9d3-3e3b-44b4-b58c-44295d528358.png)\n\n\n# Supported packages\nThe `latrend` package provides interfaces to the relevant methods for longitudinal clustering for the following packages:\n* [akmedoids](https://CRAN.R-project.org/package=akmedoids)\n* [crimCV](https://CRAN.R-project.org/package=crimCV)\n* [dtwclust](https://CRAN.R-project.org/package=dtwclust)\n* [fda](https://CRAN.R-project.org/package=fda)\n* [flexmix](https://CRAN.R-project.org/package=flexmix)\n* [funFEM](https://CRAN.R-project.org/package=funFEM)\n* [kml](https://CRAN.R-project.org/package=kml)\n* [lcmm](https://CRAN.R-project.org/package=lcmm)\n* [mclust](https://CRAN.R-project.org/package=mclust)\n* [mixAK](https://CRAN.R-project.org/package=mixAK)\n* [mixtools](https://CRAN.R-project.org/package=mixtools)\n\n# Contributing\nWe appreciate any contributions in the form of ideas, feature requests, bug reports, bug fixes, documentation improvements, code reformatting, and code submissions. Please see the [Contributing guide](https://philips-software.github.io/latrend/CONTRIBUTING.html).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fphilips-software%2Flatrend","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fphilips-software%2Flatrend","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fphilips-software%2Flatrend/lists"}