{"id":23801905,"url":"https://github.com/fabnavarro/covid-clustering","last_synced_at":"2026-06-23T15:30:57.230Z","repository":{"id":202676118,"uuid":"595489758","full_name":"fabnavarro/covid-clustering","owner":"fabnavarro","description":"Translation-invariant functional clustering on COVID-19 deaths adjusted on population risk factors","archived":false,"fork":false,"pushed_at":"2023-10-21T09:36:26.000Z","size":19490,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-02-21T16:39:12.850Z","etag":null,"topics":["clustering","covid","data-science","statistics","wavelet-decomposition"],"latest_commit_sha":null,"homepage":"https://hal.science/hal-03952739/","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/fabnavarro.png","metadata":{"files":{"readme":"README.md","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,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-01-31T07:23:00.000Z","updated_at":"2023-10-20T23:47:49.000Z","dependencies_parsed_at":null,"dependency_job_id":"5a25c8ad-eabd-4337-b255-1a203c172906","html_url":"https://github.com/fabnavarro/covid-clustering","commit_stats":null,"previous_names":["fabnavarro/covid-clustering"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/fabnavarro/covid-clustering","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fabnavarro%2Fcovid-clustering","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fabnavarro%2Fcovid-clustering/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fabnavarro%2Fcovid-clustering/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fabnavarro%2Fcovid-clustering/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/fabnavarro","download_url":"https://codeload.github.com/fabnavarro/covid-clustering/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fabnavarro%2Fcovid-clustering/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34696614,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-23T02:00:07.161Z","response_time":65,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["clustering","covid","data-science","statistics","wavelet-decomposition"],"created_at":"2025-01-01T22:15:45.363Z","updated_at":"2026-06-23T15:30:57.225Z","avatar_url":"https://github.com/fabnavarro.png","language":"R","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Translation-invariant functional clustering on COVID-19 deaths adjusted on population risk factors\n\nThe codes in this allow to reproduce the simulations presented in Cheam\net al. (2023) https://hal.science/hal-03952739/.\n\n## Installation\n\nThe packages `icamix`, `denpro` and `regpro`, need to be installed from\nthe source (because they were removed from the CRAN repository).\n\n``` bash\nR CMD INSTALL icamix_1.0.6.tar.gz\n```\n\n``` bash\nR CMD INSTALL denpro_0.9.2.tar.gz\n```\n\n``` bash\nR CMD INSTALL regpro_0.1.1.tar.gz\n```\n\nThe package and code execution require the installation of the following\nexternal libraries:\n\n``` r\npackage_list \u003c- c(\"regpro\",\n                  \"forcats\",\n                  \"latex2exp\",\n                  \"ggplot2\",\n                  \"fda\",\n                  \"mixtools\",\n                  \"HDclassif\",\n                  \"VGAM\",\n                  \"rwavelet\",\n                  \"BiocManager\",\n                  \"dtw\",\n                  \"NMF\",\n                  \"sClust\",\n                  \"geoR\",\n                  \"zoo\",\n                  \"stringr\",\n                  \"FactoMineR\",\n                  \"xtable\",\n                  \"gridExtra\",\n                  \"dplyr\",\n                  \"MASS\",\n                  \"VarSelLCM\")\n```\n\nInstall missing packages:\n\n``` r\nisinstall \u003c- sapply(package_list, \n                    function(x) x %in% rownames(installed.packages()))\npackage_list[isinstall]\nsapply(package_list[!isinstall], install.packages)\n```\n\nAlso install `Biobase`:\n\n``` r\nBiocManager::install(\"Biobase\")\n```\n\nThe codes are based on the `Clustfun` package, companion of the paper\nCheam et al. (2023). To install the package, execute the following\ncommand in a terminal:\n\n``` bash\nR CMD INSTALL --build Clustfun_1.0.0.tar.gz\n```\n\n## Reproduction of figures and tables\n\nBelow, all the information are gathered to reproduce the numerical\nresults presented in the paper.\n\n## Section 2 Description of the data\n\nThe dataset (`COVIDfull.rda`) was built from the files\n`COVID-19_LUT.csv` and `Policy.rds` downloaded from\n\u003chttps://github.com/CSSEGISandData/COVID-19_Unified-Dataset\u003e Badr et al.\n(2023). The data and scripts are stored in the folder\n`builddata-August2021/`.\n\nLoad `Section2.R` to reproduce Figure 1.\n\n``` r\nsource(\"Section2.r\")\n```\n\n\u003cimg src=\"README_files/figure-markdown_github/unnamed-chunk-8-1.png\" style=\"display: block; margin: auto;\" /\u003e\n\n### Section 4.1 Investigating the strengths of the proposed approach\n\nLoad `Section4_1plot.R` to reproduce Figures 2–4. The results are stored\nin `resultsSection4_1.rda` and can be re-executed running\n`Section4_1run.R`.\n\n``` r\nsource(\"Section4_1plot.r\")\n```\n\n\u003cimg src=\"README_files/figure-markdown_github/unnamed-chunk-9-1.png\" style=\"display: block; margin: auto;\" /\u003e\n\n### Section 4.2 Comparing the proposed approach with other methods used for COVID-19 studies\n\nLoad `Section4_2plot.R` to reproduce Figures 5–6. The results are stored\nin `resultsSection4_2.rda` and can be executed running\n`Section4_2run.R`.\n\n``` r\nsource(\"Section4_2plot.r\")\n```\n\n\u003cimg src=\"README_files/figure-markdown_github/unnamed-chunk-10-1.png\" style=\"display: block; margin: auto;\" /\u003e\n\n### Section 4.3 Investigating the robustness of the proposed approach\n\nLoad `Section4_3plot.R` to reproduce Figures 7–8. The results are stored\nin `resultsSection4_3.rda` and can be executed running\n`Section4_3run.R`.\n\n``` r\nsource(\"Section4_3plot.r\")\n```\n\n\u003cimg src=\"README_files/figure-markdown_github/unnamed-chunk-11-1.png\" style=\"display: block; margin: auto;\" /\u003e\n\n## Investigating geographical disparities for COVID-19\n\n### Section 5.1 Population risk factors\n\nThe results of this section can be reproduced by running `Section5-1.R`\n\n``` r\nsource(\"Section5-1.r\")\n```\n\n\u003cimg src=\"README_files/figure-markdown_github/unnamed-chunk-12-1.png\" style=\"display: block; margin: auto;\" /\u003e\n\n|                  |          1 |         2 |          3 |         4 |          5 |         6 |\n|:--------------|---------:|---------:|---------:|---------:|---------:|---------:|\n| PM2.5_PopWtd     | -0.5664122 | 0.0212741 | -0.4345034 | 0.0000121 |  0.1993832 | 0.0540271 |\n| NO2_PopWtd       |  0.7958363 | 0.3504402 |  0.3072890 | 0.0025897 |  0.0413344 | 0.6924301 |\n| WorldPop_Density |  0.5089838 | 0.0000000 | -0.0061600 | 0.9530119 | -0.3229638 | 0.0014989 |\n| Diabetes         |  0.2816515 | 0.4229080 |  0.7646337 | 0.0000000 | -0.4502616 | 0.0000053 |\n| Obesity          |  0.3336598 | 0.0466550 |  0.8527638 | 0.0000000 | -0.1532284 | 0.1403605 |\n| Smoking          | -0.2871324 | 0.1308322 | -0.0830285 | 0.4262674 |  0.8082869 | 0.0000000 |\n| COPD             |  0.4248760 | 0.0081631 |  0.7307828 | 0.0000000 |  0.1981437 | 0.0555693 |\n| CVD              |  0.3014341 | 0.5895446 |  0.8457820 | 0.0000000 |  0.0678408 | 0.5158928 |\n| HIV              |  0.3708583 | 0.0000000 |  0.2717158 | 0.0080689 | -0.6904543 | 0.0000000 |\n| Hypertension     |  0.1964048 | 0.7902244 |  0.8214016 | 0.0000000 |  0.3441937 | 0.0006817 |\n| WorldPop_65      |  0.0528298 | 0.0438759 |  0.2901739 | 0.0045538 |  0.8435328 | 0.0000000 |\n\nTable 2\n\n### Section 5.2 Clustering of the regions\n\nThe results of this section can be reproduced by running `Section5-2.R`\n\n``` r\nsource(\"Section5-2.r\")\n```\n\n\u003cimg src=\"README_files/figure-markdown_github/unnamed-chunk-14-1.png\" style=\"display: block; margin: auto;\" /\u003e\u003cimg src=\"README_files/figure-markdown_github/unnamed-chunk-14-2.png\" style=\"display: block; margin: auto;\" /\u003e\u003cimg src=\"README_files/figure-markdown_github/unnamed-chunk-14-3.png\" style=\"display: block; margin: auto;\" /\u003e\n\n|         1 |         2 |         3 |         4 |         5 |         6 |         7 |         8 |         9 |        10 |\n|-------:|-------:|-------:|-------:|-------:|-------:|-------:|-------:|-------:|-------:|\n|     1.000 |     2.000 |     3.000 |     4.000 |     5.000 |     6.000 |     7.000 |     8.000 |     9.000 |    10.000 |\n| -1377.804 | -1237.954 | -1187.733 | -1136.491 | -1114.798 | -1100.366 | -1065.731 | -1054.002 | -1055.569 | -1034.302 |\n\nTable 3\n\n|         1 |         2 |        3 |         4 |\n|----------:|----------:|---------:|----------:|\n|  338.9082 |  387.0266 | 585.7333 | 1350.0617 |\n|  387.0266 |  371.4739 | 534.7584 | 1185.9924 |\n|  585.7333 |  534.7584 | 549.9975 |  958.6426 |\n| 1350.0617 | 1185.9924 | 958.6426 | 1084.5153 |\n\nTable 4\n\n|         1 |         2 |        3 |         4 |        5 |         6 |         7 |\n|----------:|----------:|---------:|----------:|---------:|----------:|----------:|\n| 0.1407480 |  860.0971 | 397.0239 |  958.8668 | 638.6910 | 1.0105156 | 0.4079440 |\n| 0.3312190 | 1030.5490 | 414.8785 | 1219.6178 | 711.3828 | 1.1112846 | 0.3566133 |\n| 0.2196141 | 1463.0474 | 364.7504 | 1736.1461 | 350.8012 | 1.2270311 | 0.2840139 |\n| 0.3084189 | 2532.9712 | 961.5437 | 2253.9434 | 888.8210 | 0.9426568 | 0.3233362 |\n\nTable 5\n\n### Section 5.3 Clusters analysis example: disparities and policy decisions\n\nThe results of this section can be reproduced by running `Section5-3.R`\n\n``` r\nsource(\"Section5-3.r\")\n```\n\n\u003cimg src=\"README_files/figure-markdown_github/unnamed-chunk-18-1.png\" style=\"display: block; margin: auto;\" /\u003e\u003cimg src=\"README_files/figure-markdown_github/unnamed-chunk-18-2.png\" style=\"display: block; margin: auto;\" /\u003e\n\n# References\n\nBadr, Hamada S., Benjamin F. Zaitchik, Gaige H. Kerr, Nhat-Lan H.\nNguyen, Yen-Ting Chen, Patrick Hinson, Josh M. Colston, et al. 2023.\n“Unified Real-Time Environmental-Epidemiological Data for Multiscale\nModeling of the COVID-19 Pandemic.” *Scientific Data* 10 (1): 367.\n\nCheam, Amay, Marc Fredette, Matthieu Marbac, and Fabien Navarro. 2023.\n“\u003cspan class=\"nocase\"\u003eTranslation-invariant functional clustering on\nCOVID-19 deaths adjusted on population risk factors\u003c/span\u003e.” *Journal of\nthe Royal Statistical Society Series C: Applied Statistics* 72 (2):\n387–413.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffabnavarro%2Fcovid-clustering","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffabnavarro%2Fcovid-clustering","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffabnavarro%2Fcovid-clustering/lists"}